Xalan-C++ API Documentation

The Xalan C++ XSLT Processor Version 1.11


Classes | Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Static Protected Attributes | Friends

XObject Class Reference

Class to hold XPath return types. More...

#include <XObject.hpp>

Inherits XalanReferenceCountedObject.

Inherited by XBoolean, XNodeSetBase, XNumberBase, XResultTreeFrag, XStringBase, XToken, and XUnknown.

Collaboration diagram for XObject:
Collaboration graph
[legend]

List of all members.

Classes

Public Types

Public Member Functions

Static Public Member Functions

Protected Member Functions

Static Protected Attributes

Friends


Detailed Description

Class to hold XPath return types.

Definition at line 63 of file XObject.hpp.


Member Typedef Documentation

Definition at line 69 of file XObject.hpp.

typedef void(FormatterListener::* XObject::MemberFunctionPtr)(const XMLCh *const, const FormatterListener::size_type)

Definition at line 180 of file XObject.hpp.


Member Enumeration Documentation

Enumeration of possible object types.

Enumerator:
eTypeNull 
eTypeUnknown 
eTypeBoolean 
eTypeNumber 
eTypeString 
eTypeNodeSet 
eTypeResultTreeFrag 
eTypeUserDefined 
eTypeStringReference 
eTypeStringAdapter 
eTypeStringCached 
eTypeXTokenNumberAdapter 
eTypeXTokenStringAdapter 
eTypeNodeSetNodeProxy 
eUnknown 

Definition at line 74 of file XObject.hpp.


Constructor & Destructor Documentation

XObject::XObject ( eObjectType  theObjectType,
MemoryManager &  theMemoryManager 
)

Create an XObject.

Parameters:
theObjectType The enum for the type of the object.
theMemoryManager The MemoryManager instance.
XObject::XObject ( const XObject  )  [protected]

Create an XObject from another XObject.

The recommended copy constructor is the next overload, that accepts an explicit MemoryManager instance.

Parameters:
source The source for the copy
XObject::XObject ( const XObject source,
MemoryManager &  theManager 
) [protected]

Create an XObject from another XObject.

Parameters:
source The source for the copy
theMemoryManager The MemoryManager instance.
virtual XObject::~XObject (  )  [protected, virtual]

Member Function Documentation

virtual bool XObject::boolean ( XPathExecutionContext executionContext  )  const [pure virtual]

Cast result object to a boolean.

Parameters:
executionContext The current XPathExecutionContext
Returns:
boolean value

Implemented in XResultTreeFrag, XBoolean, XNodeSetBase, XNumberBase, XStringBase, XToken, and XUnknown.

static bool XObject::boolean ( double  theNumber  )  [inline, static]

Static conversion function.

Returns the boolean value of the supplied double.

Parameters:
theString The double to convert.
Returns:
bool value

Definition at line 372 of file XObject.hpp.

static bool XObject::boolean ( const XalanDOMString theString  )  [inline, static]

Static conversion function.

Returns the boolean value of the supplied XalanDOMString.

Parameters:
theString The XalanDOMString to convert.
Returns:
bool value

Definition at line 385 of file XObject.hpp.

static bool XObject::boolean ( const NodeRefListBase theNodeList  )  [inline, static]

Static conversion function.

Returns the boolean value of the supplied NodeRefListBase.

Parameters:
theNodeList The NodeRefListBase to convert.
Returns:
bool value

Definition at line 398 of file XObject.hpp.

virtual void XObject::dereferenced (  )  [protected, virtual]

Implements XalanReferenceCountedObject.

Reimplemented in XResultTreeFrag, and XToken.

bool XObject::equals ( const XObject theRHS,
XPathExecutionContext executionContext 
) const

Tell if two objects are functionally equal.

Parameters:
theRHS object to compare
executionContext the current execution context
Returns:
true if they are equal
MemoryManager& XObject::getMemoryManager (  )  const [inline, protected]

Get the MemoryManager for this instance.

Returns:
The MemoryManager.

Reimplemented in XResultTreeFrag.

