com.sun.jersey.core.header.reader
Class HttpHeaderReader
java.lang.Object
com.sun.jersey.core.header.reader.HttpHeaderReader
public abstract class HttpHeaderReader
- extends java.lang.Object
A pull-based reader of HTTP headers.
- Author:
- Paul.Sandoz@Sun.Com
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
HttpHeaderReader
public HttpHeaderReader()
hasNext
public abstract boolean hasNext()
hasNextSeparator
public abstract boolean hasNextSeparator(char separator,
boolean skipWhiteSpace)
next
public abstract HttpHeaderReader.Event next()
throws java.text.ParseException
- Throws:
java.text.ParseException
next
public abstract HttpHeaderReader.Event next(boolean skipWhiteSpace)
throws java.text.ParseException
- Throws:
java.text.ParseException
getEvent
public abstract HttpHeaderReader.Event getEvent()
getEventValue
public abstract java.lang.String getEventValue()
getRemainder
public abstract java.lang.String getRemainder()
getIndex
public abstract int getIndex()
nextToken
public java.lang.String nextToken()
throws java.text.ParseException
- Throws:
java.text.ParseException
nextSeparator
public char nextSeparator()
throws java.text.ParseException
- Throws:
java.text.ParseException
nextSeparator
public void nextSeparator(char c)
throws java.text.ParseException
- Throws:
java.text.ParseException
nextQuotedString
public java.lang.String nextQuotedString()
throws java.text.ParseException
- Throws:
java.text.ParseException
nextTokenOrQuotedString
public java.lang.String nextTokenOrQuotedString()
throws java.text.ParseException
- Throws:
java.text.ParseException
newInstance
public static HttpHeaderReader newInstance(java.lang.String header)
newInstance
public static HttpHeaderReader newInstance(java.lang.String header,
boolean processComments)
readDate
public static java.util.Date readDate(java.lang.String date)
throws java.text.ParseException
- Throws:
java.text.ParseException
readQualityFactor
public static int readQualityFactor(java.lang.String q)
throws java.text.ParseException
- Throws:
java.text.ParseException
readQualityFactorParameter
public static int readQualityFactorParameter(HttpHeaderReader reader)
throws java.text.ParseException
- Throws:
java.text.ParseException
readParameters
public static java.util.Map<java.lang.String,java.lang.String> readParameters(HttpHeaderReader reader)
throws java.text.ParseException
- Throws:
java.text.ParseException
readCookies
public static java.util.Map<java.lang.String,javax.ws.rs.core.Cookie> readCookies(java.lang.String header)
readCookie
public static javax.ws.rs.core.Cookie readCookie(java.lang.String header)
readNewCookie
public static javax.ws.rs.core.NewCookie readNewCookie(java.lang.String header)
readAcceptMediaType
public static java.util.List<AcceptableMediaType> readAcceptMediaType(java.lang.String header)
throws java.text.ParseException
- Throws:
java.text.ParseException
readAcceptToken
public static java.util.List<AcceptableToken> readAcceptToken(java.lang.String header)
throws java.text.ParseException
- Throws:
java.text.ParseException
readAcceptLanguage
public static java.util.List<AcceptableLanguageTag> readAcceptLanguage(java.lang.String header)
throws java.text.ParseException
- Throws:
java.text.ParseException
readAcceptableList
public static <T extends QualityFactor> java.util.List<T> readAcceptableList(HttpHeaderReader.ListElementCreator<T> c,
java.lang.String header)
throws java.text.ParseException
- Throws:
java.text.ParseException
readAcceptableList
public static <T extends QualityFactor> java.util.List<T> readAcceptableList(java.util.Comparator<T> comparator,
HttpHeaderReader.ListElementCreator<T> c,
java.lang.String header)
throws java.text.ParseException
- Throws:
java.text.ParseException
readList
public static <T> java.util.List<T> readList(HttpHeaderReader.ListElementCreator<T> c,
java.lang.String header)
throws java.text.ParseException
- Throws:
java.text.ParseException
Copyright © 2008 Sun Microsystems, Inc. All Rights Reserved.