B
    è?F[ï  ã               @   sT   G d d„ de ƒZG dd„ de ƒZG dd„ de ƒZG dd„ de ƒZG dd	„ d	e ƒZd
S )c               @   s2   e Zd ZdZddd„Zdd„ Zdd„ Zd	d
„ ZdS )ÚConnectionSettingAttributezE
    Represents the ConnectionSetting segment of ELB Attributes.
    Nc             C   s
   d | _ d S )N)Úidle_timeout)ÚselfÚ
connection© r   ú6lib/python3.7/site-packages/boto/ec2/elb/attributes.pyÚ__init__   s    z#ConnectionSettingAttribute.__init__c             C   s
   d| j  S )NzConnectionSettingAttribute(%s))r   )r   r   r   r   Ú__repr__   s    z#ConnectionSettingAttribute.__repr__c             C   s   d S )Nr   )r   ÚnameÚattrsr   r   r   r   ÚstartElement!   s    z'ConnectionSettingAttribute.startElementc             C   s   |dkrt |ƒ| _d S )NZIdleTimeout)Úintr   )r   r	   Úvaluer   r   r   r   Ú
endElement$   s    z%ConnectionSettingAttribute.endElement)N)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   r   r   r   r   r   r   r      s
   
r   c               @   s2   e Zd ZdZddd„Zdd„ Zdd„ Zd	d
„ ZdS )ÚCrossZoneLoadBalancingAttributezK
    Represents the CrossZoneLoadBalancing segement of ELB Attributes.
    Nc             C   s
   d | _ d S )N)Úenabled)r   r   r   r   r   r   ,   s    z(CrossZoneLoadBalancingAttribute.__init__c             C   s
   d| j  S )Nz#CrossZoneLoadBalancingAttribute(%s))r   )r   r   r   r   r   /   s    z(CrossZoneLoadBalancingAttribute.__repr__c             C   s   d S )Nr   )r   r	   r
   r   r   r   r   r   3   s    z,CrossZoneLoadBalancingAttribute.startElementc             C   s&   |dkr"|  ¡ dkrd| _nd| _d S )NÚEnabledÚtrueTF)Úlowerr   )r   r	   r   r   r   r   r   r   6   s    z*CrossZoneLoadBalancingAttribute.endElement)N)r   r   r   r   r   r   r   r   r   r   r   r   r   (   s
   
r   c               @   s2   e Zd ZdZddd„Zdd„ Zdd„ Zd	d
„ ZdS )ÚAccessLogAttributez=
    Represents the AccessLog segment of ELB attributes.
    Nc             C   s   d | _ d | _d | _d | _d S )N)r   Ús3_bucket_nameÚs3_bucket_prefixÚemit_interval)r   r   r   r   r   r   B   s    zAccessLogAttribute.__init__c             C   s   d| j | j| j| jf S )NzAccessLog(%s, %s, %s, %s))r   r   r   r   )r   r   r   r   r   H   s
    zAccessLogAttribute.__repr__c             C   s   d S )Nr   )r   r	   r
   r   r   r   r   r   P   s    zAccessLogAttribute.startElementc             C   sZ   |dkr$|  ¡ dkrd| _qVd| _n2|dkr4|| _n"|dkrD|| _n|dkrVt|ƒ| _d S )Nr   r   TFZS3BucketNameZS3BucketPrefixZEmitInterval)r   r   r   r   r   r   )r   r	   r   r   r   r   r   r   S   s    zAccessLogAttribute.endElement)N)r   r   r   r   r   r   r   r   r   r   r   r   r   >   s
   
r   c               @   s2   e Zd ZdZddd„Zdd„ Zdd„ Zd	d
„ ZdS )ÚConnectionDrainingAttributezF
    Represents the ConnectionDraining segment of ELB attributes.
    Nc             C   s   d | _ d | _d S )N)r   Útimeout)r   r   r   r   r   r   e   s    z$ConnectionDrainingAttribute.__init__c             C   s   d| j | jf S )NzConnectionDraining(%s, %s))r   r   )r   r   r   r   r   i   s    z$ConnectionDrainingAttribute.__repr__c             C   s   d S )Nr   )r   r	   r
   r   r   r   r   r   o   s    z(ConnectionDrainingAttribute.startElementc             C   s:   |dkr$|  ¡ dkrd| _q6d| _n|dkr6t|ƒ| _d S )Nr   r   TFZTimeout)r   r   r   r   )r   r	   r   r   r   r   r   r   r   s    z&ConnectionDrainingAttribute.endElement)N)r   r   r   r   r   r   r   r   r   r   r   r   r   a   s
   
r   c               @   s2   e Zd ZdZddd„Zdd„ Zdd„ Zd	d
„ ZdS )ÚLbAttributesz@
    Represents the Attributes of an Elastic Load Balancer.
    Nc             C   s:   || _ t| j ƒ| _t| j ƒ| _t| j ƒ| _t| j ƒ| _d S )N)	r   r   Úcross_zone_load_balancingr   Ú
access_logr   Úconnection_drainingr   Úconnecting_settings)r   r   r   r   r   r   €   s    
zLbAttributes.__init__c             C   s(   dt | jƒt | jƒt | jƒt | jƒf S )NzLbAttributes(%s, %s, %s, %s))Úreprr   r    r!   r"   )r   r   r   r   r   ˆ   s
    zLbAttributes.__repr__c             C   s<   |dkr| j S |dkr| jS |dkr*| jS |dkr8| jS d S )NZCrossZoneLoadBalancingZ	AccessLogZConnectionDrainingZConnectionSettings)r   r    r!   r"   )r   r	   r
   r   r   r   r   r      s    zLbAttributes.startElementc             C   s   d S )Nr   )r   r	   r   r   r   r   r   r   ™   s    zLbAttributes.endElement)N)r   r   r   r   r   r   r   r   r   r   r   r   r   |   s
   

r   N)Úobjectr   r   r   r   r   r   r   r   r   Ú<module>   s   #