public class ERXDownloadResponse extends WOComponent
| Bindings | |
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.EventNSKeyValueCodingAdditions.DefaultImplementation, NSKeyValueCodingAdditions.UtilityNSKeyValueCoding._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.ValueAccessorNSValidation._MethodBinding, NSValidation._ValidationBinding, NSValidation.DefaultImplementation, NSValidation.Utility, NSValidation.ValidationException_Extension, _IsEventLoggingEnabled, _keyAssociations_CLASS_CLASS, _KeyPathSeparatorChar, KeyPathSeparatorNullValue_CLASS| Constructor and Description |
|---|
ERXDownloadResponse(WOContext context) |
| Modifier and Type | Method and Description |
|---|---|
void |
appendToResponse(WOResponse aResponse,
WOContext aContext) |
void |
setContentDisposition(java.lang.String contentDisposition) |
void |
setContentType(java.lang.String contentType) |
void |
setDownloadFilename(java.lang.String newDownloadFilename) |
void |
setFileContext(ERXFileContext fileContext)
Convenience method to set file, download filename and content type.
|
void |
setFileToDownload(java.io.File aFile) |
void |
setInputStreamToDownload(java.io.InputStream inStream,
long contentSize)
WO 5.3.3 setter where contentSize is int
|
java.lang.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, variableWithNamepublic ERXDownloadResponse(WOContext context)
public void setFileContext(ERXFileContext fileContext)
fileContext - public void setDownloadFilename(java.lang.String newDownloadFilename)
public void setFileToDownload(java.io.File aFile)
aFile - the file to be downloaded.public void setInputStreamToDownload(java.io.InputStream inStream,
long contentSize)
inStream - contentSize - public void appendToResponse(WOResponse aResponse, WOContext aContext)
appendToResponse in class WOComponentpublic void setContentDisposition(java.lang.String contentDisposition)
public void setContentType(java.lang.String contentType)
public java.lang.String toString()
toString in class WOComponentCopyright © 2002 – 2022 Project Wonder.