I know this is probably a really stupid question, however I was wondering whether there is a way to minus a local date time from another, or if not, to cast localDateTime to just Date time and then subtract from there?
I need to be able to work out the date time difference, between the start of record foo and the start of record bar (which is also the end of Foo)
I am rather new to java, and for simplicity's sake, I want to be able to keep it in roughly the same layout, rather than having to convert from seconds etc.
If adding and subtracting LocalDateTime is not an option, I know that once I am in dateTime I am able to subtract them using:
Period diff = new Period(start, end);
Due to the purpose of the data, I need to keep both the date and the time in order for this to work, and as mentioned before, I wish to keep it fairly simple so theres no need to convert between seconds back to the date.
My issue is really just getting it in an acceptable format, as I say, I am rather new to java and object orientation as a whole, so please don't ridicule me for this, seemingly simple, question.
Thanks,
Jonny