heat.common.template_format.
convert_json_to_yaml
(json_str)[source]¶Convert AWS JSON template format to Heat YAML format.
Parameters: | json_str – a string containing the AWS JSON template format. |
---|---|
Returns: | the equivalent string containing the Heat YAML format. |
heat.common.template_format.
parse
(tmpl_str, tmpl_url=None)[source]¶Takes a string and returns a dict containing the parsed structure.
This includes determination of whether the string is using the JSON or YAML format.
heat.common.template_format.
validate_template_limit
(contain_str)[source]¶Validate limit for the template.
Check if the contain exceeds allowed size range.
heat.common.template_format.
yaml_dumper
(stream, default_style=None, default_flow_style=None, canonical=None, indent=None, width=None, allow_unicode=None, line_break=None, encoding=None, explicit_start=None, explicit_end=None, version=None, tags=None)[source]¶Bases: yaml.dumper.SafeDumper
yaml_representers
= {None: <unbound method SafeRepresenter.represent_undefined>, <type 'int'>: <unbound method SafeRepresenter.represent_int>, <type 'long'>: <unbound method SafeRepresenter.represent_long>, <type 'float'>: <unbound method SafeRepresenter.represent_float>, <type 'unicode'>: <unbound method SafeRepresenter.represent_unicode>, <type 'set'>: <unbound method SafeRepresenter.represent_set>, <type 'NoneType'>: <unbound method SafeRepresenter.represent_none>, <type 'bool'>: <unbound method SafeRepresenter.represent_bool>, <type 'tuple'>: <unbound method SafeRepresenter.represent_list>, <type 'dict'>: <unbound method SafeRepresenter.represent_dict>, <type 'str'>: <unbound method SafeRepresenter.represent_str>, <type 'list'>: <unbound method SafeRepresenter.represent_list>, <type 'datetime.datetime'>: <unbound method SafeRepresenter.represent_datetime>, <type 'datetime.date'>: <unbound method SafeRepresenter.represent_date>, <class 'collections.OrderedDict'>: <unbound method yaml_dumper.represent_ordered_dict>}¶heat.common.template_format.
yaml_loader
(stream)[source]¶Bases: yaml.loader.SafeLoader
yaml_constructors
= {None: <unbound method SafeConstructor.construct_undefined>, u'tag:yaml.org,2002:binary': <unbound method SafeConstructor.construct_yaml_binary>, u'tag:yaml.org,2002:bool': <unbound method SafeConstructor.construct_yaml_bool>, u'tag:yaml.org,2002:float': <unbound method SafeConstructor.construct_yaml_float>, u'tag:yaml.org,2002:int': <unbound method SafeConstructor.construct_yaml_int>, u'tag:yaml.org,2002:map': <unbound method SafeConstructor.construct_yaml_map>, u'tag:yaml.org,2002:null': <unbound method SafeConstructor.construct_yaml_null>, u'tag:yaml.org,2002:omap': <unbound method SafeConstructor.construct_yaml_omap>, u'tag:yaml.org,2002:pairs': <unbound method SafeConstructor.construct_yaml_pairs>, u'tag:yaml.org,2002:seq': <unbound method SafeConstructor.construct_yaml_seq>, u'tag:yaml.org,2002:set': <unbound method SafeConstructor.construct_yaml_set>, u'tag:yaml.org,2002:str': <unbound method yaml_loader._construct_yaml_str>, u'tag:yaml.org,2002:timestamp': <unbound method yaml_loader._construct_yaml_str>}¶Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.