Package de.xima.fc.workflow.model
Class TaskExecutionResultWrapper
- java.lang.Object
-
- de.xima.fc.workflow.model.TaskExecutionResultWrapper
-
- All Implemented Interfaces:
IWorkflowResponse,IServletResponse,Serializable
public class TaskExecutionResultWrapper extends Object implements IWorkflowResponse, Serializable
Wrapper to treat aITaskExecutionResultas aIWorkflowResponse.- Since:
- 7.0.0
- Author:
- XIMA MEDIA GmbH
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description TaskExecutionResultWrapper(IRemoteEventExecutionResult result)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description byte[]getBinValue()The binary data for the response.StringgetContentType()Applies only whenIServletResponse.getType()is set toEResponseType.SHOW_FILE:StringgetEncoding()Applies only whenIServletResponse.getType()is set toEResponseType.TEMPLATE,EResponseType.TEMPLATE_SYSTEM, orEResponseType.HTML.longgetLongValue()Returns an long value.ETextbausteinMsgCodegetMsgCode()Map<String,Serializable>getSessionAttributes()EResponseTypegetType()StringgetValue()The plain-text data of the response, used only whenIServletResponse.getType()is not set to a binary response type or redirect.VorganggetVorgang()booleanisForceDownload()Applies only whenIServletResponse.getType()is set toEResponseType.SHOW_FILE.booleanisSuccess()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface de.xima.fc.interfaces.servlet.IServletResponse
getHttpHeader, getHttpStatusCode
-
-
-
-
Constructor Detail
-
TaskExecutionResultWrapper
public TaskExecutionResultWrapper(IRemoteEventExecutionResult result)
-
-
Method Detail
-
getValue
public String getValue()
Description copied from interface:IServletResponseThe plain-text data of the response, used only whenIServletResponse.getType()is not set to a binary response type or redirect.- Specified by:
getValuein interfaceIServletResponse- Returns:
- The plain-text content of the HTTP response.
-
getContentType
public String getContentType()
Description copied from interface:IServletResponseApplies only whenIServletResponse.getType()is set toEResponseType.SHOW_FILE:Must return the content type (=mime type) that is to be sent along with the binary data. When this is either
nullor blank, an attempt is made to guess the content type from the binary data. Please note that this may fail to determine the actual content type, you should always provide a content type.- Specified by:
getContentTypein interfaceIServletResponse- Returns:
- The content type of the binary data.
-
getSessionAttributes
public Map<String,Serializable> getSessionAttributes()
- Specified by:
getSessionAttributesin interfaceIServletResponse- Returns:
- A
Mapwith attributes that should be written to theHttpSession. Existing values in theHttpSessionare overwritten.
-
getType
public EResponseType getType()
- Specified by:
getTypein interfaceIServletResponse- Returns:
- The type of response, such as whether a plain text or binary file should be returned, or a redirect should be performed.
-
getBinValue
public byte[] getBinValue()
Description copied from interface:IServletResponseThe binary data for the response. Applies only whenIServletResponse.getType()is set toEResponseType.SHOW_FILE.- Specified by:
getBinValuein interfaceIServletResponse- Returns:
- The binary content of the HTTP response.
-
isForceDownload
public boolean isForceDownload()
Description copied from interface:IServletResponseApplies only whenIServletResponse.getType()is set toEResponseType.SHOW_FILE.- Specified by:
isForceDownloadin interfaceIServletResponse- Returns:
- If
true, attempts to prevent browsers from showing the binary content inline. Iffalse, the browser may show the content inline, which is useful for PDF, image or plain text files. Please note that support for this differs between browsers.
-
getEncoding
public String getEncoding()
Description copied from interface:IServletResponseApplies only whenIServletResponse.getType()is set toEResponseType.TEMPLATE,EResponseType.TEMPLATE_SYSTEM, orEResponseType.HTML.- Specified by:
getEncodingin interfaceIServletResponse- Returns:
- The encoding that is to be used for encoding the response.
-
isSuccess
public boolean isSuccess()
- Specified by:
isSuccessin interfaceIWorkflowResponse- Returns:
trueindicates that the workflow was run successfully,falseindicates that an error occurred during workflow processing.
-
getMsgCode
public ETextbausteinMsgCode getMsgCode()
- Specified by:
getMsgCodein interfaceIWorkflowResponse- Returns:
- The response text that should be sent to the browser as a result of running the workflow. This may be a success, an error, or some other more specific message.
-
getVorgang
public Vorgang getVorgang()
- Specified by:
getVorgangin interfaceIWorkflowResponse- Returns:
- The current
Vorgangthat was processed.
-
getLongValue
public long getLongValue()
Description copied from interface:IServletResponseReturns an long value. IfEResponseType.FORM_RECORDis set, this is the id of the record.- Specified by:
getLongValuein interfaceIServletResponse- Returns:
- an long value
-
-