- All Known Subinterfaces:
Fact, Rule
- All Known Implementing Classes:
AFact, ARelation, ARule
public interface Relation
A prolog relation between arguments. Examples:
foo(1, 2).
bar(X, Y) :- foo(X, 1), Y = X.
&c.
-
Method Summary
| Modifier and Type |
Method |
Description |
List<org.antlr.v4.runtime.tree.ParseTree> |
args() |
The arguments of the relation
|
int |
arity() |
How many arguments the relation takes
|
Optional<Comment> |
comment() |
|
String |
name() |
The name of the relation
|
-
Method Details
-
-
List<org.antlr.v4.runtime.tree.ParseTree> args()
The arguments of the relation
-
int arity()
How many arguments the relation takes
Should be equivalent to args().size()
-