|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectde.unidu.is.pdatalog.ds.Rule
de.unidu.is.pdatalog.ds.Fact
The representation of a datalog probabilistic fact. A fact is a rule with an emtpy (always true) body.
| Field Summary |
| Fields inherited from class de.unidu.is.pdatalog.ds.Rule |
body, head |
| Constructor Summary | |
Fact(double prob,
Literal head)
Creates a new fact from the specified literal with the given probability. |
|
Fact(Fact fact)
Creates a new fact as a copy of the specified fact. |
|
Fact(Literal head)
Creates a new deterministic fact from the specified literal. |
|
Fact(Literal head,
Expression mapping)
Creates a new probabilistic fact. |
|
| Method Summary | |
int |
getArity()
Returns the arity of this fact's predicate. |
Expression |
getConst(int num)
Returns the constant of this fact at the specified index. |
java.lang.String |
getConsts()
Returns a string description of the constants of this fact, separated by colons. |
double |
getProb()
Returns the probabilistic weight of this fact. |
| Methods inherited from class de.unidu.is.pdatalog.ds.Rule |
addLiteral, contains, containsExactly, containsExactlyInBody, getAllArguments, getAllArgumentsAsArray, getBody, getConstants, getHead, getMapping, getMapping, getMapping, getName, getPredicateName, getVariables, isOptimizable, literalAt, literalCount, putAllArguments, putConstants, putVariables, removeLiteral, removeLiteral, setHead, setLiteral, setMapping, setOptimizable, toString |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public Fact(Literal head,
Expression mapping)
head - "head" of the factmapping - mapping functionpublic Fact(Literal head)
head - literal describing this deterministic fact
public Fact(double prob,
Literal head)
prob - probability of this facthead - literal describing this factpublic Fact(Fact fact)
fact - fact to be copied| Method Detail |
public java.lang.String getConsts()
public int getArity()
public Expression getConst(int num)
public double getProb()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||