Xerces-C++  3.1.2
Public Types | Public Member Functions | Protected Attributes | List of all members
PSVIItem Class Referenceabstract
Inheritance diagram for PSVIItem:
XMemory PSVIAttribute PSVIElement

Public Types

enum  VALIDITY_STATE { VALIDITY_NOTKNOWN = 0, VALIDITY_INVALID = 1, VALIDITY_VALID = 2 }
 
enum  ASSESSMENT_TYPE { VALIDATION_NONE = 0, VALIDATION_PARTIAL = 1, VALIDATION_FULL = 2 }
 

Public Member Functions

virtual XSValuegetActualValue () const
 Get actual value in the form of XSValue, caller needs to delete the object returned. More...
 
Constructors
 PSVIItem (MemoryManager *const manager=XMLPlatformUtils::fgMemoryManager)
 The default constructor. More...
 
Destructor
virtual ~PSVIItem ()
 
PSVIItem methods
const XMLChgetValidationContext ()
 [validation context] More...
 
VALIDITY_STATE getValidity () const
 Determine the validity of the node with respect to the validation being attempted. More...
 
ASSESSMENT_TYPE getValidationAttempted () const
 Determines the extent to which the item has been validated. More...
 
const XMLChgetSchemaNormalizedValue ()
 A list of error codes generated from validation attempts. More...
 
virtual XSTypeDefinitiongetTypeDefinition ()=0
 An item isomorphic to the type definition used to validate this element. More...
 
virtual XSSimpleTypeDefinitiongetMemberTypeDefinition ()=0
 If and only if that type definition is a simple type definition with {variety} union, or a complex type definition whose {content type} is a simple thype definition with {variety} union, then an item isomorphic to that member of the union's {member type definitions} which actually validated the element item's normalized value. More...
 
const XMLChgetSchemaDefault ()
 [schema default] More...
 
bool getIsSchemaSpecified () const
 [schema specified] More...
 
const XMLChgetCanonicalRepresentation () const
 Return the canonical representation of this value. More...
 
void setValidationAttempted (PSVIItem::ASSESSMENT_TYPE attemptType)
 methods needed by implementation More...
 
void setValidity (PSVIItem::VALIDITY_STATE validity)
 
void reset (const XMLCh *const validationContext, const XMLCh *const normalizedValue, const VALIDITY_STATE validityState, const ASSESSMENT_TYPE assessmentType)
 reset the object More...
 
- Public Member Functions inherited from XMemory
void * operator new (size_t size)
 This method overrides operator new. More...
 
void * operator new (size_t size, MemoryManager *memMgr)
 This method defines a custom operator new, that will use the provided memory manager to perform the allocation. More...
 
void * operator new (size_t size, void *ptr)
 This method overrides placement operator new. More...
 
void operator delete (void *p)
 This method overrides operator delete. More...
 
void operator delete (void *p, MemoryManager *memMgr)
 This method provides a matching delete for the custom operator new. More...
 
void operator delete (void *p, void *ptr)
 This method provides a matching delete for the placement new. More...
 

Protected Attributes

MemoryManager *const fMemoryManager
 
const XMLChfValidationContext
 
const XMLChfNormalizedValue
 
const XMLChfDefaultValue
 
XMLChfCanonicalValue
 
VALIDITY_STATE fValidityState
 
ASSESSMENT_TYPE fAssessmentType
 
bool fIsSpecified
 
XSTypeDefinitionfType
 
XSSimpleTypeDefinitionfMemberType
 

Additional Inherited Members

- Protected Member Functions inherited from XMemory
 XMemory ()
 Protected default constructor. More...
 

Member Enumeration Documentation

Enumerator
VALIDATION_NONE 

Validation status indicating that schema validation has been performed and the element in question has specifically been skipped.

VALIDATION_PARTIAL 

Validation status indicating that schema validation has been performed on the element in question under the rules of lax validation.

VALIDATION_FULL 

Validation status indicating that full schema validation has been performed on the element.

Enumerator
VALIDITY_NOTKNOWN 

Validity value indicating that validation has either not been performed or that a strict assessment of validity could not be performed.

VALIDITY_INVALID 

Validity value indicating that validation has been strictly assessed and the element in question is invalid according to the rules of schema validation.

VALIDITY_VALID 

Validity value indicating that validation has been strictly assessed and the element in question is valid according to the rules of schema validation.

Constructor & Destructor Documentation

PSVIItem::PSVIItem ( MemoryManager *const  manager = XMLPlatformUtils::fgMemoryManager)

