public class SummationAtom extends Object implements SummationAtomOrAtom
Atom
that can additionally take SummationVariables
as arguments.
SummationAtoms can be used in an ArithmeticRuleExpression
.
Note that SummationAtom is not a subclass of Atom.Modifier and Type | Field and Description |
---|---|
protected SummationVariableOrTerm[] |
args |
protected Predicate |
p |
Constructor and Description |
---|
SummationAtom(Predicate p,
SummationVariableOrTerm[] args) |
Modifier and Type | Method and Description |
---|---|
protected void |
checkSchema()
Verifies that this atom has valid arguments.
|
boolean |
equals(Object oth) |
SummationVariableOrTerm[] |
getArguments()
Returns the arguments associated with this SummationAtom.
|
int |
getArity()
Returns the number of arguments to the associated Predicate.
|
Predicate |
getPredicate()
Returns the predicate associated with this SummationAtom.
|
QueryAtom |
getQueryAtom() |
int |
hashCode() |
String |
toString() |
protected final Predicate p
protected final SummationVariableOrTerm[] args
public SummationAtom(Predicate p, SummationVariableOrTerm[] args)
protected void checkSchema()
IllegalArgumentException
- if the number of arguments doesn't match the
number of arguments of the predicateIllegalArgumentException
- if any argument is nullpublic QueryAtom getQueryAtom()
public Predicate getPredicate()
public int getArity()
public SummationVariableOrTerm[] getArguments()
Copyright © 2018 University of California, Santa Cruz. All rights reserved.