Repository URL to install this package:
Version:
1.0.8-2 ▾
|
wlanpi-profiler
/
opt
/
wlanpi-profiler
/
lib
/
python3.7
/
site-packages
/
toml
/
__pycache__
/
encoder.cpython-37.pyc
|
---|
B gÏ.÷ /ã @ sÎ d dl Z d dlZd dlZd dlmZ d dlmZ ejdkr>eZ dddZ dddZd d Zdd Z d d ZG dd deZG dd deZG dd deZG dd deZG dd deZG dd deZdS )é N)ÚDecimal)ÚInlineTableDict)é c C s( |j stdt| |d}| |¡ |S )a Writes out dict as toml to a file Args: o: Object to dump into toml f: File descriptor where the toml should be stored encoder: The ``TomlEncoder`` to use for constructing the output string Returns: String containing the toml corresponding to dictionary Raises: TypeError: When anything other than file descriptor is passed z0You can only dump an object to a file descriptor)Úencoder)ÚwriteÚ TypeErrorÚdumps)ÚoÚfr Úd© r ú/build/wlanpi-profiler-SHjkbd/wlanpi-profiler-1.0.8/debian/wlanpi-profiler/opt/wlanpi-profiler/lib/python3.7/site-packages/toml/encoder.pyÚdump s r c C s d}|dkrt | j}| | d¡\}}||7 }t| g}xÖ|rdd | ¡ D }x|D ]}||krXtdqXW ||7 }| ¡ }x|D ]~} | || | ¡\}} |sª|sâ| sâ|rÆ|dd dkrÆ|d7 }|d | d 7 }|râ||7 }x | D ]}| | || d | <