
    Vh                    j    d dl mZ dZ	 d dlZd dlmZ d dlm	Z	  G d de	      Z
y# e$ r d dlZY #w xY w)    )annotationsa  
name: pickle
short_description: Pickle formatted files
description:
  - This cache uses Python's pickle serialization format, in per host files, saved to the filesystem.
author: Brian Coca (@bcoca)
options:
  _uri:
    required: true
    description:
      - Path in which the cache plugin will save the files.
    env:
      - name: ANSIBLE_CACHE_PLUGIN_CONNECTION
    ini:
      - key: fact_caching_connection
        section: defaults
    type: path
  _prefix:
    description: User defined prefix to use when creating the files.
    env:
      - name: ANSIBLE_CACHE_PLUGIN_PREFIX
    ini:
      - key: fact_caching_prefix
        section: defaults
    type: string
  _timeout:
    default: 86400
    description: Expiration timeout in seconds for the cache plugin data. Set to 0 to never expire.
    env:
      - name: ANSIBLE_CACHE_PLUGIN_TIMEOUT
    ini:
      - key: fact_caching_timeout
        section: defaults
    type: float
N)PY3)BaseFileCacheModulec                       e Zd ZdZdZd Zd Zy)CacheModulez2
    A caching module backed by pickle files.
    Fc                    t        |d      5 }t        r t        j                  |d      cd d d        S t        j                  |      cd d d        S # 1 sw Y   y xY w)Nrbbytes)encoding)openr   pickleload)selffilepathfs      j/home/dcms/DCMS/lib/python3.12/site-packages/ansible_collections/community/general/plugins/cache/pickle.py_loadzCacheModule._load=   sK    (D! 	&Q{{1w7	& 	& {{1~		& 	& 	&s   AAAc                v    t        |d      5 }t        j                  ||d       d d d        y # 1 sw Y   y xY w)Nwb   )protocol)r   r   dump)r   valuer   r   s       r   _dumpzCacheModule._dumpE   s3    (D! 	.QKKq1-	. 	. 	.s   /8N)__name__
__module____qualname____doc___persistentr   r        r   r   r   7   s     K&.r!   r   )
__future__r   DOCUMENTATIONcPickler   ImportErroransible.module_utils.sixr   ansible.plugins.cacher   r   r    r!   r   <module>r(      sC    #"H ) 5.% .  s   & 	22