|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectsimpledb.query.Predicate
public class Predicate
A predicate is a Boolean combination of terms.
| Constructor Summary | |
|---|---|
Predicate()
Creates an empty predicate, corresponding to "true". |
|
Predicate(Term t)
Creates a predicate containing a single term. |
|
| Method Summary | |
|---|---|
void |
conjoinWith(Predicate pred)
Modifies the predicate to be the conjunction of itself and the specified predicate. |
Constant |
equatesWithConstant(java.lang.String fldname)
Determines if there is a term of the form "F=c" where F is the specified field and c is some constant. |
java.lang.String |
equatesWithField(java.lang.String fldname)
Determines if there is a term of the form "F1=F2" where F1 is the specified field and F2 is another field. |
boolean |
isSatisfied(Scan s)
Returns true if the predicate evaluates to true with respect to the specified scan. |
Predicate |
joinPred(Schema sch1,
Schema sch2)
Returns the subpredicate consisting of terms that apply to the union of the two specified schemas, but not to either schema separately. |
int |
reductionFactor(Plan p)
Calculates the extent to which selecting on the predicate reduces the number of records output by a query. |
Predicate |
selectPred(Schema sch)
Returns the subpredicate that applies to the specified schema. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Predicate()
public Predicate(Term t)
t - the term| Method Detail |
|---|
public void conjoinWith(Predicate pred)
pred - the other predicatepublic boolean isSatisfied(Scan s)
s - the scan
public int reductionFactor(Plan p)
p - the query's plan
public Predicate selectPred(Schema sch)
sch - the schema
public Predicate joinPred(Schema sch1,
Schema sch2)
sch1 - the first schemasch2 - the second schema
public Constant equatesWithConstant(java.lang.String fldname)
fldname - the name of the field
public java.lang.String equatesWithField(java.lang.String fldname)
fldname - the name of the field
public 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 | |||||||||