NIST-SIP: The Reference Implementation for JAIN-SIP 1.2

gov.nist.javax.sip.parser
Class Lexer

java.lang.Object
  extended by gov.nist.core.StringTokenizer
      extended by gov.nist.core.LexerCore
          extended by gov.nist.javax.sip.parser.Lexer

public class Lexer
extends gov.nist.core.LexerCore

Lexer class for the parser.

Version:
1.2
Author:
M. Ranganathan

Field Summary
 
Fields inherited from class gov.nist.core.LexerCore
ALPHA, AND, AT, BACK_QUOTE, BACKSLASH, BAR, COLON, DIGIT, DOLLAR, DOT, DOUBLEQUOTE, END, EQUALS, EXCLAMATION, GREATER_THAN, HAT, HT, ID, L_CURLY, L_SQUARE_BRACKET, LESS_THAN, LPAREN, MINUS, NULL, PERCENT, PLUS, POUND, QUESTION, QUOTE, R_CURLY, R_SQUARE_BRACKET, RPAREN, SAFE, SEMICOLON, SLASH, SP, STAR, START, TILDE, UNDERSCORE, WHITESPACE
 
Constructor Summary
Lexer(String lexerName, String buffer)
           
 
Method Summary
static String getHeaderName(String line)
          get the header name of the line
static String getHeaderValue(String line)
          get the header value of the line
 void selectLexer(String lexerName)
           
 
Methods inherited from class gov.nist.core.LexerCore
byteStringNoComma, byteStringNoSemicolon, byteStringNoSlash, charAsString, charAsString, comment, consumeValidChars, createParseException, getBuffer, getNextId, getNextToken, getPtr, getRest, getString, isTokenChar, lookupToken, markInputPosition, match, number, peekNextId, peekNextToken, peekNextToken, quotedString, rewindInputPosition, SPorHT, startsId, startsSafeToken, ttoken, ttokenSafe
 
Methods inherited from class gov.nist.core.StringTokenizer
consume, consume, getLine, getLines, getNextChar, getNextToken, getSDPFieldName, hasMoreChars, isAlpha, isAlphaDigit, isDigit, isHexDigit, lookAhead, lookAhead, nextToken, peekLine
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Lexer

public Lexer(String lexerName,
             String buffer)
Method Detail

getHeaderName

public static String getHeaderName(String line)
get the header name of the line

Returns:
the header name (stuff before the :) bug fix submitted by zvali@dev.java.net

getHeaderValue

public static String getHeaderValue(String line)
get the header value of the line

Returns:
String

selectLexer

public void selectLexer(String lexerName)
Overrides:
selectLexer in class gov.nist.core.LexerCore

NIST-SIP: The Reference Implementation for JAIN-SIP 1.2

A product of the NIST/ITL Advanced Networking Technologies Division.
See conditions of use.
Submit a bug report or feature request.