| java.lang.Object org.w3c.www.http.BasicValue
All known Subclasses: org.w3c.www.http.HttpTokenList, org.w3c.www.http.HttpCredential, org.w3c.www.http.HttpEntityTag, org.w3c.www.http.HttpAcceptEncodingList, org.w3c.www.http.HttpEntityTagList, org.w3c.www.http.HttpBag, org.w3c.www.http.HttpParamList, org.w3c.www.http.HttpString, org.w3c.www.http.HttpRange, org.w3c.www.http.HttpChallenge, org.w3c.www.http.HttpAcceptLanguage, org.w3c.www.http.HttpAcceptList, org.w3c.www.http.HttpAcceptCharsetList, org.w3c.www.http.HttpExtList, org.w3c.www.http.HttpMimeType, org.w3c.www.http.HttpCookieList, org.w3c.www.http.HttpRangeList, org.w3c.www.webdav.DAVTimeout, org.w3c.www.webdav.DAVStatusURIList, org.w3c.www.http.HttpWarning, org.w3c.www.http.HttpContentRange, org.w3c.www.http.HttpAcceptCharset, org.w3c.www.http.HttpSetCookieList, org.w3c.www.http.HttpAcceptLanguageList, org.w3c.www.http.HttpInteger, org.w3c.www.webdav.DAVIfList, org.w3c.www.http.HttpDate, org.w3c.www.http.HttpWarningList, org.w3c.www.http.HttpAccept, org.w3c.www.http.HttpAcceptEncoding, org.w3c.www.http.HttpCacheControl,
Field Summary | |
protected boolean | isValid | protected byte | raw The header value, as a byte array, if available. | protected int | rlen The length of the byte value in case the above buffer is shared. | protected int | roff The offset of the value in the above buffer, in case the buffer is
shared. |
Method Summary | |
public void | addBytes(byte buf, int off, int len) HeaderValue implementation - Add these bytes to the header raw value. | public void | appendValue(HttpBuffer buf) Append this header value to the given output buffer. | final protected void | checkByteValue() Compute the new RFC822 compatible representation of this header value. | protected Object | clone() | public void | emit(OutputStream out) HeaderValue implementation - Emit this header value to the given output
stream. | protected void | error(String msg) Emit a parsing error. | abstract public Object | getValue() HeaderValue implemenntation - Get this header value. | protected void | invalidateByteValue() Invalidate the current byte value for this header, if any. | abstract protected void | parse() Parse this header value into its various components. | public void | setBytes(byte buf, int off, int len) HeaderValue implementation - Reset the header byte value. | public void | setString(String strval) Set this Header Value by parsing the given String.
Parameters: strval - The String value for that object. | public String | toExternalForm() Return a String encoding this header value in an HTTP compatible way. | public String | toString() Print this header value as it would be emited. | abstract protected void | updateByteValue() Update the RFC822 compatible header value for this object. | final protected void | validate() Validate the parsed value according to the last set raw value. |
isValid | protected boolean isValid(Code) | | Are the parsed values up to date with the lastly set unparsed value ?
|
raw | protected byte raw(Code) | | The header value, as a byte array, if available.
|
rlen | protected int rlen(Code) | | The length of the byte value in case the above buffer is shared.
|
roff | protected int roff(Code) | | The offset of the value in the above buffer, in case the buffer is
shared.
|
BasicValue | public BasicValue()(Code) | | |
addBytes | public void addBytes(byte buf, int off, int len)(Code) | | HeaderValue implementation - Add these bytes to the header raw value.
Parameters: buf - The byte buffer containing some part of the header value. Parameters: off - The offset of the header value in above buffer. Parameters: len - The length of the header value in above buffer. |
appendValue | public void appendValue(HttpBuffer buf)(Code) | | Append this header value to the given output buffer.
The header value as a byte array. |
checkByteValue | final protected void checkByteValue()(Code) | | Compute the new RFC822 compatible representation of this header value.
If our value is up to date, we just return, otherwise, the abstract
updateByteValue is called to perform the job.
|
emit | public void emit(OutputStream out) throws IOException(Code) | | HeaderValue implementation - Emit this header value to the given output
stream.
Parameters: out - The output stream to emit the header value to. exception: IOException - If some IO error occured. |
getValue | abstract public Object getValue()(Code) | | HeaderValue implemenntation - Get this header value.
An object representing the parsed value for this header. |
invalidateByteValue | protected void invalidateByteValue()(Code) | | Invalidate the current byte value for this header, if any.
|
setBytes | public void setBytes(byte buf, int off, int len)(Code) | | HeaderValue implementation - Reset the header byte value.
Parameters: buf - The byte buffer containing some part of the header value. Parameters: off - The offset of the header value in above buffer. Parameters: len - The length of the header value in above buffer. |
setString | public void setString(String strval)(Code) | | Set this Header Value by parsing the given String.
Parameters: strval - The String value for that object. Itself. |
toExternalForm | public String toExternalForm()(Code) | | Return a String encoding this header value in an HTTP compatible way.
A String. |
toString | public String toString()(Code) | | Print this header value as it would be emited.
A String representation of this header value. |
updateByteValue | abstract protected void updateByteValue()(Code) | | Update the RFC822 compatible header value for this object.
|
validate | final protected void validate() throws HttpInvalidValueException(Code) | | Validate the parsed value according to the last set raw value.
This will trigger the header value parsing, if it is required at this
point.
exception: HttpInvalidValueException - If the value couldn't be parsed properly. |
|
|