|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Objectorg.javatuples.Tuple
public abstract class Tuple
Abstract base class for all tuple classes.
Constructor Summary | |
---|---|
protected |
Tuple(int size,
Object... values)
Deprecated. Will be removed in 1.4. The "size" parameter is of no use at this level, so use the simpler Tuple(values) constructor instead. |
protected |
Tuple(Object... values)
|
Method Summary | |
---|---|
int |
compareTo(Tuple o)
|
boolean |
contains(Object value)
|
boolean |
containsAll(Collection<?> collection)
|
boolean |
containsAll(Object... values)
|
boolean |
equals(Object obj)
|
abstract int |
getSize()
Return the size of the tuple. |
Object |
getValue(int pos)
Get the value at a specific position in the tuple. |
int |
hashCode()
|
int |
indexOf(Object value)
|
Iterator<Object> |
iterator()
|
int |
lastIndexOf(Object value)
|
Object[] |
toArray()
|
List<Object> |
toList()
|
String |
toString()
|
Methods inherited from class Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
@Deprecated protected Tuple(int size, Object... values)
protected Tuple(Object... values)
Method Detail |
---|
public abstract int getSize()
Return the size of the tuple.
public final Object getValue(int pos)
Get the value at a specific position in the tuple. This method has to return object, so using it you will lose the type-safety you get with the getValueX() methods.
pos
- the position of the value to be retrieved.
public final Iterator<Object> iterator()
iterator
in interface Iterable<Object>
public final String toString()
toString
in class Object
public final boolean contains(Object value)
public final boolean containsAll(Collection<?> collection)
public final boolean containsAll(Object... values)
public final int indexOf(Object value)
public final int lastIndexOf(Object value)
public final List<Object> toList()
public final Object[] toArray()
public final int hashCode()
hashCode
in class Object
public final boolean equals(Object obj)
equals
in class Object
public int compareTo(Tuple o)
compareTo
in interface Comparable<Tuple>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |