Does Java have a data type that represents a period of time eg 34 seconds, 5 minutes etc.
I've seen a few implementations of a TimeSpan that cover a Time period like from the 10th of December to the 11th of December.
What I need is something like TimeSpan in C#.
Java doesn't have pointers; Java has references.
The Java language does not support unions or direct control memory layout the way that languages like C do directly.
C is a compiled language that is it converts the code into machine language so that it could be understood by the machine or system. Java is an Interpreted language that is in Java, the code is first transformed into bytecode and that bytecode is then executed by the JVM (Java Virtual Machine).
Operators are special symbols that perform specific operations on one, two, or three operands, and then return a result. As we explore the operators of the Java programming language, it may be helpful for you to know ahead of time which operators have the highest precedence.
Not a part of the JDK currently, but will be incorporated in JDK 7 - try Joda Time
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With