Overview | Package | Class | Deprecated | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.exist.xquery.value
Interface Item

All Known Subinterfaces:
  NodeValue

All Known Implementing Classes:
  AtomicValue, NodeImpl, NodeProxy

public interface Item

This class represents an item in a sequence as defined by the XPath 2.0 specification. Every item is either an `atomic value` or a `node`.

Author:
  wolf

Method Summary
`AtomicValue` | `atomize()`
`int` | `conversionPreference(java.lang.Class javaClass)`
`AtomicValue` | `convertTo(int requiredType)` Convert this item into an atomic value, whose type corresponds to the specified target type.
`void` | `copyTo(DBBroker broker, DocumentBuilderReceiver receiver)`
`java.lang.String` | `getStringValue()` Return the string value of this item (see the definition of string value in XPath).
`int` | `getType()` Return the type of this item according to the type constants defined in class `Type`.
`java.lang.Object` | `toJavaObject(java.lang.Class target)`
`void` | `toSAX(DBBroker broker, org.xml.sax.ContentHandler handler)`
`Sequence` | `toSequence()` Convert this item into a sequence, containing only the item.

Method Detail

### getType

    public int getType()

  Return the type of this item according to the type constants defined in class `Type`.

### getStringValue

    public java.lang.String getStringValue()
                                    throws XPathException

  Return the string value of this item (see the definition of string value in XPath).

  Throws:
    `XPathException`

### toSequence

    public Sequence toSequence()

  Convert this item into a sequence, containing only the item.

### convertTo

    public AtomicValue convertTo(int requiredType)
                          throws XPathException

  Convert this item into an atomic value, whose type corresponds to the specified target type. requiredType should be one of the type constants defined in `Type`. An `XPathException` is thrown if the conversion is impossible.

  Parameters:
    `requiredType` -
  Throws:
    `XPathException`

### atomize

    public AtomicValue atomize()
                        throws XPathException

  Throws:
    `XPathException`

### toSAX

    public void toSAX(DBBroker broker,
                      org.xml.sax.ContentHandler handler)
               throws org.xml.sax.SAXException

  Throws:
    `org.xml.sax.SAXException`

### copyTo

    public void copyTo(DBBroker broker,
                       DocumentBuilderReceiver receiver)
                throws org.xml.sax.SAXException

  Throws:
    `org.xml.sax.SAXException`

### conversionPreference

    public int conversionPreference(java.lang.Class javaClass)

### toJavaObject

    public java.lang.Object toJavaObject(java.lang.Class target)
                                  throws XPathException

  Throws:
    `XPathException`

Overview | Package | Class | Deprecated | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright (C) Wolfgang Meier. All rights reserved.