
    ,Of                    b    d dl mZ d dlmZ d dlmZ d dlZd dlZd dlmZm	Z	m
Z
  G d de	      Zy)    )annotations)datetime)AnyN)	AttributeCompletableGithubObjectNotSetc                      e Zd ZdZddZddZedd       Zedd       Zedd       Z	edd       Z
edd       Zedd	       Zdd
ZddZddZy)GistCommentz
    This class represents GistComments.

    The reference can be found here
    https://docs.github.com/en/rest/reference/gists#comments

    c                    t         | _        t         | _        t         | _        t         | _        t         | _        t         | _        y N)r   _body_created_at_id_updated_at_url_userselfs    2lib/python3.12/site-packages/github/GistComment.py_initAttributeszGistComment._initAttributes<   s.    %+
06#)06$*	<B
    c                z    | j                  | j                  j                  | j                  j                  d      S )N)iduser)get__repr__r   valuer   r   s    r   __repr__zGistComment.__repr__D   s*    txx~~tzz?O?O PQQr   c                d    | j                  | j                         | j                  j                  S r   )_completeIfNotSetr   r   r   s    r   bodyzGistComment.bodyG   $    tzz*zzr   c                d    | j                  | j                         | j                  j                  S r   )r   r   r   r   s    r   
created_atzGistComment.created_atL   (    t//0%%%r   c                d    | j                  | j                         | j                  j                  S r   )r   r   r   r   s    r   r   zGistComment.idQ   s"    txx(xx~~r   c                d    | j                  | j                         | j                  j                  S r   )r   r   r   r   s    r   
updated_atzGistComment.updated_atV   r$   r   c                d    | j                  | j                         | j                  j                  S r   )r   r   r   r   s    r   urlzGistComment.url[   s"    tyy)yyr   c                d    | j                  | j                         | j                  j                  S r   )r   r   r   r   s    r   r   zGistComment.user`   r!   r   c                V    | j                   j                  d| j                        \  }}y)z}
        :calls: `DELETE /gists/{gist_id}/comments/{id} <https://docs.github.com/en/rest/reference/gists#comments>`_
        DELETEN)
_requesterrequestJsonAndCheckr)   )r   headersdatas      r   deletezGistComment.deletee   s"     ;;HdhhOr   c                    t        |t              sJ |       d|i}| j                  j                  d| j                  |      \  }}| j                  |       y)z|
        :calls: `PATCH /gists/{gist_id}/comments/{id} <https://docs.github.com/en/rest/reference/gists#comments>`_
        r    PATCH)inputN)
isinstancestrr-   r.   r)   _useAttributes)r   r    post_parametersr/   r0   s        r   editzGistComment.editk   sY     $$*d*$D
 ;;GTXXUd;eD!r   c                   d|v r| j                  |d         | _        d|v r| j                  |d         | _        d|v r| j	                  |d         | _        d|v r| j                  |d         | _        d|v r| j                  |d         | _        d|v r3| j                  t        j                  j                  |d         | _        y y )Nr    r#   r   r'   r)   r   )_makeStringAttributer   _makeDatetimeAttributer   _makeIntAttributer   r   r   _makeClassAttributegithub	NamedUserr   )r   
attributess     r   r7   zGistComment._useAttributesv   s    Z22:f3EFDJ:%#:::l;STD:--j.>?DH:%#:::l;STDJ11*U2CDDIZ11&2B2B2L2LjY_N`aDJ  r   N)returnNone)rB   r6   )rB   r   )rB   int)rB   zgithub.NamedUser.NamedUser)r    r6   rB   rC   )rA   zdict[str, Any]rB   rC   )__name__
__module____qualname____doc__r   r   propertyr    r#   r   r'   r)   r   r1   r9   r7    r   r   r
   r
   3   s    CR     & &   & &      P	"br   r
   )
__future__r   r   typingr   github.GithubObjectr?   github.NamedUserr   r   r   r
   rJ   r   r   <module>rO      s.   R #     J JOb) Obr   