FIG, 12A
public void oddHeader(SipHeader header)
I
// add the new element to the vector then determine if it has a entry
// in the headerlndex and either update or create it.
if (header == null)
return;
String headerType = header.getFieldType() .toLowerCase();
msgHeoders.oddElement (header);
int index = msgHeaders.size () -1;
// First check to see if the header already has an entry in the vector,
if (headerlndex.containsKey (headerType))
{
Vector temp = (Vector) headerlndex.get (headerType);
// add the new element to the vector
temp.addElement (new Integer (index)); Jj" ^ 200
headerlndex.put (headerType.temp);
I
else
I
// create a new vector to store the indices in.
Vector temp = new Vector (5);
temp.addElement (new Integer (index));
headerlndex.put (headerType.toLowerCase () ,temp);
I
i
public Hashtable getHeaderlndex() {return headerlndex; j public Vector getMsgHeadersQ { return msgHeaders; j