org.jwarp.flow.security
Interface IParticipantManager

All Superinterfaces:
IConfigurable, IWorkflowSystemAware
All Known Implementing Classes:
ParticipantManager

public interface IParticipantManager
extends IWorkflowSystemAware, IConfigurable

The participant manager is the manager object which actually handles all participant related stuff. Participants can created, removed and managed here. This class actually encapsulate the underlying communication to an actual implementation such as an EJB server containing the participant definitions.


Method Summary
 IParticipant createParticipant(java.lang.String name, java.lang.String description, short type, IWorkflowModel model, ITicket user)
          This creates a new participant within the given workflow model.
 IParticipant createParticipant(java.lang.String name, java.lang.String description, short type, IWorkflowSystem system, ITicket user)
          This creates a new global participant within the given workflow system.
 IParticipant getParticipant(int id, ITicket user)
          Get a participant.
 java.util.Iterator getParticipants(IWorkflowModel model, ITicket user)
          Return all the participants valid for a model.
 void removeParticipant(IParticipant participant, ITicket user)
          Removes a participant from the db.
 java.util.Iterator searchParticipants(java.lang.String name, IWorkflowSystem system, IWorkflowModel model, IWorkflow flow, ITicket admin)
          Search for participants.
 void updateParticipant(int id, java.lang.String name, java.lang.String description, short type, ITicket user)
          Update a participant.
 
Methods inherited from interface org.jwarp.flow.IWorkflowSystemAware
getWorkflowSystem, setWorkflowSystem
 
Methods inherited from interface org.jwarp.service.configuration.IConfigurable
configure
 

Method Detail

getParticipants

public java.util.Iterator getParticipants(IWorkflowModel model,
                                          ITicket user)
                                   throws java.lang.SecurityException
Return all the participants valid for a model. This method returns the model specific participants as also the flow system globally defined roles.
Parameters:
model - The model
user - The user ticket
Returns:
The participants for according to the model
Throws:
java.lang.SecurityException - If access was denied.

createParticipant

public IParticipant createParticipant(java.lang.String name,
                                      java.lang.String description,
                                      short type,
                                      IWorkflowSystem system,
                                      ITicket user)
                               throws InitializationException,
                                      java.lang.SecurityException
This creates a new global participant within the given workflow system.
Parameters:
name - The name of the new participant
description - The participant's description
type - The participant's type
system - The system
user - The user ticket
Returns:
The newly created participant
Throws:
InitializationException - If the participant could not be created.
java.lang.SecurityException - If access was denied.

createParticipant

public IParticipant createParticipant(java.lang.String name,
                                      java.lang.String description,
                                      short type,
                                      IWorkflowModel model,
                                      ITicket user)
                               throws InitializationException,
                                      java.lang.SecurityException
This creates a new participant within the given workflow model.
Parameters:
name - The name of the new role
description - The roles description
type - The participant's type
system - The system
user - The user ticket
Returns:
The newly created participant
Throws:
InitializationException - If the participant could not be created.
java.lang.SecurityException - If access was denied.

updateParticipant

public void updateParticipant(int id,
                              java.lang.String name,
                              java.lang.String description,
                              short type,
                              ITicket user)
                       throws NotFoundException,
                              java.lang.SecurityException
Update a participant.
Parameters:
id - The participant's id
name - The new participant's name
description - The new participant's description
rype - The new participant's type
user - The user ticket
Returns:
The newly created participant
Throws:
java.lang.SecurityException - If access was denied.
NotFoundException - If the participant could not be located.

removeParticipant

public void removeParticipant(IParticipant participant,
                              ITicket user)
                       throws NotFoundException,
                              java.lang.SecurityException
Removes a participant from the db. Note that a participant can only be removed if all dependencies are also removed. Dependencies are transitions that act as this participant.
Parameters:
participant - The participant
user - The user
Throws:
NotFoundException - If the participant could not be located.
java.lang.SecurityException - If access was denied.

getParticipant

public IParticipant getParticipant(int id,
                                   ITicket user)
                            throws java.lang.SecurityException
Get a participant.
Parameters:
id - The participant's id number
user - The user ticket
Returns:
The participant
Throws:
java.lang.SecurityException - If access was denied.

searchParticipants

public java.util.Iterator searchParticipants(java.lang.String name,
                                             IWorkflowSystem system,
                                             IWorkflowModel model,
                                             IWorkflow flow,
                                             ITicket admin)
                                      throws java.lang.SecurityException
Search for participants.
Parameters:
name - The participant's name
system - The workflow system
model - The workflow model
flow - The workflow
admin - The user ticket
Returns:
The participants
Throws:
java.lang.SecurityException - If access was denied.

©   O R C A   S y s t e m s