Interface TagApi
-
public interface TagApi
Contains all api operations for handling tags.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Tag
changeTag(ChangeTagRequest changeTagRequest)
Changes a tag.boolean
exists(String tagName)
Returns true if a tag with given name exists.boolean
exists(UUID tagId)
Returns true if a tag with givenid
exists.PagedResponse<Tag>
findTags(FindTagsRequest findTagsRequest)
Returns tags matching given search criteria.Tag
getTag(UUID tagId)
Returns a tag identified by givenid
.List<Tag>
getTagsByAssetId(UUID assetId)
Retrieves all tags of given asset.void
mergeTags(MergeTagsRequest mergeTagsRequest)
Merge two tags into one.void
removeTag(UUID tagId)
Remove a tag.void
removeTags(List<UUID> tagsIds)
Removes the tags identified by given ids.
-
-
-
Method Detail
-
getTag
Tag getTag(UUID tagId)
Returns a tag identified by givenid
.- Parameters:
tagId
- theid
of the tag- Returns:
- the tag
-
findTags
@SecurityAuditMethod(resultFormatter=PagedResponseFormatter.class) PagedResponse<Tag> findTags(FindTagsRequest findTagsRequest)
Returns tags matching given search criteria.- Parameters:
findTagsRequest
- the search criteria for tags- Returns:
- the found tags
-
getTagsByAssetId
@SecurityAuditMethod(resultFormatter=com.collibra.audit.formatter.CollectionFormatter.class) List<Tag> getTagsByAssetId(UUID assetId)
Retrieves all tags of given asset.- Parameters:
assetId
- Theid
of an asset- Returns:
- tags of given asset
-
changeTag
Tag changeTag(ChangeTagRequest changeTagRequest)
Changes a tag.- Parameters:
changeTagRequest
- the information required to be able to change the tag- Returns:
- the modified tag
-
removeTag
void removeTag(UUID tagId)
Remove a tag.- Parameters:
tagId
- Id of the tag to be removed.
-
removeTags
void removeTags(List<UUID> tagsIds)
Removes the tags identified by given ids.- Parameters:
tagsIds
- theid
s of the tags to remove
-
mergeTags
void mergeTags(MergeTagsRequest mergeTagsRequest)
Merge two tags into one. All assets which has been tagged by tag with id 'fromId' will be tagged by tag with id 'toId'. Tag with id 'fromId' will be removed.- Parameters:
mergeTagsRequest
- contains "fromId" and "toId" of the tags
-
exists
boolean exists(UUID tagId)
Returns true if a tag with givenid
exists.- Parameters:
tagId
- theid
of the tag- Returns:
- true if a tag with given
id
exists,false
otherwise
-
exists
boolean exists(String tagName)
Returns true if a tag with given name exists.- Parameters:
tagName
- the name of the tag- Returns:
- true if a tag with given tagName exists,
false
otherwise
-
-