
    tf                     8   d dl Z ddlmZ ddlmZ  ej                          e j
                  dd       e j                  d	d
dd      d                      Z ej                          e j
                  de       e j
                  de       e j                  ddddd      d                             Z	 ej                          e j
                  de       e j
                  de       e j                  ddddd       e j                  ddddd      d                                    Z
 ej                          e j
                  de       e j
                  de       e j                  ddddd      d                             Z ej                          e j
                  de       e j                  dde      d                       Z ej                          e j
                  de       e j                  dde      d!                      Zy)"    N   )fileops   )cli	cool_path	COOL_PATH)metavarz--longz-lzLong listing formatT)helpis_flagc                     ddl m} t        j                  |       D ]Y  }| dz   |z   }|r8 ||      j                  }|| d}n| d|d}t        j                  |       Et        j                  |       [ y)z*
    List all coolers inside a file.

    r   )Coolerz::Nz	<variable>	,)apir   r   list_coolersbinsizeclickecho)r   longr   
group_pathurir   ss          \/var/www/html/software/conda/envs/higlass/lib/python3.12/site-packages/cooler/cli/fileops.pylsr      s{     **95 

$+Sk))Ge<(e2ga[)JJqMJJsO
    src_uri)typedst_uriz--overwritez-wz;Truncate and replace destination file if it already exists.F)r
   r   defaultc                 4    t        j                  | ||       y)z
    Copy a cooler from one file to another or within the same file.

    See also: h5copy, h5repack tools from HDF5 suite.

    	overwriteN)r   cpr   r   r"   s      r   r#   r#      s    4 JJw95r   z--softz-szCreates a soft link rather than a hard link if the source and destination file are the same. Otherwise, creates an external link. This type of link uses a path rather than a pointer.c                 6    t        j                  | |||       y)z
    Create a hard link to a cooler (rather than a true copy) in the same file.
    Also supports soft links (in the same file) or external links (different
    files).

    )r"   softN)r   ln)r   r   r"   r&   s       r   r'   r'   ;   s    4 JJw94@r   c                 4    t        j                  | ||       y)z0
    Rename a cooler within the same file.

    r!   N)r   mvr$   s      r   r)   r)   X   s     JJw95r   r   z-Lz--levelc                 Z    t        j                  | |      }t        j                  |       y)z+
    Display a file's data hierarchy.

    N)r   pprint_data_treer   r   r   levelts      r   treer/   j   !     	  e,A	JJqMr   c                 Z    t        j                  | |      }t        j                  |       y)z0
    Display a file's attribute hierarchy.

    N)r   pprint_attr_treer   r   r,   s      r   attrsr3   v   r0   r   )r    r   r   commandargumentoptionr   strr#   r'   r)   intr/   r3    r   r   <module>r;      sL      [1h#8$G H 2 ( 	$	$	F6 % % 6& 	$	$	F 
; A % % &A 	$	$	F6 % % 6 C dIC( ) !  C dIC( ) ! r   