Java Timestamp Create toTimestamp(final Instant instant)

Here you can find the source of toTimestamp(final Instant instant)

Description

TODO: Documentation

License

Open Source License

Declaration

public static Timestamp toTimestamp(final Instant instant) 

Method Source Code


//package com.java2s;
import java.sql.Timestamp;

import java.time.Instant;

public class Main {
    /** TODO: Documentation */
    public static Timestamp toTimestamp(final Instant instant) {
        return new Timestamp(instant.toEpochMilli());
    }//from  w  w w.ja v a2s  .c  om
}

Related

  1. toTimestamp(Date date)
  2. toTimestamp(Date date)
  3. toTimeStamp(Date date, String time)
  4. toTimestamp(DateTime dt)
  5. toTimestamp(final Calendar cal)
  6. toTimestamp(final int year, final int month, final int dayOfMonth, final int hour, final int minute, final int second, final int millsecond)
  7. toTimestamp(final java.sql.Date date)
  8. toTimestamp(final String pValue)
  9. toTimestamp(java.sql.Date date)