XBinder XML Runtime
XBinder Version 3.0.x
|
XSD global element base class. More...
#include <rtXmlCppXSDElement.h>
Public Member Functions | |
OSXSDGlobalElement (OSRTMessageBufferIF &msgBuf) | |
This constructor sets the internal message buffer pointer to point at the given message buffer or stream object. More... | |
OSXSDGlobalElement (const OSXSDGlobalElement &o) | |
The copy constructor sets the internal message buffer pointer and context to point at the message buffer and context from the original OSCType object. More... | |
virtual | ~OSXSDGlobalElement () |
The virtual destructor does nothing. More... | |
int | decode () |
The decode method decodes the message described by the encapsulated message buffer object. | |
virtual int | decodeFrom (OSRTMessageBufferIF &) |
The decodeFrom method decodes a message from the given message buffer or stream argument. More... | |
int | encode () |
The encode method encodes a message using the encoding rules specified by the derived message buffer object. | |
virtual int | encodeTo (OSRTMessageBufferIF &) |
The encodeTo method encodes a message into the given message buffer or stream argument. More... | |
OSCTXT * | getCtxtPtr () |
The getCtxtPtr method returns the underlying C runtime context. More... | |
void * | memAlloc (size_t numocts) |
The memAlloc method allocates memory using the C runtime memory management functions. More... | |
void | memFreePtr (void *ptr) |
The memFreePtr method frees the memory at a specific location. More... | |
void | setDefaultNamespace (const OSUTF8CHAR *uri) |
The setDefaultNamespace method sets the default namespace for the element to the given value. More... | |
void | setDiag (OSBOOL value=TRUE) |
The setDiag method turns diagnostic tracing on or off. More... | |
void | setEncXSINamespace (OSBOOL value=TRUE) |
The setEncXSINamespace method sets a flag in the internal context that indicates the xsi namespace attribute must be encoded. More... | |
void | setNamespace (const OSUTF8CHAR *prefix, const OSUTF8CHAR *uri) |
The setNamespace method adds or modifies the namespace with the given URI in the namespace list to contain the given prefix. More... | |
void | setNoNSSchemaLocation (const OSUTF8CHAR *uri) |
The setNoNSSchemaLocation method adds an xsi:noNamespaceSchemaLocation attribute to the document. More... | |
void | setSchemaLocation (const OSUTF8CHAR *uri) |
The setSchemaLocation method adds an xsi:schemaLocation attribute to the document. More... | |
void | setXSIType (const OSUTF8CHAR *typeName) |
The setXSIType method sets a type name to be used in the xsi:type attribute in the top-level module element declaration. More... | |
int | validate () |
The validate method validates the message described by the encapsulated message buffer object. | |
virtual int | validateFrom (OSRTMessageBufferIF &) |
The validateFrom method validates a message from the given message buffer or stream argument. More... | |
Protected Member Functions | |
OSXSDGlobalElement () | |
The default constructor sets the message pointer member variable to NULL and creates a new context object. | |
OSXSDGlobalElement (OSRTContext &ctxt) | |
This constructor sets the message pointer member variable to NULL and initializes the context object to point at the given context value. More... | |
void | setMsgBuf (OSRTMessageBufferIF &msgBuf) |
The setMsgBuf method is used to set the internal message buffer pointer to point at the given message buffer or stream object. More... | |
Protected Attributes | |
OSRTCtxtPtr | mpContext |
The mpContext member variable holds a reference-counted C runtime variable. More... | |
OSRTMessageBufferIF * | mpMsgBuf |
The mpMsgBuf member variable is a pointer to a derived message buffer or stream class that will manage the message being encoded or decoded. | |
XSD global element base class.
This is the main base class for all generated global element control classes. It holds a variable of a generated data type as well as the associated message buffer or stream class to which a message will be encoded or from which a message will be decoded.
Definition at line 57 of file rtXmlCppXSDElement.h.
|
inlineprotected |
This constructor sets the message pointer member variable to NULL and initializes the context object to point at the given context value.
ctxt | - Reference to a context object. |
Definition at line 85 of file rtXmlCppXSDElement.h.
|
inline |
This constructor sets the internal message buffer pointer to point at the given message buffer or stream object.
The context is set to point at the context contained within the message buffer object. Thus, the message buffer and control class object share the context. It will not be released until both objects are destroyed.
msgBuf | - Reference to a message buffer or stream object. |
Definition at line 105 of file rtXmlCppXSDElement.h.
|
inline |
The copy constructor sets the internal message buffer pointer and context to point at the message buffer and context from the original OSCType object.
o | - Reference to a global element object. |
Definition at line 116 of file rtXmlCppXSDElement.h.
|
inlinevirtual |
The virtual destructor does nothing.
It is overridden by derived versions of this class.
Definition at line 123 of file rtXmlCppXSDElement.h.
|
inlinevirtual |
The decodeFrom
method decodes a message from the given message buffer or stream argument.
- | Message buffer or stream containing message to decode. |
Definition at line 138 of file rtXmlCppXSDElement.h.
|
inlinevirtual |
The encodeTo
method encodes a message into the given message buffer or stream argument.
- | Message buffer or stream to which the message is to be encoded. |
Definition at line 153 of file rtXmlCppXSDElement.h.
|
inline |
The getCtxtPtr method returns the underlying C runtime context.
This context can be used in calls to C runtime functions.
Definition at line 159 of file rtXmlCppXSDElement.h.
|
inline |
The memAlloc method allocates memory using the C runtime memory management functions.
The memory is tracked in the underlying context structure. When both this OSXSDGlobalElement derived control class object and the message buffer object are destroyed, this memory will be freed.
numocts | - Number of bytes of memory to allocate |
Definition at line 172 of file rtXmlCppXSDElement.h.
|
inline |
The memFreePtr method frees the memory at a specific location.
This memory must have been allocated using the memAlloc method described earlier.
ptr | - Pointer to a block of memory allocated with memAlloc |
Definition at line 200 of file rtXmlCppXSDElement.h.
|
inline |
The setDefaultNamespace method sets the default namespace for the element to the given value.
uri | - Default namespace URI |
Definition at line 210 of file rtXmlCppXSDElement.h.
|
inline |
The setDiag method turns diagnostic tracing on or off.
value | - Boolean on/off value (default = on) |
Definition at line 219 of file rtXmlCppXSDElement.h.
|
inline |
The setEncXSINamespace method sets a flag in the internal context that indicates the xsi namespace attribute must be encoded.
value | - Boolean on/off value (default = on) |
Definition at line 229 of file rtXmlCppXSDElement.h.
References rtXmlSetEncXSINamespace().
|
protected |
The setMsgBuf method is used to set the internal message buffer pointer to point at the given message buffer or stream object.
msgBuf | - Reference to a message buffer or stream object. |
|
inline |
The setNamespace method adds or modifies the namespace with the given URI in the namespace list to contain the given prefix.
prefix | - Namespace prefix |
uri | - Namespace URI |
Definition at line 240 of file rtXmlCppXSDElement.h.
|
inline |
The setNoNSSchemaLocation method adds an xsi:noNamespaceSchemaLocation attribute to the document.
uri | - URI for noNamespaceSchemaLocation. |
Definition at line 250 of file rtXmlCppXSDElement.h.
References rtXmlSetNoNSSchemaLocation().
|
inline |
The setSchemaLocation method adds an xsi:schemaLocation attribute to the document.
uri | - URI for schemaLocation. |
Definition at line 260 of file rtXmlCppXSDElement.h.
References rtXmlSetSchemaLocation().
|
inline |
The setXSIType method sets a type name to be used in the xsi:type attribute in the top-level module element declaration.
typeName | - XSI type name |
Definition at line 270 of file rtXmlCppXSDElement.h.
References rtXmlSetXSITypeAttr().
|
inlinevirtual |
The validateFrom
method validates a message from the given message buffer or stream argument.
- | Message buffer or stream containing message to validate. |
Definition at line 287 of file rtXmlCppXSDElement.h.
|
protected |
The mpContext member variable holds a reference-counted C runtime variable.
This context is used in calls to all C run-time functions. The context pointed at by this smart-pointer object is shared with the message buffer object contained within this class.
Definition at line 65 of file rtXmlCppXSDElement.h.