| org.w3c.jigsaw.frames.HTTPFrame org.w3c.jigsaw.frames.NegotiatedFrame
NegotiatedFrame | public class NegotiatedFrame extends HTTPFrame (Code) | | Content negotiation.
|
Inner Class :class VariantState | |
ATTR_PARANOID_VARIANT_CHECK | protected static int ATTR_PARANOID_VARIANT_CHECK(Code) | | Attribute index - Should the variants to be strictly checked?
the variants should NEVER contain negotiated resources!
|
ATTR_PUT_POLICY | protected static int ATTR_PUT_POLICY(Code) | | Attribute index - Should the PUT needs to be strictly checked?
|
ATTR_VARIANTS | protected static int ATTR_VARIANTS(Code) | | Attribute index - The set of names of variants.
|
DEFAULT_NEGOTIATED_ICON | public static String DEFAULT_NEGOTIATED_ICON(Code) | | Our default Icon
|
NEGOTIATED_ICON_P | public static String NEGOTIATED_ICON_P(Code) | | Our Icon property.
|
getParanoidVariantCheck | public boolean getParanoidVariantCheck()(Code) | | get the variant checking policy
|
getPutPolicy | public boolean getPutPolicy()(Code) | | get the "strictness" of the PUT checking
|
getVariantNames | public String[] getVariantNames()(Code) | | Get the variant names.
|
getVariantResources | public ResourceReference[] getVariantResources() throws ProtocolException(Code) | | Get the variant resources.
This is somehow broken, it shouldn't allocate the array of variants
on each call. However, don't forget that the list of variants can be
dynamically edited, this means that if we are to keep a cache of it
(as would be the case if we kept the array of variants as instance var)
we should also take care of editing of attributes (possible, but I
just don't have enough lifes).
An array of ResourceReference, or null. exception: ProtocolException - If one of the variants doesn't exist. |
negotiate | protected ResourceReference negotiate(Request request) throws ProtocolException(Code) | | Negotiate among the various variants for the Resource.
We made our best efforts to be as compliant as possible to the HTTP/1.0
content negotiation algorithm.
Parameters: request - the incomming request. a RefourceReference instance. exception: ProtocolException - If one of the variants doesn't exist. |
negotiateCharsetQuality | protected boolean negotiateCharsetQuality(Vector states, Request request)(Code) | | Negotiate on charsets.
The algorithm is described in RFC2616 (Obsoletes RFC2068)
Parameters: states - The current states of negotiation. Parameters: request - The request to handle. |
negotiateContentEncoding | protected boolean negotiateContentEncoding(Vector states, Request request) throws ProtocolException(Code) | | Negotiate among content encodings.
BUG: This will work only for single encoded variants.
Parameters: states - The current negotiation states. Parameters: request - The request to handle. a boolean. exception: ProtocolException - If one of the variants doesn't exist. |
negotiateContentType | protected boolean negotiateContentType(Vector states, Request request) throws ProtocolException(Code) | | Negotiate among content types.
Parameters: states - The current states of negotiation. Parameters: request - The request to handle. a boolean. exception: ProtocolException - If one of the variants doesn't exist. |
negotiateLanguageQuality | protected boolean negotiateLanguageQuality(Vector states, Request request) throws ProtocolException(Code) | | Negotiate among language qualities.
BUG: This will only work for variants that have one language tag.
Parameters: states - The current states of negotiation. Parameters: request - The request to handle. a boolean. exception: ProtocolException - If one of the variants doesn't exist. |
printNegotiationState | protected void printNegotiationState(String header, Vector states)(Code) | | Print the current negotiation state.
Parameters: header - The header to print first. Parameters: states - The current negotiation states. |
setParanoidVariantCheck | public void setParanoidVariantCheck(boolean strict)(Code) | | |
setPutPolicy | public void setPutPolicy(boolean strict)(Code) | | |
setValue | public synchronized void setValue(int idx, Object value)(Code) | | |
Methods inherited from org.w3c.jigsaw.frames.HTTPFrame | public void addStyleSheet(HtmlGenerator g)(Code)(Java Doc) public void attributeChanged(AttributeChangedEvent evt)(Code)(Java Doc) public Reply browse(Request request) throws ProtocolException(Code)(Java Doc) public boolean checkExpect(Request request)(Code)(Java Doc) public int checkIfMatch(Request request)(Code)(Java Doc) public int checkIfModifiedSince(Request request)(Code)(Java Doc) public int checkIfNoneMatch(Request request)(Code)(Java Doc) public int checkIfUnmodifiedSince(Request request)(Code)(Java Doc) public boolean checkRequest(RequestInterface request)(Code)(Java Doc) public int checkValidators(Request request)(Code)(Java Doc) public boolean computeContainerListing(boolean refresh)(Code)(Java Doc) public String computeETag()(Code)(Java Doc) protected File computeTrashDir(File dir)(Code)(Java Doc) protected File computeTrashFile(File file)(Code)(Java Doc) public Reply createDefaultReply(Request request, int status)(Code)(Java Doc) protected Reply createFileReply(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) public Reply delete(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) protected Reply deleteDirectoryResource(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) protected Reply deleteFileResource(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) protected Reply deleteMe(Request request) throws HTTPException(Code)(Java Doc) protected Reply deleteOtherResource(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) public Reply extended(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) public Reply get(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) protected HttpTokenList getAllow()(Code)(Java Doc) public boolean getAllowDeleteFlag()(Code)(Java Doc) public boolean getBrowsableFlag()(Code)(Java Doc) protected synchronized MimeType getBrowseType()(Code)(Java Doc) public String getCharset()(Code)(Java Doc) public String getContentEncoding()(Code)(Java Doc) public String getContentLanguage()(Code)(Java Doc) public int getContentLength()(Code)(Java Doc) public MimeType getContentType()(Code)(Java Doc) public Reply getDirectoryListing(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) public DirectoryResource getDirectoryResource()(Code)(Java Doc) protected Reply getDirectoryResource(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) public HttpEntityTag getETag()(Code)(Java Doc) public FileResource getFileResource()(Code)(Java Doc) protected Reply getFileResource(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) public String getHelpURL()(Code)(Java Doc) public String getHelpURL(String topic)(Code)(Java Doc) public String getIcon()(Code)(Java Doc) public String getIconDirectory()(Code)(Java Doc) public String getIndex()(Code)(Java Doc) public String[] getIndexes()(Code)(Java Doc) public boolean getMD5Flag()(Code)(Java Doc) public long getMaxAge()(Code)(Java Doc) protected Reply getOtherResource(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) public boolean getPutableFlag()(Code)(Java Doc) public double getQuality()(Code)(Java Doc) public boolean getRelocateFlag()(Code)(Java Doc) public String getStyleSheetURL()(Code)(Java Doc) public String getTitle()(Code)(Java Doc) public URL getURL(Request request)(Code)(Java Doc) public Reply handleRangeRequest(Request request, HttpRange r) throws ProtocolException(Code)(Java Doc) public Reply head(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) protected Reply headDirectoryResource(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) protected Reply headFileResource(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) protected Reply headOtherResource(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) public void initialize(Hashtable defs)(Code)(Java Doc) public Reply link(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) public boolean lookup(LookupState ls, LookupResult lr) throws ProtocolException(Code)(Java Doc) protected boolean lookupDirectory(LookupState ls, LookupResult lr) throws ProtocolException(Code)(Java Doc) protected boolean lookupFile(LookupState ls, LookupResult lr) throws ProtocolException(Code)(Java Doc) protected boolean lookupOther(LookupState ls, LookupResult lr) throws ProtocolException(Code)(Java Doc) protected boolean lookupResource(LookupState ls, LookupResult lr) throws ProtocolException(Code)(Java Doc) public Reply options(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) public ReplyInterface perform(RequestInterface req) throws ProtocolException, ResourceException(Code)(Java Doc) protected ReplyInterface performFrames(RequestInterface request) throws ProtocolException, ResourceException(Code)(Java Doc) public void pickleValues(Hashtable defs)(Code)(Java Doc) public Reply post(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) public Reply put(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) protected Reply putFileResource(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) protected Reply putOtherResource(Request request) throws ProtocolException(Code)(Java Doc) public void registerOtherResource(FramedResource resource)(Code)(Java Doc) public void registerResource(FramedResource resource)(Code)(Java Doc) public synchronized void setValue(int idx, Object value)(Code)(Java Doc) public Reply trace(Request request) throws HTTPException, ClientException(Code)(Java Doc) public Reply unlink(Request request) throws ProtocolException, ResourceException(Code)(Java Doc) public double unsafeGetQuality()(Code)(Java Doc) protected void updateCachedHeaders()(Code)(Java Doc)
|
|
|