org.ogf.graap.wsag.interpreter.expr
Class ExactlyOneExpression

java.lang.Object
  extended by org.ogf.graap.wsag.interpreter.expr.AbstractExpression
      extended by org.ogf.graap.wsag.interpreter.expr.ExactlyOneExpression
All Implemented Interfaces:
IExpression

public class ExactlyOneExpression
extends AbstractExpression

ExactlyOneExpression

Author:
Oliver Waeldrich

Constructor Summary
ExactlyOneExpression(TermCompositorType expression)
           
 
Method Summary
protected  TermType[] interpret(TermType[] terms, InterpreterContext context)
          template method that implements a specific interpretation strategy.
 
Methods inherited from class org.ogf.graap.wsag.interpreter.expr.AbstractExpression
interpret
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExactlyOneExpression

public ExactlyOneExpression(TermCompositorType expression)
Parameters:
expression - a term compositor representing an ExactlyOne expression
Method Detail

interpret

protected TermType[] interpret(TermType[] terms,
                               InterpreterContext context)
                        throws InterpreterException
template method that implements a specific interpretation strategy. The strategy interprets a set of terms and returns a result, i.e. the selected term in an ExactlyOne statement.

Specified by:
interpret in class AbstractExpression
Parameters:
terms - the terms to interpret
context - the interpreter context
Returns:
the strategy result, i.e. a filtered term list
Throws:
InterpreterException - indicates an error during the term interpretation
See Also:
AbstractExpression.interpret(TermType [], InterpreterContext)


Copyright © 2008-2012. All Rights Reserved.