Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## things.data.processing
Class LexicalTool

    java.lang.Object
      things.data.processing.LexicalTool

Direct Known Subclasses:
  AddressParser, AddressParserMSG, BodyProcessor_FormURLEncoded, BodyProcessor_FormURLEncodedSTRICT, RequestLineParser, RequestLineParserOLD, ResponseLineParser, ResponseLineParserOLD

    public class LexicalTool

extends java.lang.Object

These tools are used by the processors. They aren't meant for common use.

Version:
  1.0

  Version History

       EPG - Initial - 6 MAR 02
       EPG - Add hex data - 10 OCT 06

Author:
  Erich P. Gatejen

Field Summary
`static int` | `ALLOWED`
`static int` | `ASCII_HIGH`
`static int` | `BAD` Lexical names and types.
`static int` | `BREAKING`
`static int` | `CHAR`
`static int` | `CHAR_DNSCHAR`
`static int` | `CHAR_DNSCHAR_NUMERIC`
`static int` | `CHAR_DNSCHAR_POUND`
`static int` | `CLASS_ALPHA`
`static int` | `CLASS_CONTROL` Character classifications.
`static int` | `CLASS_NONE`
`static int` | `CLASS_NUMERIC`
`static int` | `CLASS_PUNCTUATION`
`static int` | `COLONVALUE`
`static int` | `CONTROL`
`static int` | `CRBYTEVALUE` Specific characters used by tools.
`static int` | `DASHVALUE`
`static int` | `DNSCHAR`
`static int` | `DOLLARBYTEVALUE`
`static int[][]` | `HEADER_READ_STATE_CHART`
`static int[][]` | `HEADER_READ_STATE_CHARTV2`
`static int` | `HP____SPECIAL_DEAD`
`static int` | `HP____SPECIAL_PAUSE`
`static int` | `HP____SPECIAL_WALKING_DEAD`
`static int` | `HP_BROKEN`
`static int` | `HP_CLEAR_PAUSE`
`static int` | `HP_CLEAR_PAUSE_CRLF`
`static int` | `HP_CLOSURE`
`static int` | `HP_CR`
`static int` | `HP_HEAD_CR`
`static int` | `HP_HEAD_CRLF`
`static int` | `HP_HEAD_LF`
`static int` | `HP_LF`
`static int` | `HP_LFCR`
`static int` | `HP_NOT_USED` Header processing chart.
`static int` | `HP_PAUSE`
`static int` | `HP_PAUSE_CRLF`
`static int` | `HP_PAUSE_CRLFCR`
`static int` | `HP_READ`
`static int` | `HP_START`
`static int` | `LEXICAL_HEADER_TERMINATION`
`static int[][]` | `LEXICAL_MAP`
`static int` | `LEXICAL_MAP_822_HEADERNAME`
`static int` | `LEXICAL_MAP_822_TYPE`
`static int` | `LEXICAL_MAP_CLASSIFICATION` Lexical map.
`static int` | `LEXICAL_MAP_DNS_TYPE`
`static int` | `LEXICAL_MAP_HEXVALUE`
`static int` | `LEXICAL_MAP_NAME`
`static int` | `LEXICAL_MAP_URI_TYPE`
`static int` | `LEXICAL_MAP_URLF_TYPE`
`static int` | `LFBYTEVALUE`
`static int` | `NO_CHARACTER`
`static int` | `NOT_ALLOWED`
`static int` | `OPENBBYTEVALUE`
`static int` | `OTHER`
`static int` | `PIPEBYTEVALUE`
`static int` | `SLASHBYTEVALUE`
`static int` | `SPACEVALUE`
`static int` | `SPECIAL`
`static int` | `SPECIAL_AMP`
`static int` | `SPECIAL_AT`
`static int` | `SPECIAL_BACKSLASH`
`static int` | `SPECIAL_CHAR_DNSCHAR_DOT`
`static int` | `SPECIAL_CLOSEBRACK`
`static int` | `SPECIAL_CLOSEPAREN`
`static int` | `SPECIAL_COLON`
`static int` | `SPECIAL_COMMA`
`static int` | `SPECIAL_DOLLAR`
`static int` | `SPECIAL_EQ`
`static int` | `SPECIAL_GT`
`static int` | `SPECIAL_LT`
`static int` | `SPECIAL_OPENBRACK`
`static int` | `SPECIAL_OPENPAREN`
`static int` | `SPECIAL_PERCENT`
`static int` | `SPECIAL_PLUS`
`static int` | `SPECIAL_QUEST`
`static int` | `SPECIAL_QUOTE`
`static int` | `SPECIAL_SEMICOLON`
`static int` | `SPECIAL_SLASH`
`static int` | `SPECIAL_SPLAT`
`static java.lang.String` | `STRING_CRLF` Sequences
`static int` | `TABVALUE`
`static int` | `URLCHAR`
`static int` | `URLFCHAR`
`static int` | `VALUE_ASCII_BOTTOM`
`static int` | `VALUE_ASCII_HIGH_BOTTOM`
`static int` | `VALUE_ASCII_HIGH_TOP`
`static int` | `VALUE_ASCII_LOW_BOTTOM` Values.
`static int` | `VALUE_ASCII_LOW_TOP`
`static int` | `VALUE_ASCII_TOP`
`static int` | `WS`
`static int` | `WS_CR_CONTROL`
`static int` | `WS_LF_CONTROL`
`static int` | `WS_SPACE`
`static int` | `WS_TAB_CONTROL`

