public class PersonalProfileManagement extends Object implements PersonalProfileManagementInterface
| Constructor and Description |
|---|
PersonalProfileManagement(String serverName,
String omasServerURL)
Create a new client with no authentication embedded in the HTTP request.
|
PersonalProfileManagement(String serverName,
String omasServerURL,
String userId,
String password)
Create a new client that passes userId and password in each HTTP request.
|
| Modifier and Type | Method and Description |
|---|---|
String |
addContactMethod(String userId,
String profileUserId,
ContactMethodType type,
String service,
String value)
Add a new contact method to the requesting user's profile.
|
String |
createPersonalProfile(String userId,
String profileUserId,
String qualifiedName,
String fullName,
String knownName,
String jobTitle,
String jobRoleDescription,
Map<String,String> additionalProperties)
Create a personal profile for an individual who is to be appointed to a governance role but does not
have a profile in open metadata.
|
void |
deleteContactMethod(String userId,
String profileUserId,
String contactMethodGUID,
ContactMethodType type)
Remove an obsolete contact method from the requesting user's profile.
|
void |
deletePersonalProfile(String userId,
String profileGUID,
String qualifiedName)
Delete the personal profile.
|
List<ContactMethod> |
getContactDetails(String userId,
String profileUserId)
Return the list of contact methods for this user.
|
long |
getKarmaPoints(String userId,
String profileUserId)
Return the total karma points for this user.
|
PersonalProfile |
getPersonalProfileByGUID(String userId,
String profileGUID)
Retrieve a personal profile by guid.
|
PersonalProfile |
getPersonalProfileByQualifiedName(String userId,
String qualifiedName)
Retrieve a personal profile by personnel/serial/unique employee number of the individual.
|
PersonalProfile |
getPersonalProfileForUser(String userId,
String profileUserId)
Retrieve a personal profile by userId.
|
List<PersonalProfile> |
getPersonalProfilesByName(String userId,
String name)
Return a list of candidate personal profiles for an individual.
|
void |
updatePersonalProfile(String userId,
String profileGUID,
String qualifiedName,
String fullName,
String knownName,
String jobTitle,
String jobRoleDescription,
Map<String,Object> profileProperties,
Map<String,String> additionalProperties)
Update properties for the personal properties.
|
public PersonalProfileManagement(String serverName, String omasServerURL) throws InvalidParameterException
serverName - name of the server to connect toomasServerURL - the network address of the server running the OMAS REST serversInvalidParameterException - bad input parameterspublic PersonalProfileManagement(String serverName, String omasServerURL, String userId, String password) throws InvalidParameterException
serverName - name of the server to connect toomasServerURL - the network address of the server running the OMAS REST serversuserId - caller's userId embedded in all HTTP requestspassword - caller's userId embedded in all HTTP requestsInvalidParameterException - bad input parameterspublic String createPersonalProfile(String userId, String profileUserId, String qualifiedName, String fullName, String knownName, String jobTitle, String jobRoleDescription, Map<String,String> additionalProperties) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
createPersonalProfile in interface PersonalProfileManagementInterfaceuserId - the name of the calling user.profileUserId - userId of the individual whose profile this is.qualifiedName - personnel/serial/unique employee number of the individual.fullName - full name of the person.knownName - known name or nickname of the individual.jobTitle - job title of the individual.jobRoleDescription - job description of the individual.additionalProperties - additional properties about the individual.InvalidParameterException - the employee number or full name is null.PropertyServerException - the server is not available.UserNotAuthorizedException - the calling user is not authorized to issue the call.public void updatePersonalProfile(String userId, String profileGUID, String qualifiedName, String fullName, String knownName, String jobTitle, String jobRoleDescription, Map<String,Object> profileProperties, Map<String,String> additionalProperties) throws InvalidParameterException, NoProfileForUserException, PropertyServerException, UserNotAuthorizedException
updatePersonalProfile in interface PersonalProfileManagementInterfaceuserId - the name of the calling user.profileGUID - unique identifier for the profile.qualifiedName - personnel/serial/unique employee number of the individual. Used to verify the profileGUID.fullName - full name of the person.knownName - known name or nickname of the individual.jobTitle - job title of the individual.jobRoleDescription - job description of the individual.profileProperties - properties about the individual for a new type that is the subclass of Person.additionalProperties - additional properties about the individual.InvalidParameterException - the known name is null or the qualifiedName does not match the profileGUID.NoProfileForUserException - unable to locate the profile for this userId.PropertyServerException - the server is not available.UserNotAuthorizedException - the calling user is not authorized to issue the call.public void deletePersonalProfile(String userId, String profileGUID, String qualifiedName) throws InvalidParameterException, NoProfileForUserException, PropertyServerException, UserNotAuthorizedException
deletePersonalProfile in interface PersonalProfileManagementInterfaceuserId - the name of the calling user.profileGUID - unique identifier for the profile.qualifiedName - personnel/serial/unique employee number of the individual.InvalidParameterException - the qualifiedName or guid is null.PropertyServerException - the server is not available.UserNotAuthorizedException - the calling user is not authorized to issue the call.NoProfileForUserExceptionpublic long getKarmaPoints(String userId, String profileUserId) throws InvalidParameterException, NoProfileForUserException, PropertyServerException, UserNotAuthorizedException
getKarmaPoints in interface PersonalProfileManagementInterfaceuserId - userId of the user making the request.profileUserId - userId of the profile to update.InvalidParameterException - the userId is null or invalid.NoProfileForUserException - the user does not have a profile.PropertyServerException - there is a problem retrieving information from the property server(s).UserNotAuthorizedException - the requesting user is not authorized to issue this request.public List<ContactMethod> getContactDetails(String userId, String profileUserId) throws InvalidParameterException, NoProfileForUserException, PropertyServerException, UserNotAuthorizedException
getContactDetails in interface PersonalProfileManagementInterfaceuserId - userId of the user making the request.profileUserId - userId of the profile to update.InvalidParameterException - the userId is null or invalid.NoProfileForUserException - the user does not have a profile.PropertyServerException - there is a problem retrieving information from the property server(s).UserNotAuthorizedException - the requesting user is not authorized to issue this request.public String addContactMethod(String userId, String profileUserId, ContactMethodType type, String service, String value) throws InvalidParameterException, NoProfileForUserException, PropertyServerException, UserNotAuthorizedException
addContactMethod in interface PersonalProfileManagementInterfaceuserId - the name of the calling user.profileUserId - userId of the profile to update.type - type of contact method.service - service for the contact method.value - account name for the service.InvalidParameterException - the userId is null or invalid. Another property is invalid.NoProfileForUserException - the user does not have a profile.PropertyServerException - there is a problem retrieving information from the property server(s).UserNotAuthorizedException - the requesting user is not authorized to issue this request.public void deleteContactMethod(String userId, String profileUserId, String contactMethodGUID, ContactMethodType type) throws InvalidParameterException, NoProfileForUserException, PropertyServerException, UserNotAuthorizedException
deleteContactMethod in interface PersonalProfileManagementInterfaceuserId - the name of the calling user.profileUserId - userId of the profile to update.contactMethodGUID - unique identifier (guid) for the obsolete contact method.type - type of contact method. This is used to confirm that the GUID is the right one.InvalidParameterException - the userId is null or invalid. Another property is invalid.NoProfileForUserException - the user does not have a profile.PropertyServerException - there is a problem retrieving information from the property server(s).UserNotAuthorizedException - the requesting user is not authorized to issue this request.public PersonalProfile getPersonalProfileByGUID(String userId, String profileGUID) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
getPersonalProfileByGUID in interface PersonalProfileManagementInterfaceuserId - the name of the calling user.profileGUID - unique identifier for the profile.InvalidParameterException - one of the parameters is invalid.PropertyServerException - the server is not available.UserNotAuthorizedException - the calling user is not authorized to issue the call.public PersonalProfile getPersonalProfileForUser(String userId, String profileUserId) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
getPersonalProfileForUser in interface PersonalProfileManagementInterfaceuserId - the name of the calling user.profileUserId - userId associated with the profile.InvalidParameterException - one of the parameters is invalid.PropertyServerException - the server is not available.UserNotAuthorizedException - the calling user is not authorized to issue the call.public PersonalProfile getPersonalProfileByQualifiedName(String userId, String qualifiedName) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
getPersonalProfileByQualifiedName in interface PersonalProfileManagementInterfaceuserId - the name of the calling user.qualifiedName - personnel/serial/unique employee number of the individual.InvalidParameterException - the employee number.PropertyServerException - the server is not available, or there is a problem retrieving the profile.UserNotAuthorizedException - the calling user is not authorized to issue the call.public List<PersonalProfile> getPersonalProfilesByName(String userId, String name) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
getPersonalProfilesByName in interface PersonalProfileManagementInterfaceuserId - the name of the calling user.name - name of individual.InvalidParameterException - the name is null.PropertyServerException - the server is not available.UserNotAuthorizedException - the calling user is not authorized to issue the call.Copyright © 2018–2019 ODPi. All rights reserved.