o
    0_Wc+  ã                   @   sò   d dl Z d dlZd dlZd dlZd dlmZ ejrod dlmZmZm	Z	m
Z
mZ d dlmZ d dlmZ d dlmZ d dlmZ d dlmZ d d	lmZ d d
lmZ d dlm Z! d dl"m#Z$ d dl%m&Z' d dl(m)Z* d dl+m,Z- G dd„ de.ƒZ/dS )é    N)ÚEnum)ÚDictÚListÚOptionalÚUnionÚAny)Údatetime)ÚRenderedDocumentState)ÚViewportState)ÚTypedViewportState)ÚAudioPlayerState)ÚAutomotiveState)ÚExperimentationState)ÚExtensionsState)ÚAppLinkState)ÚGeolocationState)ÚSystemState)ÚDisplayStatec                   @   s~   e Zd ZdZdddddddd	d
dddœZddddddddddddœZdZd'dd„Zdd„ Zdd „ Z	d!d"„ Z
d#d$„ Zd%d&„ ZdS )(ÚContextae  

    :param system: Provides information about the current state of the Alexa service and the device interacting with your skill.
    :type system: (optional) ask_sdk_model.interfaces.system.system_state.SystemState
    :param alexa_presentation_apl: Provides the current state for the Alexa.Presentation.APL interface.
    :type alexa_presentation_apl: (optional) ask_sdk_model.interfaces.alexa.presentation.apl.rendered_document_state.RenderedDocumentState
    :param audio_player: Provides the current state for the AudioPlayer interface.
    :type audio_player: (optional) ask_sdk_model.interfaces.audioplayer.audio_player_state.AudioPlayerState
    :param automotive: Provides the automotive specific information of the device.
    :type automotive: (optional) ask_sdk_model.interfaces.automotive.automotive_state.AutomotiveState
    :param display: Provides the current state for the Display interface.
    :type display: (optional) ask_sdk_model.interfaces.display.display_state.DisplayState
    :param geolocation: Provides the last gathered geolocation information of the device.
    :type geolocation: (optional) ask_sdk_model.interfaces.geolocation.geolocation_state.GeolocationState
    :param viewport: Provides the characteristics of a device&#39;s viewport.
    :type viewport: (optional) ask_sdk_model.interfaces.viewport.viewport_state.ViewportState
    :param viewports: This object contains a list of viewports characteristics related to the device&#39;s viewports.
    :type viewports: (optional) list[ask_sdk_model.interfaces.viewport.typed_viewport_state.TypedViewportState]
    :param extensions: Provides the current state for Extensions interface
    :type extensions: (optional) ask_sdk_model.interfaces.alexa.extension.extensions_state.ExtensionsState
    :param app_link: Provides the current state for app link capability.
    :type app_link: (optional) ask_sdk_model.interfaces.applink.app_link_state.AppLinkState
    :param experimentation: Provides the current experimentation state
    :type experimentation: (optional) ask_sdk_model.interfaces.alexa.experimentation.experimentation_state.ExperimentationState

    z8ask_sdk_model.interfaces.system.system_state.SystemStatez]ask_sdk_model.interfaces.alexa.presentation.apl.rendered_document_state.RenderedDocumentStatezHask_sdk_model.interfaces.audioplayer.audio_player_state.AudioPlayerStatezDask_sdk_model.interfaces.automotive.automotive_state.AutomotiveStatez;ask_sdk_model.interfaces.display.display_state.DisplayStatezGask_sdk_model.interfaces.geolocation.geolocation_state.GeolocationStatez>ask_sdk_model.interfaces.viewport.viewport_state.ViewportStatezOlist[ask_sdk_model.interfaces.viewport.typed_viewport_state.TypedViewportState]zIask_sdk_model.interfaces.alexa.extension.extensions_state.ExtensionsStatez<ask_sdk_model.interfaces.applink.app_link_state.AppLinkStatezYask_sdk_model.interfaces.alexa.experimentation.experimentation_state.ExperimentationState)ÚsystemÚalexa_presentation_aplÚaudio_playerÚ
