Version: 9.15.0
YACS::propertytypeParser Struct Reference

Class for property parser. More...

#include <propertyParsers.hxx>

Inheritance diagram for YACS::propertytypeParser:
Collaboration diagram for YACS::propertytypeParser:

Public Member Functions

virtual void buildAttr (const XML_Char **attr)
 
virtual void name (const std::string &name)
 
virtual void value (const std::string &name)
 
myprop post ()
 
- Public Member Functions inherited from YACS::parser
 parser ()
 
virtual ~parser ()
 
virtual void SetUserDataAndPush (parser *pp)
 
virtual void onStart (const XML_Char *el, const XML_Char **attr)
 
virtual void onEnd (const XML_Char *el, parser *child)
 
virtual void charData (const XML_Char *s, int len)
 
virtual void endParser ()
 
virtual void init ()
 
virtual void incrCount (const XML_Char *elem)
 
virtual void checkOrder (std::string &el)
 
virtual void maxcount (std::string name, int max, std::string &el)
 
virtual void mincount (std::string name, int min)
 
virtual void maxchoice (std::string *names, int max, std::string &el)
 
virtual void minchoice (std::string *names, int min)
 
virtual void pre ()
 
virtual void required (const std::string &name, const XML_Char **attr)
 
std::stack< parser * > & getStack ()
 
template<class T >
post ()
 
void logError (const std::string &reason)
 

Public Attributes

myprop _prop
 
- Public Attributes inherited from YACS::parser
std::string _file
 
std::string _content
 
std::map< std::string, int > * _counts
 
std::map< std::string, int > _orders
 
int _orderState
 
int _level
 
std::stack< std::map< std::string, int > * > _stackCount
 
std::stack< int > _stackOrder
 
std::map< std::string, parser * > * _defaultParsersMap
 

Static Public Attributes

static propertytypeParser propertyParser
 
- Static Public Attributes inherited from YACS::parser
static parser main_parser
 
static std::stack< parser * > _stackParser
 

Additional Inherited Members

- Static Public Member Functions inherited from YACS::parser
static void XMLCALL start_document (void *data)
 
static void XMLCALL end_document (void *data)
 
static void XMLCALL start_element (void *data, const xmlChar *name, const xmlChar **p)
 
static void XMLCALL end_element (void *data, const xmlChar *name)
 
static void XMLCALL characters (void *data, const xmlChar *ch, int len)
 
static void XMLCALL comment (void *data, const xmlChar *value)
 
static void XMLCALL cdata_block (void *data, const xmlChar *value, int len)
 
static void XMLCALL warning (void *data, const char *fmt,...)
 
static void XMLCALL error (void *data, const char *fmt,...)
 
static void XMLCALL fatal_error (void *data, const char *fmt,...)
 
static void XML_SetUserData (_xmlParserCtxt *ctxt, parser *par)
 

Detailed Description

Class for property parser.

Class used to parse a property. A property is a pair of name(string), value(string)

XML schema is

  <xsd:complexType name="PropertyType">
    <xsd:attribute name="name" type="xsd:string" use="required"/>
    <xsd:attribute name="value" type="xsd:string" use="required"/>
  </xsd:complexType>

Definition at line 43 of file propertyParsers.hxx.

Member Function Documentation

◆ buildAttr()

void YACS::propertytypeParser::buildAttr ( const XML_Char **  attr)
virtual

Reimplemented from YACS::parser.

Definition at line 27 of file propertyParsers.cxx.

28  {
29  if (!attr)
30  return;
31  required("name",attr);
32  required("value",attr);
33  for (int i = 0; attr[i]; i += 2)
34  {
35  if(std::string(attr[i]) == "name")name(attr[i+1]);
36  if(std::string(attr[i]) == "value")value(attr[i+1]);
37  }
38  }
virtual void required(const std::string &name, const XML_Char **attr)
Definition: parserBase.cxx:186
virtual void value(const std::string &name)
virtual void name(const std::string &name)

References yacsorb.CORBAEngineTest::i, name(), YACS::parser::required(), and value().

◆ name()

void YACS::propertytypeParser::name ( const std::string &  name)
virtual

Definition at line 39 of file propertyParsers.cxx.

39 { _prop._name=name; }
std::string _name
Definition: factory.hxx:96

References myprop::_name, and _prop.

Referenced by buildAttr(), and value().

◆ post()

myprop YACS::propertytypeParser::post ( )

Definition at line 41 of file propertyParsers.cxx.

41 {return _prop;}

References _prop.

◆ value()

void YACS::propertytypeParser::value ( const std::string &  name)
virtual

Member Data Documentation

◆ _prop

myprop YACS::propertytypeParser::_prop

Definition at line 50 of file propertyParsers.hxx.

Referenced by name(), post(), and value().

◆ propertyParser


The documentation for this struct was generated from the following files: