Class DatetimeTz

java.lang.Object
nu.validator.datatype.AbstractDatatype
nu.validator.datatype.DatetimeTz
All Implemented Interfaces:
org.relaxng.datatype.Datatype

public final class DatetimeTz
extends AbstractDatatype
This datatype shall accept strings that conform to the format specified for datetime attribute of the ins and del elements in Web Applications 1.0.

If the time zone designator is not "Z", the absolute value of the time zone designator must not exceed 12 hours.

This datatype must not accept the empty string.

Note that allowing a numeric time zone designator is not the only difference with datetime. This type requires seconds to be explicitly present.

Version:
$Id$
Author:
hsivonen
  • Field Details

  • Method Details

    • getPattern

      protected java.util.regex.Pattern getPattern()
      Returns the regexp for this datatype.
      Returns:
      the regexp for this datatype
      See Also:
      AbstractDatetime.getPattern()
    • getName

      public java.lang.String getName()
      Specified by:
      getName in class AbstractDatatype
    • checkHour

      protected final void checkHour​(java.lang.String hour) throws org.relaxng.datatype.DatatypeException
      Throws:
      org.relaxng.datatype.DatatypeException
    • checkMinute

      protected final void checkMinute​(java.lang.String minute) throws org.relaxng.datatype.DatatypeException
      Throws:
      org.relaxng.datatype.DatatypeException
    • checkSecond

      protected final void checkSecond​(java.lang.String second) throws org.relaxng.datatype.DatatypeException
      Throws:
      org.relaxng.datatype.DatatypeException
    • checkMilliSecond

      protected final void checkMilliSecond​(java.lang.String millisecond) throws org.relaxng.datatype.DatatypeException
      Throws:
      org.relaxng.datatype.DatatypeException
    • checkValid

      public void checkValid​(java.lang.CharSequence literal) throws org.relaxng.datatype.DatatypeException
      Specified by:
      checkValid in class AbstractDatatype
      Throws:
      org.relaxng.datatype.DatatypeException