Top Description Inners Fields Constructors Methods
org.eclipse.jetty.http.content

public Class PreCompressedHttpContentFactory

extends Object
implements Factory
Class Inheritance
All Implemented Interfaces
org.eclipse.jetty.http.content.HttpContent.Factory
Imports
java.io.IOException, java.util.Arrays, .HashSet, .List, .Set, org.eclipse.jetty.http.CompressedContentFormat, org.eclipse.jetty.http.content.HttpContent.Factory

This HttpContent.Factory populates the HttpContent#getPreCompressedContentFormats() field for any HttpContent fetched through this factory.

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class

Field Summary

Modifier and TypeField and Description
private final HttpContent.Factory
private final List<CompressedContentFormat>

Constructor Summary

AccessConstructor and Description
public
public

Method Summary

Modifier and TypeMethod and Description
public HttpContent
getContent(String
The path within the context to the resource
pathInContext
)

Implements org.eclipse.jetty.http.content.HttpContent.Factory.getContent.

public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

_factoryback to summary
private final HttpContent.Factory _factory
_preCompressedFormatsback to summary
private final List<CompressedContentFormat> _preCompressedFormats

Constructor Detail

PreCompressedHttpContentFactoryback to summary
public PreCompressedHttpContentFactory(HttpContent.Factory factory, CompressedContentFormat[] preCompressedFormats)
PreCompressedHttpContentFactoryback to summary
public PreCompressedHttpContentFactory(HttpContent.Factory factory, List<CompressedContentFormat> preCompressedFormats)

Method Detail

getContentback to summary
public HttpContent getContent(String pathInContext) throws IOException

Implements org.eclipse.jetty.http.content.HttpContent.Factory.getContent.

Parameters
pathInContext:String

Doc from org.eclipse.jetty.http.content.HttpContent.Factory.getContent.

The path within the context to the resource

Returns:HttpContent

Doc from org.eclipse.jetty.http.content.HttpContent.Factory.getContent.

A HttpContent

Annotations
@Override
Exceptions
IOException:

Doc from org.eclipse.jetty.http.content.HttpContent.Factory.getContent.

if unable to get content

toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object.

Returns:String

a string representation of the object.

Annotations
@Override
org.eclipse.jetty.http.content back to summary

private Class PreCompressedHttpContentFactory.CompressedFormatsHttpContent

extends Wrapper
Class Inheritance

Field Summary

Modifier and TypeField and Description
private final Set<CompressedContentFormat>

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public Set<CompressedContentFormat>
Inherited from org.eclipse.jetty.http.content.HttpContent.Wrapper:
getByteBuffergetBytesOccupiedgetCharacterEncodinggetContentEncodinggetContentEncodingValuegetContentLengthgetContentLengthValuegetContentTypegetContentTypeValuegetETaggetETagValuegetLastModifiedgetLastModifiedInstantgetLastModifiedValuegetMimeTypegetResourcegetWrappedreleasetoString

Field Detail

compressedFormatsback to summary
private final Set<CompressedContentFormat> compressedFormats

Constructor Detail

CompressedFormatsHttpContentback to summary
public CompressedFormatsHttpContent(HttpContent content, Set<CompressedContentFormat> compressedFormats)

Method Detail

getPreCompressedContentFormatsback to summary
public Set<CompressedContentFormat> getPreCompressedContentFormats()

Overrides org.eclipse.jetty.http.content.HttpContent.Wrapper.getPreCompressedContentFormats.

Implements org.eclipse.jetty.http.content.HttpContent.getPreCompressedContentFormats.

Returns:Set<CompressedContentFormat>

Doc from org.eclipse.jetty.http.content.HttpContent.getPreCompressedContentFormats.

Set of available pre-compressed formats for this content, or null if this has not been checked.

Annotations
@Override