public class BufferedHeader extends Object implements FormattedHeader, Cloneable, Serializable
| Constructor and Description |
|---|
BufferedHeader(CharArrayBuffer buffer)
Creates a new header from a buffer.
|
| Modifier and Type | Method and Description |
|---|---|
Object |
clone() |
CharArrayBuffer |
getBuffer()
Obtains the buffer with the formatted header.
|
HeaderElement[] |
getElements()
Parses the value.
|
String |
getName()
Gets the name of this pair.
|
String |
getValue()
Gets the value of this pair.
|
int |
getValuePos()
Obtains the start of the header value in the
buffer. |
String |
toString() |
public BufferedHeader(CharArrayBuffer buffer) throws ParseException
buffer - the buffer containing the header to representParseException - in case of a parse errorpublic String getName()
NameValuePairgetName in interface NameValuePairnull.public String getValue()
NameValuePairgetValue in interface NameValuePairnull.public HeaderElement[] getElements() throws ParseException
HeadergetElements in interface HeaderHeaderElement entries, may be empty, but is never nullParseException - in case of a parsing errorpublic int getValuePos()
FormattedHeaderbuffer.
By accessing the value in the buffer, creation of a temporary string
can be avoided.getValuePos in interface FormattedHeadergetBuffer.public CharArrayBuffer getBuffer()
FormattedHeadergetBuffer in interface FormattedHeaderpublic Object clone() throws CloneNotSupportedException
clone in class ObjectCloneNotSupportedExceptionCopyright © 2005–2022 The Apache Software Foundation. All rights reserved.