 |
Eclipse SUMO - Simulation of Urban MObility
|
Go to the documentation of this file.
18 #ifndef SUMOSAXAttributesImpl_Xerces_h
19 #define SUMOSAXAttributesImpl_Xerces_h
30 #include <xercesc/sax2/Attributes.hpp>
54 const std::map<int, XMLCh*>& predefinedTags,
55 const std::map<int, std::string>& predefinedTagsMML,
56 const std::string& objectType);
127 long long int getLong(
int id)
const;
157 const std::string& def)
const;
199 double getFloat(
const std::string&
id)
const;
212 const std::string& def)
const;
270 std::string
getName(
int attr)
const;
298 const XERCES_CPP_NAMESPACE::Attributes&
myAttrs;
bool hasAttribute(int id) const
Returns the information whether the named (by its enum-value) attribute is within the current list.
FringeType
algorithms for computing right of way
std::map< int, XMLCh * > AttrMap
Definition of a map of attribute ids to their xerces-representation.
std::string getName(int attr) const
Converts the given attribute id into a man readable string.
long long int getLong(int id) const
Returns the long-value of the named (by its enum-value) attribute.
RGBColor getColor() const
Returns the value of the named attribute.
Encapsulated Xerces-SAX-attributes.
const XERCES_CPP_NAMESPACE::Attributes & myAttrs
The encapsulated attributes.
SumoXMLEdgeFunc
Numbers representing special SUMO-XML-attribute values for representing edge functions used in netbui...
SUMOSAXAttributes * clone() const
return a new deep-copy attributes object
virtual ~SUMOSAXAttributesImpl_Xerces()
Destructor.
PositionVector getShape(int attr) const
Tries to read given attribute assuming it is a PositionVector.
std::string getStringSecure(int id, const std::string &def) const
Returns the string-value of the named (by its enum-value) attribute.
SumoXMLEdgeFunc getEdgeFunc(bool &ok) const
Returns the value of the named attribute.
SumoXMLNodeType getNodeType(bool &ok) const
Returns the value of the named attribute.
SumoXMLNodeType
Numbers representing special SUMO-XML-attribute values for representing node- (junction-) types used ...
bool getBool(int id) const
Returns the bool-value of the named (by its enum-value) attribute.
double getFloat(int id) const
Returns the double-value of the named (by its enum-value) attribute.
Boundary getBoundary(int attr) const
Tries to read given attribute assuming it is a Boundary.
A class that stores a 2D geometrical boundary.
SUMOSAXAttributesImpl_Xerces(const XERCES_CPP_NAMESPACE::Attributes &attrs, const std::map< int, XMLCh * > &predefinedTags, const std::map< int, std::string > &predefinedTagsMML, const std::string &objectType)
Constructor.
FringeType getFringeType(bool &ok) const
returns fringe type
const std::map< int, std::string > & myPredefinedTagsMML
Map of attribute ids to their (readable) string-representation.
const AttrMap & myPredefinedTags
Map of attribute ids to their xerces-representation.
RightOfWay
algorithms for computing right of way
int getInt(int id) const
Returns the int-value of the named (by its enum-value) attribute.
const XMLCh * getAttributeValueSecure(int id) const
Returns Xerces-value of the named attribute.
std::vector< std::string > getAttributeNames() const
Retrieves all attribute names.
RightOfWay getRightOfWay(bool &ok) const
returns rightOfWay method
std::string getString(int id) const
Returns the string-value of the named (by its enum-value) attribute.
SUMOSAXAttributesImpl_Xerces & operator=(const SUMOSAXAttributesImpl_Xerces &src)
Invalidated assignment operator.
Encapsulated SAX-Attributes.
void serialize(std::ostream &os) const
Prints all attribute names and values into the given stream.