Definition at line 821 of file XObject.hpp.

virtual eObjectType XObject::getRealType (  )  const [protected, virtual]

Tell what kind of class this is.

Returns:
numeric type value

Reimplemented in XNodeSetNodeProxy, XStringAdapter, XStringCached, XStringReference, XTokenNumberAdapter, and XTokenStringAdapter.

eObjectType XObject::getType (  )  const [inline]

Tell what kind of class this is.

Returns:
numeric type value

Definition at line 358 of file XObject.hpp.

virtual const XalanDOMString& XObject::getTypeString (  )  const [pure virtual]

Given a request type, return the equivalent string.

For diagnostic purposes.

Returns:
string for type

Implemented in XResultTreeFrag, XBoolean, XNodeSetBase, XNumberBase, XStringBase, XToken, and XUnknown.

bool XObject::greaterThan ( const XObject theRHS,
XPathExecutionContext executionContext 
) const

Tell if one object is greater than the other.

Parameters:
theRHS object to compare
Returns:
true if they are equal
bool XObject::greaterThanOrEquals ( const XObject theRHS,
XPathExecutionContext executionContext 
) const

Tell if one object is greater than or equal the other.

Parameters:
theRHS object to compare
Returns:
true if they are equal
static void XObject::initialize ( MemoryManager &  theMemoryManager  )  [static]

Perform static initialization.

See class XPathInit.

Parameters:
theMemoryManager The MemoryManager instance.

Reimplemented in XUnknown.

bool XObject::lessThan ( const XObject theRHS,
XPathExecutionContext executionContext 
) const

Tell if one object is less than the other.

Parameters:
theRHS object to compare
Returns:
true if they are equal
bool XObject::lessThanOrEquals ( const XObject theRHS,
XPathExecutionContext executionContext 
) const

Tell if one object is less than or equal the other.

Parameters:
theRHS object to compare
Returns:
true if they are equal
virtual const NodeRefListBase& XObject::nodeset (  )  const [virtual]

Cast result object to a nodelist.

This function does not have access to the current XPathExecutionContext, so the result may contain data from whitespace text nodes that might have been stripped otherwise.

Parameters:
executionContext The current XPathExecutionContext
Returns:
node list

Reimplemented in XNodeSet, XNodeSetBase, and XNodeSetNodeProxy.

bool XObject::notEquals ( const XObject theRHS,
XPathExecutionContext executionContext 
) const

Tell if two objects are functionally not equal.

Parameters:
theRHS object to compare
executionContext the current execution context
Returns:
true if they are equal
virtual double XObject::num ( XPathExecutionContext executionContext  )  const [virtual]

Cast result object to a number.

Parameters:
executionContext The current XPathExecutionContext
Returns:
numeric value

Reimplemented in XResultTreeFrag, XBoolean, XNodeSetBase, XNumber, XNumberBase, XStringBase, XToken, XTokenNumberAdapter, XTokenStringAdapter, and XUnknown.

virtual double XObject::num (  )  const [virtual]

Cast result object to a number.

This function does not have access to the current XPathExecutionContext, so the result may contain data from whitespace text nodes that might have been stripped otherwise.

Returns:
numeric value

Reimplemented in XResultTreeFrag, XNumber, XToken, XTokenNumberAdapter, XTokenStringAdapter, and XUnknown.

static double XObject::number ( bool  theBoolean  )  [inline, static]

Static conversion function.

Returns:
bool value

Definition at line 693 of file XObject.hpp.

static double XObject::number ( XPathExecutionContext executionContext,
const NodeRefListBase theNodeList 
) [static]

Static conversion function.

Returns:
The number value of the node list
static double XObject::number ( const XalanDOMString theString,
MemoryManager &  theManager 
) [inline, static]

Definition at line 699 of file XObject.hpp.

static double XObject::number ( XPathExecutionContext executionContext,
const XalanNode theNode 
) [static]

Static conversion function.

Returns:
The number value of the node
virtual void XObject::ProcessXObjectTypeCallback ( XObjectTypeCallback theCallbackObject  )  const [pure virtual]

