Class ElementResultBuilder
- java.lang.Object
 - 
- de.xima.fc.workflow.processor.logic.validation.ElementResultBuilder
 
 
- 
- All Implemented Interfaces:
 IWorkflowElementValidationResultBuilder,org.apache.commons.lang3.builder.Builder<IWorkflowElementValidationResult>
public class ElementResultBuilder extends Object implements IWorkflowElementValidationResultBuilder
Default implementation of aIWorkflowElementValidationResultBuilder.- Since:
 - 7.0.0
 - Author:
 - XIMA MEDIA GmbH
 
 
- 
- 
Constructor Summary
Constructors Constructor Description ElementResultBuilder() 
- 
Method Summary
 
 - 
 
- 
- 
Method Detail
- 
addException
public ElementResultBuilder addException(Throwable exception)
Description copied from interface:IWorkflowElementValidationResultBuilderAdds the exceptions to the validation result, seeIWorkflowElementValidationResult.getExceptions().- Specified by:
 addExceptionin interfaceIWorkflowElementValidationResultBuilder- Parameters:
 exception- Exceptions to add that occurred during validation.- Returns:
 - This builder instance for chaining.
 
 
- 
addExceptions
public ElementResultBuilder addExceptions(Iterable<Throwable> exceptions)
Description copied from interface:IWorkflowElementValidationResultBuilderAdds an exception to the validation result, seeIWorkflowElementValidationResult.getExceptions().- Specified by:
 addExceptionsin interfaceIWorkflowElementValidationResultBuilder- Parameters:
 exceptions- Exception to add that occurred during validation.- Returns:
 - This builder instance for chaining.
 
 
- 
addMessage
public IWorkflowElementValidationResultBuilder addMessage(EValidationSeverity severity, String localizedMessage)
Description copied from interface:IWorkflowElementValidationResultBuilderAdds a message to the validation result.- Specified by:
 addMessagein interfaceIWorkflowElementValidationResultBuilder- Parameters:
 severity- Severity of the message to add.localizedMessage- Localized message to add.- Returns:
 - This builder instance for chaining.
 
 
- 
addMessage
public ElementResultBuilder addMessage(IWorkflowValidationMessage message)
Description copied from interface:IWorkflowElementValidationResultBuilderAdds the given message @Override to the validation result.- Specified by:
 addMessagein interfaceIWorkflowElementValidationResultBuilder- Parameters:
 message- Message to add.- Returns:
 - This builder instance for chaining.
 
 
- 
addMessages
public ElementResultBuilder addMessages(Iterable<IWorkflowValidationMessage> messages)
Description copied from interface:IWorkflowElementValidationResultBuilderAdds the given messages to the validation result.- Specified by:
 addMessagesin interfaceIWorkflowElementValidationResultBuilder- Parameters:
 messages- Messages to add.- Returns:
 - This builder instance for chaining.
 
 
- 
append
public IWorkflowElementValidationResultBuilder append(IWorkflowElementValidationResult validationResult)
Description copied from interface:IWorkflowElementValidationResultBuilderAppends the given validation result to this builder. All messages are added, and this result is marked as invalid when the given result is invalid.- Specified by:
 appendin interfaceIWorkflowElementValidationResultBuilder- Parameters:
 validationResult- Validation result to add to the list of results.- Returns:
 - This builder instance for chaining.
 
 
- 
build
public IWorkflowElementValidationResult build()
- Specified by:
 buildin interfaceorg.apache.commons.lang3.builder.Builder<IWorkflowElementValidationResult>
 
- 
markInvalid
public ElementResultBuilder markInvalid()
Description copied from interface:IWorkflowElementValidationResultBuilderMarks the validation result as invalid. By default, the result will be valid.- Specified by:
 markInvalidin interfaceIWorkflowElementValidationResultBuilder- Returns:
 - This builder instance for chaining.
 
 
- 
setValid
public IWorkflowElementValidationResultBuilder setValid(boolean valid)
Description copied from interface:IWorkflowElementValidationResultBuilderMarks the validation result as invalid. By default, the result will be valid.- Specified by:
 setValidin interfaceIWorkflowElementValidationResultBuilder- Parameters:
 valid-trueto mark the result as valid,falseto mark it as invalid.- Returns:
 - This builder instance for chaining.
 
 
- 
exception
public static IWorkflowElementValidationResult exception(Exception e)
- Parameters:
 e- Exception that occurred.- Returns:
 - A validation result for when an exception occurred during validation.
 
 
- 
valid
public static IWorkflowElementValidationResult valid()
- Returns:
 - An immutable valid result wihtout any messages.
 
 
 - 
 
 -