View RSS Feed

.paul.

  1. java (7) equivalent of .Net timespan

    by , 07-28-2012 at 07:03 AM
    Quote Originally Posted by .paul. View Post
    i used Dates in this particular case, as they were better suited to the application.

    but i also created a java TimeSpan class, similar to the .Net Framework TimeSpan class:

    Java Code:
    package javaTimeSpans;
    
    /**
     *
     * @author Paul
     */
    public class TimeSpan {
        
        private int _days;
        private int _hours;
        private int _minutes;
        private int _seconds;
        
        public int Days(){
    ...
    Categories
    Uncategorized