## edu.stanford.nlp.util
Class IntTuple

    java.lang.Object
      edu.stanford.nlp.util.IntTuple

All Implemented Interfaces:
  Serializable

Direct Known Subclasses:
  IntPair, IntQuadruple, IntTriple, IntUni

    public class IntTuple

extends Object
implements Serializable

A tuple of int. There are special classes for IntUni, IntPair, IntTriple and IntQuadruple. The motivation for that was the different hashCode implementations. By using the static IntTuple.getIntTuple(numElements) one can obtain an instance of the appropriate sub-class.

Author:
  Kristina Toutanova (kristina@cs.stanford.edu)
See Also:
  Serialized Form

Constructor Summary
`IntTuple(int num)`
`IntTuple(int[] arr)`

Method Summary
`static IntTuple` `concat(IntTuple t1, IntTuple t2)`
`int[]` `elems()`
`boolean` `equals(Object iO)`
`int` `get(int num)`
`IntTuple` `getCopy()`
`static IntTuple` `getIntTuple(int num)`
`static IntTuple` `getIntTuple(List<Integer> integers)`
`int` `hashCode()`
`int` `length()`
`void` `print()`
`void` `set(int num, int val)`
`void` `shiftLeft()`
`String` `toString()`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Constructor Detail

### IntTuple

    public IntTuple(int[] arr)

### IntTuple

    public IntTuple(int num)

Method Detail

### get

    public int get(int num)

### set

    public void set(int num,
                    int val)

### shiftLeft

    public void shiftLeft()

### getCopy

    public IntTuple getCopy()

### elems

    public int[] elems()

### equals

    public boolean equals(Object iO)

  Overrides:
    `equals` in class `Object`

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `Object`

### length

    public int length()

### getIntTuple

    public static IntTuple getIntTuple(int num)

### getIntTuple

    public static IntTuple getIntTuple(List<Integer> integers)

### toString

    public String toString()

  Overrides:
    `toString` in class `Object`

### concat

    public static IntTuple concat(IntTuple t1,
                                  IntTuple t2)

### print

    public void print()

Stanford NLP Group