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 TestName

    java.lang.Object
      org.basex.query.xpath.locpath.Test
          org.basex.query.xpath.locpath.TestName

    public final class TestName

extends Test

NodeTest testing for a name match.

Author:
  Workgroup DBIS, University of Konstanz 2005-07, ISC License, Tim Petrowsky

Field Summary
`static int` | `ALL` Test accepting all names.
`static byte[]` | `ALLNODES` Test accepting all names.
`int` | `id` Index reference to the Tag/Attribute.
`static int` | `UNKNOWN` Unknown tag/attribute name.

Constructor Summary
`TestName(boolean t)` Constructor, accepting all tags/attribute names.
`TestName(byte[] nm, boolean t)` Constructor.

Method Summary
`void` | `compile(Data data)` Optimizes the expression.
`boolean` | `eval(Data data, int pre, int kind)` Evaluates a node test.
`boolean` | `sameAs(Test test)` Checks current and specified class for equivalence.
`java.lang.String` | `toString()`

Methods inherited from class org.basex.query.xpath.locpath.Test
`eval`

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

Field Detail

### ALL

    public static final int ALL

  Test accepting all names.

  See Also:
    Constant Field Values

### ALLNODES

    public static final byte[] ALLNODES

  Test accepting all names.

### id

    public int id

  Index reference to the Tag/Attribute.

### UNKNOWN

    public static final int UNKNOWN

  Unknown tag/attribute name.

  See Also:
    Constant Field Values

Constructor Detail

### TestName

    public TestName(boolean t)

  Constructor, accepting all tags/attribute names.

  Parameters:
    `t` - tag reference

### TestName

    public TestName(byte[] nm,
                    boolean t)

  Constructor.

  Parameters:
    `nm` - the name to match.
    `t` - tag reference

Method Detail

### compile

    public void compile(Data data)

  Description copied from class: `Test`
  Optimizes the expression.

  Overrides:
    `compile` in class `Test`
  Parameters:
    `data` - data reference

### eval

    public boolean eval(Data data,
                        int pre,
                        int kind)

  Description copied from class: `Test`
  Evaluates a node test.

  Specified by:
    `eval` in class `Test`
  Parameters:
    `data` - data reference
    `pre` - pre value
    `kind` - node kind
  Returns:
    result of evaluation

### sameAs

    public boolean sameAs(Test test)

  Description copied from class: `Test`
  Checks current and specified class for equivalence.

  Specified by:
    `sameAs` in class `Test`
  Parameters:
    `test` - node test to be compared
  Returns:
    result of check

### toString

    public java.lang.String toString()

  Specified by:
    `toString` in class `Test`

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