Classes | Functions
psen_scan_v2_standalone::configuration::xml_config_parsing Namespace Reference

Namespace for parsing xml configuration files exported from the psenScan Configurator. More...

Classes

class  XMLConfigurationParserException
 

Functions

const tinyxml2::XMLElement * getFirstChildElement (const tinyxml2::XMLElement *parent, const char *name)
 
const char * getText (const tinyxml2::XMLElement *element)
 
bool isEncoderEnabled (const tinyxml2::XMLConstHandle &doc_handle)
 
ZoneSetConfiguration parseFile (const char *filename)
 
std::vector< ZoneSetSpeedRangeparseSpeedRanges (const tinyxml2::XMLConstHandle &doc_handle)
 
ZoneSetConfiguration parseString (const char *xml)
 
ZoneSetConfiguration parseTinyXML (const tinyxml2::XMLDocument &doc)
 
ZoneSet parseZoneSet (const tinyxml2::XMLElement *xml_set_element)
 
std::vector< ZoneSetparseZoneSets (const tinyxml2::XMLConstHandle &doc_handle)
 
ZoneSetSpeedRange parseZoneSetSpeedRange (const tinyxml2::XMLElement *xml_zone_set_select_element)
 
std::vector< unsigned long > ro_string_to_vec (const std::string &ro_string)
 Convert string from a <ro> element to values. More...
 
unsigned long ro_value_to_uint (const std::string &ro_value)
 Converts a quadrupel <ro> value into the respective length in mm. More...
 
bool textIsEqual (const tinyxml2::XMLElement *element, const char *str)
 

Detailed Description

Namespace for parsing xml configuration files exported from the psenScan Configurator.

Function Documentation

◆ getFirstChildElement()

const tinyxml2::XMLElement* psen_scan_v2_standalone::configuration::xml_config_parsing::getFirstChildElement ( const tinyxml2::XMLElement *  parent,
const char *  name 
)
inline

Definition at line 28 of file xml_configuration_parsing.cpp.

◆ getText()

const char* psen_scan_v2_standalone::configuration::xml_config_parsing::getText ( const tinyxml2::XMLElement *  element)

Definition at line 40 of file xml_configuration_parsing.cpp.

◆ isEncoderEnabled()

bool psen_scan_v2_standalone::configuration::xml_config_parsing::isEncoderEnabled ( const tinyxml2::XMLConstHandle &  doc_handle)

Definition at line 136 of file xml_configuration_parsing.cpp.

◆ parseFile()

ZoneSetConfiguration psen_scan_v2_standalone::configuration::xml_config_parsing::parseFile ( const char *  filename)

Definition at line 250 of file xml_configuration_parsing.cpp.

◆ parseSpeedRanges()

std::vector<ZoneSetSpeedRange> psen_scan_v2_standalone::configuration::xml_config_parsing::parseSpeedRanges ( const tinyxml2::XMLConstHandle &  doc_handle)

Definition at line 187 of file xml_configuration_parsing.cpp.

◆ parseString()

ZoneSetConfiguration psen_scan_v2_standalone::configuration::xml_config_parsing::parseString ( const char *  xml)

Definition at line 262 of file xml_configuration_parsing.cpp.

◆ parseTinyXML()

ZoneSetConfiguration psen_scan_v2_standalone::configuration::xml_config_parsing::parseTinyXML ( const tinyxml2::XMLDocument &  doc)

Definition at line 216 of file xml_configuration_parsing.cpp.

◆ parseZoneSet()

ZoneSet psen_scan_v2_standalone::configuration::xml_config_parsing::parseZoneSet ( const tinyxml2::XMLElement *  xml_set_element)

Definition at line 56 of file xml_configuration_parsing.cpp.

◆ parseZoneSets()

std::vector<ZoneSet> psen_scan_v2_standalone::configuration::xml_config_parsing::parseZoneSets ( const tinyxml2::XMLConstHandle &  doc_handle)

Definition at line 159 of file xml_configuration_parsing.cpp.

◆ parseZoneSetSpeedRange()

ZoneSetSpeedRange psen_scan_v2_standalone::configuration::xml_config_parsing::parseZoneSetSpeedRange ( const tinyxml2::XMLElement *  xml_zone_set_select_element)

Definition at line 111 of file xml_configuration_parsing.cpp.

◆ ro_string_to_vec()

std::vector<unsigned long> psen_scan_v2_standalone::configuration::xml_config_parsing::ro_string_to_vec ( const std::string &  ro_string)

Convert string from a <ro> element to values.

The value in a <ro> element is a string with length 4*N where N is the number of distance values. 4 succedding values form a set that can be transformed into the lenth in mm.

Parameters
ro_string
Returns
std::vector<unsigned int>

Definition at line 74 of file xml_configuration_parsing.h.

◆ ro_value_to_uint()

unsigned long psen_scan_v2_standalone::configuration::xml_config_parsing::ro_value_to_uint ( const std::string &  ro_value)

Converts a quadrupel <ro> value into the respective length in mm.

The conversion of 4 characters follows the rule "abcd" -> 0xcdab Examples: "D307" -> 0x07D3 -> 2003mm "ED03" -> 0x03ED -> 1005mm "2B01" -> 0x012B -> 299mm "8913" -> 0x1389 -> 5001mm

Parameters
ro_valuestring containing a quadrupel of hex values
Returns
unsigned long length in mm

Definition at line 57 of file xml_configuration_parsing.h.

◆ textIsEqual()

bool psen_scan_v2_standalone::configuration::xml_config_parsing::textIsEqual ( const tinyxml2::XMLElement *  element,
const char *  str 
)
inline

Definition at line 51 of file xml_configuration_parsing.cpp.



psen_scan_v2
Author(s): Pilz GmbH + Co. KG
autogenerated on Sat Nov 5 2022 02:13:36