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

## org.basex.query.xpath.locpath
Class Steps

    java.lang.Object
      org.basex.query.xpath.locpath.Steps

    public final class Steps

extends java.lang.Object

Location Steps.

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

Constructor Summary
`Steps()`

Method Summary
`void` | `add(int s, Step step)` Adds the specified step at the specified position.
`void` | `add(Step step)` Adds the specified step.
`boolean` | `compile(XPContext ctx)` Optimizes the predicates.
`NodeSet` | `eval(XPContext ctx)` Evaluates the location steps.
`Step` | `get(int s)` Returns the specified step.
`Step` | `last()` Returns the last location step.
`void` | `remove(int s)` Removes the specified step.
`boolean` | `sameAs(Steps stps)` Returns the location steps for equality.
`void` | `set(int s, Step step)` Sets the specified step.
`int` | `size()` Returns the number of location steps.
`java.lang.String` | `toString()`

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

Constructor Detail

### Steps

    public Steps()

Method Detail

### add

    public void add(int s,
                    Step step)

  Adds the specified step at the specified position.

  Parameters:
    `s` - step index
    `step` - step to be added

### add

    public void add(Step step)

  Adds the specified step.

  Parameters:
    `step` - step to be added

### compile

    public boolean compile(XPContext ctx)
                    throws EvalException

  Optimizes the predicates.

  Parameters:
    `ctx` - query context
  Returns:
    false if location step yields no results
  Throws:
    `EvalException` - evaluation exception

### eval

    public NodeSet eval(XPContext ctx)
                 throws EvalException

  Evaluates the location steps.

  Parameters:
    `ctx` - query context
  Returns:
    result of check
  Throws:
    `EvalException` - evaluation exception

### get

    public Step get(int s)

  Returns the specified step.

  Parameters:
    `s` - step index
  Returns:
    location step

### last

    public Step last()

  Returns the last location step.

  Returns:
    location step

### remove

    public void remove(int s)

  Removes the specified step.

  Parameters:
    `s` - step index

### sameAs

    public boolean sameAs(Steps stps)

  Returns the location steps for equality.

  Parameters:
    `stps` - location steps to be compared
  Returns:
    result of check

### set

    public void set(int s,
                    Step step)

  Sets the specified step.

  Parameters:
    `s` - step index
    `step` - step to be set

### size

    public int size()

  Returns the number of location steps.

  Returns:
    number of steps

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

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