//
// Copyright (c) Microsoft Corporation. All rights reserved.
// 
//
// File generated by WinMDIDL version 8.00.0021
//

import "inspectable.idl";
import "AsyncInfo.idl";
import "EventToken.idl";
import "windowscontracts.idl";
import "Windows.Foundation.idl";
import "Windows.Devices.Geolocation.idl";

// Forward Declare
namespace Windows
{
    namespace Devices
    {
        namespace Geolocation
        {
            runtimeclass Geoposition;

            interface IGeoshape;
        }
    }
}
namespace Windows
{
    namespace Foundation
    {
        typedef struct DateTime DateTime;

        typedef struct TimeSpan TimeSpan;

        apicontract UniversalApiContract;
    }
}
namespace Windows
{
    namespace Devices
    {
        namespace Geolocation
        {
            namespace Geofencing
            {
                typedef enum GeofenceMonitorStatus GeofenceMonitorStatus;

                typedef enum GeofenceRemovalReason GeofenceRemovalReason;

                typedef enum GeofenceState GeofenceState;

                typedef enum MonitoredGeofenceStates MonitoredGeofenceStates;

                interface IGeofence;

                interface IGeofenceFactory;

                interface IGeofenceMonitor;

                interface IGeofenceMonitorStatics;

                interface IGeofenceStateChangeReport;

                runtimeclass Geofence;

                runtimeclass GeofenceMonitor;

                runtimeclass GeofenceStateChangeReport;
            }
        }
    }
}

// Generic instantiations
namespace Windows
{
    namespace Devices
    {
        namespace Geolocation
        {
            namespace Geofencing
            {
                declare
                {
                    interface Windows.Foundation.Collections.IIterable<Windows.Devices.Geolocation.Geofencing.Geofence*>;

                    interface Windows.Foundation.Collections.IIterable<Windows.Devices.Geolocation.Geofencing.GeofenceStateChangeReport*>;

                    interface Windows.Foundation.Collections.IIterator<Windows.Devices.Geolocation.Geofencing.Geofence*>;

                    interface Windows.Foundation.Collections.IIterator<Windows.Devices.Geolocation.Geofencing.GeofenceStateChangeReport*>;

                    interface Windows.Foundation.Collections.IVectorView<Windows.Devices.Geolocation.Geofencing.Geofence*>;

                    interface Windows.Foundation.Collections.IVectorView<Windows.Devices.Geolocation.Geofencing.GeofenceStateChangeReport*>;

                    interface Windows.Foundation.Collections.IVector<Windows.Devices.Geolocation.Geofencing.Geofence*>;

                    interface Windows.Foundation.TypedEventHandler<Windows.Devices.Geolocation.Geofencing.GeofenceMonitor*, IInspectable*>;
                }
            }
        }
    }
}

// Type definition
namespace Windows
{
    namespace Devices
    {
        namespace Geolocation
        {
            namespace Geofencing
            {
                [contract(Windows.Foundation.UniversalApiContract, 1.0)]
                enum GeofenceMonitorStatus
                {
                    Ready          = 0,
                    Initializing   = 1,
                    NoData         = 2,
                    Disabled       = 3,
                    NotInitialized = 4,
                    NotAvailable   = 5
                };

                [contract(Windows.Foundation.UniversalApiContract, 1.0)]
                enum GeofenceRemovalReason
                {
                    Used    = 0,
                    Expired = 1
                };

                [contract(Windows.Foundation.UniversalApiContract, 1.0)]
                [flags]
                enum GeofenceState
                {
                    None    = 0x0,
                    Entered = 0x1,
                    Exited  = 0x2,
                    Removed = 0x4
                };

                [contract(Windows.Foundation.UniversalApiContract, 1.0)]
                [flags]
                enum MonitoredGeofenceStates
                {
                    None    = 0x0,
                    Entered = 0x1,
                    Exited  = 0x2,
                    Removed = 0x4
                };

                [contract(Windows.Foundation.UniversalApiContract, 1.0)]
                [exclusiveto(Windows.Devices.Geolocation.Geofencing.Geofence)]
                [uuid(9C090823-EDB8-47E0-8245-5BF61D321F2D)]
                interface IGeofence : IInspectable
                {
                    [propget] HRESULT StartTime([out] [retval] Windows.Foundation.DateTime* value);
                    [propget] HRESULT Duration([out] [retval] Windows.Foundation.TimeSpan* value);
                    [propget] HRESULT DwellTime([out] [retval] Windows.Foundation.TimeSpan* value);
                    [propget] HRESULT Id([out] [retval] HSTRING* value);
                    [propget] HRESULT MonitoredStates([out] [retval] Windows.Devices.Geolocation.Geofencing.MonitoredGeofenceStates* value);
                    [propget] HRESULT Geoshape([out] [retval] Windows.Devices.Geolocation.IGeoshape** value);
                    [propget] HRESULT SingleUse([out] [retval] boolean* value);
                }

