ó
š9^c           @   s   d  e  f d     YZ d S(   t	   CustomArgc           B   s   e  Z d  Z d	 d	 d	 d  Z e d    Z e j d    Z e d    Z e j d    Z e d    Z	 e	 j d    Z	 d   Z
 RS(
   sg  Values that will be carried along with the email and its activity data.

    Substitutions will not be made on custom arguments, so any string entered
    into this parameter will be assumed to be the custom argument that you
    would like to be used. Top-level CustomArgs may be overridden by ones in a
    Personalization. May not exceed 10,000 bytes.
    c         C   sg   d |  _ d |  _ d |  _ | d k	 r3 | |  _ n  | d k	 rK | |  _ n  | d k	 rc | |  _ n  d S(   s  Create a CustomArg with the given key and value.

            :param key: Key for this CustomArg
            :type key: string, optional
            :param value: Value of this CustomArg
            :type value: string, optional
            :param p: p is the Personalization object or Personalization
                      object index
            :type p: Personalization, integer, optional
        N(   t   Nonet   _keyt   _valuet   _personalizationt   keyt   valuet   personalization(   t   selfR   R   t   p(    (    sB   /tmp/pip-unpacked-wheel-v7av_c/sendgrid/helpers/mail/custom_arg.pyt   __init__
   s    			c         C   s   |  j  S(   s8   Key for this CustomArg.

        :rtype: string
        (   R   (   R   (    (    sB   /tmp/pip-unpacked-wheel-v7av_c/sendgrid/helpers/mail/custom_arg.pyR       s    c         C   s   | |  _  d S(   sk   Key for this CustomArg.

        :param value: Key for this CustomArg.
        :type value: string
        N(   R   (   R   R   (    (    sB   /tmp/pip-unpacked-wheel-v7av_c/sendgrid/helpers/mail/custom_arg.pyR   (   s    c         C   s   |  j  S(   s9   Value of this CustomArg.

        :rtype: string
        (   R   (   R   (    (    sB   /tmp/pip-unpacked-wheel-v7av_c/sendgrid/helpers/mail/custom_arg.pyR   1   s    c         C   s   | |  _  d S(   sm   Value of this CustomArg.

        :param value: Value of this CustomArg.
        :type value: string
        N(   R   (   R   R   (    (    sB   /tmp/pip-unpacked-wheel-v7av_c/sendgrid/helpers/mail/custom_arg.pyR   9   s    c         C   s   |  j  S(   sm   The Personalization object or Personalization object index

        :rtype: Personalization, integer
        (   R   (   R   (    (    sB   /tmp/pip-unpacked-wheel-v7av_c/sendgrid/helpers/mail/custom_arg.pyR   B   s    c         C   s   | |  _  d S(   sŲ   The Personalization object or Personalization object index

        :param value: The Personalization object or Personalization object
                      index
        :type value: Personalization, integer
        N(   R   (   R   R   (    (    sB   /tmp/pip-unpacked-wheel-v7av_c/sendgrid/helpers/mail/custom_arg.pyR   J   s    c         C   s;   i  } |  j  d k	 r7 |  j d k	 r7 |  j | |  j  <n  | S(   s   
        Get a JSON-ready representation of this CustomArg.

        :returns: This CustomArg, ready for use in a request body.
        :rtype: dict
        N(   R   R   R   (   R   t
   custom_arg(    (    sB   /tmp/pip-unpacked-wheel-v7av_c/sendgrid/helpers/mail/custom_arg.pyt   getT   s    N(   t   __name__t
   __module__t   __doc__R   R
   t   propertyR   t   setterR   R   R   (    (    (    sB   /tmp/pip-unpacked-wheel-v7av_c/sendgrid/helpers/mail/custom_arg.pyR       s   		
N(   t   objectR    (    (    (    sB   /tmp/pip-unpacked-wheel-v7av_c/sendgrid/helpers/mail/custom_arg.pyt   <module>   t    