Top Posts & Pages
- Eclipse prompt for arg when launching an application
- Difference between two dates in java
- A web server embedded in your java application with Jetty
- Validate XML schema with Commons Configuration in Java
- Generate a XSD easily from an existing XML
- Simple SFTP example in Java with Jsch
- Wake on Lan with Java
- Add color to eclipse console output using the log level
- Pass through proxy from your java program
- Connect to ssh server with java
Categories
Tag Archives: diff
Difference between two dates in java
The easiest way to get the difference between two dates without using a third library is using the TimeUnitclass. Be careful, the result is rounded. I use this code mostly when I need to render a human readable interval. Notice … Continue reading