I have to find the difference between the start and the complete load time event. The start load is in java whereas end is in react.
In react I have this
completeLoad = moment();
I want to record the initial load time in java and then find the difference between the two. I am not sure how to record time in java in similar format as momemt(). Need some help here.
In Java, you have Instant which models a single instantaneous point on the time-line.
Instant#now
gives you the current instant from the system clock.Output from a sample run: