public static double getDouble(Timestamp timestamp) {
    // Same algorithm as TimestampWritable (not currently import-able here).
    double seconds, nanos;
    seconds = millisToSeconds(timestamp.getTime());
    nanos = timestamp.getNanos();
    return seconds + nanos / 1000000000;
  }
Return a double representation of a Timestamp.
@param timestamp
@return
storage-api/src/java/org/apache/hadoop/hive/ql/exec/vector/TimestampColumnVector.java