org.basex.query
Class LibraryModule

java.lang.Object
  extended by org.basex.data.ExprInfo
      extended by org.basex.query.StaticScope
          extended by org.basex.query.LibraryModule
All Implemented Interfaces:
Scope

public class LibraryModule
extends StaticScope

An XQuery main module.

Author:
BaseX Team 2005-12, BSD License, Leo Woerteler

Field Summary
 QNm name
          Library name.
 
Fields inherited from class org.basex.query.StaticScope
compiled, expr, info, scope
 
Constructor Summary
LibraryModule(QNm nm, java.lang.String xqdoc)
          Constructor.
 
Method Summary
 void compile(QueryContext ctx)
          Compiles the expression contained in this scope.
 void plan(FElem e)
          Creates an expression tree.
 java.lang.String toString()
           
 boolean visit(ASTVisitor visitor)
          Traverses this scope with the given ASTVisitor.
 
Methods inherited from class org.basex.query.StaticScope
compiled, doc
 
Methods inherited from class org.basex.data.ExprInfo
addPlan, addPlan, description, info, planAttr, planElem
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

name

public final QNm name
Library name.

Constructor Detail

LibraryModule

public LibraryModule(QNm nm,
                     java.lang.String xqdoc)
Constructor.

Parameters:
nm - of library
xqdoc - documentation
Method Detail

visit

public boolean visit(ASTVisitor visitor)
Description copied from interface: Scope
Traverses this scope with the given ASTVisitor.

Parameters:
visitor - visitor
Returns:
continue flag

compile

public void compile(QueryContext ctx)
             throws QueryException
Description copied from interface: Scope
Compiles the expression contained in this scope.

Parameters:
ctx - query context
Throws:
QueryException - compilation errors

toString

public java.lang.String toString()
Specified by:
toString in class ExprInfo

plan

public void plan(FElem e)
Description copied from class: ExprInfo
Creates an expression tree.

Specified by:
plan in class ExprInfo
Parameters:
e - root element