Code example for Timestamp

Methods: compareTo

0
 
        if ((summary1 != null) && (summary1.getLastUpdate() != null)) {
            Timestamp ts = summary1.getLastUpdate();
 
            if (summary2 != null) {
                return ts.compareTo(summary2.getLastUpdate());
            } else { 
                return ts.compareTo(null);
            } 
        } 
 
        return result;
    } 
}