Skip navigation links

Oracle® Data Integrator Java API Reference
11g Release 1 (11.1.1.5.0)

E17060-02


oracle.odi.domain.xrefs.expression
Class ExpressionStringBuilder

java.lang.Object
  extended by oracle.odi.domain.xrefs.expression.ExpressionStringBuilder


public final class ExpressionStringBuilder
extends java.lang.Object

Helps in the construction of an Expression instance.

This class provides methods to build an expression using ODI objects that can be part of an expression (i.e. variable, column, etc.), as well as plain string corresponding to statements from a predefined language.

You can use that class in order to:

Since:
11.1.1.3.0
See Also:
Expression

Constructor Summary
ExpressionStringBuilder(com.sunopsis.language.SnpsLanguage pLanguage)
          Create a new ExpressionStringBuilder.

 

Method Summary
 ExpressionStringBuilder append(IColumn<?> pColumn, java.lang.String pDataStoreAlias)
          Append the string representation of the given IColumn to this builder's expression.
 ExpressionStringBuilder append(ISourceColumn pSourceColumn)
          Append the string representation of the given ISourceColumn to this builder's expression.
 ExpressionStringBuilder append(OdiSequence pOdiSequence, boolean pBinding)
          Append the string representation of the given OdiSequence to this builder's expression.
 ExpressionStringBuilder append(OdiSequence pOdiSequence, boolean pBinding, boolean pQualified)
          Append the string representation of the given OdiSequence to this builder's expression.
 ExpressionStringBuilder append(OdiUserFunction pOdiUserFunction)
          Append the string representation of the given OdiUserFunction to this builder's expression.
 ExpressionStringBuilder append(OdiUserFunction pOdiUserFunction, java.util.List<ExpressionStringBuilder> pBuilders)
          Append the string representation of the given OdiUserFunction to this builder's expression and uses the pBuilders as parameters of the function.
 ExpressionStringBuilder append(OdiVariable pOdiVariable, boolean pBinding)
          Append the string representation of the given OdiVariable to this builder's expression.
 ExpressionStringBuilder append(OdiVariable pOdiVariable, boolean pBinding, boolean pQualified)
          Append the string representation of the given OdiVariable to this builder's expression.
 ExpressionStringBuilder append(java.lang.String pString)
          Append the given string to this builder's expression.
 com.sunopsis.language.parser.SnpsExpressionTag[] getExpressionTags()
          Returns the current expression tags of this builder.
 com.sunopsis.language.SnpsLanguage getLanguage()
          Returns the language that is used by this builder.
 Expression toExpression()
          Conversion method that takes the current state of this builder and returns it as an Expression instance.
 java.lang.String toString()
          Returns the string representation of the expression of this builder.

 

Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait

 

Constructor Detail

ExpressionStringBuilder

public ExpressionStringBuilder(com.sunopsis.language.SnpsLanguage pLanguage)
Create a new ExpressionStringBuilder.
Parameters:
pLanguage - a language definition

Method Detail

getLanguage

public com.sunopsis.language.SnpsLanguage getLanguage()
Returns the language that is used by this builder.
Returns:
language

getExpressionTags

public com.sunopsis.language.parser.SnpsExpressionTag[] getExpressionTags()
Returns the current expression tags of this builder.
Returns:
an array of tags according the state of this builder

toString

public java.lang.String toString()
Returns the string representation of the expression of this builder.
Overrides:
toString in class java.lang.Object
See Also:
Object.toString()

toExpression

public Expression toExpression()
Conversion method that takes the current state of this builder and returns it as an Expression instance.
Returns:
a valid Expression object

append

public ExpressionStringBuilder append(java.lang.String pString)
Append the given string to this builder's expression.
Parameters:
pString - the string to append
Returns:
a reference to this object

append

public ExpressionStringBuilder append(OdiVariable pOdiVariable,
                                      boolean pBinding)
                               throws IllegalExpressionObjectException
