Interface GovernanceRolesInterface
- All Known Implementing Classes:
GovernanceRoleManager
public interface GovernanceRolesInterface
GovernanceRolesInterface covers the definition of governance roles and their appointments.
-
Method Summary
Modifier and TypeMethodDescriptionappointGovernanceRole
(String userId, String roleGUID, String profileGUID, Date startDate) Link a person to a governance role.createGovernanceRole
(String userId, GovernanceRoleProperties properties) Create a definition of a new governance role.void
deleteGovernanceRole
(String userId, String governanceRoleGUID) Delete the properties of the governance role.getCurrentGovernanceRoleAppointments
(String userId, int domainIdentifier, int startFrom, int pageSize) Return all the governance roles and their incumbents (if any).getGovernanceRoleByGUID
(String userId, String governanceRoleGUID) Retrieve the properties of a governance role using its unique identifier.getGovernanceRoleByRoleId
(String userId, String roleId) Retrieve the properties of a governance role using its unique name.getGovernanceRoleHistoryByGUID
(String userId, String governanceRoleGUID) Retrieve the appointment history for a governance role by unique guid.getGovernanceRolesByDomainId
(String userId, int domainIdentifier, int startFrom, int pageSize) Retrieve all the governance roles for a particular governance domain.getGovernanceRolesByTitle
(String userId, String title, int startFrom, int pageSize) Retrieve all the governance roles for a particular title.void
relieveGovernanceRole
(String userId, String roleGUID, String profileGUID, String appointmentGUID, Date endDate) Unlink a person from a governance role appointment.void
updateGovernanceRole
(String userId, String roleGUID, boolean isMergeUpdate, GovernanceRoleProperties properties)
-
Method Details
-
createGovernanceRole
String createGovernanceRole(String userId, GovernanceRoleProperties properties) throws UserNotAuthorizedException, InvalidParameterException, PropertyServerException Create a definition of a new governance role.- Parameters:
userId
- calling userproperties
- role properties- Returns:
- unique identifier of new role
- Throws:
InvalidParameterException
- one of the parameters is invalidPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
updateGovernanceRole
void updateGovernanceRole(String userId, String roleGUID, boolean isMergeUpdate, GovernanceRoleProperties properties) throws UserNotAuthorizedException, InvalidParameterException, PropertyServerException - Parameters:
userId
- calling userroleGUID
- identifier of the governance role to updateisMergeUpdate
- are unspecified properties unchanged (true) or replaced with null?properties
- properties to change- Throws:
InvalidParameterException
- one of the parameters is invalidPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
deleteGovernanceRole
void deleteGovernanceRole(String userId, String governanceRoleGUID) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException Delete the properties of the governance role.- Parameters:
userId
- calling usergovernanceRoleGUID
- identifier of the governance role to delete- Throws:
InvalidParameterException
- guid or userId is nullPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
getGovernanceRoleByGUID
GovernanceRoleElement getGovernanceRoleByGUID(String userId, String governanceRoleGUID) throws UserNotAuthorizedException, InvalidParameterException, PropertyServerException Retrieve the properties of a governance role using its unique identifier.- Parameters:
userId
- calling usergovernanceRoleGUID
- unique identifier- Returns:
- properties of the role and any current appointees
- Throws:
InvalidParameterException
- guid or userId is nullPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
getGovernanceRoleHistoryByGUID
GovernanceRoleHistory getGovernanceRoleHistoryByGUID(String userId, String governanceRoleGUID) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Retrieve the appointment history for a governance role by unique guid.- Parameters:
userId
- the name of the calling user.governanceRoleGUID
- unique identifier (guid) of the governance role.- Returns:
- governance role object
- Throws:
InvalidParameterException
- guid or userId is nullPropertyServerException
- the server is not available.UserNotAuthorizedException
- the calling user is not authorized to issue the call.
-
getGovernanceRoleByRoleId
List<GovernanceRoleElement> getGovernanceRoleByRoleId(String userId, String roleId) throws UserNotAuthorizedException, InvalidParameterException, PropertyServerException Retrieve the properties of a governance role using its unique name. The results are returned as a list since it is possible that two roles have the same identifier due to the distributed nature of the open metadata ecosystem. By returning all the search results here it is possible to manage the duplicates through this interface.- Parameters:
userId
- calling userroleId
- unique name- Returns:
- list of roles retrieved
- Throws:
InvalidParameterException
- name or userId is nullPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
getGovernanceRolesByDomainId
List<GovernanceRoleElement> getGovernanceRolesByDomainId(String userId, int domainIdentifier, int startFrom, int pageSize) throws UserNotAuthorizedException, InvalidParameterException, PropertyServerException Retrieve all the governance roles for a particular governance domain.- Parameters:
userId
- calling userdomainIdentifier
- identifier of domain - 0 means allstartFrom
- where to start from in the list of definitionspageSize
- max number of results to return in one call- Returns:
- list of matching roles
- Throws:
InvalidParameterException
- domain identifier is undefined or userId is nullPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
getGovernanceRolesByTitle
List<GovernanceRoleElement> getGovernanceRolesByTitle(String userId, String title, int startFrom, int pageSize) throws UserNotAuthorizedException, InvalidParameterException, PropertyServerException Retrieve all the governance roles for a particular title. The title can include regEx wildcards.- Parameters:
userId
- calling usertitle
- identifier of rolestartFrom
- where to start from in the list of definitionspageSize
- max number of results to return in one call- Returns:
- list of matching roles (null if no matching elements)
- Throws:
InvalidParameterException
- title or userId is nullPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
getCurrentGovernanceRoleAppointments
List<GovernanceRoleAppointee> getCurrentGovernanceRoleAppointments(String userId, int domainIdentifier, int startFrom, int pageSize) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Return all the governance roles and their incumbents (if any).- Parameters:
userId
- the name of the calling user.domainIdentifier
- identifier of domain - 0 means allstartFrom
- where to start from in the list of definitionspageSize
- max number of results to return in one call- Returns:
- list of governance role objects
- Throws:
InvalidParameterException
- the userId is either null or invalid.PropertyServerException
- the server is not available.UserNotAuthorizedException
- the calling user is not authorized to issue the call.
-
appointGovernanceRole
String appointGovernanceRole(String userId, String roleGUID, String profileGUID, Date startDate) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Link a person to a governance role. Only one person may be appointed at any one time.- Parameters:
userId
- the name of the calling userroleGUID
- unique identifier (guid) of the governance roleprofileGUID
- unique identifier for the profilestartDate
- the official start date of the appointment - null means effective immediately- Returns:
- unique identifier (guid) of the appointment relationship
- Throws:
InvalidParameterException
- the unique identifier of the governance role or profile is either null or invalidPropertyServerException
- the server is not available.UserNotAuthorizedException
- the calling user is not authorized to issue the call.
-
relieveGovernanceRole
void relieveGovernanceRole(String userId, String roleGUID, String profileGUID, String appointmentGUID, Date endDate) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Unlink a person from a governance role appointment.- Parameters:
userId
- the name of the calling userroleGUID
- unique identifier (guid) of the governance roleprofileGUID
- unique identifier for the profileappointmentGUID
- unique identifier (guid) of the appointment relationshipendDate
- the official end of the appointment - null means effective immediately- Throws:
InvalidParameterException
- the profile is not linked to this governance rolePropertyServerException
- the server is not available.UserNotAuthorizedException
- the calling user is not authorized to issue the call.
-