Constructor Summary
`LexicalTool()`

Method Summary
`static int` | `get822HeadernameType(int theCharacter)` Get 822 Headername type.
`static int` | `get822HeadernameTypeWithDollar(int theCharacter)` Get 822 Headername type.
`static int` | `get822Type(int theCharacter)` Get 822 type.
`static int` | `getClassification(int theCharacter)` Get character classification.
`static int` | `getDNSType(int theCharacter)` Get 822 type.
`static int` | `getHexValue(int theCharacter)` Get hex value for the character.
`static int` | `getLower(int theCharacter)` Get the lowercase version of this character.
`static int` | `getName(int theCharacter)` Get character name.
`static int` | `getUpper(int theCharacter)` Get the uppercase version of this character.
`static int` | `getURIType(int theCharacter)` Get character URI type.
`static int` | `getURLFType(int theCharacter)` Get URL form encoding character type.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### CRBYTEVALUE

    public static final int CRBYTEVALUE

  Specific characters used by tools.

  See Also:
    Constant Field Values

### LFBYTEVALUE

    public static final int LFBYTEVALUE

See Also:
  Constant Field Values

### SPACEVALUE

    public static final int SPACEVALUE

See Also:
  Constant Field Values

### DASHVALUE

    public static final int DASHVALUE

See Also:
  Constant Field Values

### DOLLARBYTEVALUE

    public static final int DOLLARBYTEVALUE

See Also:
  Constant Field Values

### PIPEBYTEVALUE

    public static final int PIPEBYTEVALUE

See Also:
  Constant Field Values

### OPENBBYTEVALUE

    public static final int OPENBBYTEVALUE

See Also:
  Constant Field Values

### SLASHBYTEVALUE

    public static final int SLASHBYTEVALUE

See Also:
  Constant Field Values

### TABVALUE

    public static final int TABVALUE

See Also:
  Constant Field Values

### COLONVALUE

    public static final int COLONVALUE

See Also:
  Constant Field Values

### STRING_CRLF

    public static final java.lang.String STRING_CRLF

  Sequences

  See Also:
    Constant Field Values

### CLASS_CONTROL

    public static final int CLASS_CONTROL

  Character classifications.

  See Also:
    Constant Field Values

### CLASS_ALPHA

    public static final int CLASS_ALPHA

See Also:
  Constant Field Values

### CLASS_NUMERIC

    public static final int CLASS_NUMERIC

See Also:
  Constant Field Values

### CLASS_PUNCTUATION

    public static final int CLASS_PUNCTUATION

See Also:
  Constant Field Values

### CLASS_NONE

    public static final int CLASS_NONE

See Also:
  Constant Field Values

### BAD

    public static final int BAD

  Lexical names and types.

  See Also:
    Constant Field Values

### NOT_ALLOWED

    public static final int NOT_ALLOWED

See Also:
  Constant Field Values

### NO_CHARACTER

    public static final int NO_CHARACTER

See Also:
  Constant Field Values

### ALLOWED

    public static final int ALLOWED

See Also:
  Constant Field Values

### CONTROL

    public static final int CONTROL

See Also:
  Constant Field Values

### OTHER

    public static final int OTHER

See Also:
  Constant Field Values

### BREAKING

    public static final int BREAKING

See Also:
  Constant Field Values

### SPECIAL

    public static final int SPECIAL

See Also:
  Constant Field Values

### WS

    public static final int WS

See Also:
  Constant Field Values

### WS_SPACE

    public static final int WS_SPACE

See Also:
  Constant Field Values

### WS_LF_CONTROL

    public static final int WS_LF_CONTROL

See Also:
  Constant Field Values

### WS_CR_CONTROL

    public static final int WS_CR_CONTROL

See Also:
  Constant Field Values

### WS_TAB_CONTROL

    public static final int WS_TAB_CONTROL

See Also:
  Constant Field Values

### CHAR

    public static final int CHAR

See Also:
  Constant Field Values

### CHAR_DNSCHAR_POUND

    public static final int CHAR_DNSCHAR_POUND

See Also:
  Constant Field Values

### CHAR_DNSCHAR_NUMERIC

    public static final int CHAR_DNSCHAR_NUMERIC

See Also:
  Constant Field Values

### CHAR_DNSCHAR

    public static final int CHAR_DNSCHAR

See Also:
  Constant Field Values

### DNSCHAR

    public static final int DNSCHAR

See Also:
  Constant Field Values

### URLCHAR

    public static final int URLCHAR

See Also:
  Constant Field Values

### URLFCHAR

    public static final int URLFCHAR

See Also:
  Constant Field Values

### SPECIAL_CHAR_DNSCHAR_DOT

    public static final int SPECIAL_CHAR_DNSCHAR_DOT

See Also:
  Constant Field Values

### SPECIAL_QUOTE

    public static final int SPECIAL_QUOTE

See Also:
  Constant Field Values

### SPECIAL_PERCENT

    public static final int SPECIAL_PERCENT

See Also:
  Constant Field Values

### SPECIAL_AMP

    public static final int SPECIAL_AMP

See Also:
  Constant Field Values

### SPECIAL_OPENPAREN

    public static final int SPECIAL_OPENPAREN

See Also:
  Constant Field Values

### SPECIAL_CLOSEPAREN

    public static final int SPECIAL_CLOSEPAREN

See Also:
  Constant Field Values

### SPECIAL_SPLAT

    public static final int SPECIAL_SPLAT

See Also:
  Constant Field Values

### SPECIAL_PLUS

    public static final int SPECIAL_PLUS

See Also:
  Constant Field Values

### SPECIAL_COMMA

    public static final int SPECIAL_COMMA

See Also:
  Constant Field Values

### SPECIAL_SLASH

    public static final int SPECIAL_SLASH

See Also:
  Constant Field Values

### SPECIAL_COLON

    public static final int SPECIAL_COLON

See Also:
  Constant Field Values

### SPECIAL_SEMICOLON

    public static final int SPECIAL_SEMICOLON

See Also:
  Constant Field Values

### SPECIAL_LT

    public static final int SPECIAL_LT

See Also:
  Constant Field Values

### SPECIAL_EQ

    public static final int SPECIAL_EQ

See Also:
  Constant Field Values

### SPECIAL_GT

    public static final int SPECIAL_GT

See Also:
  Constant Field Values

### SPECIAL_QUEST

    public static final int SPECIAL_QUEST

See Also:
  Constant Field Values

### SPECIAL_AT

    public static final int SPECIAL_AT

See Also:
  Constant Field Values

### SPECIAL_OPENBRACK

    public static final int SPECIAL_OPENBRACK

See Also:
  Constant Field Values

### SPECIAL_BACKSLASH

    public static final int SPECIAL_BACKSLASH

See Also:
  Constant Field Values

### SPECIAL_CLOSEBRACK

    public static final int SPECIAL_CLOSEBRACK

See Also:
  Constant Field Values

