Top "Java.time.instant" questions

The Java class to represent an instantaneous point on the time-line.

Converting string to Instant

I am trying to covert datetime in string to instant using java 8 or utils package. For eg. String requestTime = "04:30 PM, …

java date timezone zoneddatetime java.time.instant
Is there any way to convert ZoneId to ZoneOffset in java 8?

I have an epoch second and a zoneId,by method1.It can be convert to LocalDateTime with system default zoneId,…

java java-8 java-time zoneddatetime java.time.instant
Convert java.time.Instant to java.sql.Timestamp without Zone offset

In the application I am developing, I need to convert java.time.Instant object to java.sql.Timestamp. When I …

java date time timestamp java.time.instant
How to convert from Instant to LocalDate

I have an Instant coming from a source that should, according to the spec, be a LocalDate, but don't see …

java-8 localdate java.time.instant java-time
Timestamp to Instant in Java

I have a pojo which has a filed type as Instant. I want to set the Instant getting it from …

java time timestamp java.time.instant
Extracting date, hour and minute from Instant.now() generated date

I have this code that generates a date and time, ZoneId z = ZoneId.of( "Africa/Nairobi" ); Instant instant = Instant.now(); …

java datetime hour zoneddatetime java.time.instant
Why JPA does not support java.time.Instant?

I think that java.time.Instant is the best choice to store a date into DB: it is the most …

java jpa java.time.instant
Java 8 date/time: instant, could not be parsed at index 19

I have following piece of code: String dateInString = "2016-09-18T12:17:21:000Z"; Instant instant = Instant.parse(dateInString); ZonedDateTime zonedDateTime = instant.…

java date parsing time java.time.instant
converting Joda time Instant to Java time Instant

I have an instance of Instant (org.joda.time.Instant) which I get in some api response. I have another …

java time jodatime java-time java.time.instant
Mapstruct LocalDateTime to Instant

I am new in Mapstruct. I have a model object which includes LocalDateTime type field. DTO includes Instant type field. …

java-time mapstruct datetime-conversion localdate java.time.instant