org.ucl.xpath.types
Class XSString

java.lang.Object
  extended byorg.ucl.xpath.types.AnyType
      extended byorg.ucl.xpath.types.AnySimpleType
          extended byorg.ucl.xpath.types.AnyAtomicType
              extended byorg.ucl.xpath.types.CtrType
                  extended byorg.ucl.xpath.types.XSString
All Implemented Interfaces:
CmpEq, CmpGt, CmpLt
Direct Known Subclasses:
XSNCName

public class XSString
extends CtrType
implements CmpEq, CmpGt, CmpLt

A representation of the String datatype


Constructor Summary
XSString()
          Initialises to null
XSString(java.lang.String x)
          Initialises using the supplied String
 
Method Summary
 ResultSequence constructor(ResultSequence arg)
          Creates a new ResultSequence consisting of the extractable String in the supplied ResultSequence
 boolean eq(AnyType arg)
          Equality comparison between this and the supplied representation which must be of type String
 boolean gt(AnyType arg)
          Comparison between this and the supplied representation which must be of type String
 boolean lt(AnyType arg)
          Comparison between this and the supplied representation which must be of type String
 java.lang.String string_type()
          Retrieves the datatype's full pathname
 java.lang.String string_value()
          Retrieves a String representation of the string stored.
 java.lang.String type_name()
          Retrieves the datatype's name
 java.lang.String value()
          Retrieves a String representation of the string stored.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XSString

public XSString(java.lang.String x)
Initialises using the supplied String

Parameters:
x - The String to initialise to

XSString

public XSString()
Initialises to null

Method Detail

string_type

public java.lang.String string_type()
Retrieves the datatype's full pathname

Specified by:
string_type in class AnyType
Returns:
"xs:string" which is the datatype's full pathname

type_name

public java.lang.String type_name()
Retrieves the datatype's name

Specified by:
type_name in class CtrType
Returns:
"string" which is the datatype's name

string_value

public java.lang.String string_value()
Retrieves a String representation of the string stored. This method is functionally identical to value()

Specified by:
string_value in class AnyType
Returns:
The String stored

value

public java.lang.String value()
Retrieves a String representation of the string stored. This method is functionally identical to string_value()

Returns:
The String stored

constructor

public ResultSequence constructor(ResultSequence arg)
                           throws DynamicError
Creates a new ResultSequence consisting of the extractable String in the supplied ResultSequence

Specified by:
constructor in class CtrType
Parameters:
arg - The ResultSequence from which to extract the String
Returns:
New ResultSequence consisting of the supplied String
Throws:
DynamicError

eq

public boolean eq(AnyType arg)
           throws DynamicError
Equality comparison between this and the supplied representation which must be of type String

Specified by:
eq in interface CmpEq
Parameters:
arg - The representation to compare with
Returns:
True if the two representation are of the same String. False otherwise
Throws:
DynamicError

gt

public boolean gt(AnyType arg)
           throws DynamicError
Comparison between this and the supplied representation which must be of type String

Specified by:
gt in interface CmpGt
Parameters:
arg - The representation to compare with
Returns:
True if this String is lexographically greater than that supplied. False otherwise
Throws:
DynamicError

lt

public boolean lt(AnyType arg)
           throws DynamicError
Comparison between this and the supplied representation which must be of type String

Specified by:
lt in interface CmpLt
Parameters:
arg - The representation to compare with
Returns:
True if this String is lexographically less than that supplied. False otherwise
Throws:
DynamicError