Class HttpHeaderElement
- java.lang.Object
-
- org.exoplatform.common.http.client.HttpHeaderElement
-
public class HttpHeaderElement extends Object
This class holds a description of an http header element. It is used byUtil.parseHeader.- Version:
- 0.3-3 06/05/2001
- Author:
- Ronald Tschal�r
- See Also:
Util.parseHeader(java.lang.String),Util.getElement(java.util.Vector, java.lang.String),Util.assembleHeader(java.util.Vector)
-
-
Constructor Summary
Constructors Constructor Description HttpHeaderElement(String name)Construct an element with the given name.HttpHeaderElement(String name, String value, NVPair[] params)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidappendTo(StringBuffer buf)Append this header element to the given buffer.booleanequals(Object obj)Two elements are equal if they have the same name.StringgetName()NVPair[]getParams()StringgetValue()StringtoString()
-
-
-
Constructor Detail
-
HttpHeaderElement
public HttpHeaderElement(String name)
Construct an element with the given name. The value and parameters are set to null. This can be used when a dummy element is constructed for comparison or retrieval purposes.- Parameters:
name- the name of the element
-
-
Method Detail
-
getName
public String getName()
- Returns:
- the name
-
getValue
public String getValue()
- Returns:
- the value
-
getParams
public NVPair[] getParams()
- Returns:
- the parameters
-
equals
public boolean equals(Object obj)
Two elements are equal if they have the same name. The comparison is case-insensitive.
-
toString
public String toString()
-
appendTo
public void appendTo(StringBuffer buf)
Append this header element to the given buffer. This is basically a more efficient version oftoString()for assembling multiple elements.- Parameters:
buf- the StringBuffer to append this header to- See Also:
toString()
-
-