com.tietoenator.trip.jxp.session

## Class TdbDateform

- java.lang.Object
- - com.tietoenator.trip.jxp.session.TdbDateform

-     public class TdbDateform
      extends java.lang.Object

  Date/time formatting and parsing for the current TRIP dateform. An instance of this class is obtained via the TdbSession method getCurrentDateform().
  See Also:
    `TdbSession.getCurrentDateform()`

- - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.lang.String` | `formatDate(java.util.Date value)` Formats a Java Date into a TRIP DATE string.
    `java.util.Date` | `formatDate(java.lang.String value)` Parses a string with a TRIP DATE value into a Java Date.
    `java.lang.String` | `formatTime(java.util.Date value)` Formats a Java Date into a TRIP TIME string.
    `java.util.Date` | `formatTime(java.lang.String value)` Parses a string with a TRIP TIME value into a Java Date.
    `java.util.Date` | `formatTimestamp(java.lang.String dateTimeValue)` Parses a string with a TRIP time stamp string (such as the lastUpdated value for database designs available via TdbDatabaseDesign) into a Java Date object.
    `java.util.Date` | `formatTimestamp(java.lang.String dateValue, java.lang.String timeValue)` Parses a string with a TRIP DATE value and a string with a TRIP TIME value into a single Java Date object.
    `int` | `getDateformNumber()` Retrieves the number of the date form represented by this object.

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

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

- - ### Method Detail

    - #### getDateformNumber

          public int getDateformNumber()

      Retrieves the number of the date form represented by this object.

    - #### formatDate

          public java.util.Date formatDate(java.lang.String value)
                                    throws TdbException

      Parses a string with a TRIP DATE value into a Java Date.
      Parameters:
        `value` - String with a TRIP DATE value.
      Returns:
        Java Date object
      Throws:
        `TdbException`

    - #### formatDate

          public java.lang.String formatDate(java.util.Date value)

      Formats a Java Date into a TRIP DATE string.
      Parameters:
        `value` - Java date object.
      Returns:
        Date formatted as a string in the current TRIP dateform.

    - #### formatTime

          public java.lang.String formatTime(java.util.Date value)

      Formats a Java Date into a TRIP TIME string.
      Parameters:
        `value` - Java date object.
      Returns:
        The time part of the date object formatted as a string.

    - #### formatTime

          public java.util.Date formatTime(java.lang.String value)
                                    throws java.text.ParseException

      Parses a string with a TRIP TIME value into a Java Date.
      Parameters:
        `value` - String with a TRIP TIME value.
      Returns:
        Java Date object
      Throws:
        `java.text.ParseException`

    - #### formatTimestamp

          public java.util.Date formatTimestamp(java.lang.String dateValue,
                                                java.lang.String timeValue)
                                         throws TdbException

      Parses a string with a TRIP DATE value and a string with a TRIP TIME value into a single Java Date object.
      Parameters:
        `dateValue` - Date value in the current TRIP dateform.
        `timeValue` - TRIP time value
      Returns:
        Java Date object
      Throws:
        `TdbException`

    - #### formatTimestamp

          public java.util.Date formatTimestamp(java.lang.String dateTimeValue)
                                         throws TdbException

      Parses a string with a TRIP time stamp string (such as the lastUpdated value for database designs available via TdbDatabaseDesign) into a Java Date object.
      Parameters:
        `dateTimeValue` - Time stamp string where the date part is in the current TRIP dateform.
      Returns:
        Java Date object
      Throws:
        `TdbException`