Append the string representation of the given OdiVariable to this builder's expression.
Parameters:
pOdiVariable - the variable to append
pBinding - true if the variable should be resolved during SQL binding, or false to resolve it using direct replacement
Returns:
a reference to this object
Throws:
IllegalExpressionObjectException - if the string representation of the given variable is illegal

append

public ExpressionStringBuilder append(OdiVariable pOdiVariable,
                                      boolean pBinding,
                                      boolean pQualified)
                               throws IllegalExpressionObjectException
Append the string representation of the given OdiVariable to this builder's expression.
Parameters:
pOdiVariable - the variable to append
pBinding - true if the variable should be resolved during SQL binding, or false to resolve it using direct replacement
pQualified - if true the variable is fully qualified
Returns:
a reference to this object
Throws:
IllegalExpressionObjectException - if the string representation of the given variable is illegal
Since:
11.1.1.5.0

append

public ExpressionStringBuilder append(OdiUserFunction pOdiUserFunction)
                               throws IllegalExpressionObjectException
Append the string representation of the given OdiUserFunction to this builder's expression.
Parameters:
pOdiUserFunction - the user function to append
Returns:
a reference to this object
Throws:
IllegalExpressionObjectException - if the string representation of the given user function is illegal

append

public ExpressionStringBuilder append(OdiUserFunction pOdiUserFunction,
                                      java.util.List<ExpressionStringBuilder> pBuilders)
                               throws IllegalExpressionObjectException
Append the string representation of the given OdiUserFunction to this builder's expression and uses the pBuilders as parameters of the function. Note that every parameter is considered as existing (optional parameters are considered as mandatory) and only one instance is taken for each parameter, even for repeatable ones.
Parameters:
pOdiUserFunction - the user function to append
pBuilders - the ExpressionStringBuilders to be used as parameters for the function
Returns:
a reference to this object
Throws:
IllegalExpressionObjectException - if the string representation of the given user function is illegal

append

public ExpressionStringBuilder append(OdiSequence pOdiSequence,
                                      boolean pBinding)
                               throws IllegalExpressionObjectException
Append the string representation of the given OdiSequence to this builder's expression.
Parameters:
pOdiSequence - the sequence to append
pBinding - true if the sequence should be resolved during SQL binding, or false to resolve it using direct replacement
Returns:
a reference to this object
Throws:
IllegalExpressionObjectException - if the string representation of the given sequence is illegal

append

public ExpressionStringBuilder append(OdiSequence pOdiSequence,
                                      boolean pBinding,
                                      boolean pQualified)
                               throws IllegalExpressionObjectException
Append the string representation of the given OdiSequence to this builder's expression.
Parameters:
pOdiSequence - the sequence to append
pBinding - true if the sequence should be resolved during SQL binding, or false to resolve it using direct replacement
pQualified - if true the sequence will be fully qualified
Returns:
a reference to this object
Throws:
IllegalExpressionObjectException - if the string representation of the given sequence is illegal
Since:
11.1.1.5.0

append

public ExpressionStringBuilder append(IColumn<?> pColumn,
                                      java.lang.String pDataStoreAlias)
                               throws IllegalExpressionObjectException
Append the string representation of the given IColumn to this builder's expression.
Parameters:
pColumn - the column to append
pDataStoreAlias - the alias of the data store to be appended to the column name
Returns:
a reference to this object
Throws:
IllegalExpressionObjectException - if the string representation of the given column is illegal

append

public ExpressionStringBuilder append(ISourceColumn pSourceColumn)
                               throws IllegalExpressionObjectException
Append the string representation of the given ISourceColumn to this builder's expression.
Parameters:
pSourceColumn - the column to append
Returns:
a reference to this object
Throws:
IllegalExpressionObjectException - if the string representation of the given column is illegal

Skip navigation links

Oracle® Data Integrator Java API Reference
11g Release 1 (11.1.1.5.0)

E17060-02


Copyright © 2011, Oracle and/or its affiliates. All rights reserved.