Package schrodinger :: Package infra :: Module ark
[hide private]
[frames] | no frames]

Module ark

Python interface for Ark

Functions [hide private]
 
fromArgv(...)
fromArgv(arg, arg, ...) --> nest,others
 
fromString(...)
fromString(string, style=STRICT|DEFAULT|KEYVALS) --> nest
 
toString(...)
toString(nest,whitespace=bool,nodelim=bool) --> string
Variables [hide private]
  DEFAULT = 0
  KEYVALS = 1
  STRICT = -1
  __package__ = None
hash(x)
Function Details [hide private]

fromArgv(...)

 
fromArgv(arg, arg, ...) --> nest,others

Expected use is something like
        nest,sys.argv = ark.parseArgv(*sys.argv)
Takes the --include xxx and --cfg yyy options and incorporates
them into a single ark.

fromString(...)

 

fromString(string, style=STRICT|DEFAULT|KEYVALS) --> nest

Parse an ark string into a python vector/dictionary nest. For a 'config file'-like string is to set style=KEYVALS For parsing the output of toString set style=STRICT|DEFAULT If you want extra predantry set style=STRICT.

toString(...)

 

toString(nest,whitespace=bool,nodelim=bool) --> string

Parse an ark string into a python vector-dictionary nest. Keyword arguments are optional. For writing out a human readable config file whitespace=1 and nodelim=1 and the top level of the nest be a dictionary.