All Packages Class Hierarchy This Package Previous Next Index
Class ProgolInterface.Mode
java.lang.Object
|
+----ProgolInterface.Mode
- public class Mode
- extends Object
A class that represents a Progol mode declaration.
The Class stores the mode type, predicate name and arity
and a Vector of mode arguments, of type ModeArg.
- See Also:
- ModeArg
-
Mode(Clause)
- Constructs a Mode from a clause representation.
-
Mode(int, String, int)
- Constructs a Mode of the specified mode type, predicate and arity.
-
ArgumentAt(int)
-
-
arguments()
-
-
arity()
-
-
isHead()
-
-
listArgs(List)
- Places a List representation of the arguments of the mode in
the given java.awt.List.
-
modeType()
-
-
predicate()
-
-
predicateSymbol()
-
-
setArgumentAt(ModeArg, int)
- Puts the specified ModeArg at the specified position.
-
toString()
-
Mode
public Mode(int mt,
String pred,
int arity)
- Constructs a Mode of the specified mode type, predicate and arity.
Since arguments are not specified, it fills them in with "+any"'s.
- Parameters:
- mt - The mode type.
- pred - The predicate of the mode (without arity).
- arity - The arity of the mode.
Mode
public Mode(Clause cl)
- Constructs a Mode from a clause representation.
- Parameters:
- clause - A Clause representation of the mode.
arity
public final int arity()
- Returns:
- the arity of the mode.
predicateSymbol
public final String predicateSymbol()
- Returns:
- the predicate symbol of the mode.
predicate
public final String predicate()
- Returns:
- the predicate (without arity) of the mode.
modeType
public final String modeType()
- Returns:
- the mode type of the mode.
isHead
public final boolean isHead()
- Returns:
- true, if the mode is a head mode.
arguments
public final Vector arguments()
- Returns:
- a Vector of the mode arguments.
setArgumentAt
public final void setArgumentAt(ModeArg ma,
int pos)
- Puts the specified ModeArg at the specified position.
ArgumentAt
public final ModeArg ArgumentAt(int pos)
- Returns:
- the ModeArg at the specified position.
listArgs
public final void listArgs(List list)
- Places a List representation of the arguments of the mode in
the given java.awt.List.
toString
public final String toString()
- Returns:
- a string representation of the Mode.
- Overrides:
- toString in class Object
All Packages Class Hierarchy This Package Previous Next Index