public  SIPHeader  parse() throws ParseException { try { CSeq c= new CSeq();  this.lexer.match (TokenTypes.CSEQ); this.lexer.SPorHT(); this.lexer.match(':'); this.lexer.SPorHT(); String number=this.lexer.number(); c.setSequenceNumber(Integer.parseInt(number)); this.lexer.SPorHT(); String m = method(); c.setMethod(m); this.lexer.SPorHT(); this.lexer.match('\n'); return c; } catch (NumberFormatException ex) { Debug.printStackTrace(ex); throw createParseException("Number format exception"); } catch (InvalidArgumentException ex) { Debug.printStackTrace(ex); throw createParseException(ex.getMessage()); } }
public SIPHeader parse() throws ParseException { try { CSeq c = new CSeq();  this.lexer.match(TokenTypes.CSEQ); this.lexer.SPorHT(); this.lexer.match(':'); this.lexer.SPorHT(); String number = this.lexer.number(); c.setSequenceNumber(Integer.parseInt(number)); this.lexer.SPorHT(); String m = method();   if ( m.equalsIgnoreCase(Request.INVITE)) m = Request.INVITE; else if ( m.equalsIgnoreCase(Request.ACK)) m = Request.ACK; else if ( m.equalsIgnoreCase(Request.BYE)) m = Request.BYE; else if ( m.equalsIgnoreCase(Request.INFO)) m = Request.INFO; else if ( m.equalsIgnoreCase(Request.NOTIFY)) m = Request.NOTIFY; else if ( m.equalsIgnoreCase(Request.PRACK)) m = Request.PRACK; else if ( m.equalsIgnoreCase(Request.CANCEL)) m = Request.CANCEL;  c.setMethod(m); this.lexer.SPorHT(); this.lexer.match('\n'); return c; } catch (NumberFormatException ex) { Debug.printStackTrace(ex); throw createParseException("Number format exception"); } catch (InvalidArgumentException ex) { Debug.printStackTrace(ex); throw createParseException(ex.getMessage()); } }
	public  SIPHeader  parse() throws ParseException {             try {		CSeq c= new CSeq();				this.lexer.match (TokenTypes.CSEQ);		this.lexer.SPorHT();		this.lexer.match(':');		this.lexer.SPorHT();                String number=this.lexer.number();                c.setSequenceNumber(Integer.parseInt(number));                this.lexer.SPorHT();		String m = method();                c.setMethod(m);                this.lexer.SPorHT();		this.lexer.match('\n');                  return c;              }               catch (NumberFormatException ex) {                   Debug.printStackTrace(ex);		   throw createParseException("Number format exception");              } catch (InvalidArgumentException ex) {                  Debug.printStackTrace(ex);                   throw createParseException(ex.getMessage());              }	}