Interface IResolvedAttachmentList
- All Superinterfaces:
IAttachmentItemResolutionErrorProviding
- All Known Implementing Classes:
ResolvedAttachmentList
Interface representing the resolved attachments as returned by
IWorkflowFileHandler.resolveReferencedAttachments(WorkflowNode, IReferencedAttachmentList, IAttachmentSearchOptions)
resolveReferencedAttachments}.- Since:
- 8.1.0
- Author:
- XIMA MEDIA GmbH
-
Method Summary
Modifier and TypeMethodDescription<R,
E extends Throwable>
RcollectResult
(IResolvedAttachmentListProcessor<R, E> handler) Iterates over all resolved attachment items, processes them with the given handler, and returns the combined result of all attachment items.Retrieves the list of resolved attachment items.default List<IResolvedAttachment>
default List<IResolvedAttachment>
Methods inherited from interface de.xima.fc.interfaces.workflow.retval.IAttachmentItemResolutionErrorProviding
getErrors, getErrors, getErrorsAttachmentCountReducedTozeroByFilterOptions, getErrorsAttachmentFilterDoesNotMatch, getErrorsCannotProcessAttachmentItem, getErrorsCannotProcessAttachmentList, getErrorsDatabaseError, getErrorsFileSystemError, getErrorsNodeDoesNotExist, getErrorsNodeDoesNotProvideAttachments, getErrorsNodeNotExecuted, getErrorsUploadFieldDoesNotExist, getErrorsUploadFieldDoesNotProvideAttachments, isHasError
-
Method Details
-
collectResult
Iterates over all resolved attachment items, processes them with the given handler, and returns the combined result of all attachment items. Standard use case is to convert errors to hard and soft workflow node errors and return a list of all resolved attachments.If you wish to use the standard error behavior for attachments, use
standardAttachmentErrorsSingle
orstandardAttachmentErrorsMultiple
. Otherwise, provide your own processor implementation, or extend theStandardErrorAttachmentListProcessor
.- Type Parameters:
R
- Type of the combined result of all attachment items.E
- Type of the error that may be thrown when anyerrors
are present.- Parameters:
handler
- Handler for processing the errors and the results.- Returns:
- The combined result of all attachment items.
- Throws:
E
- The first error thrown by the handler.
-
getAttachmentItems
Retrieves the list of resolved attachment items. This list always contains one entry for eachAttachmentItem
that was passed toresolveReferencedAttachments
, independent of whether any exceptions occurred while resolving that item. WhenIAttachmentItemResolutionErrorProviding.getErrors()
is notnull
, this list is empty.- Returns:
- A list with the resolved attachments.
-
getAttachmentList
IReferencedAttachmentList getAttachmentList()- Returns:
- The attachment list that was resolved to obtain this result.
-
getResolvedAttachmentsComplete
- Returns:
- All resolved attachments that were found, when no errors occurred. When
errors
is not empty, this method throws. - Throws:
Exception
- One of the exceptions present inIAttachmentItemResolutionErrorProviding.getErrors()
.
-
getResolvedAttachmentsPartial
- Returns:
- All attachments that were found, regardless of whether errors occurred or not. When
errors
is not empty, this list may be incomplete.
-