
    IR-ei                         d dl mZ dgZddgZ G d dej                  Z G d dej                  Z G d d          ZdS )	    registry	NDIOMixin
NDDataReadNDDataWritec                   (     e Zd ZdZ fdZd Z xZS )r   a>  Read and parse gridded N-dimensional data and return as an NDData-derived
    object.

    This function provides the NDDataBase interface to the astropy unified I/O
    layer.  This allows easily reading a file in the supported data formats,
    for example::

      >>> from astropy.nddata import CCDData
      >>> dat = CCDData.read('image.fits')

    Get help on the available readers for ``CCDData`` using the``help()`` method::

      >>> CCDData.read.help()  # Get help reading CCDData and list supported formats
      >>> CCDData.read.help('fits')  # Get detailed help on CCDData FITS reader
      >>> CCDData.read.list_formats()  # Print list of available formats

    For more information see:

    - https://docs.astropy.org/en/stable/nddata
    - https://docs.astropy.org/en/stable/io/unified.html

    Parameters
    ----------
    *args : tuple, optional
        Positional arguments passed through to data reader. If supplied the
        first argument is the input filename.
    format : str, optional
        File format specifier.
    cache : bool, optional
        Caching behavior if file is a URL.
    **kwargs : dict, optional
        Keyword arguments passed through to data reader.

    Returns
    -------
    out : `NDData` subclass
        NDData-basd object corresponding to file contents

    Notes
    -----
    c                 R    t                                          ||dd            d S )Nreadr   super__init__selfinstancecls	__class__s      :lib/python3.11/site-packages/astropy/nddata/mixins/ndio.pyr   zNDDataRead.__init__6   s*    3>>>>>    c                 8     | j         j        | j        g|R i |S N)r   r
   _clsr   argskwargss      r   __call__zNDDataRead.__call__:   s)    !t}!$)=d===f===r   __name__
__module____qualname____doc__r   r   __classcell__r   s   @r   r   r      sR        ( (T? ? ? ? ?> > > > > > >r   c                   (     e Zd ZdZ fdZd Z xZS )r   a  Write this CCDData object out in the specified format.

    This function provides the NDData interface to the astropy unified I/O
    layer.  This allows easily writing a file in many supported data formats
    using syntax such as::

      >>> from astropy.nddata import CCDData
      >>> dat = CCDData(np.zeros((12, 12)), unit='adu')  # 12x12 image of zeros
      >>> dat.write('zeros.fits')

    Get help on the available writers for ``CCDData`` using the``help()`` method::

      >>> CCDData.write.help()  # Get help writing CCDData and list supported formats
      >>> CCDData.write.help('fits')  # Get detailed help on CCDData FITS writer
      >>> CCDData.write.list_formats()  # Print list of available formats

    For more information see:

    - https://docs.astropy.org/en/stable/nddata
    - https://docs.astropy.org/en/stable/io/unified.html

    Parameters
    ----------
    *args : tuple, optional
        Positional arguments passed through to data writer. If supplied the
        first argument is the output filename.
    format : str, optional
        File format specifier.
    **kwargs : dict, optional
        Keyword arguments passed through to data writer.

    Notes
    -----
    c                 R    t                                          ||dd            d S )Nwriter   r   r   s      r   r   zNDDataWrite.__init__b   s*    3$?????r   c                 <     | j         j        | j        g|R i | d S r   )r   r%   	_instancer   s      r   r   zNDDataWrite.__call__f   s/    DN<T<<<V<<<<<r   r   r"   s   @r   r   r   >   sW        ! !F@ @ @ @ @= = = = = = =r   c                   R    e Zd ZdZ ej        e          Z ej        e          Z	dS )r   z
    Mixin class to connect NDData to the astropy input/output registry.

    This mixin adds two methods to its subclasses, ``read`` and ``write``.
    N)
r   r   r   r    r   UnifiedReadWriteMethodr   r
   r   r%    r   r   r   r   j   s>          +8*:66D+H+K88EEEr   N)
astropy.ior   __all____doctest_skip__UnifiedReadWriter   r   r   r*   r   r   <module>r/      s   
       - -0 0> 0> 0> 0> 0>* 0> 0> 0>f)= )= )= )= )=(+ )= )= )=X9 9 9 9 9 9 9 9 9 9r   