Module jumpscale.data.serializers.toml
Expand source code
import pytoml
def dumps(d):
    """dump dict object into toml stream
    Arguments:
        d (dict) : the dict which will be dumped
    Returns:
        string : the toml stream
    """
    s = pytoml.dumps(d)
    return s
def loads(s):
    """loads the data from toml string into dict
    Arguments:
        s (string) : the toml stream
    Returns:
        dict : the loaded data from toml stram
    """
    d = pytoml.loads(s)
    return d
Functions
def dumps(d)- 
dump dict object into toml stream
Arguments
d (dict) : the dict which will be dumped
Returns
string- the toml stream
 
Expand source code
def dumps(d): """dump dict object into toml stream Arguments: d (dict) : the dict which will be dumped Returns: string : the toml stream """ s = pytoml.dumps(d) return s def loads(s)- 
loads the data from toml string into dict
Arguments
s (string) : the toml stream
Returns
dict- the loaded data from toml stram
 
Expand source code
def loads(s): """loads the data from toml string into dict Arguments: s (string) : the toml stream Returns: dict : the loaded data from toml stram """ d = pytoml.loads(s) return d