Skip to main content

Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Stardust/Knowledge Base/API/JavaAPICookbook/QueryingWorklists

< Stardust‎ | Knowledge Base
Revision as of 06:40, 5 February 2014 by Unnamed Poltroon (Talk) (Introduction)

Introduction

This article will provide examples/usage of different Query API's. It is assumed that you are familiar with the modeling the processes with Stardust.

Scenario 1:

   This API usage will provide you the User and User group related information, precisely which users belong to which user groups.
UserQuery userQuery = new UserQuery();
UserGroupQuery userGroupQuery = new UserGroupQuery();
UserGroups usergroups = queryService.getAllUserGroups(userGroupQuery);
 
for (UserGroup userGroup : usergroups) {
				System.out.println("userGroup****** " + userGroup.getId());
				UserQuery userQuery1 = userQuery.findAllForUserGroup(userGroup.getId());
				Users existingusers = queryService.getAllUsers(userQuery1);
				System.out.println("existingusers.getSize****** " + existingusers.getSize());
 
				for (User user : existingusers) {
					System.out.println("user" + user.getId());
				}
 
			}

Back to the top