                [contract(Windows.Foundation.UniversalApiContract, 1.0)]
                [exclusiveto(Windows.Devices.Geolocation.Geofencing.Geofence)]
                [uuid(841F624B-325F-4B90-BCA7-2B8022A93796)]
                interface IGeofenceFactory : IInspectable
                {
                    HRESULT Create([in] HSTRING id, [in] Windows.Devices.Geolocation.IGeoshape* geoshape, [out] [retval] Windows.Devices.Geolocation.Geofencing.Geofence** geofence);
                    HRESULT CreateWithMonitorStates([in] HSTRING id, [in] Windows.Devices.Geolocation.IGeoshape* geoshape, [in] Windows.Devices.Geolocation.Geofencing.MonitoredGeofenceStates monitoredStates, [in] boolean singleUse, [out] [retval] Windows.Devices.Geolocation.Geofencing.Geofence** geofence);
                    HRESULT CreateWithMonitorStatesAndDwellTime([in] HSTRING id, [in] Windows.Devices.Geolocation.IGeoshape* geoshape, [in] Windows.Devices.Geolocation.Geofencing.MonitoredGeofenceStates monitoredStates, [in] boolean singleUse, [in] Windows.Foundation.TimeSpan dwellTime, [out] [retval] Windows.Devices.Geolocation.Geofencing.Geofence** geofence);
                    HRESULT CreateWithMonitorStatesDwellTimeStartTimeAndDuration([in] HSTRING id, [in] Windows.Devices.Geolocation.IGeoshape* geoshape, [in] Windows.Devices.Geolocation.Geofencing.MonitoredGeofenceStates monitoredStates, [in] boolean singleUse, [in] Windows.Foundation.TimeSpan dwellTime, [in] Windows.Foundation.DateTime startTime, [in] Windows.Foundation.TimeSpan duration, [out] [retval] Windows.Devices.Geolocation.Geofencing.Geofence** geofence);
                }

                [contract(Windows.Foundation.UniversalApiContract, 1.0)]
                [exclusiveto(Windows.Devices.Geolocation.Geofencing.GeofenceMonitor)]
                [uuid(4C0F5F78-1C1F-4621-BBBD-833B92247226)]
                interface IGeofenceMonitor : IInspectable
                {
                    [propget] HRESULT Status([out] [retval] Windows.Devices.Geolocation.Geofencing.GeofenceMonitorStatus* value);
                    [propget] HRESULT Geofences([out] [retval] Windows.Foundation.Collections.IVector<Windows.Devices.Geolocation.Geofencing.Geofence*>** value);
                    [propget] HRESULT LastKnownGeoposition([out] [retval] Windows.Devices.Geolocation.Geoposition** value);
                    [eventadd] HRESULT GeofenceStateChanged([in] Windows.Foundation.TypedEventHandler<Windows.Devices.Geolocation.Geofencing.GeofenceMonitor*, IInspectable*>* eventHandler, [out] [retval] EventRegistrationToken* token);
                    [eventremove] HRESULT GeofenceStateChanged([in] EventRegistrationToken token);
                    HRESULT ReadReports([out] [retval] Windows.Foundation.Collections.IVectorView<Windows.Devices.Geolocation.Geofencing.GeofenceStateChangeReport*>** value);
                    [eventadd] HRESULT StatusChanged([in] Windows.Foundation.TypedEventHandler<Windows.Devices.Geolocation.Geofencing.GeofenceMonitor*, IInspectable*>* eventHandler, [out] [retval] EventRegistrationToken* token);
                    [eventremove] HRESULT StatusChanged([in] EventRegistrationToken token);
                }

                [contract(Windows.Foundation.UniversalApiContract, 1.0)]
                [exclusiveto(Windows.Devices.Geolocation.Geofencing.GeofenceMonitor)]
                [uuid(2DD32FCF-7E75-4899-ACE3-2BD0A65CCE06)]
                interface IGeofenceMonitorStatics : IInspectable
                {
                    [propget] HRESULT Current([out] [retval] Windows.Devices.Geolocation.Geofencing.GeofenceMonitor** value);
                }

                [contract(Windows.Foundation.UniversalApiContract, 1.0)]
                [exclusiveto(Windows.Devices.Geolocation.Geofencing.GeofenceStateChangeReport)]
                [uuid(9A243C18-2464-4C89-BE05-B3FFFF5BABC5)]
                interface IGeofenceStateChangeReport : IInspectable
                {
                    [propget] HRESULT NewState([out] [retval] Windows.Devices.Geolocation.Geofencing.GeofenceState* value);
                    [propget] HRESULT Geofence([out] [retval] Windows.Devices.Geolocation.Geofencing.Geofence** value);
                    [propget] HRESULT Geoposition([out] [retval] Windows.Devices.Geolocation.Geoposition** value);
                    [propget] HRESULT RemovalReason([out] [retval] Windows.Devices.Geolocation.Geofencing.GeofenceRemovalReason* value);
                }

                [activatable(Windows.Devices.Geolocation.Geofencing.IGeofenceFactory, Windows.Foundation.UniversalApiContract, 1.0)]
                [contract(Windows.Foundation.UniversalApiContract, 1.0)]
                [marshaling_behavior(agile)]
                runtimeclass Geofence
                {
                    [default] interface Windows.Devices.Geolocation.Geofencing.IGeofence;
                }

                [contract(Windows.Foundation.UniversalApiContract, 1.0)]
                [marshaling_behavior(agile)]
                [static(Windows.Devices.Geolocation.Geofencing.IGeofenceMonitorStatics, Windows.Foundation.UniversalApiContract, 1.0)]
                runtimeclass GeofenceMonitor
                {
                    [default] interface Windows.Devices.Geolocation.Geofencing.IGeofenceMonitor;
                }

                [contract(Windows.Foundation.UniversalApiContract, 1.0)]
                [marshaling_behavior(agile)]
                runtimeclass GeofenceStateChangeReport
                {
                    [default] interface Windows.Devices.Geolocation.Geofencing.IGeofenceStateChangeReport;
                }
            }
        }
    }
}
