org.apache.wicket.request.resource
Class ResourceStreamResource

java.lang.Object
  extended by org.apache.wicket.request.resource.AbstractResource
      extended by org.apache.wicket.request.resource.ResourceStreamResource
All Implemented Interfaces:
Serializable, IResource, IClusterable

public class ResourceStreamResource
extends AbstractResource

TODO javadoc

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class org.apache.wicket.request.resource.AbstractResource
AbstractResource.ResourceResponse, AbstractResource.WriteCallback
 
Nested classes/interfaces inherited from interface org.apache.wicket.request.resource.IResource
IResource.Attributes
 
Field Summary
 
Fields inherited from class org.apache.wicket.request.resource.AbstractResource
INTERNAL_HEADERS
 
Constructor Summary
ResourceStreamResource(IResourceStream stream)
          Construct.
 
Method Summary
 Duration getCacheDuration()
           
protected  AbstractResource.ResourceResponse newResourceResponse(IResource.Attributes attributes)
          Override this method to return a AbstractResource.ResourceResponse for the request.
 ResourceStreamResource setCacheDuration(Duration cacheDuration)
           
 ResourceStreamResource setContentDisposition(ContentDisposition contentDisposition)
           
 ResourceStreamResource setFileName(String fileName)
           
 ResourceStreamResource setTextEncoding(String textEncoding)
           
 
Methods inherited from class org.apache.wicket.request.resource.AbstractResource
configureCache, flushResponseAfterHeaders, getCachingStrategy, respond, setResponseHeaders
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResourceStreamResource

public ResourceStreamResource(IResourceStream stream)
Construct.

Parameters:
stream -
Method Detail

setFileName

public ResourceStreamResource setFileName(String fileName)
Parameters:
fileName -
Returns:
this

setContentDisposition

public ResourceStreamResource setContentDisposition(ContentDisposition contentDisposition)
Parameters:
contentDisposition -
Returns:
thsi

setTextEncoding

public ResourceStreamResource setTextEncoding(String textEncoding)
Parameters:
textEncoding -
Returns:
this

getCacheDuration

public Duration getCacheDuration()
Returns:
the duration for which the resource will be cached by the browser

setCacheDuration

public ResourceStreamResource setCacheDuration(Duration cacheDuration)
Parameters:
cacheDuration - the duration for which the resource will be cached by the browser
Returns:
this component

newResourceResponse

protected AbstractResource.ResourceResponse newResourceResponse(IResource.Attributes attributes)
Description copied from class: AbstractResource
Override this method to return a AbstractResource.ResourceResponse for the request.

Specified by:
newResourceResponse in class AbstractResource
Parameters:
attributes - request attributes
Returns:
resource data instance


Copyright © 2006-2012 Apache Software Foundation. All Rights Reserved.