U
    ±[Öe'  ã                   @   sR   d Z ddlmZmZ ddlmZ ddlmZ ddlm	Z	m
Z
 G dd„ deeƒZd	S )
zÙ
    pyexcel.plugins.sources.pydata.arraysource
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    Representation of array source

    :copyright: (c) 2015-2022 by Onni Software Ltd.
    :license: New BSD License
é    )ÚAbstractSourceÚMemorySourceMixin)ÚDEFAULT_SHEET_NAME)Úparamsé   )ÚArrayReaderÚ_FakeIOc                   @   s4   e Zd ZdZefdd„Zdd„ Zdd„ Zdd	„ Zd
S )ÚArraySourcez1
    A two dimensional array as sheet source
    c                 K   s&   || _ tƒ | _|| _tj| f|Ž d S ©N)Ú_ArraySource__arrayr   Ú_contentÚ_ArraySource__sheet_namer   Ú__init__)ÚselfÚarrayZ
sheet_nameÚkeywords© r   úl/var/www/html/services/stratfitenv/lib/python3.8/site-packages/pyexcel/plugins/sources/pydata/arraysource.pyr      s    zArraySource.__init__c                 C   s   t | jf| jŽ}| j| ¡ iS r
   )r   r   Z	_keywordsr   Úto_array)r   Zarray_readerr   r   r   Úget_data   s    zArraySource.get_datac                 C   s
   t jd fS r
   )r   ZARRAY)r   r   r   r   Úget_source_info    s    zArraySource.get_source_infoc                 C   s   | j  | ¡ ¡ d S r
   )r   Zsetvaluer   )r   Zsheetr   r   r   Ú
write_data#   s    zArraySource.write_dataN)	Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   r   r   r   r   r   r   r   r	      s
   r	   N)r   Zpyexcel.sourcer   r   Zpyexcel.constantsr   Zpyexcel.plugins.sourcesr   Úcommonr   r   r	   r   r   r   r   Ú<module>   s
   	