Created
July 26, 2015 08:29
-
-
Save apanda/73d8651b6bfd65a8d3ba to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
In [35]: class NF(yaml.YAMLObject): | |
yaml_tag=u'tag:yaml.org,2002:nf' | |
def __init__(self): | |
pass | |
....: | |
In [36]: class Softnic(yaml.YAMLObject): | |
yaml_tag=u'tag:yaml.org,2002:softnic' | |
def __init__(self): | |
pass | |
....: | |
In [37]: x = yaml.load(a) | |
In [38]: x['requests'][0].argument | |
Out[38]: {'cores': [0]} | |
In [39]: x['requests'][1].argument | |
Out[39]: {'arguments': ['-e'], 'cores': [1], 'name': 'firewall', 'nfid': 1} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment