issrg.dis
Class Util

java.lang.Object
  extended by issrg.dis.Util

public class Util
extends java.lang.Object

This is a class to contain useful routines. They are public and static.

Author:
anhnt

Field Summary
static java.lang.String DATE_SEPARATOR
          This is the separator between the dates.
static java.lang.String SN_NAME_SEPARATOR
          This is the separator between the serial number and the DN of the Issuer.
static java.lang.String TIME_SEPARATOR
          This is the separator between the times.
 
Constructor Summary
Util()
           
 
Method Summary
static Generalized_Time buildGeneralizedTime(java.lang.String date)
          Builds a date out of a string representation of it in date.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DATE_SEPARATOR

public static java.lang.String DATE_SEPARATOR
This is the separator between the dates. You can change it at runtime


TIME_SEPARATOR

public static java.lang.String TIME_SEPARATOR
This is the separator between the times. You can change it at runtime


SN_NAME_SEPARATOR

public static java.lang.String SN_NAME_SEPARATOR
This is the separator between the serial number and the DN of the Issuer. You can change it at runtime

Constructor Detail

Util

public Util()
Method Detail

buildGeneralizedTime

public static Generalized_Time buildGeneralizedTime(java.lang.String date)
                                             throws java.lang.Exception
Builds a date out of a string representation of it in date.

Parameters:
date - the string representation of the date in form "yyyy.mm.dd hh:mm:ss". The separators between numbers are defined by DATE_SEPARATOR and TIME_SEPARATOR respectively, the space between date and time is not redefinable. The lengths of numbers and ranges of their values are not checked (unless Generalized_Time or GregorianCalendar constructor does. More specific time values can be omitted. That is, "yyyy" is a valid value, and "yyyy.mm", and "yyyy.mm.dd hh", etc; but "yyyy.mm hh" is not: day must be specified first.
Returns:
returns Generalized_Time object, which contains the date.
Throws:
ACCreationException - if the string representation does not comply with the rules specified above.
java.lang.Exception