The default constructor.

Parameters
managerThe configurable memory manager
PSVIItem::~PSVIItem ( )
virtual

Member Function Documentation

virtual XSValue* PSVIItem::getActualValue ( ) const
virtual

Get actual value in the form of XSValue, caller needs to delete the object returned.

Returns
an XSValue
const XMLCh * PSVIItem::getCanonicalRepresentation ( ) const

Return the canonical representation of this value.

Note that, formally, this is not a PSVI property.

Returns
string representing the canonical representation, if this item was validated by a simple type definition for which canonical representations of values are defined.

References fCanonicalValue.

bool PSVIItem::getIsSchemaSpecified ( ) const

[schema specified]

See also
XML Schema Part 1: Structures [schema specified]
Returns
true - value was specified in schema, false - value comes from the infoset

References fIsSpecified.

virtual XSSimpleTypeDefinition* PSVIItem::getMemberTypeDefinition ( )
pure virtual

If and only if that type definition is a simple type definition with {variety} union, or a complex type definition whose {content type} is a simple thype definition with {variety} union, then an item isomorphic to that member of the union's {member type definitions} which actually validated the element item's normalized value.

Returns
a simple type declaration

Implemented in PSVIElement, and PSVIAttribute.

const XMLCh * PSVIItem::getSchemaDefault ( )

[schema default]

Returns
The canonical lexical representation of the declaration's {value constraint} value.
See also
XML Schema Part 1: Structures [schema default]

References fDefaultValue.

const XMLCh * PSVIItem::getSchemaNormalizedValue ( )

A list of error codes generated from validation attempts.

Need to find all the possible sub-clause reports that need reporting

Returns
list of error codes [schema normalized value]
See also
XML Schema Part 1: Structures [schema normalized value]
Returns
the normalized value of this item after validation

References fNormalizedValue.

virtual XSTypeDefinition* PSVIItem::getTypeDefinition ( )
pure virtual

An item isomorphic to the type definition used to validate this element.

Returns
a type declaration

Implemented in PSVIElement, and PSVIAttribute.

PSVIItem::ASSESSMENT_TYPE PSVIItem::getValidationAttempted ( ) const

Determines the extent to which the item has been validated.

Returns
return the [validation attempted] property. The possible values are VALIDATION_NONE, VALIDATION_ORDERED_PARTIAL and VALIDATION_FULL

References fAssessmentType.

const XMLCh * PSVIItem::getValidationContext ( )

[validation context]

Returns
A string identifying the nearest ancestor element information item with a [schema information] property (or this element item itself if it has such a property) (form to be determined)
See also
XML Schema Part 1: Structures [validation context]

References fValidationContext.

PSVIItem::VALIDITY_STATE PSVIItem::getValidity ( ) const

Determine the validity of the node with respect to the validation being attempted.

Returns
return the [validity] property. Possible values are: VALIDITY_UNKNOWN, VALIDITY_INVALID, VALIDITY_VALID

References fValidityState.

void PSVIItem::reset ( const XMLCh *const  validationContext,
const XMLCh *const  normalizedValue,
const VALIDITY_STATE  validityState,
const ASSESSMENT_TYPE  assessmentType 
)

reset the object

Parameters
validationContextcorresponds to schema validation context property
normalizedValuecorresponds to schema normalized value property
validityStatestate of item's validity
assessmentTypetype of assessment carried out on item
void PSVIItem::setValidationAttempted ( PSVIItem::ASSESSMENT_TYPE  attemptType)

methods needed by implementation

void PSVIItem::setValidity ( PSVIItem::VALIDITY_STATE  validity)

Member Data Documentation

ASSESSMENT_TYPE PSVIItem::fAssessmentType
protected

Referenced by getValidationAttempted().

XMLCh* PSVIItem::fCanonicalValue
protected
const XMLCh* PSVIItem::fDefaultValue
protected

Referenced by getSchemaDefault().

bool PSVIItem::fIsSpecified
protected

Referenced by getIsSchemaSpecified().

XSSimpleTypeDefinition* PSVIItem::fMemberType
protected
MemoryManager* const PSVIItem::fMemoryManager
protected
const XMLCh* PSVIItem::fNormalizedValue
protected
XSTypeDefinition* PSVIItem::fType
protected
const XMLCh* PSVIItem::fValidationContext
protected

Referenced by getValidationContext().

VALIDITY_STATE PSVIItem::fValidityState
protected

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