Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.apache.derby.iapi.types
Class DateTimeParser  view DateTimeParser download DateTimeParser.java

java.lang.Object
  extended byorg.apache.derby.iapi.types.DateTimeParser

class DateTimeParser
extends java.lang.Object

This class provides a simple regular expression parser for standard format dates, times, and timestamps


Field Summary
private  char currentSeparator
           
private  int fieldStart
           
private  int len
           
private  java.lang.String str
           
private  java.lang.String trimmedString
           
 
Constructor Summary
(package private) DateTimeParser(java.lang.String str)
           
 
Method Summary
(package private)  java.lang.String checkEnd()
          Check that we are at the end of the string: that the rest of the characters, if any, are blanks.
(package private)  char getCurrentSeparator()
           
(package private)  java.lang.String getTrimmedString()
          Get the parsed string with trailing blanks removed.
(package private)  char nextSeparator()
           
(package private)  int parseChoice(java.lang.String[] choices)
          Determine if the next characters are one of a choice of strings.
(package private)  int parseInt(int maxDigits, boolean truncationAllowed, char[] separator, boolean isFraction)
          Parse the next integer.
private  void updateCurrentSeparator()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

str

private java.lang.String str

trimmedString

private java.lang.String trimmedString

len

private int len

fieldStart

private int fieldStart

currentSeparator

private char currentSeparator
Constructor Detail

DateTimeParser

DateTimeParser(java.lang.String str)
Method Detail

parseInt

int parseInt(int maxDigits,
             boolean truncationAllowed,
             char[] separator,
             boolean isFraction)
       throws org.apache.derby.iapi.error.StandardException
Parse the next integer.


parseChoice

int parseChoice(java.lang.String[] choices)
          throws org.apache.derby.iapi.error.StandardException
Determine if the next characters are one of a choice of strings.


updateCurrentSeparator

private void updateCurrentSeparator()

checkEnd

java.lang.String checkEnd()
                    throws org.apache.derby.iapi.error.StandardException
Check that we are at the end of the string: that the rest of the characters, if any, are blanks.


getTrimmedString

java.lang.String getTrimmedString()
Get the parsed string with trailing blanks removed. This method is only valid after checkEnd has been called.


nextSeparator

char nextSeparator()

getCurrentSeparator

char getCurrentSeparator()