COVISE Core
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
covise::coConfigSchema Class Reference

#include <coConfigSchema.h>

Collaboration diagram for covise::coConfigSchema:
Collaboration graph
[legend]

Public Member Functions

QStringList getGroupsFromSchema ()
 return a List of all Groups (is used in mainwindow to create treeModel) More...
 
coConfigSchemaInfosListgetSchemaInfosForGroup (const QString groupName)
 deliver coConfigSchemaInfosList for group if exists, else nullPointer More...
 
coConfigSchemaInfosgetSchemaInfosForElement (const QString &name)
 return a pointer to the coConfigSchemaInfos of an element More...
 

Static Public Member Functions

static coConfigSchemagetInstance (xercesc::XSModel *model=0)
 
static void loadSchema (const QString &filename=0)
 

Protected Member Functions

 coConfigSchema (xercesc::XSModel *model)
 
 ~coConfigSchema ()
 

Private Member Functions

coConfigSchemaInfoscreateSchemaInfos (xercesc::XSElementDeclaration *elementDecl, const QString parent=QString(""))
 walk the SchemaTree from a given Element, create coConfigSchemaInfos for each and fill them with name in elements Hash More...
 
void sortInGroups ()
 
void walkTree ()
 
void addAnnotationsForElement (xercesc::XSElementDeclaration *elementDecl, coConfigSchemaInfos *schemaInfos)
 get annotations for a element and fill them into the coConfigSchemaInfos More...
 
QHash< QString, QString > * createFromSchemaFileAnnotationsList (xercesc::XSAnnotationList *annoList)
 
QHash< QString, QString > * createFromSchemaFileAnnotation (xercesc::XSAnnotation *anno)
 collects content of xs:appinfo (e.g.: name = "MyName"), divides them by = and adds to a QHash More...
 
QString processSimpleTypeDefinition (xercesc::XSSimpleTypeDefinition *xsSimpleTypeDef)
 
QList< xercesc::XSElementDeclaration * > processParticle (xercesc::XSParticle *xsParticle)
 
QString printCompositorTypeConnector (xercesc::XSModelGroup::COMPOSITOR_TYPE type)
 

Private Attributes

QHash< QString, coConfigSchemaInfos * > elements
 
QHash< QString, coConfigSchemaInfosList * > groups
 
bool walked
 

Static Private Attributes

static xercesc::XSModel * xsModel = 0
 
static coConfigSchemaconfigSchema = 0
 
static QString fileName = ""
 

Constructor & Destructor Documentation

◆ coConfigSchema()

covise::coConfigSchema::coConfigSchema ( xercesc::XSModel *  model)
inlineprotected

◆ ~coConfigSchema()

coConfigSchema::~coConfigSchema ( )
protected

Member Function Documentation

◆ addAnnotationsForElement()

void coConfigSchema::addAnnotationsForElement ( xercesc::XSElementDeclaration *  elementDecl,
coConfigSchemaInfos schemaInfos 
)
private

get annotations for a element and fill them into the coConfigSchemaInfos

◆ createFromSchemaFileAnnotation()

QHash< QString, QString > * coConfigSchema::createFromSchemaFileAnnotation ( xercesc::XSAnnotation *  anno)
private

collects content of xs:appinfo (e.g.: name = "MyName"), divides them by = and adds to a QHash

◆ createFromSchemaFileAnnotationsList()

QHash< QString, QString > * coConfigSchema::createFromSchemaFileAnnotationsList ( xercesc::XSAnnotationList *  annoList)
private

◆ createSchemaInfos()

coConfigSchemaInfos * coConfigSchema::createSchemaInfos ( xercesc::XSElementDeclaration *  elementDecl,
const QString  parent = QString("") 
)
private

walk the SchemaTree from a given Element, create coConfigSchemaInfos for each and fill them with name in elements Hash

process elementType

process Attributes of type

now finaly add infos for one attribute to cConfigSchemaInfo object QStr name of attribute e.g. value bool if attribute is required or optional QStr defaultValue QStr readableRule get QString pattern for RegExp QStr attributeDescrition

end process Attributes of type,

◆ getGroupsFromSchema()

QStringList coConfigSchema::getGroupsFromSchema ( )

return a List of all Groups (is used in mainwindow to create treeModel)

◆ getInstance()

static coConfigSchema * covise::coConfigSchema::getInstance ( xercesc::XSModel *  model = 0)
inlinestatic

◆ getSchemaInfosForElement()

coConfigSchemaInfos * coConfigSchema::getSchemaInfosForElement ( const QString &  name)

return a pointer to the coConfigSchemaInfos of an element

◆ getSchemaInfosForGroup()

coConfigSchemaInfosList * coConfigSchema::getSchemaInfosForGroup ( const QString  groupName)

deliver coConfigSchemaInfosList for group if exists, else nullPointer

◆ loadSchema()

void coConfigSchema::loadSchema ( const QString &  filename = 0)
static

◆ printCompositorTypeConnector()

QString coConfigSchema::printCompositorTypeConnector ( xercesc::XSModelGroup::COMPOSITOR_TYPE  type)
private

◆ processParticle()

QList< xercesc::XSElementDeclaration * > coConfigSchema::processParticle ( xercesc::XSParticle *  xsParticle)
private

◆ processSimpleTypeDefinition()

QString coConfigSchema::processSimpleTypeDefinition ( xercesc::XSSimpleTypeDefinition *  xsSimpleTypeDef)
private

◆ sortInGroups()

void coConfigSchema::sortInGroups ( )
private

◆ walkTree()

void coConfigSchema::walkTree ( )
private

Member Data Documentation

◆ configSchema

covise::coConfigSchema * coConfigSchema::configSchema = 0
staticprivate

◆ elements

QHash<QString, coConfigSchemaInfos *> covise::coConfigSchema::elements
private

◆ fileName

QString coConfigSchema::fileName = ""
staticprivate

◆ groups

QHash<QString, coConfigSchemaInfosList *> covise::coConfigSchema::groups
private

◆ walked

bool covise::coConfigSchema::walked
private

◆ xsModel

xercesc::XSModel * coConfigSchema::xsModel = 0
staticprivate

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