Interface AssetConsumerTaggingInterface
- All Known Implementing Classes:
AssetConsumer
public interface AssetConsumerTaggingInterface
AssetConsumerTaggingInterface support the management and use of informal tags, whether public or private.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addTagToAsset
(String userId, String assetGUID, String tagGUID, boolean isPublic) Adds a tag (either private of public) to an asset.void
addTagToElement
(String userId, String elementGUID, String tagGUID, boolean isPublic) Adds a tag (either private of public) to an element attached to an asset - such as schema element, glossary term, ...createPrivateTag
(String userId, String tagName, String tagDescription) Creates a new private informal tag and returns the unique identifier for it.createPublicTag
(String userId, String tagName, String tagDescription) Creates a new public informal tag and returns the unique identifier for it.void
Removes an informal tag from the repository.findMyTags
(String userId, String tag, int startFrom, int pageSize) Return the list of the calling user's private tags containing the supplied string in either the name or description.Return the list of tags containing the supplied string in either the name or description.getAssetsByTag
(String userId, String tagGUID, int startFrom, int pageSize) Return the list of unique identifiers for assets that are linked to a specific tag either directly, or via one of its schema elements.getMyTagsByName
(String userId, String tag, int startFrom, int pageSize) Return the list of the calling user's private tags exactly matching the supplied name.Return the tag for the supplied unique identifier (guid).getTagsByName
(String userId, String tag, int startFrom, int pageSize) Return the list of tags exactly matching the supplied name.void
removeTagFromAsset
(String userId, String assetGUID, String tagGUID) Removes a tag from the asset that was added by this user.void
removeTagFromElement
(String userId, String elementGUID, String tagGUID) Removes a tag from an element attached to an asset - such as schema element, glossary term, ...void
updateTagDescription
(String userId, String tagGUID, String tagDescription) Updates the description of an existing tag (either private or public).
-
Method Details
-
createPublicTag
String createPublicTag(String userId, String tagName, String tagDescription) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Creates a new public informal tag and returns the unique identifier for it.- Parameters:
userId
- userId of user making request.tagName
- name of the tag.tagDescription
- (optional) description of the tag. Setting a description, particularly in a public tag makes the tag more valuable to other users and can act as an embryonic glossary term.- Returns:
- GUID for new tag.
- Throws:
InvalidParameterException
- one of the parameters is null or invalid.PropertyServerException
- there is a problem adding the asset properties to the property server.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
createPrivateTag
String createPrivateTag(String userId, String tagName, String tagDescription) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Creates a new private informal tag and returns the unique identifier for it.- Parameters:
userId
- userId of user making request.tagName
- name of the tag.tagDescription
- (optional) description of the tag. Setting a description, particularly in a public tag makes the tag more valuable to other users and can act as an embryonic glossary term.- Returns:
- GUID for new tag.
- Throws:
InvalidParameterException
- one of the parameters is null or invalid.PropertyServerException
- there is a problem adding the asset properties to the property server.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
updateTagDescription
void updateTagDescription(String userId, String tagGUID, String tagDescription) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Updates the description of an existing tag (either private or public).- Parameters:
userId
- userId of user making request.tagGUID
- unique identifier for the tag.tagDescription
- description of the tag. Setting a description, particularly in a public tag makes the tag more valuable to other users and can act as an embryonic glossary term.- Throws:
InvalidParameterException
- one of the parameters is null or invalid.PropertyServerException
- there is a problem adding the asset properties to the property server.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
deleteTag
void deleteTag(String userId, String tagGUID) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Removes an informal tag from the repository. All the tagging relationships to this informal tag are lost.. A private tag can be deleted by its creator and all the references are lost; a public tag can be deleted by anyone, but only if it is not attached to any referenceable.- Parameters:
userId
- userId of user making request.tagGUID
- unique id for the tag.- Throws:
InvalidParameterException
- one of the parameters is null or invalid.PropertyServerException
- there is a problem updating the asset properties in the property server.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
getTag
InformalTagElement getTag(String userId, String guid) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Return the tag for the supplied unique identifier (guid).- Parameters:
userId
- userId of the user making the request.guid
- unique identifier of the tag.- Returns:
- tag
- Throws:
InvalidParameterException
- the userId is null or invalid.PropertyServerException
- there is a problem retrieving information from the property server(s).UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
getTagsByName
List<InformalTagElement> getTagsByName(String userId, String tag, int startFrom, int pageSize) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Return the list of tags exactly matching the supplied name.- Parameters:
userId
- the name of the calling user.tag
- name of tag.startFrom
- index of the list to start from (0 for start)pageSize
- maximum number of elements to return.- Returns:
- tag list
- Throws:
InvalidParameterException
- the userId is null or invalid.PropertyServerException
- there is a problem retrieving information from the property server(s).UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
getMyTagsByName
List<InformalTagElement> getMyTagsByName(String userId, String tag, int startFrom, int pageSize) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Return the list of the calling user's private tags exactly matching the supplied name.- Parameters:
userId
- the name of the calling user.tag
- name of tag.startFrom
- index of the list to start from (0 for start)pageSize
- maximum number of elements to return.- Returns:
- tag list
- Throws:
InvalidParameterException
- the userId is null or invalid.PropertyServerException
- there is a problem retrieving information from the property server(s).UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
findTags
List<InformalTagElement> findTags(String userId, String tag, int startFrom, int pageSize) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Return the list of tags containing the supplied string in either the name or description.- Parameters:
userId
- the name of the calling user.tag
- name of tag. This may include wild card characters.startFrom
- index of the list to start from (0 for start)pageSize
- maximum number of elements to return.- Returns:
- tag list
- Throws:
InvalidParameterException
- the userId is null or invalid.PropertyServerException
- there is a problem retrieving information from the property server(s).UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
findMyTags
List<InformalTagElement> findMyTags(String userId, String tag, int startFrom, int pageSize) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Return the list of the calling user's private tags containing the supplied string in either the name or description.- Parameters:
userId
- the name of the calling user.tag
- name of tag. This may include wild card characters.startFrom
- index of the list to start from (0 for start)pageSize
- maximum number of elements to return.- Returns:
- tag list
- Throws:
InvalidParameterException
- the userId is null or invalid.PropertyServerException
- there is a problem retrieving information from the property server(s).UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
addTagToAsset
void addTagToAsset(String userId, String assetGUID, String tagGUID, boolean isPublic) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Adds a tag (either private of public) to an asset.- Parameters:
userId
- userId of user making request.assetGUID
- unique id for the asset.tagGUID
- unique id of the tag.isPublic
- flag indicating whether the attachment of the tag is public or not- Throws:
InvalidParameterException
- one of the parameters is null or invalid.PropertyServerException
- there is a problem adding the asset properties to the property server.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
addTagToElement
void addTagToElement(String userId, String elementGUID, String tagGUID, boolean isPublic) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Adds a tag (either private of public) to an element attached to an asset - such as schema element, glossary term, ...- Parameters:
userId
- userId of user making request.elementGUID
- unique id for the element.tagGUID
- unique id of the tag.isPublic
- flag indicating whether the attachment of the tag is public or not- Throws:
InvalidParameterException
- one of the parameters is null or invalid.PropertyServerException
- there is a problem adding the asset properties to the property server.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
removeTagFromAsset
void removeTagFromAsset(String userId, String assetGUID, String tagGUID) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Removes a tag from the asset that was added by this user.- Parameters:
userId
- userId of user making request.assetGUID
- unique id for the asset.tagGUID
- unique id for the tag.- Throws:
InvalidParameterException
- one of the parameters is null or invalid.PropertyServerException
- there is a problem updating the asset properties in the property server.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
removeTagFromElement
void removeTagFromElement(String userId, String elementGUID, String tagGUID) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Removes a tag from an element attached to an asset - such as schema element, glossary term, ... that was added by this user.- Parameters:
userId
- userId of user making request.elementGUID
- unique id for the element.tagGUID
- unique id for the tag.- Throws:
InvalidParameterException
- one of the parameters is null or invalid.PropertyServerException
- there is a problem updating the asset properties in the property server.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-
getAssetsByTag
List<String> getAssetsByTag(String userId, String tagGUID, int startFrom, int pageSize) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Return the list of unique identifiers for assets that are linked to a specific tag either directly, or via one of its schema elements. An Asset's GUID may appear multiple times in the results if it is tagged multiple times with the requested tag.- Parameters:
userId
- the name of the calling user.tagGUID
- unique identifier of tag.startFrom
- index of the list to start from (0 for start)pageSize
- maximum number of elements to return.- Returns:
- asset guid list
- Throws:
InvalidParameterException
- the userId is null or invalid.PropertyServerException
- there is a problem retrieving information from the property server(s).UserNotAuthorizedException
- the requesting user is not authorized to issue this request.
-