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

## com.qizx.api
Interface XQuerySession

All Superinterfaces:
  ItemFactory

    public interface XQuerySession

extends ItemFactory

Simple XQuery session without access to XML Libraries, used in Qizx/open.

Method Summary
`Expression` | `compileExpression(String xquery)` Creates an executable Expression by compiling a XQuery script.
`void` | `enableJavaBinding(String className)` Enables a class for the 'Java Binding' mechanism.
`XQueryContext` | `getContext()` Access to the default XQuery Context.
`FullTextFactory` | `getFullTextFactory()` Returns the Fulltext Provider associated with the session.
`ModuleResolver` | `getModuleResolver()` Returns the private module resolver defined for the session.
`Indexing.WordSieve` | `getWordSieve()` Deprecated. see `getFullTextFactory()` `setFullTextFactory(com.qizx.api.fulltext.FullTextFactory)`
`void` | `setFullTextFactory(FullTextFactory fulltextProvider)` Redefines the full-text factory associated with the session.
`void` | `setModuleResolver(ModuleResolver resolver)` Defines a private Module resolver for the session.
`void` | `setWordSieve(Indexing.WordSieve wordSieve)` Deprecated. see `setFullTextFactory(com.qizx.api.fulltext.FullTextFactory)`

Methods inherited from interface com.qizx.api.ItemFactory
`copySequence, createItem, createItem, createItem, createItem, createItem, createItem, createItem, createSequence, getNodeType, getQName, getQName, getQName, getType`

Method Detail

### getContext

    XQueryContext getContext()

  Access to the default XQuery Context. This context is inherited by expressions compiled from this session.

  Returns:
    the XQuery context used as a basis for compiled expressions.

### compileExpression

    Expression compileExpression(String xquery)
                                 throws CompilationException

  Creates an executable Expression by compiling a XQuery script.

  Parameters:
    `xquery` - a string containing a XQuery script.
  Returns:
    an executable Expression that can be used for several executions. Before an execution, the expression can be prepared by binding values with variables
  Throws:
    `CompilationException` - thrown after compilation if parsing or static analysis errors are detected. A CompilationException bears a list of `Message`s.

### setModuleResolver

    void setModuleResolver(ModuleResolver resolver)

  Defines a private Module resolver for the session. By default, the Module resolver is defined globally on the XQuerySessionManager or the LibraryManager.

  Parameters:
    `resolver` - a Module resolver; if set to null, the default module resolver will then be used for the session

### getModuleResolver

    ModuleResolver getModuleResolver()

  Returns the private module resolver defined for the session.

  Returns:
    null if no private module resolver was defined for the session

### setWordSieve

    void setWordSieve(Indexing.WordSieve wordSieve)
                      throws DataModelException

  Deprecated. see `setFullTextFactory(com.qizx.api.fulltext.FullTextFactory)`

  Defines the private full-text word tokenizer for the session. By default it is an instance of `DefaultWordSieve`.

  Throws:
    `DataModelException` - if the session is in fact an XML Library, changing the word sieve can generate an exception (for example if it is read-only).

### getWordSieve

    Indexing.WordSieve getWordSieve()

  Deprecated. see `getFullTextFactory()` `setFullTextFactory(com.qizx.api.fulltext.FullTextFactory)`

  Returns the private full-text word tokenizer defined for the session.

  Returns:
    the private full-text word tokenizer defined for the session. By default it is an instance of `DefaultWordSieve`

### enableJavaBinding

    void enableJavaBinding(String className)

  Enables a class for the 'Java Binding' mechanism.

  Attention: the Java Binding mechanism is not enabled by default when using the API. Each Java class has to be enabled specifically. It is possible to enable all classes at once (though not advisable for security reasons) by passing a null name.

  Attention: once a class has been enabled, it can no longer be disabled in the same session.

  Parameters:
    `className` - fully qualified class name (e.g java.sql.DriverManager). If the value 'null' is used instead of a class name, then all Java to Java extensions are enabled or disabled.

### setFullTextFactory

    void setFullTextFactory(FullTextFactory fulltextProvider)

  Redefines the full-text factory associated with the session.

  A FullTextFactory provides access to- or allows redefining full-text resources such as text tokenizer, stemming, thesaurus and scoring method.

  By default, an instance of `DefaultFullTextFactory` is used. It is also possible to define a FullTextFactory on the `LibraryManager` which controls a group of Libraries.

  Parameters:
    `fulltextProvider` - a new Fulltext Provider.

### getFullTextFactory

    FullTextFactory getFullTextFactory()

  Returns the Fulltext Provider associated with the session.

  Returns:
    the Fulltext Provider associated with the session.

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