NCL Composer  0.1.5
 All Classes Functions Variables Pages
composer::util::AttributeReferences Class Reference

Keep information about which pair (element, attribute) can refer a value of another pair (element, attribute). More...

#include <AttributeReferences.h>

Collaboration diagram for composer::util::AttributeReferences:

Public Types

enum  REFERENCE_SCOPE { ANY_SCOPE = 0, SAME_SCOPE, USERDEFINED_SCOPE }
 

Public Member Functions

 AttributeReferences (QString element, QString attr, QString ref_element, QString ref_attr, REFERENCE_SCOPE scope=ANY_SCOPE)
 Constructor. More...
 
 AttributeReferences (QString element, QString attr, QString ref_element, QString ref_attr, QString scope)
 Constructor. More...
 
QString getElement ()
 Get the source element. More...
 
QString getAttribute ()
 Get the source attribute. More...
 
QString getRefElement ()
 Get the name of referred element. More...
 
QString getRefAttribute ()
 Get the name of the referred attribute (an ref_element's attribute). More...
 
void setScope (QString scope)
 Sets the scope of the object as a string. More...
 
REFERENCE_SCOPE getScope ()
 Gets the scope of the object as a REFERENCE_SCOPE. More...
 
QString getUserDefinedScope ()
 Gets the string where the user define the scope. More...
 

Detailed Description

Keep information about which pair (element, attribute) can refer a value of another pair (element, attribute).

This class is mainly used to described the language profile.

Definition at line 25 of file AttributeReferences.h.

Constructor & Destructor Documentation

composer::util::AttributeReferences::AttributeReferences ( QString  element,
QString  attr,
QString  ref_element,
QString  ref_attr,
REFERENCE_SCOPE  scope = ANY_SCOPE 
)

Constructor.

Parameters
elementThe source Element.
attrThe source Attribute (should be an element's attribute).
ref_elementThe target element.
ref_attrThe target attribute (should be an ref_element's attribute).
scopeWhich scope.

Definition at line 15 of file AttributeReferences.cpp.

composer::util::AttributeReferences::AttributeReferences ( QString  element,
QString  attr,
QString  ref_element,
QString  ref_attr,
QString  scope 
)

Constructor.

Parameters
elementThe source Element.
attrThe source Attribute (should be an element's attribute).
ref_elementThe target element.
ref_attrThe target attribute (should be an ref_element's attribute).
scopeWhich scope (as a string).

Definition at line 30 of file AttributeReferences.cpp.

Member Function Documentation

QString composer::util::AttributeReferences::getAttribute ( )

Get the source attribute.

Returns
QString the name of the source attribute.

Definition at line 57 of file AttributeReferences.cpp.

Here is the caller graph for this function:

QString composer::util::AttributeReferences::getElement ( )

Get the source element.

Returns
QString the name of the source element.

Definition at line 52 of file AttributeReferences.cpp.

QString composer::util::AttributeReferences::getRefAttribute ( )

Get the name of the referred attribute (an ref_element's attribute).

Returns
QString The name of the referred attribute.

Definition at line 67 of file AttributeReferences.cpp.

QString composer::util::AttributeReferences::getRefElement ( )

Get the name of referred element.

Returns
QString The name of the referred element.

Definition at line 62 of file AttributeReferences.cpp.

AttributeReferences::REFERENCE_SCOPE composer::util::AttributeReferences::getScope ( )

Gets the scope of the object as a REFERENCE_SCOPE.

Returns
REFERENCE_SCOPE the type of the scope.

Definition at line 72 of file AttributeReferences.cpp.

QString composer::util::AttributeReferences::getUserDefinedScope ( )

Gets the string where the user define the scope.

Returns
QString the user defined scope.

Definition at line 86 of file AttributeReferences.cpp.

void composer::util::AttributeReferences::setScope ( QString  scope)

Sets the scope of the object as a string.

Returns
QString the name of the scope.

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