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

## org.apache.slide.search.basic
Class QueryTree

    java.lang.Object
      org.apache.slide.search.basic.QueryTree

public class QueryTree
extends java.lang.Object

Represents the scopes for all stores, that are within the scope of one query.

Version:
  $Revision: 1.4 $

Nested Class Summary
`(package private) class` | `QueryTree.TokenizedScope` Helper class to handle the scopes

Constructor Summary
`(package private)` | `QueryTree(java.util.Enumeration stores, Scope scope, Scope[] excluded)` Constructs a query tree

Method Summary
`boolean` | `hasChildren(Scope scopeToBeChecked)` Checks, if the indicated scope has children within this QueryTree.
`java.util.Iterator` | `iterator()` Retrieves an iterator of all scopes in this Tree
`int` | `relativeDepth(Scope scope)` calculates the depth of scope within this QueryTree (relative to the topLevel of tree)

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

Constructor Detail

### QueryTree

    QueryTree(java.util.Enumeration stores,
              Scope scope,
              Scope[] excluded)
        throws InvalidScopeException

  Constructs a query tree

Parameters:
  `stores` - all stores, that are within this namespace
  `scope` - the scope of this query
  `excluded` - a list of scopes, that shall be excluded from search

Method Detail

### hasChildren

    public boolean hasChildren(Scope scopeToBeChecked)

  Checks, if the indicated scope has children within this QueryTree.

  Parameters:
    `scopeToBeChecked` - the Scope to be checked
  Returns:
    a boolean

### relativeDepth

    public int relativeDepth(Scope scope)

  calculates the depth of scope within this QueryTree (relative to the topLevel of tree)

  Parameters:
    `scope` - a Scope
  Returns:
    an int

### iterator

    public java.util.Iterator iterator()

  Retrieves an iterator of all scopes in this Tree

  Returns:
    an Iterator of Scope objects

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