automotiveÚdisplayÚgeolocationÚviewportÚ	viewportsÚ
extensionsÚapp_linkÚexperimentationÚSystemzAlexa.Presentation.APLZAudioPlayerZ
AutomotiveZDisplayZGeolocationZViewportZ	ViewportsZ
ExtensionsZAppLinkZExperimentationFNc                 C   sL   d| _ || _|| _|| _|| _|| _|| _|| _|| _|	| _	|
| _
|| _dS )aÀ  

        :param system: Provides information about the current state of the Alexa service and the device interacting with your skill.
        :type system: (optional) ask_sdk_model.interfaces.system.system_state.SystemState
        :param alexa_presentation_apl: Provides the current state for the Alexa.Presentation.APL interface.
        :type alexa_presentation_apl: (optional) ask_sdk_model.interfaces.alexa.presentation.apl.rendered_document_state.RenderedDocumentState
        :param audio_player: Provides the current state for the AudioPlayer interface.
        :type audio_player: (optional) ask_sdk_model.interfaces.audioplayer.audio_player_state.AudioPlayerState
        :param automotive: Provides the automotive specific information of the device.
        :type automotive: (optional) ask_sdk_model.interfaces.automotive.automotive_state.AutomotiveState
        :param display: Provides the current state for the Display interface.
        :type display: (optional) ask_sdk_model.interfaces.display.display_state.DisplayState
        :param geolocation: Provides the last gathered geolocation information of the device.
        :type geolocation: (optional) ask_sdk_model.interfaces.geolocation.geolocation_state.GeolocationState
        :param viewport: Provides the characteristics of a device&#39;s viewport.
        :type viewport: (optional) ask_sdk_model.interfaces.viewport.viewport_state.ViewportState
        :param viewports: This object contains a list of viewports characteristics related to the device&#39;s viewports.
        :type viewports: (optional) list[ask_sdk_model.interfaces.viewport.typed_viewport_state.TypedViewportState]
        :param extensions: Provides the current state for Extensions interface
        :type extensions: (optional) ask_sdk_model.interfaces.alexa.extension.extensions_state.ExtensionsState
        :param app_link: Provides the current state for app link capability.
        :type app_link: (optional) ask_sdk_model.interfaces.applink.app_link_state.AppLinkState
        :param experimentation: Provides the current experimentation state
        :type experimentation: (optional) ask_sdk_model.interfaces.alexa.experimentation.experimentation_state.ExperimentationState
        N)Z_Context__discriminator_valuer   r   r   r   r   r   r   r   r   r   r   )Úselfr   r   r   r   r   r   r   r   r   r   r   © r"   ú7D:\Flask\env\Lib\site-packages\ask_sdk_model/context.pyÚ__init___   s   
zContext.__init__c                 C   s¦   i }t  | j¡D ]H\}}t| |ƒ}t|tƒr"ttdd„ |ƒƒ||< qt|tƒr-|j||< qt	|dƒr9| 
¡ ||< qt|tƒrLttdd„ | ¡ ƒƒ||< q|||< q|S )z&Returns the model properties as a dictc                 S   s&   t | dƒr	|  ¡ S t| tƒr| jS | S )NÚto_dict©Úhasattrr%   Ú
isinstancer   Úvalue)Úxr"   r"   r#   Ú<lambda>‘   s    z!Context.to_dict.<locals>.<lambda>r%   c                 S   sF   t | d dƒr| d | d  ¡ fS t| d tƒr!| d | d jfS | S )Né   r%   r   r&   )Úitemr"   r"   r#   r+   ›   s
   ÿÿ)ÚsixÚ	iteritemsÚdeserialized_typesÚgetattrr(   ÚlistÚmapr   r)   r'   r%   ÚdictÚitems)r!   ÚresultÚattrÚ_r)   r"   r"   r#   r%   ˆ   s&   

ý


û
zContext.to_dictc                 C   s   t  |  ¡ ¡S )z.Returns the string representation of the model)ÚpprintÚpformatr%   ©r!   r"   r"   r#   Úto_str¦   s   zContext.to_strc                 C   s   |   ¡ S )zFor `print` and `pprint`)r<   r;   r"   r"   r#   Ú__repr__«   s   zContext.__repr__c                 C   s   t |tƒsdS | j|jkS )z&Returns true if both objects are equalF)r(   r   Ú__dict__©r!   Úotherr"   r"   r#   Ú__eq__°   s   
zContext.__eq__c                 C   s
   | |k S )z*Returns true if both objects are not equalr"   r?   r"   r"   r#   Ú__ne__¸   s   
zContext.__ne__)NNNNNNNNNNN)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r0   Zattribute_mapZsupports_multiple_typesr$   r%   r<   r=   rA   rB   r"   r"   r"   r#   r   '   sB    õõ
)r   )0r9   Úrer.   ÚtypingÚenumr   ÚTYPE_CHECKINGr   r   r   r   r   r   ZGask_sdk_model.interfaces.alexa.presentation.apl.rendered_document_stater	   ZRenderedDocumentState_4fad8b14Z0ask_sdk_model.interfaces.viewport.viewport_stater
   ZViewportState_a05eceb9Z6ask_sdk_model.interfaces.viewport.typed_viewport_stater   ZTypedViewportState_c366f13eZ7ask_sdk_model.interfaces.audioplayer.audio_player_stater   ZAudioPlayerState_ac652451Z4ask_sdk_model.interfaces.automotive.automotive_stater   ZAutomotiveState_2b614eeaZDask_sdk_model.interfaces.alexa.experimentation.experimentation_stater   ZExperimentationState_37bb7c62Z9ask_sdk_model.interfaces.alexa.extension.extensions_stater   ZExtensionsState_f02207d3Z/ask_sdk_model.interfaces.applink.app_link_stater   ZAppLinkState_370eda23Z6ask_sdk_model.interfaces.geolocation.geolocation_stater   ZGeolocationState_5225020dZ,ask_sdk_model.interfaces.system.system_stater   ZSystemState_22fcb230Z.ask_sdk_model.interfaces.display.display_stater   ZDisplayState_726e4959Úobjectr   r"   r"   r"   r#   Ú<module>   s(   