|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmln.Predicate
dstruct.FelixPredicate
public class FelixPredicate
The predicate object used in Felix, which extends the Predicate class in Tuffy to contain Felix-related fields and methods.
Nested Class Summary | |
---|---|
static class |
FelixPredicate.FPProperty
Properties that can be assigned to each predicate. |
Field Summary | |
---|---|
(package private) java.util.HashMap<FelixClause,java.util.ArrayList<java.lang.String>> |
chainRulePartitions
Map from chain-rule clauses to possible partitions of sequence. |
boolean |
isCorefMapPredicate
Whether this predicate is the view-based representation of a coref operator. |
(package private) java.util.HashSet<java.lang.Integer> |
keyPositions
If this predicate has key constraints, this set records the position of keys. |
StatOperator.OPType |
mustbe
The type of operator this predicate must be assigned to. |
FelixPredicate |
oriCorefPredicate
If isCorefMapPredicate is true, to which this
predicate serves. |
(package private) java.util.HashMap<FelixPredicate.FPProperty,java.util.HashSet<FelixClause>> |
properities
Map from predicate properties ( FelixPredicate.FPProperty ) to
clauses satisfying the corresponding property. |
(package private) java.util.HashSet<FelixClause> |
registeredClauses
Clauses related to this predicate. |
(package private) static int |
tmpPredCounter
Global counter for temporary predicates. |
Fields inherited from class mln.Predicate |
---|
hasSoftEvidence, iclauses, intCounterStep, isBuiltIn, isCRFHead, isCurrentlyView, isDedupalogHead, isInMem, isLRHead, mln, nextTupleID, posOfCRFFollowField, posOfLRField, seqName, toDump |
Constructor Summary | |
---|---|
FelixPredicate(java.lang.String aname,
boolean aClosedWorld)
The constructor. |
Method Summary | |
---|---|
java.util.ArrayList<java.lang.String> |
getCRFPartitionFields()
Get partitioning fields of sequence if this predicate is CRF. |
java.util.ArrayList<java.lang.String> |
getKeyFieldsArgs()
Get the key position if this predicate is LR or CRF. |
java.util.HashSet<java.lang.Integer> |
getKeyPositions()
Get keyPositions . |
java.util.ArrayList<java.lang.String> |
getLabelFieldsArgs()
Get the label fields' name if this predicate is LR or CRF. |
java.util.ArrayList<java.lang.String> |
getLabelFieldsTypeTable()
Get the label types if this predicate is LR or CRF. |
java.util.ArrayList<java.lang.Integer> |
getLabelPositions()
Get the label position if this predicate is LR or CRF. |
static java.lang.String |
getNextTmpPredicateName()
Get the name of the next temporary predicate. |
FelixPredicate |
getOriCorefPredicate()
If isCorefMapPredicate is true, to which this
predicate serves. |
java.util.HashSet<FelixClause> |
getPropertyClauses(FelixPredicate.FPProperty prop)
Get clauses associated to the given property. |
java.util.HashSet<FelixClause> |
getRelevantClauses()
Get all clauses related to this predicate. |
boolean |
hasProperty(FelixPredicate.FPProperty prop)
Whether this predicate has the given property. |
boolean |
isCorefMap()
Whether this predicate is the view-based representation of a coref operator. |
void |
registerProperty(FelixPredicate.FPProperty prop,
FelixClause evid,
int... _pos)
Add a property to this predicate, along with the clause with this property. |
java.lang.String |
toString()
|
void |
tryToExtractSeqFromChainRule(FelixClause fc)
If the given clause is a CRF chain rule, try to extract the partitions of sequence. |
Methods inherited from class mln.Predicate |
---|
addDependentAttrPosition, addEvidence, addFunctionalDependency, addQuery, addRelatedClause, appendArgument, appendArgument, arity, closeFiles, flushEvidence, getArgPositionByName, getArgs, getBuiltInPredByName, getDependentAttrPositions, getDependentAttrs, getID, getKeyAttrPositions, getKeyAttrs, getName, getQueryAtoms, getRelAct, getRelatedClauses, getRelName, getTypeAt, groundAndStoreAtom, hasDependentAttributes, hasEvidence, hasMoreToGround, hasQuery, hasSoftEvidence, isBuiltInPredName, isChainPredicate, isClosedWorld, isCompletelySepcified, isImmutable, isSafeRefOnly, nextTupleID, nextTupleID, nextTupleIDAndUpdate, noNeedToGround, prepareDB, prepareDBAgain, sealDefinition, setAllQuery, setClosedWorld, setCompeletelySpecified, setHasSoftEvidence, setID, setSafeRefOnly, storeQueries |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public StatOperator.OPType mustbe
public boolean isCorefMapPredicate
public FelixPredicate oriCorefPredicate
isCorefMapPredicate
is true, to which this
predicate serves.
java.util.HashMap<FelixPredicate.FPProperty,java.util.HashSet<FelixClause>> properities
FelixPredicate.FPProperty
) to
clauses satisfying the corresponding property.
java.util.HashSet<FelixClause> registeredClauses
java.util.HashSet<java.lang.Integer> keyPositions
java.util.HashMap<FelixClause,java.util.ArrayList<java.lang.String>> chainRulePartitions
static int tmpPredCounter
Constructor Detail |
---|
public FelixPredicate(java.lang.String aname, boolean aClosedWorld)
aname
- aClosedWorld
- Method Detail |
---|
public java.util.ArrayList<java.lang.Integer> getLabelPositions()
public java.util.ArrayList<java.lang.String> getCRFPartitionFields()
public java.util.ArrayList<java.lang.String> getKeyFieldsArgs()
public java.util.ArrayList<java.lang.String> getLabelFieldsTypeTable()
public java.util.ArrayList<java.lang.String> getLabelFieldsArgs()
public static java.lang.String getNextTmpPredicateName()
public boolean isCorefMap()
public FelixPredicate getOriCorefPredicate()
isCorefMapPredicate
is true, to which this
predicate serves.
public java.util.HashSet<FelixClause> getPropertyClauses(FelixPredicate.FPProperty prop)
prop
-
public boolean hasProperty(FelixPredicate.FPProperty prop)
prop
-
public java.util.HashSet<java.lang.Integer> getKeyPositions()
keyPositions
.
public java.util.HashSet<FelixClause> getRelevantClauses()
public void registerProperty(FelixPredicate.FPProperty prop, FelixClause evid, int... _pos)
prop
- evid
- _pos
- if this property is key constraint, this parameter is the position
of keys.public void tryToExtractSeqFromChainRule(FelixClause fc)
fc
- 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 |