o
    .j^                     @   s,   d dl mZ d dlmZ G dd deZdS )   )_parse_date)FeedParserDictc                   @   s   e Zd ZdddZdd Zdd Zdd	 Zd
d Zdd Zdd Z	dd Z
dd Zdd Zdd Zdd Zdd Zdd Zdd Zd d! Zd"d# Zd$d% Zd&d' Zd(d) Zd*d+ Zd,d- Zd.d/ Zd0d1 Zd2d3 Zd4d5 Zd6d7 Zd8d9 Zd:d; Zd<S )=	Namespacedcdcterms)z http://purl.org/dc/elements/1.1/zhttp://purl.org/dc/terms/c                 C      |    d S N_end_authorself r   M/home/thesage/.local/lib/python3.10/site-packages/feedparser/namespaces/dc.py_end_dc_author'      zNamespace._end_dc_authorc                 C   r   r   r	   r   r   r   r   _end_dc_creator*   r   zNamespace._end_dc_creatorc                 C   r   r   _end_updatedr   r   r   r   _end_dc_date-   r   zNamespace._end_dc_datec                 C   r   r   )_end_descriptionr   r   r   r   _end_dc_description0   r   zNamespace._end_dc_descriptionc                 C   r   r   )_end_languager   r   r   r   _end_dc_language3   r   zNamespace._end_dc_languagec                 C   r   r   )_end_webmasterr   r   r   r   _end_dc_publisher6   r   zNamespace._end_dc_publisherc                 C   r   r   )_end_rightsr   r   r   r   _end_dc_rights9   r   zNamespace._end_dc_rightsc                 C   r   r   )_end_categoryr   r   r   r   _end_dc_subject<   r   zNamespace._end_dc_subjectc                 C   r   r   )
_end_titler   r   r   r   _end_dc_title?   r   zNamespace._end_dc_titlec                 C   r   r   )_end_createdr   r   r   r   _end_dcterms_createdB   r   zNamespace._end_dcterms_createdc                 C   r   r   )_end_publishedr   r   r   r   _end_dcterms_issuedE   r   zNamespace._end_dcterms_issuedc                 C   r   r   r   r   r   r   r   _end_dcterms_modifiedH   r   zNamespace._end_dcterms_modifiedc                 C      |  | d S r   _start_authorr   attrs_dr   r   r   _start_dc_authorK      zNamespace._start_dc_authorc                 C   r&   r   r'   r)   r   r   r   _start_dc_creatorN   r,   zNamespace._start_dc_creatorc                 C   r&   r   _start_updatedr)   r   r   r   _start_dc_dateQ   r,   zNamespace._start_dc_datec                 C   r&   r   )_start_descriptionr)   r   r   r   _start_dc_descriptionT   r,   zNamespace._start_dc_descriptionc                 C   r&   r   )_start_languager)   r   r   r   _start_dc_languageW   r,   zNamespace._start_dc_languagec                 C   r&   r   )_start_webmasterr)   r   r   r   _start_dc_publisherZ   r,   zNamespace._start_dc_publisherc                 C   r&   r   )_start_rightsr)   r   r   r   _start_dc_rights]   r,   zNamespace._start_dc_rightsc                 C   r&   r   )_start_categoryr)   r   r   r   _start_dc_subject`   r,   zNamespace._start_dc_subjectc                 C   r&   r   )_start_titler)   r   r   r   _start_dc_titlec   r,   zNamespace._start_dc_titlec                 C   r&   r   )_start_createdr)   r   r   r   _start_dcterms_createdf   r,   z Namespace._start_dcterms_createdc                 C   r&   r   )_start_publishedr)   r   r   r   _start_dcterms_issuedi   r,   zNamespace._start_dcterms_issuedc                 C   r&   r   r.   r)   r   r   r   _start_dcterms_modifiedl   r,   z!Namespace._start_dcterms_modifiedc                 C   s   |  dd d S )Nvalidity   )pushr)   r   r   r   _start_dcterms_valido   s   zNamespace._start_dcterms_validc                 C   s   |  ddD ];}d|v rC|dd\}}|dkr-| jd|dd | jd	t|dd q|d
krC| jd|dd | jdt|dd qd S )NrB   ;=rC   startvalidity_startT)	overwritevalidity_start_parsedendvalidity_endvalidity_end_parsed)popsplit_saver   )r   validity_detailkeyvaluer   r   r   _end_dcterms_validr   s   zNamespace._end_dcterms_validc                 C   s:   d| _ |  }|dg  |d t  | dd d S )NrC   contributorsname    )incontributor_get_context
setdefaultappendr   rD   )r   r*   contextr   r   r   _start_dc_contributor}   s
   zNamespace._start_dc_contributorc                 C   s   |    d| _d S )NrX   )	_end_namerY   r   r   r   r   _end_dc_contributor   s   
zNamespace._end_dc_contributorN) __name__
__module____qualname__supported_namespacesr   r   r   r   r   r   r   r   r    r"   r$   r%   r+   r-   r0   r2   r4   r6   r8   r:   r<   r>   r@   rA   rE   rU   r^   r`   r   r   r   r   r   !   s@    r   N)	datetimesr   utilr   objectr   r   r   r   r   <module>   s   