private int locateLineByKey( String key ) {

	if( key == null )
	    return -1;


	// Search current line.
	for( int i = 0; i < this.list.size(); i++ ) {
	    
	    HTTPHeaderLine line = this.list.get(i);
	    if( line.getKey() != null && line.getKey().equalsIgnoreCase(key) ) {
		
		return i;
	    }
	}
	
	return -1;
    }