public class ERXDownloadResponse extends WOComponent
Name | Description |
---|---|
contentDisposition | A string to set the content-disposition header. Defaults to
"attachment;filename=\"" + downloadFilename() + "\"" |
contentType | A string to represents the MIME type (text/plain, application/pdf, etc.) of the file |
downloadFilename | A string that represents the name of the file. Defaults to "downloadedfile" |
fileContext | An ERXFileContext object that contains a reference to the file, the file name and the MIME type. If you set this binding, you don't need to set the contentType, fileToDownload and downloadFilename bindings. |
fileToDownload | A java.io.File object that will be returned in the response |
WOComponent._EventLoggingEnabler, WOComponent.Event
NSKeyValueCodingAdditions.DefaultImplementation, NSKeyValueCodingAdditions.Utility
NSKeyValueCoding._BooleanFieldBinding, NSKeyValueCoding._BooleanMethodBinding, NSKeyValueCoding._FieldBinding, NSKeyValueCoding._ForwardingBinding, NSKeyValueCoding._KeyBinding, NSKeyValueCoding._KeyBindingCreation, NSKeyValueCoding._MethodBinding, NSKeyValueCoding._NumberFieldBinding, NSKeyValueCoding._NumberMethodBinding, NSKeyValueCoding._ReflectionKeyBindingCreation, NSKeyValueCoding.ErrorHandling, NSKeyValueCoding.MapImplementation, NSKeyValueCoding.Null<T>, NSKeyValueCoding.UnknownKeyException, NSKeyValueCoding.ValueAccessor
NSValidation._MethodBinding, NSValidation._ValidationBinding, NSValidation.DefaultImplementation, NSValidation.Utility, NSValidation.ValidationException
_Extension, _IsEventLoggingEnabled, _keyAssociations
_CLASS
_CLASS, _KeyPathSeparatorChar, KeyPathSeparator
NullValue
_CLASS
Constructor and Description |
---|
ERXDownloadResponse(WOContext context) |
Modifier and Type | Method and Description |
---|---|
void |
appendToResponse(WOResponse aResponse,
WOContext aContext) |
void |
setContentDisposition(String contentDisposition) |
void |
setContentType(String contentType) |
void |
setDownloadFilename(String newDownloadFilename) |
void |
setFileContext(ERXFileContext fileContext)
Convenience method to set file, download filename and content type.
|
void |
setFileToDownload(File aFile) |
void |
setInputStreamToDownload(InputStream inStream,
long contentSize)
WO 5.3.3 setter where contentSize is int
|
String |
toString() |
__valueForBinding, _associationWithName, _awakeInContext, _childTemplate, _cleanUpStatelessComponent, _componentDefinition, _componentUnroll, _isPage, _setContext, _setIsPage, _setParent, _setSubcomponent, _sleepInContext, _subcomponentForElementWithID, _templateNameForClass, _unroll, application, awake, baseURL, bindingKeys, canAccessFieldsDirectly, canGetValueForBinding, canSetValueForBinding, clone, context, debugString, descriptionForResponse, ensureAwakeInContext, frameworkName, generateResponse, handleQueryWithUnboundKey, handleTakeValueForUnboundKey, hasBinding, hasSession, invokeAction, isCachingEnabled, isEventLoggingEnabled, isStateless, logString, name, pageWithName, parent, path, pathURL, performParentAction, pullValuesFromParent, pushValuesToParent, reset, session, set_componentUnroll, set_unroll, setCachingEnabled, setValueForBinding, setVariableValueForName, sleep, synchronizesVariablesWithBindings, takeValueForKey, takeValueForKeyPath, takeValuesFromRequest, template, templateWithHTMLString, templateWithHTMLString, templateWithHTMLString, templateWithName, unableToSetNullForKey, validateTakeValueForKeyPath, validateValueForKey, validationFailedWithException, valueForBinding, valueForBooleanBinding, valueForIntegerBinding, valueForKey, valueForKeyPath, valueForNSArrayBindings, valueForNSDictionaryBindings, valueForNumberBinding, valueForStringBinding, variableValueForName, variableWithName
public ERXDownloadResponse(WOContext context)
public void setFileContext(ERXFileContext fileContext)
fileContext
- public void setDownloadFilename(String newDownloadFilename)
public void setFileToDownload(File aFile)
aFile
- the file to be downloaded.public void setInputStreamToDownload(InputStream inStream, long contentSize)
inStream
- contentSize
- public void appendToResponse(WOResponse aResponse, WOContext aContext)
appendToResponse
in class WOComponent
public void setContentDisposition(String contentDisposition)
public void setContentType(String contentType)
public String toString()
toString
in class WOComponent
Copyright © 2002 – 2024 Project Wonder.