Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "Stardust/Knowledge Base/Java API"

(New page: = Java API Cookbook<br> = NOTE to authors: Please make sure to specify the version on which a command was executed<br>[All version numbers < 7.0 refer to the Infinity Process Platform...)
 
(Queries)
(36 intermediate revisions by 8 users not shown)
Line 1: Line 1:
= Java API Cookbook<br> =
+
__NOTOC__
 +
<pre>NOTE to authors: Please make sure to specify the version on which the example was tested.
 +
All version numbers &lt; 7.0 refer to the Infinity Process Platform (IPP)
 +
</pre>
 +
<br>NOTE: The ServiceFactory caches the authenticated Stardust services for the user. For use in a production environment it is important that the clients cache the ServiceFactory per user. Not caching the ServiceFactory means that a new login will be performed for every interaction with the engine. <br>  
  
NOTE to authors: Please make sure to specify the version on which a command was executed<br>[All version numbers &lt; 7.0 refer to the Infinity Process Platform (IPP)]<br>
+
== Process and Activity Instance Lifecycle  ==
  
= Runtime unbinding of activity events and setting data path of process instance)<br> =
+
*[[Stardust/Knowledge Base/API/JavaAPICookbook/Stardust Workflow Service in Action|Stardust Workflow Service in Action]]
 +
**Starting a Process
 +
**Activating and completing an Activity
 +
**Aborting an Activity
 +
**Delegating an Activity
 +
**Suspending an Activity
 +
**Fetching the User Work List
 +
**Submitting Process Data<br>
  
(Versions: 5.3.x)<br>  
+
*[[Stardust/Knowledge Base/API/ExamplesofAPIUsage/StartProcess|Start a process]]
 +
*[[Stardust/Knowledge Base/API/ExamplesofAPIUsage/CompleteAnActivity|Complete an Activity]]
 +
*[[Stardust/Knowledge Base/API/ExamplesofAPIUsage/AttachADocument|Attaching a document to a process instance]]<br>  
  