### SPECIAL_DOLLAR

    public static final int SPECIAL_DOLLAR

See Also:
  Constant Field Values

### LEXICAL_HEADER_TERMINATION

    public static final int LEXICAL_HEADER_TERMINATION

See Also:
  Constant Field Values

### ASCII_HIGH

    public static final int ASCII_HIGH

See Also:
  Constant Field Values

### VALUE_ASCII_LOW_BOTTOM

    public static final int VALUE_ASCII_LOW_BOTTOM

  Values.

  See Also:
    Constant Field Values

### VALUE_ASCII_LOW_TOP

    public static final int VALUE_ASCII_LOW_TOP

See Also:
  Constant Field Values

### VALUE_ASCII_BOTTOM

    public static final int VALUE_ASCII_BOTTOM

See Also:
  Constant Field Values

### VALUE_ASCII_TOP

    public static final int VALUE_ASCII_TOP

See Also:
  Constant Field Values

### VALUE_ASCII_HIGH_BOTTOM

    public static final int VALUE_ASCII_HIGH_BOTTOM

See Also:
  Constant Field Values

### VALUE_ASCII_HIGH_TOP

    public static final int VALUE_ASCII_HIGH_TOP

See Also:
  Constant Field Values

### LEXICAL_MAP_CLASSIFICATION

    public static final int LEXICAL_MAP_CLASSIFICATION

  Lexical map.

  See Also:
    Constant Field Values

### LEXICAL_MAP_NAME

    public static final int LEXICAL_MAP_NAME

See Also:
  Constant Field Values

### LEXICAL_MAP_822_TYPE

    public static final int LEXICAL_MAP_822_TYPE

See Also:
  Constant Field Values

### LEXICAL_MAP_DNS_TYPE

    public static final int LEXICAL_MAP_DNS_TYPE

See Also:
  Constant Field Values

### LEXICAL_MAP_822_HEADERNAME

    public static final int LEXICAL_MAP_822_HEADERNAME

See Also:
  Constant Field Values

### LEXICAL_MAP_URI_TYPE

    public static final int LEXICAL_MAP_URI_TYPE

See Also:
  Constant Field Values

### LEXICAL_MAP_HEXVALUE

    public static final int LEXICAL_MAP_HEXVALUE

See Also:
  Constant Field Values

### LEXICAL_MAP_URLF_TYPE

    public static final int LEXICAL_MAP_URLF_TYPE

See Also:
  Constant Field Values

### LEXICAL_MAP

    public static final int[][] LEXICAL_MAP

### HP_NOT_USED

    public static final int HP_NOT_USED

  Header processing chart.

      0       HP_START                        clear_flags     read    transition
      1       HP_BROKEN                       transition              FLAG_BROKEN
      2       HP_READ                         yield   read    transition
      3       HP_HEAD_CR                      yield   read    transition
      4       HP_HEAD_LF                      yield   read    transition
      5       HP_CR                           yield   read    transition
      6       HP_LF                           yield   read    transition
      7       HP_LFCR                         yield   read    transition
      8       HP_PAUSE                        transition              PAUSE
      9       HP_CLEAR_PAUSE          clear_flags             transition
      10      HP_PAUSE_CRLF           transition              PAUSE
      11      HP_CLEAR_PAUSE_CRLF     clear_flags             transition
      12      HP_PAUSE_CRLFCR         yield   read    transition              PAUSE
      13      HP_HEAD_CRLF            yield   read    transition
      X       HP_CLOSURE                      yield                           DONE

  See Also:
    Constant Field Values

### HP_START

    public static final int HP_START

See Also:
  Constant Field Values

### HP_BROKEN

    public static final int HP_BROKEN

See Also:
  Constant Field Values

### HP_READ

    public static final int HP_READ

See Also:
  Constant Field Values

### HP_HEAD_CR

    public static final int HP_HEAD_CR

See Also:
  Constant Field Values

### HP_HEAD_LF

    public static final int HP_HEAD_LF

See Also:
  Constant Field Values

### HP_CR

    public static final int HP_CR

See Also:
  Constant Field Values

### HP_LF

    public static final int HP_LF

See Also:
  Constant Field Values

### HP_LFCR

    public static final int HP_LFCR

