Overview | Package | Class | Tree | Deprecated | Index | Help
| Copyright © 2008 BEA Systems, Inc. All Rights Reserved
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bea.p13n.expression
Class ExpressionFactory

    java.lang.Object
      com.bea.p13n.expression.ExpressionFactory

    public abstract class ExpressionFactory

extends Object

A factory class to create instances of the various implementation classes in the expression package.

Constructor Summary
`ExpressionFactory()`

Method Summary
`static Evaluator` | `createEvaluator(Map environment)` Creates a stateful `Evaluator` using the supplied environment.
`static Evaluator` | `createEvaluator(Map environment, UnificationList unificationList)` Creates an `Evaluator` object using the supplied environment and a `UnificationList`.
`static Executor` | `createExecutor(Map environment)` Creates an `Executor` if it is not cached, otherwise returns the cached `Executor`.
`static Expression` | `createExpression(Map environment, Reader reader)` Creates an `Expression` using the supplied environment, reading and parsing the characters from the supplied reader.
`static Expression` | `createExpression(Map environment, String xmlString)` Creates an `Expression` using the supplied environment and parsing the supplied string.
`static Optimizer` | `createOptimizer(Map environment, ObjectFilter objectFilter)` Creates an `Optimizer` using the supplied environment and an `ObjectFilter`.
`static UnificationList` | `createUnificationList(Map environment)` Creates a `UnificationList` using the supplied environment.
`static Unifier` | `createUnifier(Map environment, UnificationList unificationList)` Creates a `Unifier` using the supplied environment and the `UnificationList`.
`static Validator` | `createValidator(Map environment)` Creates a stateful `Evaluator` object using the supplied environment.
`static Validator` | `createValidator(Map environment, Evaluator evaluator)` Creates a `Validator` object using the supplied environment and an `Evaluator`.

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

Constructor Detail

### ExpressionFactory

    public ExpressionFactory()

Method Detail

### createUnifier

    public static Unifier createUnifier(Map environment,
                                        UnificationList unificationList)

  Creates a `Unifier` using the supplied environment and the `UnificationList`.

  Parameters
    `environment` - A `Map` containing environment information that is used to create a `Unifier`.
    `unificationList` - A `UnificationList` that is used to bind variables to their values.
  Returns
    A `Unifier` that can unify an expression.
  See Also
    `Unifier`

### createUnificationList

    public static UnificationList createUnificationList(Map environment)

  Creates a `UnificationList` using the supplied environment.

  Parameters
    `environment` - A `Map` containing the environment information that is used to create a `UnificationList`.
  Returns
    A `UnificationList`.
  See Also
    `UnificationList`

### createExecutor

    public static Executor createExecutor(Map environment)

  Creates an `Executor` if it is not cached, otherwise returns the cached `Executor`.

  Parameters
    `environment` - The environment information to be used during creation of an `Executor`.
  Returns
    An `Executor` that can execute an expression.
  See Also
    `Executor`

### createEvaluator

    public static Evaluator createEvaluator(Map environment)

  Creates a stateful `Evaluator` using the supplied environment.

  Parameters
    `environment` - The environment information to be used during creation of an `Evaluator`.
  Returns
    An `Evaluator` that can evaluate an expression.
  See Also
    `Evaluator`

### createEvaluator

    public static Evaluator createEvaluator(Map environment,
                                            UnificationList unificationList)

  Creates an `Evaluator` object using the supplied environment and a `UnificationList`. If the supplied `UnificationList` is null then a stateful `Evaluator` is returned, otherwise a stateless `Evaluator` is created by associating the supplied `UnificationList`.

  Parameters
    `environment` - The environment information to be used during creation of an `Evaluator`.
    `unificationList` - An UnificationList.
  Returns
    An `Evaluator` that can evaluate an expression.
  See Also
    `Evaluator`

### createValidator

    public static Validator createValidator(Map environment)

  Creates a stateful `Evaluator` object using the supplied environment.

  Parameters
    `environment` - The environment information to be used during creation of the `Evaluator`.
  Returns
    A `Validator` that can validate an expression.
  See Also
    `Validator`

### createValidator

    public static Validator createValidator(Map environment,
                                            Evaluator evaluator)

  Creates a `Validator` object using the supplied environment and an `Evaluator`. If the supplied `Evaluator` is null then a stateful `Validator` is returned otherwise a stateless `Validator` is created by associating the given `Evaluator`.

  Parameters
    `environment` - The environment information to be used during creation of the `Validator`.
    `evaluator` - An `Evaluator` to evaluate an expression during validation.
  Returns
    A `Validator` that can validate an expression.
  See Also
    `Validator`

### createOptimizer

    public static Optimizer createOptimizer(Map environment,
                                            ObjectFilter objectFilter)

  Creates an `Optimizer` using the supplied environment and an `ObjectFilter`.

  Parameters
    `environment` - The information that is used to create an `Optimizer`.
    `objectFilter` - An `ObjectFilter` that is used during optimization.
  Returns
    An `Optimizer` that can optimize an expression.
  See Also
    `Optimizer`

### createExpression

    public static Expression createExpression(Map environment,
                                              Reader reader)
                                       throws ExpressionException

  Creates an `Expression` using the supplied environment, reading and parsing the characters from the supplied reader.

  Parameters
    `environment` - The information that is used to create an `Expression`.
    `reader` - The reader from which the characters will be read and parsed into an expression object.
  Returns
    An `Expression`.
  Throws
    `ExpressionException` - If an error occurs during reading or parsing.
  See Also
    `Expression`

### createExpression

    public static Expression createExpression(Map environment,
                                              String xmlString)
                                       throws ExpressionException

  Creates an `Expression` using the supplied environment and parsing the supplied string.

  Parameters
    `environment` - The information that is used to create an `Expression`.
    `xmlString` - The XML string that is read and parsed into an expression object.
  Returns
    An `Expression`.
  Throws
    `ExpressionException` - If an error occurs during parsing.
  See Also
    `Expression`

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

Copyright © 2008 BEA Systems, Inc. All Rights Reserved