public class PreferTag extends Object implements Comparable<PreferTag>
Constructor and Description |
---|
PreferTag(org.glassfish.jersey.message.internal.HttpHeaderReader reader)
Parse the prefer tag and parameters out of the header
|
PreferTag(PreferTag preferTag)
Create a new PreferTag from an existing tag
|
PreferTag(String inputTag)
Create a blank prefer tag
|
Modifier and Type | Method and Description |
---|---|
void |
addResponseHeaders(javax.servlet.http.HttpServletResponse servletResponse)
Add appropriate response headers to indicate that the incoming preferences were acknowledged
|
int |
compareTo(PreferTag otherTag)
We consider tags with the same name to be equal, because the definition of Prefer headers does not permit that tags
with the same name be consumed except by selecting for the first appearing tag.
|
static PreferTag |
emptyTag()
Create an empty PreferTag
|
boolean |
equals(Object obj) |
Map<String,String> |
getParams()
Get any additional parameters for the prefer tag
|
String |
getTag()
Get the tag name
|
String |
getValue()
Get the default value for the tag
|
int |
hashCode() |
public PreferTag(PreferTag preferTag)
preferTag
- the preferTagpublic PreferTag(org.glassfish.jersey.message.internal.HttpHeaderReader reader) throws ParseException
reader
- the readerParseException
- if parse exception occurredpublic PreferTag(String inputTag) throws ParseException
inputTag
- the input tagParseException
- if parse exception occurredpublic String getValue()
public Map<String,String> getParams()
public void addResponseHeaders(javax.servlet.http.HttpServletResponse servletResponse)
servletResponse
- the servlet responsepublic int compareTo(PreferTag otherTag)
compareTo
in interface Comparable<PreferTag>
Comparable.compareTo(java.lang.Object)
Copyright © 2013–2015 DuraSpace, Inc.. All rights reserved.