Interface IRefinedTriggerDataDescriptor<Model>
-
- Type Parameters:
Model
- Type of the properties model for the trigger.
- All Known Subinterfaces:
IBaseTrigger<TData>
,IBeanValidatingTrigger<TData>
,IBuiltinTriggerType<TData>
,IDefaultClientHandlerTrigger<TData>
,IOfficialHelpPageTrigger<TData>
,IPluginTriggerHandler<TData>
,ISemverUpdatingTrigger<TData>
,ISingleBaseBuiltinTriggerPrototype<TData>
,ISingleBaseTriggerPrototype<TData>
,ISingleBuiltinTriggerPrototype<TData>
,ISingleTriggerPrototype<TData>
,ISpecificTriggerListener<TData>
,ITriggerHandler<Model>
- All Known Implementing Classes:
APluginTriggerHandler
,FcCatchErrorHandler
,FcDoiVerifiedHandler
,FcFormRecordMessagePostedHandler
,FcFormRecordMessageUploadRequestFulfilledHandler
,FcFormSubmitButtonHandler
,FcInvitationErrorHandler
,FcInvitationSentHandler
,FcManualHandler
,FcQualifiedFormSubmitButtonHandler
,FcStateTimerHandler
,FcTimePointHandler
,FcUserInvocationHandler
public interface IRefinedTriggerDataDescriptor<Model>
SeeITriggerDataDescriptor
for more details. This is similar, but allows the provided data to be refined depending on the trigger's configuration, i.e. the contents of its property model. For example, a trigger might expose certain filter settings on the UI that limit what kind of events the trigger reacts to. Depending on the user's choice, the data provided by the trigger might change. By defining a value descriptor for each case, we can show the user only the relevant data for that case.All value descriptors must be compatible with the general descriptors returned by
ITriggerDataDescriptor
. The final value descriptor is obtained by taking the intersection of the general value descriptor with the refined value descriptor, i.e.:intersect
(getTriggerDataDescriptor()
,getTriggerDataDescriptor(model)
)intersect
(getTriggerFilesDescriptor()
,getTriggerFilesDescriptor(model)
)union: string | number
). Depending on the trigger's configuration, the refined value descriptor could be either just a string or just a number. Or you can use a general file descriptor that allows PDF and Word documents. Depending on the trigger's configuration, the refined file descriptor could allow either just a PDF document or just a Word document.On the other hand, if general value descriptor were to allow only strings and the refined value descriptor were to allow only booleans, the final value descriptor would evaluate to
intersect(boolean, string) = void
. In other words, the trigger could not provide data. Any attempts to provide data when the trigger fires will be ignored by the workflow engine. Similarly, if the general file value descriptor were to allow only PDF documents and the refined file value descriptor were to allow only Word documents, the final file value descriptor would evaluate tointersect(PDF, Word) = empty
, so no files would be allowed.Note: The value and file descriptors are also used by the UI to inform the UI about the possible return values of a trigger. By ignoring all provided values incompatible with the value and file descriptors, the workflow engine ensures that the UI agrees with the actual behavior.
- Since:
- 8.2.0
-
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default IValueDescriptor<?,? extends IValueBuilder<?>>
getTriggerDataDescriptor(IValueDescriptorFactory factory, Model data)
Same asgetTriggerDataDescriptor
without data, but refined depending on the current trigger's configuration.default IFileValueDescriptor
getTriggerFilesDescriptor(Model data)
Same asgetTriggerFilesDescriptor
without data, but refined depending on the current trigger's configuration.
-
-
-
Method Detail
-
getTriggerDataDescriptor
default IValueDescriptor<?,? extends IValueBuilder<?>> getTriggerDataDescriptor(IValueDescriptorFactory factory, Model data)
Same asgetTriggerDataDescriptor
without data, but refined depending on the current trigger's configuration.Creates the value descriptor for the data that is made available to the workflow when a task with this trigger starts.
- Parameters:
factory
- Factory that may be used for creating the descriptor. Instead of the factory passed in to this method, you may also useValueDescriptorFactory.getInstance()
if you wish to cache the descriptor in a static or instance field.- Returns:
- The value descriptor for the data that is made available to the workflow when a task with this trigger is
executed. If
null
, the non-refined descriptor is used. - See Also:
ITriggerHandler.onTaskBegin(ITriggerOnTaskBeginParams)
-
getTriggerFilesDescriptor
default IFileValueDescriptor getTriggerFilesDescriptor(Model data)
Same asgetTriggerFilesDescriptor
without data, but refined depending on the current trigger's configuration.Creates the files descriptor for the files that are made available to the workflow when a task with this trigger starts.
- Returns:
- The files descriptor for the files that are made available to the workflow when a task with this trigger
is executed. If
null
, the non-refined descriptor is used. - See Also:
ITriggerHandler.onTaskBegin(ITriggerOnTaskBeginParams)
-
-