Process a callback request for preferred type information.

Parameters:
theCallbackObject object to call back

Implemented in XResultTreeFrag, XBoolean, XNodeSetBase, XNumberBase, XStringBase, XToken, and XUnknown.

virtual void XObject::ProcessXObjectTypeCallback ( XObjectTypeCallback theCallbackObject  )  [pure virtual]

Process a callback request for preferred type information.

Parameters:
theCallbackObject object to call back

Implemented in XResultTreeFrag, XBoolean, XNodeSetBase, XNumberBase, XStringBase, XToken, and XUnknown.

virtual void XObject::referenced (  )  [protected, virtual]

Implements XalanReferenceCountedObject.

Reimplemented in XToken.

virtual const XalanDocumentFragment& XObject::rtree (  )  const [virtual]

Cast result object to a result tree fragment.

Parameters:
executionContext The current XPathExecutionContext
Returns:
result tree fragment

Reimplemented in XResultTreeFrag, XNodeSetBase, and XStringBase.

void XObject::setFactory ( XObjectFactory theFactory  )  [inline]

Definition at line 731 of file XObject.hpp.

virtual const XalanDOMString& XObject::str (  )  const [pure virtual]

Cast result object to a string.

This function does not have access to the current XPathExecutionContext, so the result may contain data from whitespace text nodes that might have been stripped otherwise.

Parameters:
executionContext The current XPathExecutionContext
Returns:
string value

Implemented in XResultTreeFrag, XBoolean, XNodeSetBase, XNumber, XNumberBase, XString, XStringAdapter, XStringBase, XStringCached, XStringReference, XToken, XTokenNumberAdapter, XTokenStringAdapter, and XUnknown.

virtual void XObject::str ( XPathExecutionContext executionContext,
FormatterListener formatterListener,
MemberFunctionPtr  function 
) const [pure virtual]

Send the string value to a FormatterListener instance.

Parameters:
executionContext The current XPathExecutionContext
formatterListener The FormatterListener instance
function A pointer to the member function of FormatterListener to call

Implemented in XResultTreeFrag, XBoolean, XNodeSetBase, XNumber, XNumberBase, XString, XStringAdapter, XStringBase, XStringCached, XStringReference, XToken, XTokenNumberAdapter, XTokenStringAdapter, and XUnknown.

virtual void XObject::str ( FormatterListener formatterListener,
MemberFunctionPtr  function 
) const [pure virtual]

Send the string value to a FormatterListener instance.

This function does not have access to the current XPathExecutionContext, so the result may contain data from whitespace text nodes that might have been stripped otherwise.

Parameters:
formatterListener The FormatterListener instance
function A pointer to the member function of FormatterListener to call

Implemented in XResultTreeFrag, XBoolean, XNodeSetBase, XNumber, XNumberBase, XString, XStringAdapter, XStringBase, XStringCached, XStringReference, XToken, XTokenNumberAdapter, XTokenStringAdapter, and XUnknown.

virtual void XObject::str ( XalanDOMString theBuffer  )  const [pure virtual]

Append the string value directly a string.

This function does not have access to the current XPathExecutionContext, so the result may contain data from whitespace text nodes that might have been stripped otherwise.

Parameters:
theBuffer The buffer for the data

Implemented in XResultTreeFrag, XBoolean, XNodeSetBase, XNumber, XNumberBase, XString, XStringAdapter, XStringBase, XStringCached, XStringReference, XToken, XTokenNumberAdapter, XTokenStringAdapter, and XUnknown.

virtual void XObject::str ( XPathExecutionContext executionContext,
XalanDOMString theBuffer 
) const [pure virtual]

Append the string value directly a string.

Parameters:
executionContext The current XPathExecutionContext
theBuffer The buffer for the data

Implemented in XResultTreeFrag, XBoolean, XNodeSetBase, XNumber, XNumberBase, XString, XStringAdapter, XStringBase, XStringCached, XStringReference, XToken, XTokenNumberAdapter, XTokenStringAdapter, and XUnknown.

