|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--com.fdsapi.arrays.ConditionalCompositeContainer
This class is used to build the ArrayFilter and ArraySQL classes (ArraySQL is simply backed by ArrayFilter). This class validates
the given sql. This class does not need to be used directly by developers.
All classes that implement the ConditionalComposite interface implement the ConditionalComposite design
pattern.
View Code
| Constructor Summary | |
ConditionalCompositeContainer()
|
|
ConditionalCompositeContainer(ConditionalComposite rootComposite)
Contructor that takes an explicit ConditionalComposite (typically ConditionalCompositeOr) as the root (i.e. |
|
| Method Summary | |
void |
addAnd()
Add a logical "and" between Conditionals in the active ConditionalComposite |
void |
addConditional(Conditional conditional)
Add a Conditional to the currently active ConditionalComposite. |
void |
addConditionalComposite(ConditionalComposite comp)
This adds the ConditionalComposite to the chain AND makes it the active ConditionalComposite to which all subsequent Conditionals are added to until the paren level changes. |
void |
addLeftParen()
Add a left paren to group Conditionals together. |
void |
addNot()
Negate the value of the active ConditionalComposite |
void |
addOr()
Add a logical "or" between Conditionals in the active ConditionalComposite |
void |
addRightParen()
Add a right paren to end the current grouping of Conditionals together. |
void |
build()
This method is called to convert ArrayFilter calls such as addConditional that build the object structure that implements ArrayFilter. |
java.lang.String |
getType()
Empty implementation |
boolean |
isTrue(java.lang.Object[] row)
This method calls the root composites isTrue(...) method and it in turn calls all Conditionals that are contained's isTrue(...) methods. |
java.lang.String |
toString()
Display a string representation of all Conditionals owned by this ConditionalComposite |
void |
validate()
Method that validates the syntax of the ArraySQL or ArrayFilter method calls. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public ConditionalCompositeContainer()
public ConditionalCompositeContainer(ConditionalComposite rootComposite)
| Method Detail |
public void build()
public boolean isTrue(java.lang.Object[] row)
isTrue in interface ConditionalCompositepublic void validate()
public void addConditional(Conditional conditional)
addConditional in interface ConditionalCompositepublic void addConditionalComposite(ConditionalComposite comp)
public void addLeftParen()
public void addRightParen()
public void addNot()
addNot in interface ConditionalCompositepublic void addAnd()
public void addOr()
public java.lang.String getType()
getType in interface Conditionalpublic java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||