Class WorkflowElementWithDeserializedModel<TData,​TElement>

    • Method Detail

      • withCustomLocator

        public static <TData,​TElement> IWorkflowElementWithDeserializedModel<TData,​TElement> withCustomLocator​(TElement element,
                                                                                                                           ElementKey key,
                                                                                                                           Function<TElement,​TData> dataLocator,
                                                                                                                           Mandant client)
        Creates a new wrapped workflow element that retrieves the custom properties on demand by using the given locator.
        Type Parameters:
        TData - Type of the workflow element's properties model.
        TElement - Type of the workflow element, i.e. a node or trigger.
        Parameters:
        element - The element to wrap.
        key - Key of the element.
        dataLocator - Function that can retrieve the data to associate with the element.
        client - The current client context for locating client node or trigger plugins.
        Returns:
        A new wrapped workflow element for the given element.
      • withData

        public static <TData,​TElement> IWorkflowElementWithDeserializedModel<TData,​TElement> withData​(TElement element,
                                                                                                                  ElementKey key,
                                                                                                                  TData data,
                                                                                                                  Mandant client)
        Creates a new wrapped workflow element that uses the given custom properties.
        Type Parameters:
        TData - Type of the workflow element's properties model.
        TElement - Type of the workflow element, i.e. a node or trigger.
        Parameters:
        element - The element to wrap.
        key - Key of the element.
        data - The data to associate with the element.
        client - The current client context for locating client node or trigger plugins.
        Returns:
        A new wrapped workflow element for the given element.
      • withDataOnDemand

        public static <TData,​TElement extends IWorkflowElementEntityIWorkflowElementWithDeserializedModel<TData,​TElement> withDataOnDemand​(TElement element,
                                                                                                                                                         ElementKey key,
                                                                                                                                                         Mandant client)
        Creates a new wrapped workflow element that deserializes the custom properties on demand.
        Type Parameters:
        TData - Type of the workflow element's properties model.
        TElement - Type of the workflow element, i.e. a node or trigger.
        Parameters:
        element - The element to wrap.
        key - Key of the element.
        client - The current client context for locating client node or trigger plugins.
        Returns:
        A new wrapped workflow element for the given element.
      • withDataOnDemand

        public static <TData> IWorkflowElementWithDeserializedModel<TData,​WorkflowNode> withDataOnDemand​(WorkflowNode node,
                                                                                                               Mandant client)
        Creates a new wrapped workflow node that deserializes the custom properties on demand.
        Type Parameters:
        TData - Type of the workflow node's properties model.
        Parameters:
        node - The node to wrap.
        client - The current client context for locating client node or trigger plugins.
        Returns:
        A new wrapped workflow node for the given node.
      • withDataOnDemand

        public static <TData> IWorkflowElementWithDeserializedModel<TData,​WorkflowTrigger> withDataOnDemand​(WorkflowTrigger trigger,
                                                                                                                  Mandant client)
        Creates a new wrapped workflow trigger that deserializes the custom properties on demand.
        Type Parameters:
        TData - Type of the workflow trigger's properties model.
        Parameters:
        trigger - The trigger to wrap.
        client - The current client context for locating client node or trigger plugins.
        Returns:
        A new wrapped workflow trigger for the given trigger.