There are certain instances when you want to unbind an event (e.g timer) associated with an activity instance during runtime execution of your process instance, and also set the value of a data path defined for the process. The following code snippet shows how this can be achieved:<br>
+
== Monitoring, Events and Event Actions ==
<pre>for (int i = 0; i &lt; lActivityInstances.size(); i++) {
+
  
  Activity ai = (Activity) lActivityInstances.get(i);
+
*[[Stardust/Knowledge_Base/Java_API/Event_Binding|Event Binding]] - binding and unbinding event handler via the API<br>
 +
*[[Stardust/Knowledge_Base/Java_API/Dynamic_Event_Binding|Binding a Process Timer Through API]]
 +
*[[Stardust/Knowledge Base/Java API/Dynamic Event Binding| Dynamic Event Binding]] dynamic event binding of a process timer event
 +
*[[Stardust/Knowledge_Base/Java_API/IWorklistMonitor_Example|IWorklistMonitor Example Implementation]] - sending push notifications or triggering other system activity when a worklist content changes<br>
 +
*[[Stardust/Knowledge_Base/Java_API/IPartitionMonitor_Example|IPartitionMonitor Example Implementation]] - triggering participant synchronization or other system activity when a new model is deployed or deleted or when users are created, enabled or disabled<br>
  
  workflowService.unbindActivityEventHandler(lActivityInstances .get(i).getOID(), "timer");
+
== Queries  ==
  
  HashMap outmap = new HashMap();
+
*[[Stardust/Knowledge Base/API/JavaAPICookbook/QueryingWorklists|Querying Worklists]] - querying different user, user group, role or organization worklists based on different predicates
 +
*[[Stardust/Knowledge Base/API/JavaAPICookbook/QueryingWorklist Utility|Querying Worklist Utility]] - a utility program to provide a list of WorkItems (Activity Instances) for a given combination of user, partition, role and department
 +
*[[Stardust/Knowledge Base/API/JavaAPICookbook/Querying Workflow and Runtime|Querying Worklow and Runtime Information]] - querying e.g. model information, users having a certain role, the logged in user,...
 +
*[[Stardust/Knowledge Base/API/JavaAPICookbook/Querying Activity Instance List|Querying Activity Instance List ]] - querying e.g. Activity Instance List, Activity Instance having a certain state,...
 +
*[[Stardust/Knowledge Base/API/ExamplesofAPIUsage/GeneratingRoleBasedAPI|Generating Role/Grant-based Stardust API Queries]]
 +
*[[Stardust/Knowledge Base/API/JavaAPICookbook/CheckingUserSpecificRole|Checking if a user has specific role]]
 +
*[[Stardust/Knowledge Base/API/JavaAPICookbook/FetchingOrganizationOfProviderModel |Fetching organization of Provider Model]]
 +
*[[Stardust/Knowledge Base/API/JavaAPICookbook/FetchingPIandAIHistoricalEvents |Fetching PI and AI Historical Events]]   
 +
*[[Stardust/Knowledge Base/API/ExamplesofAPIUsage/ActivityEventHibernateInitially|Checking Activity Event and Hibernate initially Status]]
 +
*[[Stardust/Knowledge Base/Java API/Queries/Partitions|Queries related to Audit Trail Partitions, e.g. listing existing partitions]]
 +
*[[Stardust/Knowledge Base/Java API/Process Instance Queries|Process Instance Queries]]&nbsp;- querying for process instances satisfying various search criteria
 +
*[[Stardust/Knowledge Base/Java API/Process Definition Queries|Process Definition Queries]]&nbsp;- querying for process definitions satisfying various search criteria
 +
*Status of a Process Instance
 +
*History of a ProcessInstance
 +
*Listing Data Mappings of an Activity
  
  workflowService.activateAndComplete(lActivityInstances.get(i).getOID(), null, outmap);
+
<br>
  
  workflowService.setOutDataPath(lProcessInstances.get(0).getOID(),"date", outmap);
+
== Organizational Structure &amp; Authorizations  ==
 +
 
 +
*[[Stardust/Knowledge Base/API/ExamplesofAPIUsage/CreateDepartments|Creating Departments Programmatically]]<br>
 +
 
 +
<br>
 +
 
 +
== Process Data  ==
 +
 
 +
*[[Stardust/Knowledge Base/Java API/Reading Process Data|Reading Process Data]]
 +
 
 +
<br>
 +
 
 +
== Document Management  ==
 +
*[[Stardust/Knowledge_Base/Java_API/Document_Management|DMS Java API Examples]]
 +
*[[Stardust/Knowledge Base/Java API/Document Security|Document Security]]
 +
<br>
 +
 
 +
== Other  ==
 +
 
 +
*[[Stardust/Knowledge_Base/Java_API/Support_Case_Example|Executing the Support Case Example using the Stardust Java API]]
 +
*[[Stardust/Knowledge Base/API/ExamplesofAPIUsage/CompleteAPIExample|Complete Stardust API Example]]
  
}
 
</pre>
 
 
<br>
 
<br>

Revision as of 00:34, 11 April 2014

NOTE to authors: Please make sure to specify the version on which the example was tested. 
All version numbers < 7.0 refer to the Infinity Process Platform (IPP)


NOTE: The ServiceFactory caches the authenticated Stardust services for the user. For use in a production environment it is important that the clients cache the ServiceFactory per user. Not caching the ServiceFactory means that a new login will be performed for every interaction with the engine.

Process and Activity Instance Lifecycle

  • Stardust Workflow Service in Action
    • Starting a Process
    • Activating and completing an Activity
    • Aborting an Activity
    • Delegating an Activity
    • Suspending an Activity
    • Fetching the User Work List
    • Submitting Process Data

Monitoring, Events and Event Actions

Queries


Organizational Structure & Authorizations


Process Data


Document Management


Other


Back to the top