MeshLink
Computational geometry access
MeshLinkParser Class Reference

Base class for MeshLink data parser interface. More...

#include <MeshLinkParser.h>

Inheritance diagram for MeshLinkParser:

Public Member Functions

 MeshLinkParser ()
 Default constructor. More...
 
 ~MeshLinkParser ()
 Destructor. More...
 
virtual bool validate (const std::string &fileName, const std::string &schemaName)
 Validate MeshLink XML file against MeshLink schema. More...
 
virtual bool parseMeshLinkFile (std::string fname, MeshAssociativity *meshAssociativity)
 Parse MeshLink xml file into MeshAssociativity. More...
 
virtual bool getMeshLinkAttributes (std::string &xmlns, std::string &xmlns_xsi, std::string &schemaLocation)
 Return schema-related attributes. More...
 

Detailed Description

Base class for MeshLink data parser interface.

Provides a neutral interface for parsing MeshLink XML data according to an XML Schema Definition (XSD) using a wrapped parsing library.

Definition at line 32 of file MeshLinkParser.h.

Constructor & Destructor Documentation

◆ MeshLinkParser()

MeshLinkParser::MeshLinkParser ( )
inline

Default constructor.

Definition at line 35 of file MeshLinkParser.h.

◆ ~MeshLinkParser()

MeshLinkParser::~MeshLinkParser ( )
inline

Destructor.

Definition at line 37 of file MeshLinkParser.h.

Member Function Documentation

◆ getMeshLinkAttributes()

virtual bool MeshLinkParser::getMeshLinkAttributes ( std::string &  xmlns,
std::string &  xmlns_xsi,
std::string &  schemaLocation 
)
inlinevirtual

Return schema-related attributes.

These attributes are typically used when exporting MeshAssociativity data to a MeshLink XML file.

Parameters
[out]xmlnsthe XML namespace string
[out]xmlns_xsithe XML Schema Instance string
[out]schemaLocationthe XML Schema Definition (XSD) file name

Reimplemented in MeshLinkParserXerces.

Definition at line 68 of file MeshLinkParser.h.

◆ parseMeshLinkFile()

virtual bool MeshLinkParser::parseMeshLinkFile ( std::string  fname,
MeshAssociativity meshAssociativity 
)
inlinevirtual

Parse MeshLink xml file into MeshAssociativity.

Parameters
fnamethe name (path) of the MeshLink XML file to parse
meshAssociativitythe MeshAssociativity object to populate
Returns
true if XML file is valid within the defintion of the schema and the file was successfully read into the MeshAssociativity

Reimplemented in MeshLinkParserXerces.

Definition at line 57 of file MeshLinkParser.h.

◆ validate()

virtual bool MeshLinkParser::validate ( const std::string &  fileName,
const std::string &  schemaName 
)
inlinevirtual

Validate MeshLink XML file against MeshLink schema.

Parameters
fileNamethe name of the XML file to validate
schemaNamethe name of the schema file used for validation; if empty, the XML file must designate the XML Schema Definition (XSD) file location
Returns
true if XML file is valid within the defintion of the schema

Reimplemented in MeshLinkParserXerces.

Definition at line 47 of file MeshLinkParser.h.


The documentation for this class was generated from the following file: