Package com.tietoenator.trip.jxp.data

# Class TdbTuple

java.lang.Object
com.tietoenator.trip.jxp.data.TdbTuple

public class TdbTuple extends Object
Represents rows in the table of fields in a record that the TdbTupleList class is an representation of.

Since:
  TRIPjxp 1.3-0
See Also:
  - `TdbTupleList`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `clear()`
  Blanks out all the TRIP subfield values represented by this tuple.
  `TdbTupleList`
  `getTupleList()`
  A reference to the associated TdbTupleList object that contains the tuple.
  `String`
  `getValue(int fieldIndex)`
  Get the value of a field within the tuple.
  `String`
  `getValue(String fieldName)`
  Get the value of a field within the tuple.
  `void`
  `remove()`
  Removes the tuple associated with this TdbTuple instance.
  `void`
  `setValue(int fieldIndex, String val)`
  Set the value of a field within the tuple.
  `void`
  `setValue(String fieldName, String val)`
  Set the value of a field within the tuple.

  ### Methods inherited from class java.lang.Object

  `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Method Details

  - ### getTupleList

    public TdbTupleList getTupleList()
    A reference to the associated TdbTupleList object that contains the tuple.
    Returns:
      TdbTupleList reference

  - ### clear

    public void clear() throws TdbException
    Blanks out all the TRIP subfield values represented by this tuple.

    This method does not remove the tuple itself, all values are merely cleared. To remove the typle use the remove method on the TdbTuple or the TdbTupleList class.

    Throws:
      `TdbException`
    See Also:
      - `remove()`
      - `TdbTupleList.remove(int)`

  - ### remove

    public void remove() throws TdbException
    Removes the tuple associated with this TdbTuple instance.
    Throws:
      `TdbException`

  - ### getValue

    public String getValue(int fieldIndex) throws TdbException
    Get the value of a field within the tuple.
    Parameters:
      `fieldIndex` - Zero-based index of field.
    Returns:
      Value of the specified field for this tuple.
    Throws:
      `TdbException` - If the index is outside the valid range, or if the tuple that this TdbTuple object represents has been removed from the tuple list.

  - ### getValue

    public String getValue(String fieldName) throws TdbException
    Get the value of a field within the tuple.
    Parameters:
      `fieldName` - Name of field.
    Returns:
      Value of the specified field for this tuple.
    Throws:
      `TdbException` - If the index is outside the valid range, or if the tuple that this TdbTuple object represents has been removed from the tuple list.

  - ### setValue

    public void setValue(int fieldIndex, String val) throws TdbException
    Set the value of a field within the tuple.
    Parameters:
      `fieldIndex` - Zero-based index of field.
      `val` - Value to assign to the specified field in this tuple.
    Throws:
      `TdbException` - If the index is outside the valid range, or if the tuple that this TdbTuple object represents has been removed from the tuple list.

  - ### setValue

    public void setValue(String fieldName, String val) throws TdbException
    Set the value of a field within the tuple.
    Parameters:
      `fieldName` - Name of field.
      `val` - Value to assign to the specified field in this tuple.
    Throws:
      `TdbException` - If the tuple has been removed from the list, or when the specified field is unknown.