|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--unitloader.QBool
Title: the QBool class representing booelan operations.
Description: Class to represent boolean queries. Uses Comp and QBool objects to construct complex queries recursively.
Comp
Field Summary | |
private java.lang.Object |
first
|
private java.lang.String |
op
|
private java.lang.Object |
second
|
Constructor Summary | |
QBool(java.lang.String op,
Comp arg)
Overloaded constructor for the one and only usefull unary boolean operator (not). |
|
QBool(java.lang.String op,
Comp first,
Comp second)
Overloaded constructor for binary boolean operators (or, and, nor, nand). |
|
QBool(java.lang.String op,
Comp first,
QBool second)
Overloaded constructor for binary boolean operators (or, and, nor, nand). |
|
QBool(java.lang.String op,
QBool arg)
Overloaded constructor for unary boolean operators (not). |
|
QBool(java.lang.String op,
QBool first,
Comp second)
Overloaded constructor for binary boolean operators (or, and, nor, nand). |
|
QBool(java.lang.String op,
QBool first,
QBool second)
Overloaded constructor for binary boolean operators (or, and, nor, nand). |
|
QBool(java.lang.String compOp,
java.lang.String elem,
java.util.List valList)
Overloaded constructor for nested QBools containing multiple comparisons with the same concept and comparison operator. |
Method Summary | |
java.lang.Object |
getFirst()
Returns the first operand of this object. |
java.lang.String |
getOp()
Returns the name of the boolean operation represented with this object. |
java.lang.Object |
getSecond()
Returns the second operand of this object. |
boolean |
isQBool(int firstOrSecond)
Check whether the given child (argument) specified with the parameter of this method is a boolean operation. |
Methods inherited from class java.lang.Object |
|
Field Detail |
private java.lang.String op
private java.lang.Object first
private java.lang.Object second
Constructor Detail |
public QBool(java.lang.String op, QBool first, QBool second)
op
- boolean operation as a string (currently "and", "or"
"nand", and "nor" implemented).first
- first argument (boolean query).second
- second argument (boolean query).java.lang.IllegalArgumentException
- if wrong parameter is passed.public QBool(java.lang.String op, QBool first, Comp second)
op
- boolean operation as a string.first
- first argument (boolean query).second
- second argument (Comp object).java.lang.IllegalArgumentException
- if wrong parameter is passed.public QBool(java.lang.String op, Comp first, QBool second)
op
- boolean operation as a string.first
- first argument (Comp object).second
- second argument (boolean query).java.lang.IllegalArgumentException
- if wrong parameter is passed.public QBool(java.lang.String op, Comp first, Comp second)
op
- boolean operation as a string.first
- first argument (Comp object).second
- second argument (Comp object).java.lang.IllegalArgumentException
- if wrong parameter is passed.public QBool(java.lang.String op, QBool arg)
op
- boolean operation as a string (only "not" implemented).arg
- argument (boolean query).java.lang.IllegalArgumentException
- if wrong parameter is passed.public QBool(java.lang.String op, Comp arg)
op
- boolean operation as a string (only "not" implemented).arg
- argument (Comp object).java.lang.IllegalArgumentException
- if wrong parameter is passed.public QBool(java.lang.String compOp, java.lang.String elem, java.util.List valList)
compOp
- comparison operation as a string.elem
- argument as a String.valList
- argument (List object).java.lang.IllegalArgumentException
- if wrong parameter is passed.Method Detail |
public boolean isQBool(int firstOrSecond)
firstOrSecond
- specifies which child is to be checked (1 or 2).java.lang.IllegalArgumentException
- if wrong parameter is passed.public java.lang.String getOp()
public java.lang.Object getFirst()
public java.lang.Object getSecond()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |