This sample demonstrates how to set email notification for all users added to the workflow system. Run the sample by entering a command similar to the following:
java UserInfoSample username password server_name:port_number/connectionPoint_name email_suffix
Refer to the comments in the sample source for further information. The samples are located on the P8 Documentation CD or ESD image in:
ecm_help\developer_help\process_java_api\Developer Files\samples\api
See also Running the API Samples.
General descriptions of the UserInfoSample methods follow:
The main method displays a usage line if you supply less than the required arguments; otherwise, the method passes the arguments to the constructor.
The UserInfoSample constructor gets the VWSession object and uses VWsession.fetchUsers to get the VWSecurityList object. It then gets the VWUserInfo object using VWSession.fetchUserInfo, and sets the email address using VWUserInfo.setEMailAddress. Notification flags are then combined (bitwise OR) using the VWUserInfo NOTIFICATION* fields, and set using VWUserInfo.setNotificationFlags, for email notification to this user the specified (NOTIFICATION*) events occur.