org.jsmpp.util
Class AbsoluteTimeFormatter

java.lang.Object
  extended by org.jsmpp.util.AbsoluteTimeFormatter
All Implemented Interfaces:
TimeFormatter

public class AbsoluteTimeFormatter
extends java.lang.Object
implements TimeFormatter

Absolute time formatter is TimeFormatter implementation referred to SMPP Protocol Specification v3.4 point 7.1.1.

Author:
uudashr

Constructor Summary
AbsoluteTimeFormatter()
           
 
Method Summary
 java.lang.String format(java.util.Calendar calendar)
          Format the date to String representation.
 java.lang.String format(java.util.Date date)
          Format the date to String representation.
static java.lang.String format(java.lang.Integer year, java.lang.Integer month, java.lang.Integer day, java.lang.Integer hour, java.lang.Integer minute, java.lang.Integer second, int tenthsOfSecond, int timeDiff, java.lang.Character sign)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbsoluteTimeFormatter

public AbsoluteTimeFormatter()
Method Detail

format

public java.lang.String format(java.util.Calendar calendar)
Description copied from interface: TimeFormatter
Format the date to String representation.

Specified by:
format in interface TimeFormatter
Parameters:
calendar - is the calendar to format.
Returns:
the formatted date or null if the date is null.

format

public java.lang.String format(java.util.Date date)
Description copied from interface: TimeFormatter
Format the date to String representation.

Specified by:
format in interface TimeFormatter
Parameters:
date - is the date to format.
Returns:
the formatted date or null if the date is null.

format

public static final java.lang.String format(java.lang.Integer year,
                                            java.lang.Integer month,
                                            java.lang.Integer day,
                                            java.lang.Integer hour,
                                            java.lang.Integer minute,
                                            java.lang.Integer second,
                                            int tenthsOfSecond,
                                            int timeDiff,
                                            java.lang.Character sign)