virtual const XalanDOMString& XObject::str ( XPathExecutionContext executionContext  )  const [pure virtual]

Cast result object to a string.

Parameters:
executionContext The current XPathExecutionContext
Returns:
string value

Implemented in XResultTreeFrag, XBoolean, XNodeSetBase, XNumber, XNumberBase, XString, XStringAdapter, XStringBase, XStringCached, XStringReference, XToken, XTokenNumberAdapter, XTokenStringAdapter, and XUnknown.

static void XObject::string ( const NodeRefListBase theNodeList,
XalanDOMString theString 
) [inline, static]

Static conversion function.

Append the string value of the NodeRefListBase to the supplied XalanDOMString parameter.

Deprecated:
This function is deprecated and should not be used.
Parameters:
theNodeList The NodeRefListBase to convert.
theString The output XalanDOMString.

Definition at line 534 of file XObject.hpp.

static void XObject::string ( const NodeRefListBase theNodeList,
FormatterListener formatterListener,
MemberFunctionPtr  function 
) [inline, static]

Static conversion function.

Calls the supplied FormatterListener member function with the string value of the NodeRefListBase.

Deprecated:
This function is deprecated and should not be used.
Parameters:
theNodeList The NodeRefListBase to convert.
formatterListener The FormatterListener instance.
function The FormatterListener member function to call.

Definition at line 557 of file XObject.hpp.

static void XObject::string ( double  theNumber,
XalanDOMString theString 
) [inline, static]

Static conversion function.

Append the string value of the double to the supplied XalanDOMString parameter.

Parameters:
theNumber The double to convert.
theString The output XalanDOMString.

Definition at line 464 of file XObject.hpp.

static void XObject::string ( const NodeRefListBase theNodeList,
XPathExecutionContext theExecutionContext,
FormatterListener formatterListener,
MemberFunctionPtr  function 
) [inline, static]

Static conversion function.

Calls the supplied FormatterListener member function with the string value of the NodeRefListBase.

Parameters:
theNodeList The NodeRefListBase to convert.
theExecutionContext The current XPathExecutionContext.
formatterListener The FormatterListener instance.
function The FormatterListener member function to call.

Definition at line 642 of file XObject.hpp.

static void XObject::string ( bool  theBool,
XalanDOMString theString 
) [inline, static]

Static conversion function.

Appends the supplied boolean value to a string.

Parameters:
theBool The boolean value to convert.
theString The string value of the provided boolean value.

Definition at line 425 of file XObject.hpp.

static void XObject::string ( double  theNumber,
FormatterListener formatterListener,
MemberFunctionPtr  function 
) [inline, static]

Static conversion function.

Calls the supplied FormatterListener member function with the string value of the double.

Parameters:
theNumber The double to convert.
formatterListener The FormatterListener instance.
function The FormatterListener member function to call.

Definition at line 480 of file XObject.hpp.

static void XObject::string ( bool  theBool,
FormatterListener formatterListener,
MemberFunctionPtr  function 
) [inline, static]

Static conversion function.

Calls the supplied FormatterListener member function with the string value of the boolean.

Parameters:
theBool The boolean value to convert.
formatterListener The FormatterListener instance.
function The FormatterListener member function to call.

Definition at line 441 of file XObject.hpp.

static void XObject::string ( const XalanNode theNode,
XalanDOMString theString 
) [inline, static]

Static conversion function.

Append the string value of the XalanNode to the supplied XalanDOMString parameter.

Deprecated:
This function is deprecated and should not be used.
Parameters:
theNode The XalanNode to convert.
theString The output XalanDOMString.

Definition at line 498 of file XObject.hpp.

static const XalanDOMString& XObject::string ( bool  theBool  )  [inline, static]

Static conversion function.

Returns a reference to a XalanDOMString instance with the string value of the boolean.

Parameters:
theBool The boolean value to convert.
Returns:
The string value of the boolean

Definition at line 412 of file XObject.hpp.

static void XObject::string ( const XalanNode theNode,
XPathExecutionContext theExecutionContext,
XalanDOMString theString 
) [inline, static]

