public class Tuple
extends java.lang.Object
implements java.io.Serializable
Modifier and Type | Field and Description |
---|---|
static java.lang.Object |
ANY |
static java.lang.Object |
UNKNOWN |
Constructor and Description |
---|
Tuple(java.lang.Object[] objs) |
Tuple(java.lang.String name) |
Tuple(java.lang.String name,
java.lang.Object... objs) |
Modifier and Type | Method and Description |
---|---|
boolean |
booleanContent(int index)
Get the i-th argument coverted to a boolean
|
double |
doubleContent(int index)
Get the i-th argument coverted to an double
|
java.lang.Object |
getContent(int index)
Get the i-th argument of the tuple.
|
java.lang.Object[] |
getContents()
Get the full array of arguments.
|
java.lang.String |
getLabel()
Get the label of the tuple.
|
int |
getNArgs()
Get the arity of the tuple.
|
int |
intContent(int index)
Get the i-th argument coverted to an integer
|
java.lang.String |
stringContent(int index)
Get the i-th argument coverted to a String
|
java.lang.String |
toString()
Get the string representation of the tuple.
|
public static final java.lang.Object ANY
public static final java.lang.Object UNKNOWN
public Tuple(java.lang.String name)
public Tuple(java.lang.String name, java.lang.Object... objs)
public Tuple(java.lang.Object[] objs)
public java.lang.String getLabel()
public java.lang.Object getContent(int index)
index
- index of the argumentpublic java.lang.Object[] getContents()
public int intContent(int index)
index
- public double doubleContent(int index)
index
- public boolean booleanContent(int index)
index
- public java.lang.String stringContent(int index)
index
- public int getNArgs()
public java.lang.String toString()
toString
in class java.lang.Object
>DEIS - University of Bologna