org.mariadb.jdbc.internal.packet.dao.parameters

## Class TimestampParameter

- java.lang.Object
- - org.mariadb.jdbc.internal.packet.dao.parameters.ParameterHolder
  - - org.mariadb.jdbc.internal.packet.dao.parameters.NotLongDataParameterHolder
    - - org.mariadb.jdbc.internal.packet.dao.parameters.TimestampParameter

All Implemented Interfaces:
  Cloneable

    public class TimestampParameter
    extends NotLongDataParameterHolder

### Constructor Summary

Constructors
Constructor and Description
`TimestampParameter(Timestamp ts, Calendar cal, boolean fractionalSeconds, Options options)` Constructor.

### Method Summary

All Methods Instance Methods Concrete Methods
`long` `getApproximateTextProtocolLength()`
`MariaDbType` `getMariaDbType()`
`void` `writeBinary(PacketOutputStream writeBuffer)` Write timeStamp in binary format.
`void` `writeTo(OutputStream os)` Write parameter value.

### Methods inherited from class org.mariadb.jdbc.internal.packet.dao.parameters.NotLongDataParameterHolder

`isLongData`

### Methods inherited from class org.mariadb.jdbc.internal.packet.dao.parameters.ParameterHolder

`toString, writeBufferType`

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

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Constructor Detail

#### TimestampParameter

    public TimestampParameter(Timestamp ts,
                              Calendar cal,
                              boolean fractionalSeconds,
                              Options options)

Constructor.

Parameters:
  `ts` - timestamps
  `cal` - session calendar
  `fractionalSeconds` - must fractional Seconds be send to database.
  `options` - session options

### Method Detail

#### writeTo

    public void writeTo(OutputStream os)
                 throws IOException

Description copied from class: `ParameterHolder`
Write parameter value.

Specified by:
  `writeTo` in class `ParameterHolder`
Parameters:
  `os` - the stream to write to
Throws:
  `IOException` - when something goes wrong

#### getApproximateTextProtocolLength

    public long getApproximateTextProtocolLength()
                                          throws IOException

Specified by:
  `getApproximateTextProtocolLength` in class `ParameterHolder`
Throws:
  `IOException`

#### writeBinary

    public void writeBinary(PacketOutputStream writeBuffer)

Write timeStamp in binary format.

Specified by:
  `writeBinary` in class `NotLongDataParameterHolder`
Parameters:
  `writeBuffer` - buffer to write

#### getMariaDbType

    public MariaDbType getMariaDbType()

Specified by:
  `getMariaDbType` in class `ParameterHolder`