Static conversion function.

Append the string value of the XalanNode to the supplied XalanDOMString parameter.

Parameters:
theNode The XalanNode to convert.
theExecutionContext The current XPathExecutionContext.
theString The output XalanDOMString.

Definition at line 579 of file XObject.hpp.

static void XObject::string ( const XalanNode theNode,
FormatterListener formatterListener,
MemberFunctionPtr  function 
) [inline, static]

Static conversion function.

Calls the supplied FormatterListener member function with the string value of the XalanNode.

Deprecated:
This function is deprecated and should not be used.
Parameters:
theNode The XalanNode to convert.
formatterListener The FormatterListener instance.
function The FormatterListener member function to call.

Definition at line 516 of file XObject.hpp.

static void XObject::string ( const NodeRefListBase theNodeList,
XPathExecutionContext theExecutionContext,
XalanDOMString theString 
) [inline, static]

Static conversion function.

Append the string value of the NodeRefListBase to the supplied XalanDOMString parameter.

Parameters:
theNodeList The NodeRefListBase to convert.
theExecutionContext The current XPathExecutionContext.
theString The output XalanDOMString.

Definition at line 619 of file XObject.hpp.

static void XObject::string ( const XalanDOMString theString,
FormatterListener formatterListener,
MemberFunctionPtr  function 
) [inline, static]

Calls the supplied FormatterListener member function with the string.

Parameters:
theString The XalanDOMString to convert.
formatterListener The FormatterListener instance.
function The FormatterListener member function to call.

Definition at line 669 of file XObject.hpp.

static void XObject::string ( const XalanNode theNode,
XPathExecutionContext theExecutionContext,
FormatterListener formatterListener,
MemberFunctionPtr  function 
) [inline, static]

Static conversion function.

Calls the supplied FormatterListener member function with the string value of the XalanNode.

Parameters:
theNode The XalanNode to convert.
theExecutionContext The current XPathExecutionContext.
formatterListener The FormatterListener instance.
function The FormatterListener member function to call.

Definition at line 597 of file XObject.hpp.

virtual double XObject::stringLength ( XPathExecutionContext executionContext  )  const [pure virtual]

Get the length of the string value of the instance.

Returns:
The length of the string value

Implemented in XResultTreeFrag, XBoolean, XNodeSetBase, XNumber, XNumberBase, XString, XStringAdapter, XStringBase, XStringCached, XStringReference, XToken, XTokenNumberAdapter, XTokenStringAdapter, and XUnknown.

static void XObject::terminate (  )  [static]

Perform static shut down.

See class XPathInit.

Reimplemented in XUnknown.

void XObject::throwInvalidConversionException ( const XalanDOMString theTargetType  )  const [protected]

Friends And Related Function Documentation

friend class XObjectFactory [friend]

Definition at line 728 of file XObject.hpp.

friend class XObjectPtr [friend]

Definition at line 67 of file XObject.hpp.


Member Data Documentation

const XalanDOMString& XObject::s_booleanString [static, protected]

Definition at line 850 of file XObject.hpp.

const XalanDOMString XObject::s_emptyString [static, protected]

Definition at line 848 of file XObject.hpp.

const XalanDOMString& XObject::s_falseString [static, protected]

Definition at line 852 of file XObject.hpp.

const XalanDOMString& XObject::s_nodesetString [static, protected]

Definition at line 854 of file XObject.hpp.

const XalanDOMString& XObject::s_numberString [static, protected]

Definition at line 856 of file XObject.hpp.

Definition at line 858 of file XObject.hpp.

const XalanDOMString& XObject::s_stringString [static, protected]

Definition at line 860 of file XObject.hpp.

const XalanDOMString& XObject::s_trueString [static, protected]

Definition at line 862 of file XObject.hpp.


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

Interpreting class diagrams

Doxygen and GraphViz are used to generate this API documentation from the Xalan-C header files.

Xalan-C++ XSLT Processor Version 1.11
Copyright © 1999-2012 The Apache Software Foundation.
All Rights Reserved.

Apache Logo