XML

Name -- Syntax / Description
xml_parse
xml_parse( filepath, location, output var )
Parces an XML file.
Returns 1 on success, 0 on error
  • filepath = Location of the file to parse
  • location = either 'script' or 'data'
  • output = xml file parsed into an aggregate structure defined below:
    The variable has one structure member with the name of the root tag as the member name.
xml_parse_error
xml_parse_error( lineno var, error var )
Retrieves error information for xml_parse(), xml_parse_section(), and xml_parse_section_init()
Returns null
  • lineno = line number of the XML file the error occurred (if applicable)
  • errortext = text of the error
xml_parse_section
xml_parse_section( output var, eof var )
Return a section of XML
Returns 1 on success, 0 on failure.
  • output = Parsed XML output, same format as xml_parse()
  • eof = boolean "end of file".
xml_parse_section_getstate
xml_parse_section_getstate( target var )
Retrieves parse state information from a xml_parse_section session.
Returns 1 on success, 0 on failure.
  • target = output aggregate
xml_parse_section_init
xml_parse_section_init( filepath, location, level )
Initializes a xml_parse_section session.
Returns 1 on success, 0 on failure.
  • filepath = source file path (same as xml_parse)
  • location = 'script' or 'data'
  • level = level (not including the root) to return a "section" of parsed XML output.
xml_parse_section_setstate
xml_parse_section_setstate( source var )
Sets internal parse state information for a xml_parse_section session.
Returns 1 on success, 0 on failure.
  • source = input aggregate
xml_parse_set_colon_replacement
xml_parse_set_colon_replacement( colon )
xml_parse_var
xml_parse_var( var var, output var )
User Annotations: xml