All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
te::xsd::ComplexContent Class Reference

It models an XML Schema complexContent element. More...

#include <ComplexContent.h>

Inheritance diagram for te::xsd::ComplexContent:
te::xsd::Identifiable te::xsd::Annotated

Public Member Functions

 ComplexContent (TypeDerivation *dev=0, Annotation *ann=0, std::string *id=0)
 Constructor. More...
 
 ComplexContent (const ComplexContent &rhs)
 Copy constructor. More...
 
AnnotationgetAnnotation () const
 It returns the associated annotation. More...
 
std::string * getId () const
 It returns a pointer (may be NULL) to the object id. More...
 
TypeDerivationgetTypeDerivation () const
 It returns the derivation type of this ComplexContent. More...
 
bool isMixed ()
 If the ComplexContent is mixed or not. More...
 
ComplexContentoperator= (const ComplexContent &rhs)
 Assignment operator. More...
 
void setAnnotation (Annotation *ann)
 It sets the associated annotation. More...
 
void setAsMixed (bool v)
 It specifies whether character data is allowed to appear between the child elements of this complexType element. More...
 
void setId (std::string *id)
 it sets the id. More...
 
void setTypeDerivation (TypeDerivation *t)
 It sets the derivation type of this ComplexContent: (restriction | extension). More...
 
 ~ComplexContent ()
 Destructor. More...
 

Private Attributes

TypeDerivationm_derivation
 It can be: restriction (Restriction4ComplexContent) | extension. (Required) More...
 
bool m_mixed
 It specifies whether character data is allowed to appear between the child elements of this complexType element. Default is false. (Optional) More...
 

Detailed Description

It models an XML Schema complexContent element.

The ComplexContent element defines extensions or restrictions on a complex type that contains mixed content or elements only.

Note
Parent elements: complexType

Definition at line 49 of file ComplexContent.h.

Constructor & Destructor Documentation

te::xsd::ComplexContent::ComplexContent ( TypeDerivation dev = 0,
Annotation ann = 0,
std::string *  id = 0 
)

Constructor.

Parameters
devIt specifies the element content and can be: restriction | extension.
annAn annotation.
idIt specifies a unique ID for the element.
Note
The ComplexContent object will take the ownership of the pointers.

Definition at line 28 of file ComplexContent.cpp.

te::xsd::ComplexContent::ComplexContent ( const ComplexContent rhs)

Copy constructor.

Parameters
rhsRight-hand-side object.

Definition at line 36 of file ComplexContent.cpp.

References te::xsd::TypeDerivation::clone(), and m_derivation.

te::xsd::ComplexContent::~ComplexContent ( )

Destructor.

Definition at line 45 of file ComplexContent.cpp.

Member Function Documentation

te::xsd::Annotation * te::xsd::Annotated::getAnnotation ( ) const
inherited

It returns the associated annotation.

Returns
The associated annotation.

Definition at line 30 of file Annotated.cpp.

References te::xsd::Annotated::m_annotation.

std::string * te::xsd::Identifiable::getId ( ) const
inherited

It returns a pointer (may be NULL) to the object id.

Definition at line 35 of file Identifiable.cpp.

te::xsd::TypeDerivation * te::xsd::ComplexContent::getTypeDerivation ( ) const

It returns the derivation type of this ComplexContent.

Returns
The derivation type: restriction | extension.

Definition at line 73 of file ComplexContent.cpp.

bool te::xsd::ComplexContent::isMixed ( )

If the ComplexContent is mixed or not.

Returns
True if the ComplexContent is mixed and false if not.

Definition at line 68 of file ComplexContent.cpp.

te::xsd::ComplexContent & te::xsd::ComplexContent::operator= ( const ComplexContent rhs)

Assignment operator.

Parameters
rhsRight-hand-side object.
Returns
A reference to this object.

Definition at line 50 of file ComplexContent.cpp.

References te::xsd::TypeDerivation::clone(), m_derivation, m_mixed, te::xsd::Identifiable::operator=(), and te::xsd::Annotated::operator=().

void te::xsd::Annotated::setAnnotation ( Annotation ann)
inherited

It sets the associated annotation.

Parameters
annThe annotation to be associated to the object. The annotated class will take the ownership of the given pointer.

Definition at line 35 of file Annotated.cpp.

Referenced by te::xsd::serialize::ReadAnnotated().

void te::xsd::ComplexContent::setAsMixed ( bool  v)

It specifies whether character data is allowed to appear between the child elements of this complexType element.

Parameters
vTrue indicates that character data is allowed to appear between the child elements of this complexType element.

Definition at line 78 of file ComplexContent.cpp.

void te::xsd::Identifiable::setId ( std::string *  id)
inherited

it sets the id.

Parameters
idThe id to be associated to the object. It will take the ownership of the given string.

Definition at line 29 of file Identifiable.cpp.

References te::xsd::Identifiable::m_id.

Referenced by te::xsd::serialize::ReadIdentifiable().

void te::xsd::ComplexContent::setTypeDerivation ( TypeDerivation t)

It sets the derivation type of this ComplexContent: (restriction | extension).

Parameters
tThe derivation type of this ComplexContent.
Note
The ComplexContent object will take the ownership of the given TypeDerivation.

Definition at line 83 of file ComplexContent.cpp.

Member Data Documentation

TypeDerivation* te::xsd::ComplexContent::m_derivation
private

It can be: restriction (Restriction4ComplexContent) | extension. (Required)

Definition at line 116 of file ComplexContent.h.

Referenced by ComplexContent(), and operator=().

bool te::xsd::ComplexContent::m_mixed
private

It specifies whether character data is allowed to appear between the child elements of this complexType element. Default is false. (Optional)

Definition at line 115 of file ComplexContent.h.

Referenced by operator=().


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