## Xalan-C++ API Documentation

### The Xalan C++ XSLT Processor Version 1.10

Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members File Members

# XToken Class Reference

`#include <XToken.hpp>`

Inheritance diagram for XToken:

[legend]
Collaboration diagram for XToken:

[legend]
List of all members.

## Public Methods

- XToken ()
- XToken (const XalanDOMString &theString, MemoryManagerType &theManager)
    Create an XToken for string in the token queue. More...
- XToken (double theNumber, const XalanDOMString &theString)
    Create an XToken for number in the token queue. More...
- XToken (const XToken &theSource)
- virtual ~XToken ()
- virtual const XalanDOMString& getTypeString () const
    Given a request type, return the equivalent string. More...
- virtual double num () const
    Cast result object to a number. More...
- virtual bool boolean () const
    Cast result object to a boolean. More...
- virtual const XalanDOMString& str () const
    Cast result object to a string. More...
- virtual void str (FormatterListener &formatterListener, MemberFunctionPtr function) const
    Send the string value to a FormatterListener instance. More...
- virtual void str (XalanDOMString &theBuffer) const
    Append the string value directly a string. More...
- virtual double stringLength () const
    Get the length of the string value of the instance.. More...
- virtual void ProcessXObjectTypeCallback (XObjectTypeCallback &theCallbackObject)
    Process a callback request for preferred type information. More...
- virtual void ProcessXObjectTypeCallback (XObjectTypeCallback &theCallbackObject) const
    Process a callback request for preferred type information. More...
- XToken& operator= (const XToken &theRHS)
- void set (const XalanDOMString &theString, MemoryManagerType &theManager)
    Set the instance as a string in the token queue. More...
- void set (double theNumber, const XalanDOMString &theString, MemoryManagerType &theManager)
    Set the instance as a number in the token queue. More...

## Protected Methods

- virtual void referenced ()
- virtual void dereferenced ()

## Constructor & Destructor Documentation

XToken::XToken ( | )

XToken::XToken ( | const XalanDOMString & theString,
| MemoryManagerType & theManager )`[explicit]`

Create an XToken for string in the token queue.

Parameters:

  theString | The string data for the token. The instance will keep a point to this string, so it must be persistent.

XToken::XToken ( | double theNumber,
| const XalanDOMString & theString )

Create an XToken for number in the token queue.

Parameters:

  theNumber | The numeric data for the token. This must be consistent with the lexical value in theString.
  theString | The string data for the token. The instance will keep a point to this string, so it must be persistent.

XToken::XToken ( | const XToken & theSource )

XToken::~XToken ( | )`[virtual]`

## Member Function Documentation

void XToken::ProcessXObjectTypeCallback ( | XObjectTypeCallback & theCallbackObject ) const`[virtual]`

Process a callback request for preferred type information.

Parameters:

  theCallbackObject | object to call back

Reimplemented from XObject.

void XToken::ProcessXObjectTypeCallback ( | XObjectTypeCallback & theCallbackObject )`[virtual]`

Process a callback request for preferred type information.

Parameters:

  theCallbackObject | object to call back

Reimplemented from XObject.

bool XToken::boolean ( | ) const`[virtual]`

Cast result object to a boolean.

Returns:
  boolean value

Reimplemented from XObject.

void XToken::dereferenced ( | )`[protected, virtual]`

| Reimplemented from XObject.

const XalanDOMString & XToken::getTypeString ( | ) const`[virtual]`

Given a request type, return the equivalent string.

For diagnostic purposes.

Returns:
  string for type

Reimplemented from XObject.

double XToken::num ( | ) const`[virtual]`

Cast result object to a number.

Returns:
  numeric value

Reimplemented from XObject.

XToken & XToken::operator= ( | const XToken & theRHS )

void XToken::referenced ( | )`[protected, virtual]`

| Reimplemented from XObject.

void XToken::set ( | double theNumber,
| const XalanDOMString & theString,
| MemoryManagerType & theManager )

Set the instance as a number in the token queue.

Parameters:

  theNumber | The numeric data for the token. This must be consistent with the lexical value in theString.
  theString | The string data for the token. XToken will keep a point to this string, so it must be persistent.

void XToken::set ( | const XalanDOMString & theString,
| MemoryManagerType & theManager )

Set the instance as a string in the token queue.

Parameters:

  theString | The string data for the token. XToken will keep a point to this string, so it must be persistent.

void XToken::str ( | XalanDOMString & theBuffer ) const`[virtual]`

Append the string value directly a string.

Parameters:

  theBuffer | The buffer for the data

Reimplemented from XObject.

void XToken::str ( | FormatterListener & formatterListener,
| MemberFunctionPtr function ) const`[virtual]`

Send the string value to a FormatterListener instance.

Parameters:

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

Reimplemented from XObject.

const XalanDOMString & XToken::str ( | ) const`[virtual]`

Cast result object to a string.

Returns:
  string value

Reimplemented from XObject.

double XToken::stringLength ( | ) const`[virtual]`

Get the length of the string value of the instance..

Returns:
  The length of the string value

Reimplemented from XObject.

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

- XToken.hpp

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.10 Copyright © 1999-2004 The Apache Software Foundation. All Rights Reserved.