See Also:
  Constant Field Values

### HP_PAUSE

    public static final int HP_PAUSE

See Also:
  Constant Field Values

### HP_CLEAR_PAUSE

    public static final int HP_CLEAR_PAUSE

See Also:
  Constant Field Values

### HP_PAUSE_CRLF

    public static final int HP_PAUSE_CRLF

See Also:
  Constant Field Values

### HP_CLEAR_PAUSE_CRLF

    public static final int HP_CLEAR_PAUSE_CRLF

See Also:
  Constant Field Values

### HP_PAUSE_CRLFCR

    public static final int HP_PAUSE_CRLFCR

See Also:
  Constant Field Values

### HP_HEAD_CRLF

    public static final int HP_HEAD_CRLF

See Also:
  Constant Field Values

### HP_CLOSURE

    public static final int HP_CLOSURE

See Also:
  Constant Field Values

### HP____SPECIAL_PAUSE

    public static final int HP____SPECIAL_PAUSE

See Also:
  Constant Field Values

### HP____SPECIAL_WALKING_DEAD

    public static final int HP____SPECIAL_WALKING_DEAD

See Also:
  Constant Field Values

### HP____SPECIAL_DEAD

    public static final int HP____SPECIAL_DEAD

See Also:
  Constant Field Values

### HEADER_READ_STATE_CHART

    public static final int[][] HEADER_READ_STATE_CHART

### HEADER_READ_STATE_CHARTV2

    public static final int[][] HEADER_READ_STATE_CHARTV2

Constructor Detail

### LexicalTool

    public LexicalTool()

Method Detail

### getName

    public static final int getName(int theCharacter)

  Get character name.

  Parameters:
    `theCharacter` - is the character to evaluate.
  Returns:
    the name for the character.

### get822Type

    public static final int get822Type(int theCharacter)

  Get 822 type.

  Parameters:
    `theCharacter` - is the character to evaluate.
  Returns:
    the type for the character.

### getDNSType

    public static final int getDNSType(int theCharacter)

  Get 822 type.

  Parameters:
    `theCharacter` - is the character to evaluate.
  Returns:
    the type for the character.

### get822HeadernameType

    public static final int get822HeadernameType(int theCharacter)

  Get 822 Headername type.

  Parameters:
    `theCharacter` - is the character to evaluate.
  Returns:
    the type for the character.

### get822HeadernameTypeWithDollar

    public static final int get822HeadernameTypeWithDollar(int theCharacter)

  Get 822 Headername type. Allow dollar. Some oddball systems let dollar be a header character. This adds condition check that will make it slower than the regular version of this method.

  Parameters:
    `theCharacter` - is the character to evaluate.
  Returns:
    the type for the character.

### getClassification

    public static final int getClassification(int theCharacter)

  Get character classification.

  Parameters:
    `theCharacter` - is the character to evaluate.
  Returns:
    the classification for the character.

### getURIType

    public static final int getURIType(int theCharacter)

  Get character URI type.

  Parameters:
    `theCharacter` - is the character to evaluate.
  Returns:
    the URI type for the character.

### getHexValue

    public static final int getHexValue(int theCharacter)

  Get hex value for the character. If it isn't a hex character, it'll return a negative number.

  Parameters:
    `theCharacter` - is the character to evaluate.
  Returns:
    the hex value or a negative number

### getURLFType

    public static final int getURLFType(int theCharacter)

  Get URL form encoding character type.

  Parameters:
    `theCharacter` - is the character to evaluate.
  Returns:
    the URL form encoding type for the character.

### getUpper

    public static final int getUpper(int theCharacter)
                              throws java.lang.Exception

  Get the uppercase version of this character. It'll throw an exception if the character isn't alpha.

  Parameters:
    `theCharacter` - to get the uppercase version.
  Returns:
    the character.
  Throws:
    `java.lang.Exception`

### getLower

    public static final int getLower(int theCharacter)
                              throws java.lang.Exception

  Get the lowercase version of this character. It'll throw an exception if the character isn't alpha.

  Parameters:
    `theCharacter` - to get the lowercase version.
  Returns:
    the character.
  Throws:
    `java.lang.Exception`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Things.