public class AssetTagLocalServiceImpl extends AssetTagLocalServiceBaseImpl
assetEntryFinder, assetEntryLocalService, assetEntryPersistence, assetTagFinder, assetTagLocalService, assetTagPersistence, classNameLocalService, classNamePersistence, counterLocalService, groupFinder, groupLocalService, groupPersistence, persistedModelLocalServiceRegistry, userFinder, userLocalService, userPersistence
Constructor and Description |
---|
AssetTagLocalServiceImpl() |
Modifier and Type | Method and Description |
---|---|
com.liferay.asset.kernel.model.AssetTag |
addTag(long userId,
long groupId,
String name,
com.liferay.portal.kernel.service.ServiceContext serviceContext)
Adds an asset tag.
|
protected com.liferay.portal.kernel.search.SearchContext |
buildSearchContext(long companyId,
long[] groupIds,
String name,
int start,
int end,
com.liferay.portal.kernel.search.Sort sort) |
List<com.liferay.asset.kernel.model.AssetTag> |
checkTags(long userId,
com.liferay.portal.kernel.model.Group group,
String[] names)
Returns the asset tags matching the group and names, creating new asset
tags matching the names if the group doesn't already have them.
|
List<com.liferay.asset.kernel.model.AssetTag> |
checkTags(long userId,
long groupId,
String[] names)
Returns the asset tags matching the group and names, creating new asset
tags matching the names if the group doesn't already have them.
|
com.liferay.asset.kernel.model.AssetTag |
decrementAssetCount(long tagId,
long classNameId)
Decrements the number of assets to which the asset tag has been applied.
|
void |
deleteGroupTags(long groupId)
Deletes all asset tags in the group.
|
void |
deleteTag(com.liferay.asset.kernel.model.AssetTag tag)
Deletes the asset tag.
|
void |
deleteTag(long tagId)
Deletes the asset tag.
|
com.liferay.asset.kernel.model.AssetTag |
fetchTag(long groupId,
String name)
Returns the asset tag with the name in the group.
|
List<com.liferay.asset.kernel.model.AssetTag> |
getEntryTags(long entryId)
Returns the asset tags of the asset entry.
|
List<com.liferay.asset.kernel.model.AssetTag> |
getGroupsTags(long[] groupIds)
Returns the asset tags in the groups.
|
List<com.liferay.asset.kernel.model.AssetTag> |
getGroupTags(long groupId)
Returns the asset tags in the group.
|
List<com.liferay.asset.kernel.model.AssetTag> |
getGroupTags(long groupId,
int start,
int end)
Returns a range of all the asset tags in the group.
|
int |
getGroupTagsCount(long groupId)
Returns the number of asset tags in the group.
|
List<com.liferay.asset.kernel.model.AssetTag> |
getSocialActivityCounterOffsetTags(long groupId,
String socialActivityCounterName,
int startOffset,
int endOffset) |
List<com.liferay.asset.kernel.model.AssetTag> |
getSocialActivityCounterPeriodTags(long groupId,
String socialActivityCounterName,
int startPeriod,
int endPeriod) |
com.liferay.asset.kernel.model.AssetTag |
getTag(long tagId)
Returns the asset tag with the primary key.
|
com.liferay.asset.kernel.model.AssetTag |
getTag(long groupId,
String name)
Returns the asset tag with the name in the group.
|
long[] |
getTagIds(long[] groupIds,
String name)
Returns the primary keys of the asset tags with the name in the groups.
|
long[] |
getTagIds(long[] groupIds,
String[] names)
Returns the primary keys of the asset tags with the names in the groups.
|
long[] |
getTagIds(long groupId,
String[] names)
Returns the primary keys of the asset tags with the names in the group.
|
long[] |
getTagIds(String name)
Returns the primary keys of the asset tags with the names.
|
String[] |
getTagNames()
Returns the names of all the asset tags.
|
protected String[] |
getTagNames(List<com.liferay.asset.kernel.model.AssetTag> tags) |
String[] |
getTagNames(long classNameId,
long classPK)
Returns the names of the asset tags of the entity.
|
String[] |
getTagNames(String className,
long classPK)
Returns the names of the asset tags of the entity
|
List<com.liferay.asset.kernel.model.AssetTag> |
getTags()
Returns all the asset tags.
|
protected List<com.liferay.asset.kernel.model.AssetTag> |
getTags(com.liferay.portal.kernel.search.Hits hits) |
List<com.liferay.asset.kernel.model.AssetTag> |
getTags(long classNameId,
long classPK)
Returns the asset tags of the entity.
|
List<com.liferay.asset.kernel.model.AssetTag> |
getTags(long groupId,
long classNameId,
String name) |
List<com.liferay.asset.kernel.model.AssetTag> |
getTags(long groupId,
long classNameId,
String name,
int start,
int end) |
List<com.liferay.asset.kernel.model.AssetTag> |
getTags(String className,
long classPK)
Returns the asset tags of the entity.
|
int |
getTagsSize(long groupId,
long classNameId,
String name) |
int |
getTagsSize(long groupId,
String name) |
boolean |
hasTag(long groupId,
String name)
Returns
true if the group contains an asset tag with the
name. |
com.liferay.asset.kernel.model.AssetTag |
incrementAssetCount(long tagId,
long classNameId)
Increments the number of assets to which the asset tag has been applied.
|
void |
mergeTags(long fromTagId,
long toTagId)
Replaces all occurrences of the first asset tag with the second asset tag
and deletes the first asset tag.
|
List<com.liferay.asset.kernel.model.AssetTag> |
search(long[] groupIds,
String name,
int start,
int end)
Returns the asset tags in the groups whose names match the pattern.
|
List<com.liferay.asset.kernel.model.AssetTag> |
search(long groupId,
String name,
int start,
int end)
Returns the asset tags in the group whose names match the pattern.
|
com.liferay.portal.kernel.search.BaseModelSearchResult<com.liferay.asset.kernel.model.AssetTag> |
searchTags(long[] groupIds,
String name,
int start,
int end,
com.liferay.portal.kernel.search.Sort sort) |
protected com.liferay.portal.kernel.search.BaseModelSearchResult<com.liferay.asset.kernel.model.AssetTag> |
searchTags(com.liferay.portal.kernel.search.SearchContext searchContext) |
com.liferay.asset.kernel.model.AssetTag |
updateTag(long userId,
long tagId,
String name,
com.liferay.portal.kernel.service.ServiceContext serviceContext) |
protected void |
validate(String name) |
addAssetEntryAssetTag, addAssetEntryAssetTag, addAssetEntryAssetTags, addAssetEntryAssetTags, addAssetTag, afterPropertiesSet, clearAssetEntryAssetTags, createAssetTag, deleteAssetEntryAssetTag, deleteAssetEntryAssetTag, deleteAssetEntryAssetTags, deleteAssetEntryAssetTags, deleteAssetTag, deleteAssetTag, deletePersistedModel, destroy, dynamicQuery, dynamicQuery, dynamicQuery, dynamicQuery, dynamicQueryCount, dynamicQueryCount, fetchAssetTag, fetchAssetTagByUuidAndGroupId, getActionableDynamicQuery, getAssetEntryAssetTags, getAssetEntryAssetTags, getAssetEntryAssetTags, getAssetEntryAssetTagsCount, getAssetEntryFinder, getAssetEntryLocalService, getAssetEntryPersistence, getAssetEntryPrimaryKeys, getAssetTag, getAssetTagByUuidAndGroupId, getAssetTagFinder, getAssetTagLocalService, getAssetTagPersistence, getAssetTags, getAssetTagsByUuidAndCompanyId, getAssetTagsByUuidAndCompanyId, getAssetTagsCount, getClassNameLocalService, getClassNamePersistence, getCounterLocalService, getExportActionableDynamicQuery, getGroupFinder, getGroupLocalService, getGroupPersistence, getIndexableActionableDynamicQuery, getModelClass, getModelClassName, getOSGiServiceIdentifier, getPersistedModel, getUserFinder, getUserLocalService, getUserPersistence, hasAssetEntryAssetTag, hasAssetEntryAssetTags, initActionableDynamicQuery, runSQL, setAssetEntryAssetTags, setAssetEntryFinder, setAssetEntryLocalService, setAssetEntryPersistence, setAssetTagFinder, setAssetTagLocalService, setAssetTagPersistence, setClassNameLocalService, setClassNamePersistence, setCounterLocalService, setGroupFinder, setGroupLocalService, setGroupPersistence, setUserFinder, setUserLocalService, setUserPersistence, updateAssetTag
@Indexable(type=REINDEX) public com.liferay.asset.kernel.model.AssetTag addTag(long userId, long groupId, String name, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException
userId
- the primary key of the user adding the asset taggroupId
- the primary key of the group in which the asset tag is to
be addedname
- the asset tag's nameserviceContext
- the service context to be appliedcom.liferay.portal.kernel.exception.PortalException
public List<com.liferay.asset.kernel.model.AssetTag> checkTags(long userId, com.liferay.portal.kernel.model.Group group, String[] names) throws com.liferay.portal.kernel.exception.PortalException
For each name, if an asset tag with the name doesn't already exist in the group, this method creates a new asset tag with the name in the group.
userId
- the primary key of the user checking the asset tagsgroup
- the group in which to check the asset tagsnames
- the asset tag namescom.liferay.portal.kernel.exception.PortalException
public List<com.liferay.asset.kernel.model.AssetTag> checkTags(long userId, long groupId, String[] names) throws com.liferay.portal.kernel.exception.PortalException
userId
- the primary key of the user checking the asset tagsgroupId
- the primary key of the group in which check the asset
tagsnames
- the asset tag namescom.liferay.portal.kernel.exception.PortalException
@Indexable(type=REINDEX) public com.liferay.asset.kernel.model.AssetTag decrementAssetCount(long tagId, long classNameId) throws com.liferay.portal.kernel.exception.PortalException
tagId
- the primary key of the asset tagclassNameId
- the class name ID of the entity to which the asset
tag had been appliedcom.liferay.portal.kernel.exception.PortalException
public void deleteGroupTags(long groupId) throws com.liferay.portal.kernel.exception.PortalException
groupId
- the primary key of the group in which to delete all asset
tagscom.liferay.portal.kernel.exception.PortalException
@SystemEvent(type=1) public void deleteTag(com.liferay.asset.kernel.model.AssetTag tag) throws com.liferay.portal.kernel.exception.PortalException
tag
- the asset tag to be deletedcom.liferay.portal.kernel.exception.PortalException
public void deleteTag(long tagId) throws com.liferay.portal.kernel.exception.PortalException
tagId
- the primary key of the asset tagcom.liferay.portal.kernel.exception.PortalException
public com.liferay.asset.kernel.model.AssetTag fetchTag(long groupId, String name)
groupId
- the primary key of the groupname
- the asset tag's namenull
if
it could not be foundpublic List<com.liferay.asset.kernel.model.AssetTag> getEntryTags(long entryId)
entryId
- the primary key of the asset entrypublic List<com.liferay.asset.kernel.model.AssetTag> getGroupsTags(long[] groupIds)
groupIds
- the primary keys of the groupspublic List<com.liferay.asset.kernel.model.AssetTag> getGroupTags(long groupId)
groupId
- the primary key of the grouppublic List<com.liferay.asset.kernel.model.AssetTag> getGroupTags(long groupId, int start, int end)
groupId
- the primary key of the groupstart
- the lower bound of the range of asset tagsend
- the upper bound of the range of asset tags (not inclusive)public int getGroupTagsCount(long groupId)
groupId
- the primary key of the grouppublic List<com.liferay.asset.kernel.model.AssetTag> getSocialActivityCounterOffsetTags(long groupId, String socialActivityCounterName, int startOffset, int endOffset)
public List<com.liferay.asset.kernel.model.AssetTag> getSocialActivityCounterPeriodTags(long groupId, String socialActivityCounterName, int startPeriod, int endPeriod)
public com.liferay.asset.kernel.model.AssetTag getTag(long tagId) throws com.liferay.portal.kernel.exception.PortalException
tagId
- the primary key of the asset tagcom.liferay.portal.kernel.exception.PortalException
public com.liferay.asset.kernel.model.AssetTag getTag(long groupId, String name) throws com.liferay.portal.kernel.exception.PortalException
groupId
- the primary key of the groupname
- the name of the asset tagcom.liferay.portal.kernel.exception.PortalException
public long[] getTagIds(long groupId, String[] names)
groupId
- the primary key of the groupnames
- the names of the asset tagspublic long[] getTagIds(long[] groupIds, String name)
groupIds
- the primary keys of the groupsname
- the name of the asset tagspublic long[] getTagIds(long[] groupIds, String[] names)
groupIds
- the primary keys of the groupsnames
- the names of the asset tagspublic long[] getTagIds(String name)
name
- the name of the asset tagspublic String[] getTagNames()
public String[] getTagNames(long classNameId, long classPK)
classNameId
- the class name ID of the entityclassPK
- the primary key of the entitypublic String[] getTagNames(String className, long classPK)
className
- the class name of the entityclassPK
- the primary key of the entitypublic List<com.liferay.asset.kernel.model.AssetTag> getTags()
public List<com.liferay.asset.kernel.model.AssetTag> getTags(long classNameId, long classPK)
classNameId
- the class name ID of the entityclassPK
- the primary key of the entitypublic List<com.liferay.asset.kernel.model.AssetTag> getTags(long groupId, long classNameId, String name)
public List<com.liferay.asset.kernel.model.AssetTag> getTags(long groupId, long classNameId, String name, int start, int end)
@ThreadLocalCachable public List<com.liferay.asset.kernel.model.AssetTag> getTags(String className, long classPK)
className
- the class name of the entityclassPK
- the primary key of the entitypublic int getTagsSize(long groupId, long classNameId, String name)
public int getTagsSize(long groupId, String name)
public boolean hasTag(long groupId, String name)
true
if the group contains an asset tag with the
name.groupId
- the primary key of the groupname
- the name of the asset tagtrue
if the group contains an asset tag with the
name; false
otherwise.@Indexable(type=REINDEX) public com.liferay.asset.kernel.model.AssetTag incrementAssetCount(long tagId, long classNameId) throws com.liferay.portal.kernel.exception.PortalException
tagId
- the primary key of the asset tagclassNameId
- the class name ID of the entity to which the asset
tag is being appliedcom.liferay.portal.kernel.exception.PortalException
public void mergeTags(long fromTagId, long toTagId) throws com.liferay.portal.kernel.exception.PortalException
fromTagId
- the primary key of the asset tag to be replacedtoTagId
- the primary key of the asset tag to apply to the asset
entries of the other asset tagcom.liferay.portal.kernel.exception.PortalException
public List<com.liferay.asset.kernel.model.AssetTag> search(long groupId, String name, int start, int end)
groupId
- the primary key of the groupname
- the pattern to matchstart
- the lower bound of the range of asset tagsend
- the upper bound of the range of asset tags (not inclusive)public List<com.liferay.asset.kernel.model.AssetTag> search(long[] groupIds, String name, int start, int end)
groupIds
- the primary keys of the groupsname
- the pattern to matchstart
- the lower bound of the range of asset tagsend
- the upper bound of the range of asset tags (not inclusive)public com.liferay.portal.kernel.search.BaseModelSearchResult<com.liferay.asset.kernel.model.AssetTag> searchTags(long[] groupIds, String name, int start, int end, com.liferay.portal.kernel.search.Sort sort) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
@Indexable(type=REINDEX) public com.liferay.asset.kernel.model.AssetTag updateTag(long userId, long tagId, String name, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected com.liferay.portal.kernel.search.SearchContext buildSearchContext(long companyId, long[] groupIds, String name, int start, int end, com.liferay.portal.kernel.search.Sort sort)
protected String[] getTagNames(List<com.liferay.asset.kernel.model.AssetTag> tags)
protected List<com.liferay.asset.kernel.model.AssetTag> getTags(com.liferay.portal.kernel.search.Hits hits) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected com.liferay.portal.kernel.search.BaseModelSearchResult<com.liferay.asset.kernel.model.AssetTag> searchTags(com.liferay.portal.kernel.search.SearchContext searchContext) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException
protected void validate(String name) throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalException