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

## org.basex.query.item
Class Nod

    java.lang.Object
      org.basex.query.ExprInfo
          org.basex.query.expr.Expr
              org.basex.query.item.Item
                  org.basex.query.item.Nod

Direct Known Subclasses:
  DBNode, FNode

    public abstract class Nod

extends Item

Node Type.

Author:
  Workgroup DBIS, University of Konstanz 2005-09, ISC License, Christian Gruen

Field Summary

Fields inherited from class org.basex.query.item.Item
`type`

Method Summary
`NodeIter` | `anc()` Returns an ancestor axis iterator.
`NodeIter` | `ancOrSelf()` Returns an ancestor-or-self axis iterator.
`abstract NodeIter` | `attr()` Returns an attribute axis iterator.
`byte[]` | `base()` Returns the database name.
`boolean` | `bool()` Returns a boolean representation of the item.
`abstract NodeMore` | `child()` Returns a child axis iterator.
`abstract Nod` | `copy()` Creates a new copy (clone) of the node.
`double` | `dbl()` Returns a double representation of the item.
`java.math.BigDecimal` | `dec()` Returns a decimal representation of the item.
`abstract NodeIter` | `desc()` Returns a descendant axis iterator.
`abstract NodeIter` | `descOrSelf()` Returns a descendant-or-self axis iterator.
`int` | `diff(Item i)` Returns the difference between the current and the specified item.
`abstract int` | `diff(Nod nod)` Compares two nodes for their unique order.
`boolean` | `eq(Item i)` Checks the items for equality.
`Nod` | `finish()` Returns a final node representation.
`float` | `flt()` Returns a float representation of the item.
`NodeIter` | `foll()` Returns a following axis iterator.
`NodeIter` | `follSibl()` Returns a following-sibling axis iterator.
`abstract boolean` | `is(Nod nod)` Compares two nodes for equality.
`long` | `itr()` Returns an integer (long) representation of the item.
`BXNode` | `java()` Returns a Java object.
`static int` | `kind(Type t)` Returns a database kind for the specified node type.
`byte[]` | `nname()` Returns the node name.
`Atts` | `ns()` Returns a namespace array.
`NodeIter` | `par()` Returns a parent axis iterator.
`abstract Nod` | `parent()` Returns the parent node.
`void` | `parent(Nod p)` Sets the parent node.
`NodeIter` | `prec()` Returns a preceding axis iterator.
`NodeIter` | `precSibl()` Returns a preceding-sibling axis iterator.
`QNm` | `qname()` Returns the node name.
`QNm` | `qname(QNm nm)` Returns a temporary node name.
`NodeMore` | `self()` Returns an self axis iterator.

Methods inherited from class org.basex.query.item.Item
`atomic, castErr, comp, d, duplicates, ebv, hash, i, iter, iter, n, name, node, plan, removable, returned, s, score, score, serialize, str, test, toString, u, uses`

Methods inherited from class org.basex.query.expr.Expr
`addText, checkCtx, checkDbl, checkItr, e, indexAccessible, indexEquivalent, remove, sameAs, size`

Methods inherited from class org.basex.query.ExprInfo
`color, info`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Method Detail

### bool

    public final boolean bool()

  Description copied from class: `Item`
  Returns a boolean representation of the item.

  Overrides:
    `bool` in class `Item`
  Returns:
    boolean value

### itr

    public final long itr()
                   throws QueryException

  Description copied from class: `Item`
  Returns an integer (long) representation of the item.

  Overrides:
    `itr` in class `Item`
  Returns:
    long value
  Throws:
    `QueryException` - evaluation exception

### flt

    public final float flt()
                    throws QueryException

  Description copied from class: `Item`
  Returns a float representation of the item.

  Overrides:
    `flt` in class `Item`
  Returns:
    float value
  Throws:
    `QueryException` - evaluation exception

### dec

    public java.math.BigDecimal dec()
                             throws QueryException

  Description copied from class: `Item`
  Returns a decimal representation of the item.

  Overrides:
    `dec` in class `Item`
  Returns:
    decimal value
  Throws:
    `QueryException` - evaluation exception

### dbl

    public double dbl()
               throws QueryException

  Description copied from class: `Item`
  Returns a double representation of the item.

  Overrides:
    `dbl` in class `Item`
  Returns:
    double value
  Throws:
    `QueryException` - evaluation exception

### eq

    public final boolean eq(Item i)
                     throws QueryException

  Description copied from class: `Item`
  Checks the items for equality.

  Specified by:
    `eq` in class `Item`
  Parameters:
    `i` - item to be compared.
  Returns:
    result of check
  Throws:
    `QueryException` - evaluation exception

### diff

    public final int diff(Item i)
                   throws QueryException

  Description copied from class: `Item`
  Returns the difference between the current and the specified item.

  Overrides:
    `diff` in class `Item`
  Parameters:
    `i` - item to be compared.
  Returns:
    difference
  Throws:
    `QueryException` - evaluation exception

### copy

    public abstract Nod copy()

  Creates a new copy (clone) of the node.

  Returns:
    new copy

### nname

    public byte[] nname()

  Returns the node name.

  Returns:
    name

### qname

    public QNm qname()

  Returns the node name.

  Returns:
    name

### qname

    public QNm qname(QNm nm)
              throws QueryException

  Returns a temporary node name.

  Parameters:
    `nm` - temporary qname
  Returns:
    name
  Throws:
    `QueryException` - query exception

### ns

    public Atts ns()

  Returns a namespace array.

  Returns:
    namespace array

### base

    public byte[] base()

  Returns the database name.

  Returns:
    database name

### is

    public abstract boolean is(Nod nod)

  Compares two nodes for equality.

  Parameters:
    `nod` - node to be compared
  Returns:
    result of check

### diff

    public abstract int diff(Nod nod)

  Compares two nodes for their unique order.

  Parameters:
    `nod` - node to be compared
  Returns:
    0 if the nodes are equal or a positive/negative value if the node appears after/before the argument

### finish

    public Nod finish()

  Returns a final node representation. This method should be called as soon as a node is passed on as result node.

  Returns:
    node

### parent

    public abstract Nod parent()

  Returns the parent node.

  Returns:
    parent node

### parent

    public void parent(Nod p)

  Sets the parent node.

  Parameters:
    `p` - parent node

### anc

    public final NodeIter anc()

  Returns an ancestor axis iterator.

  Returns:
    iterator

### ancOrSelf

    public final NodeIter ancOrSelf()

  Returns an ancestor-or-self axis iterator.

  Returns:
    iterator

### attr

    public abstract NodeIter attr()

  Returns an attribute axis iterator.

  Returns:
    iterator

### child

    public abstract NodeMore child()

  Returns a child axis iterator.

  Returns:
    iterator

### desc

    public abstract NodeIter desc()

  Returns a descendant axis iterator.

  Returns:
    iterator

### descOrSelf

    public abstract NodeIter descOrSelf()

  Returns a descendant-or-self axis iterator.

  Returns:
    iterator

### foll

    public final NodeIter foll()

  Returns a following axis iterator.

  Returns:
    iterator

### follSibl

    public final NodeIter follSibl()

  Returns a following-sibling axis iterator.

  Returns:
    iterator

### par

    public NodeIter par()

  Returns a parent axis iterator.

  Returns:
    iterator

### prec

    public final NodeIter prec()

  Returns a preceding axis iterator.

  Returns:
    iterator

### precSibl

    public final NodeIter precSibl()

  Returns a preceding-sibling axis iterator.

  Returns:
    iterator

### self

    public final NodeMore self()

  Returns an self axis iterator.

  Returns:
    iterator

### kind

    public static int kind(Type t)

  Returns a database kind for the specified node type.

  Parameters:
    `t` - node type
  Returns:
    node kind

### java

    public final BXNode java()

  Description copied from class: `Item`
  Returns a Java object.

  Overrides:
    `java` in class `Item`
  Returns:
    string representation

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