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 d dlmZ ejr9d dlm	Z	m
Z
mZmZmZ d dlmZ d dlmZ G dd deZdS )	    N)Enum)	SlotValue)DictListOptionalUnionAny)datetime)Resolutionsc                       sf   e Zd ZdZddddZddddZdZd fd
d	Zdd Zdd Z	dd Z
dd Zdd Z  ZS )SimpleSlotValuea  
    Slot value containing a single string value and resolutions.


    :param value: A string that represents the value the user spoke for the slot. This is the actual value the user spoke, not necessarily the canonical value or one of the synonyms defined for the entity. Note that AMAZON.LITERAL slot values sent to your service are always in all lower case.
    :type value: (optional) str
    :param resolutions: Contains the results of entity resolution. These are organized by authority. An authority represents the source for the data provided for the slot. For a custom slot type, the authority is the slot type you defined.
    :type resolutions: (optional) ask_sdk_model.slu.entityresolution.resolutions.Resolutions

    strz:ask_sdk_model.slu.entityresolution.resolutions.Resolutions)object_typevalueresolutionstyper   r   FNc                    s2   d| _ | j | _tt| j| j d || _|| _dS )a  Slot value containing a single string value and resolutions.

        :param value: A string that represents the value the user spoke for the slot. This is the actual value the user spoke, not necessarily the canonical value or one of the synonyms defined for the entity. Note that AMAZON.LITERAL slot values sent to your service are always in all lower case.
        :type value: (optional) str
        :param resolutions: Contains the results of entity resolution. These are organized by authority. An authority represents the source for the data provided for the slot. For a custom slot type, the authority is the slot type you defined.
        :type resolutions: (optional) ask_sdk_model.slu.entityresolution.resolutions.Resolutions
        ZSimple)r   N)Z%_SimpleSlotValue__discriminator_valuer   superr   __init__r   r   )selfr   r   	__class__ AD:\Flask\env\Lib\site-packages\ask_sdk_model/simple_slot_value.pyr   6   s
   	
zSimpleSlotValue.__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   r   )xr   r   r   <lambda>O   s    z)SimpleSlotValue.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   Y   s
   )six	iteritemsdeserialized_typesgetattrr   listmapr   r   r   r   dictitems)r   resultattr_r   r   r   r   r   F   s&   





zSimpleSlotValue.to_dictc                 C   s   t |  S )z.Returns the string representation of the model)pprintpformatr   r   r   r   r   to_strd   s   zSimpleSlotValue.to_strc                 C   s   |   S )zFor `print` and `pprint`)r.   r-   r   r   r   __repr__i   s   zSimpleSlotValue.__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__n   s   
zSimpleSlotValue.__eq__c                 C   s
   | |k S )z*Returns true if both objects are not equalr   r1   r   r   r   __ne__v   s   
zSimpleSlotValue.__ne__)NN)__name__
__module____qualname____doc__r"   Zattribute_mapZsupports_multiple_typesr   r   r.   r/   r3   r4   __classcell__r   r   r   r   r      s"    r   )r+   rer    typingenumr   Zask_sdk_model.slot_valuer   TYPE_CHECKINGr   r   r   r   r   r	   Z.ask_sdk_model.slu.entityresolution.resolutionsr
   ZResolutions_e7d66a3r   r   r   r   r   <module>   s   