o
    Õjï  ã                   @  s„   d Z ddlmZ ddlZddlmZ ddlmZ	 ddl
mZ ddlmZ ddlmZ dd	lmZ er8dd
lmZ G dd„ deƒZdS )zLCore properties part, corresponds to ``/docProps/core.xml`` part in package.é    )ÚannotationsN)ÚTYPE_CHECKING)ÚCONTENT_TYPE)ÚCoreProperties)ÚPackURI)ÚXmlPart)ÚCT_CoreProperties)Ú
OpcPackagec                   @  s8   e Zd ZdZeddd„ƒZedd„ ƒZedd	d
„ƒZdS )ÚCorePropertiesPartzÄCorresponds to part named ``/docProps/core.xml``.

    The "core" is short for "Dublin Core" and contains document metadata relatively common across
    documents of all types, not just DOCX.
    Úpackager	   c                 C  s8   |   |¡}|j}d|_d|_d|_tj tjj	¡|_
|S )ziReturn a new |CorePropertiesPart| object initialized with default values for
        its base properties.zWord Documentzpython-docxé   )Ú_newÚcore_propertiesÚtitleZlast_modified_byÚrevisionÚdtÚdatetimeÚnowÚtimezoneÚutcÚmodified)Úclsr   Zcore_properties_partr   © r   úY/var/www/html/Deteccion_Ine/venv/lib/python3.10/site-packages/docx/opc/parts/coreprops.pyÚdefault   s   
zCorePropertiesPart.defaultc                 C  s
   t | jƒS )z|A |CoreProperties| object providing read/write access to the core properties
        contained in this core properties part.)r   Úelement)Úselfr   r   r   r   %   s   
z"CorePropertiesPart.core_propertiesÚreturnc                 C  s$   t dƒ}tj}t ¡ }t||||ƒS )Nz/docProps/core.xml)r   ÚCTZOPC_CORE_PROPERTIESr   Únewr
   )r   r   ZpartnameÚcontent_typeZcorePropertiesr   r   r   r   +   s   zCorePropertiesPart._newN)r   r	   )r   r	   r   r
   )	Ú__name__Ú
__module__Ú__qualname__Ú__doc__Úclassmethodr   Úpropertyr   r   r   r   r   r   r
      s    
r
   )r$   Ú
__future__r   r   r   Útypingr   Zdocx.opc.constantsr   r   Zdocx.opc.corepropsr   Zdocx.opc.packurir   Zdocx.opc.partr   Zdocx.oxml.corepropsr   Zdocx.opc.packager	   r
   r   r   r   r   Ú<module>   s    