# WARNING: Please don't edit this file. It was generated by Python/WinRT v3.2.1

import datetime
import sys
import types
import typing
import uuid as _uuid
from builtins import property as _property

import winrt._winrt
import winrt.system
import winrt.windows.devices.enumeration as windows_devices_enumeration
import winrt.windows.foundation as windows_foundation
import winrt.windows.foundation.collections as windows_foundation_collections
import winrt.windows.storage.streams as windows_storage_streams
import winrt.windows.ui.popups as windows_ui_popups

from winrt.windows.media.casting import CastingConnectionErrorStatus, CastingConnectionState, CastingPlaybackTypes

Self = typing.TypeVar('Self')

@typing.final
class CastingConnection(winrt.system.Object, windows_foundation.IClosable):
    def __enter__(self: Self) -> Self: ...
    def __exit__(self, exc_type: typing.Optional[typing.Type[BaseException]], exc_value: typing.Optional[BaseException], traceback: typing.Optional[types.TracebackType]) -> None: ...
    # System.Void Windows.Media.Casting.CastingConnection::Close()
    def close(self) -> None: ...
    # Windows.Foundation.IAsyncOperation`1<Windows.Media.Casting.CastingConnectionErrorStatus> Windows.Media.Casting.CastingConnection::DisconnectAsync()
    def disconnect_async(self) -> windows_foundation.IAsyncOperation[CastingConnectionErrorStatus]: ...
    # Windows.Foundation.IAsyncOperation`1<Windows.Media.Casting.CastingConnectionErrorStatus> Windows.Media.Casting.CastingConnection::RequestStartCastingAsync(Windows.Media.Casting.CastingSource)
    def request_start_casting_async(self, value: CastingSource, /) -> windows_foundation.IAsyncOperation[CastingConnectionErrorStatus]: ...
    # Windows.Foundation.EventRegistrationToken Windows.Media.Casting.CastingConnection::add_ErrorOccurred(Windows.Foundation.TypedEventHandler`2<Windows.Media.Casting.CastingConnection,Windows.Media.Casting.CastingConnectionErrorOccurredEventArgs>)
    def add_error_occurred(self, handler: windows_foundation.TypedEventHandler[CastingConnection, CastingConnectionErrorOccurredEventArgs], /) -> windows_foundation.EventRegistrationToken: ...
    # System.Void Windows.Media.Casting.CastingConnection::remove_ErrorOccurred(Windows.Foundation.EventRegistrationToken)
    def remove_error_occurred(self, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
    # Windows.Foundation.EventRegistrationToken Windows.Media.Casting.CastingConnection::add_StateChanged(Windows.Foundation.TypedEventHandler`2<Windows.Media.Casting.CastingConnection,System.Object>)
    def add_state_changed(self, handler: windows_foundation.TypedEventHandler[CastingConnection, winrt.system.Object], /) -> windows_foundation.EventRegistrationToken: ...
    # System.Void Windows.Media.Casting.CastingConnection::remove_StateChanged(Windows.Foundation.EventRegistrationToken)
    def remove_state_changed(self, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
    # Windows.Media.Casting.CastingSource Windows.Media.Casting.CastingConnection::get_Source()
    @_property
    def source(self) -> CastingSource: ...
    # System.Void Windows.Media.Casting.CastingConnection::put_Source(Windows.Media.Casting.CastingSource)
    @source.setter
    def source(self, value: CastingSource) -> None: ...
    # Windows.Media.Casting.CastingDevice Windows.Media.Casting.CastingConnection::get_Device()
    @_property
    def device(self) -> CastingDevice: ...
    # Windows.Media.Casting.CastingConnectionState Windows.Media.Casting.CastingConnection::get_State()
    @_property
    def state(self) -> CastingConnectionState: ...

@typing.final
class CastingConnectionErrorOccurredEventArgs(winrt.system.Object):
    # Windows.Media.Casting.CastingConnectionErrorStatus Windows.Media.Casting.CastingConnectionErrorOccurredEventArgs::get_ErrorStatus()
    @_property
    def error_status(self) -> CastingConnectionErrorStatus: ...
    # System.String Windows.Media.Casting.CastingConnectionErrorOccurredEventArgs::get_Message()
    @_property
    def message(self) -> str: ...

@typing.final
class CastingDevice_Static(winrt._winrt.IInspectable_Static):
    # Windows.Foundation.IAsyncOperation`1<System.Boolean> Windows.Media.Casting.CastingDevice::DeviceInfoSupportsCastingAsync(Windows.Devices.Enumeration.DeviceInformation)
    def device_info_supports_casting_async(cls, device: windows_devices_enumeration.DeviceInformation, /) -> windows_foundation.IAsyncOperation[bool]: ...
    # Windows.Foundation.IAsyncOperation`1<Windows.Media.Casting.CastingDevice> Windows.Media.Casting.CastingDevice::FromIdAsync(System.String)
    def from_id_async(cls, value: str, /) -> windows_foundation.IAsyncOperation[CastingDevice]: ...
    # System.String Windows.Media.Casting.CastingDevice::GetDeviceSelector(Windows.Media.Casting.CastingPlaybackTypes)
    def get_device_selector(cls, type: CastingPlaybackTypes, /) -> str: ...
    # Windows.Foundation.IAsyncOperation`1<System.String> Windows.Media.Casting.CastingDevice::GetDeviceSelectorFromCastingSourceAsync(Windows.Media.Casting.CastingSource)
    def get_device_selector_from_casting_source_async(cls, casting_source: CastingSource, /) -> windows_foundation.IAsyncOperation[str]: ...

@typing.final
class CastingDevice(winrt.system.Object, metaclass=CastingDevice_Static):
    # Windows.Media.Casting.CastingConnection Windows.Media.Casting.CastingDevice::CreateCastingConnection()
    def create_casting_connection(self) -> CastingConnection: ...
    # Windows.Foundation.IAsyncOperation`1<Windows.Media.Casting.CastingPlaybackTypes> Windows.Media.Casting.CastingDevice::GetSupportedCastingPlaybackTypesAsync()
    def get_supported_casting_playback_types_async(self) -> windows_foundation.IAsyncOperation[CastingPlaybackTypes]: ...
    # System.String Windows.Media.Casting.CastingDevice::get_FriendlyName()
    @_property
    def friendly_name(self) -> str: ...
    # Windows.Storage.Streams.IRandomAccessStreamWithContentType Windows.Media.Casting.CastingDevice::get_Icon()
    @_property
    def icon(self) -> windows_storage_streams.IRandomAccessStreamWithContentType: ...
    # System.String Windows.Media.Casting.CastingDevice::get_Id()
    @_property
    def id(self) -> str: ...

@typing.final
class CastingDevicePicker(winrt.system.Object):
    def __new__(cls: typing.Type[Self]) -> Self: ...
    # System.Void Windows.Media.Casting.CastingDevicePicker::Hide()
    def hide(self) -> None: ...
    # System.Void Windows.Media.Casting.CastingDevicePicker::Show(Windows.Foundation.Rect)
    def show(self, selection: typing.Union[windows_foundation.Rect, typing.Tuple[winrt.system.Single, winrt.system.Single, winrt.system.Single, winrt.system.Single]], /) -> None: ...
    # System.Void Windows.Media.Casting.CastingDevicePicker::Show(Windows.Foundation.Rect,Windows.UI.Popups.Placement)
    def show_with_placement(self, selection: typing.Union[windows_foundation.Rect, typing.Tuple[winrt.system.Single, winrt.system.Single, winrt.system.Single, winrt.system.Single]], preferred_placement: windows_ui_popups.Placement, /) -> None: ...
    # Windows.Foundation.EventRegistrationToken Windows.Media.Casting.CastingDevicePicker::add_CastingDevicePickerDismissed(Windows.Foundation.TypedEventHandler`2<Windows.Media.Casting.CastingDevicePicker,System.Object>)
    def add_casting_device_picker_dismissed(self, handler: windows_foundation.TypedEventHandler[CastingDevicePicker, winrt.system.Object], /) -> windows_foundation.EventRegistrationToken: ...
    # System.Void Windows.Media.Casting.CastingDevicePicker::remove_CastingDevicePickerDismissed(Windows.Foundation.EventRegistrationToken)
    def remove_casting_device_picker_dismissed(self, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
    # Windows.Foundation.EventRegistrationToken Windows.Media.Casting.CastingDevicePicker::add_CastingDeviceSelected(Windows.Foundation.TypedEventHandler`2<Windows.Media.Casting.CastingDevicePicker,Windows.Media.Casting.CastingDeviceSelectedEventArgs>)
    def add_casting_device_selected(self, handler: windows_foundation.TypedEventHandler[CastingDevicePicker, CastingDeviceSelectedEventArgs], /) -> windows_foundation.EventRegistrationToken: ...
    # System.Void Windows.Media.Casting.CastingDevicePicker::remove_CastingDeviceSelected(Windows.Foundation.EventRegistrationToken)
    def remove_casting_device_selected(self, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
    # Windows.Devices.Enumeration.DevicePickerAppearance Windows.Media.Casting.CastingDevicePicker::get_Appearance()
    @_property
    def appearance(self) -> windows_devices_enumeration.DevicePickerAppearance: ...
    # Windows.Media.Casting.CastingDevicePickerFilter Windows.Media.Casting.CastingDevicePicker::get_Filter()
    @_property
    def filter(self) -> CastingDevicePickerFilter: ...

@typing.final
class CastingDevicePickerFilter(winrt.system.Object):
    # System.Boolean Windows.Media.Casting.CastingDevicePickerFilter::get_SupportsVideo()
    @_property
    def supports_video(self) -> bool: ...
    # System.Void Windows.Media.Casting.CastingDevicePickerFilter::put_SupportsVideo(System.Boolean)
    @supports_video.setter
    def supports_video(self, value: bool) -> None: ...
    # System.Boolean Windows.Media.Casting.CastingDevicePickerFilter::get_SupportsPictures()
    @_property
    def supports_pictures(self) -> bool: ...
    # System.Void Windows.Media.Casting.CastingDevicePickerFilter::put_SupportsPictures(System.Boolean)
    @supports_pictures.setter
    def supports_pictures(self, value: bool) -> None: ...
    # System.Boolean Windows.Media.Casting.CastingDevicePickerFilter::get_SupportsAudio()
    @_property
    def supports_audio(self) -> bool: ...
    # System.Void Windows.Media.Casting.CastingDevicePickerFilter::put_SupportsAudio(System.Boolean)
    @supports_audio.setter
    def supports_audio(self, value: bool) -> None: ...
    # Windows.Foundation.Collections.IVector`1<Windows.Media.Casting.CastingSource> Windows.Media.Casting.CastingDevicePickerFilter::get_SupportedCastingSources()
    @_property
    def supported_casting_sources(self) -> typing.MutableSequence[CastingSource]: ...

@typing.final
class CastingDeviceSelectedEventArgs(winrt.system.Object):
    # Windows.Media.Casting.CastingDevice Windows.Media.Casting.CastingDeviceSelectedEventArgs::get_SelectedCastingDevice()
    @_property
    def selected_casting_device(self) -> CastingDevice: ...

@typing.final
class CastingSource(winrt.system.Object):
    # Windows.Foundation.Uri Windows.Media.Casting.CastingSource::get_PreferredSourceUri()
    @_property
    def preferred_source_uri(self) -> windows_foundation.Uri: ...
    # System.Void Windows.Media.Casting.CastingSource::put_PreferredSourceUri(Windows.Foundation.Uri)
    @preferred_source_uri.setter
    def preferred_source_uri(self, value: windows_foundation.Uri) -> None: ...

