@ProviderType
public class AssetCategoryLocalServiceUtil
extends Object
AssetCategoryLocalServiceImpl
and is the
primary access point for service operations in application layer code running
on the local server. Methods of this service will not have security checks
based on the propagated JAAS credentials because this service can only be
accessed from within the same VM.AssetCategoryLocalService
,
AssetCategoryLocalServiceBaseImpl
,
AssetCategoryLocalServiceImpl
Constructor and Description |
---|
AssetCategoryLocalServiceUtil() |
Modifier and Type | Method and Description |
---|---|
static AssetCategory |
addAssetCategory(AssetCategory assetCategory)
Adds the asset category to the database.
|
static void |
addAssetEntryAssetCategories(long entryId,
List<AssetCategory> assetCategories) |
static void |
addAssetEntryAssetCategories(long entryId,
long[] categoryIds) |
static void |
addAssetEntryAssetCategory(long entryId,
AssetCategory assetCategory) |
static void |
addAssetEntryAssetCategory(long entryId,
long categoryId) |
static AssetCategory |
addCategory(long userId,
long groupId,
long parentCategoryId,
Map<Locale,String> titleMap,
Map<Locale,String> descriptionMap,
long vocabularyId,
String[] categoryProperties,
ServiceContext serviceContext) |
static AssetCategory |
addCategory(long userId,
long groupId,
String title,
long vocabularyId,
ServiceContext serviceContext) |
static void |
addCategoryResources(AssetCategory category,
boolean addGroupPermissions,
boolean addGuestPermissions) |
static void |
addCategoryResources(AssetCategory category,
ModelPermissions modelPermissions) |
static void |
clearAssetEntryAssetCategories(long entryId) |
static AssetCategory |
createAssetCategory(long categoryId)
Creates a new asset category with the primary key.
|
static AssetCategory |
deleteAssetCategory(AssetCategory assetCategory)
Deletes the asset category from the database.
|
static AssetCategory |
deleteAssetCategory(long categoryId)
Deletes the asset category with the primary key from the database.
|
static void |
deleteAssetEntryAssetCategories(long entryId,
List<AssetCategory> assetCategories) |
static void |
deleteAssetEntryAssetCategories(long entryId,
long[] categoryIds) |
static void |
deleteAssetEntryAssetCategory(long entryId,
AssetCategory assetCategory) |
static void |
deleteAssetEntryAssetCategory(long entryId,
long categoryId) |
static void |
deleteCategories(List<AssetCategory> categories) |
static void |
deleteCategories(long[] categoryIds) |
static AssetCategory |
deleteCategory(AssetCategory category) |
static AssetCategory |
deleteCategory(AssetCategory category,
boolean skipRebuildTree) |
static AssetCategory |
deleteCategory(long categoryId) |
static PersistedModel |
deletePersistedModel(PersistedModel persistedModel) |
static void |
deleteVocabularyCategories(long vocabularyId) |
static DynamicQuery |
dynamicQuery() |
static <T> List<T> |
dynamicQuery(DynamicQuery dynamicQuery)
Performs a dynamic query on the database and returns the matching rows.
|
static <T> List<T> |
dynamicQuery(DynamicQuery dynamicQuery,
int start,
int end)
Performs a dynamic query on the database and returns a range of the matching rows.
|
static <T> List<T> |
dynamicQuery(DynamicQuery dynamicQuery,
int start,
int end,
OrderByComparator<T> orderByComparator)
Performs a dynamic query on the database and returns an ordered range of the matching rows.
|
static long |
dynamicQueryCount(DynamicQuery dynamicQuery)
Returns the number of rows matching the dynamic query.
|
static long |
dynamicQueryCount(DynamicQuery dynamicQuery,
Projection projection)
Returns the number of rows matching the dynamic query.
|
static AssetCategory |
fetchAssetCategory(long categoryId) |
static AssetCategory |
fetchAssetCategoryByReferenceCode(long companyId,
String externalReferenceCode)
Returns the asset category with the matching external reference code and company.
|
static AssetCategory |
fetchAssetCategoryByUuidAndGroupId(String uuid,
long groupId)
Returns the asset category matching the UUID and group.
|
static AssetCategory |
fetchCategory(long categoryId) |
static AssetCategory |
fetchCategory(long groupId,
long parentCategoryId,
String name,
long vocabularyId) |
static ActionableDynamicQuery |
getActionableDynamicQuery() |
static List<AssetCategory> |
getAssetCategories(int start,
int end)
Returns a range of all the asset categories.
|
static List<AssetCategory> |
getAssetCategoriesByUuidAndCompanyId(String uuid,
long companyId)
Returns all the asset categories matching the UUID and company.
|
static List<AssetCategory> |
getAssetCategoriesByUuidAndCompanyId(String uuid,
long companyId,
int start,
int end,
OrderByComparator<AssetCategory> orderByComparator)
Returns a range of asset categories matching the UUID and company.
|
static int |
getAssetCategoriesCount()
Returns the number of asset categories.
|
static AssetCategory |
getAssetCategory(long categoryId)
Returns the asset category with the primary key.
|
static AssetCategory |
getAssetCategoryByUuidAndGroupId(String uuid,
long groupId)
Returns the asset category matching the UUID and group.
|
static List<AssetCategory> |
getAssetEntryAssetCategories(long entryId) |
static List<AssetCategory> |
getAssetEntryAssetCategories(long entryId,
int start,
int end) |
static List<AssetCategory> |
getAssetEntryAssetCategories(long entryId,
int start,
int end,
OrderByComparator<AssetCategory> orderByComparator) |
static int |
getAssetEntryAssetCategoriesCount(long entryId) |
static long[] |
getAssetEntryPrimaryKeys(long categoryId)
Returns the entryIds of the asset entries associated with the asset category.
|
static List<AssetCategory> |
getCategories() |
static List<AssetCategory> |
getCategories(Hits hits) |
static List<AssetCategory> |
getCategories(long classNameId,
long classPK) |
static List<AssetCategory> |
getCategories(String className,
long classPK) |
static AssetCategory |
getCategory(long categoryId) |
static AssetCategory |
getCategory(String uuid,
long groupId) |
static long[] |
getCategoryIds(String className,
long classPK) |
static String[] |
getCategoryNames() |
static String[] |
getCategoryNames(long classNameId,
long classPK) |
static String[] |
getCategoryNames(String className,
long classPK) |
static List<AssetCategory> |
getChildCategories(long parentCategoryId) |
static List<AssetCategory> |
getChildCategories(long parentCategoryId,
int start,
int end,
OrderByComparator<AssetCategory> obc) |
static int |
getChildCategoriesCount(long parentCategoryId) |
static List<AssetCategory> |
getDescendantCategories(AssetCategory category) |
static List<AssetCategory> |
getEntryCategories(long entryId) |
static ExportActionableDynamicQuery |
getExportActionableDynamicQuery(PortletDataContext portletDataContext) |
static IndexableActionableDynamicQuery |
getIndexableActionableDynamicQuery() |
static String |
getOSGiServiceIdentifier()
Returns the OSGi service identifier.
|
static PersistedModel |
getPersistedModel(Serializable primaryKeyObj) |
static AssetCategoryLocalService |
getService() |
static List<Long> |
getSubcategoryIds(long parentCategoryId) |
static long[] |
getViewableCategoryIds(String className,
long classPK,
long[] categoryIds) |
static List<AssetCategory> |
getVocabularyCategories(long vocabularyId,
int start,
int end,
OrderByComparator<AssetCategory> obc) |
static List<AssetCategory> |
getVocabularyCategories(long parentCategoryId,
long vocabularyId,
int start,
int end,
OrderByComparator<AssetCategory> obc) |
static int |
getVocabularyCategoriesCount(long vocabularyId) |
static List<AssetCategory> |
getVocabularyRootCategories(long vocabularyId,
int start,
int end,
OrderByComparator<AssetCategory> obc) |
static int |
getVocabularyRootCategoriesCount(long vocabularyId) |
static boolean |
hasAssetEntryAssetCategories(long entryId) |
static boolean |
hasAssetEntryAssetCategory(long entryId,
long categoryId) |
static AssetCategory |
mergeCategories(long fromCategoryId,
long toCategoryId) |
static AssetCategory |
moveCategory(long categoryId,
long parentCategoryId,
long vocabularyId,
ServiceContext serviceContext) |
static void |
rebuildTree(long groupId,
boolean force) |
static List<AssetCategory> |
search(long groupId,
String name,
String[] categoryProperties,
int start,
int end) |
static BaseModelSearchResult<AssetCategory> |
searchCategories(long companyId,
long[] groupIds,
String title,
long[] vocabularyIds,
int start,
int end) |
static BaseModelSearchResult<AssetCategory> |
searchCategories(long companyId,
long[] groupIds,
String title,
long[] parentCategoryIds,
long[] vocabularyIds,
int start,
int end) |
static BaseModelSearchResult<AssetCategory> |
searchCategories(long companyId,
long[] groupIds,
String title,
long[] vocabularyIds,
long[] parentCategoryIds,
int start,
int end,
Sort sort) |
static BaseModelSearchResult<AssetCategory> |
searchCategories(long companyId,
long groupIds,
String title,
long vocabularyId,
int start,
int end) |
static void |
setAssetEntryAssetCategories(long entryId,
long[] categoryIds) |
static AssetCategory |
updateAssetCategory(AssetCategory assetCategory)
Updates the asset category in the database or adds it if it does not yet exist.
|
static AssetCategory |
updateCategory(long userId,
long categoryId,
long parentCategoryId,
Map<Locale,String> titleMap,
Map<Locale,String> descriptionMap,
long vocabularyId,
String[] categoryProperties,
ServiceContext serviceContext) |
public static AssetCategory addAssetCategory(AssetCategory assetCategory)
assetCategory
- the asset categorypublic static void addAssetEntryAssetCategories(long entryId, List<AssetCategory> assetCategories)
public static void addAssetEntryAssetCategories(long entryId, long[] categoryIds)
public static void addAssetEntryAssetCategory(long entryId, AssetCategory assetCategory)
public static void addAssetEntryAssetCategory(long entryId, long categoryId)
public static AssetCategory addCategory(long userId, long groupId, long parentCategoryId, Map<Locale,String> titleMap, Map<Locale,String> descriptionMap, long vocabularyId, String[] categoryProperties, ServiceContext serviceContext) throws PortalException
PortalException
public static AssetCategory addCategory(long userId, long groupId, String title, long vocabularyId, ServiceContext serviceContext) throws PortalException
PortalException
public static void addCategoryResources(AssetCategory category, boolean addGroupPermissions, boolean addGuestPermissions) throws PortalException
PortalException
public static void addCategoryResources(AssetCategory category, ModelPermissions modelPermissions) throws PortalException
PortalException
public static void clearAssetEntryAssetCategories(long entryId)
public static AssetCategory createAssetCategory(long categoryId)
categoryId
- the primary key for the new asset categorypublic static AssetCategory deleteAssetCategory(AssetCategory assetCategory)
assetCategory
- the asset categorypublic static AssetCategory deleteAssetCategory(long categoryId) throws PortalException
categoryId
- the primary key of the asset categoryPortalException
- if a asset category with the primary key could not be foundpublic static void deleteAssetEntryAssetCategories(long entryId, List<AssetCategory> assetCategories)
public static void deleteAssetEntryAssetCategories(long entryId, long[] categoryIds)
public static void deleteAssetEntryAssetCategory(long entryId, AssetCategory assetCategory)
public static void deleteAssetEntryAssetCategory(long entryId, long categoryId)
public static void deleteCategories(List<AssetCategory> categories) throws PortalException
PortalException
public static void deleteCategories(long[] categoryIds) throws PortalException
PortalException
public static AssetCategory deleteCategory(AssetCategory category) throws PortalException
PortalException
public static AssetCategory deleteCategory(AssetCategory category, boolean skipRebuildTree) throws PortalException
PortalException
public static AssetCategory deleteCategory(long categoryId) throws PortalException
PortalException
public static PersistedModel deletePersistedModel(PersistedModel persistedModel) throws PortalException
PortalException
public static void deleteVocabularyCategories(long vocabularyId) throws PortalException
PortalException
public static DynamicQuery dynamicQuery()
public static <T> List<T> dynamicQuery(DynamicQuery dynamicQuery)
dynamicQuery
- the dynamic querypublic static <T> List<T> dynamicQuery(DynamicQuery dynamicQuery, int start, int end)
Useful when paginating results. Returns a maximum of end - start
instances. start
and end
are not primary keys, they are indexes in the result set. Thus, 0
refers to the first result in the set. Setting both start
and end
to QueryUtil.ALL_POS
will return the full result set. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil.ALL_POS
), then the query will include the default ORDER BY logic from AssetCategoryModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
dynamicQuery
- the dynamic querystart
- the lower bound of the range of model instancesend
- the upper bound of the range of model instances (not inclusive)public static <T> List<T> dynamicQuery(DynamicQuery dynamicQuery, int start, int end, OrderByComparator<T> orderByComparator)
Useful when paginating results. Returns a maximum of end - start
instances. start
and end
are not primary keys, they are indexes in the result set. Thus, 0
refers to the first result in the set. Setting both start
and end
to QueryUtil.ALL_POS
will return the full result set. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil.ALL_POS
), then the query will include the default ORDER BY logic from AssetCategoryModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
dynamicQuery
- the dynamic querystart
- the lower bound of the range of model instancesend
- the upper bound of the range of model instances (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)public static long dynamicQueryCount(DynamicQuery dynamicQuery)
dynamicQuery
- the dynamic querypublic static long dynamicQueryCount(DynamicQuery dynamicQuery, Projection projection)
dynamicQuery
- the dynamic queryprojection
- the projection to apply to the querypublic static AssetCategory fetchAssetCategory(long categoryId)
public static AssetCategory fetchAssetCategoryByReferenceCode(long companyId, String externalReferenceCode)
companyId
- the primary key of the companyexternalReferenceCode
- the asset category's external reference codenull
if a matching asset category could not be foundpublic static AssetCategory fetchAssetCategoryByUuidAndGroupId(String uuid, long groupId)
uuid
- the asset category's UUIDgroupId
- the primary key of the groupnull
if a matching asset category could not be foundpublic static AssetCategory fetchCategory(long categoryId)
public static AssetCategory fetchCategory(long groupId, long parentCategoryId, String name, long vocabularyId)
public static ActionableDynamicQuery getActionableDynamicQuery()
public static List<AssetCategory> getAssetCategories(int start, int end)
Useful when paginating results. Returns a maximum of end - start
instances. start
and end
are not primary keys, they are indexes in the result set. Thus, 0
refers to the first result in the set. Setting both start
and end
to QueryUtil.ALL_POS
will return the full result set. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil.ALL_POS
), then the query will include the default ORDER BY logic from AssetCategoryModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
start
- the lower bound of the range of asset categoriesend
- the upper bound of the range of asset categories (not inclusive)public static List<AssetCategory> getAssetCategoriesByUuidAndCompanyId(String uuid, long companyId)
uuid
- the UUID of the asset categoriescompanyId
- the primary key of the companypublic static List<AssetCategory> getAssetCategoriesByUuidAndCompanyId(String uuid, long companyId, int start, int end, OrderByComparator<AssetCategory> orderByComparator)
uuid
- the UUID of the asset categoriescompanyId
- the primary key of the companystart
- the lower bound of the range of asset categoriesend
- the upper bound of the range of asset categories (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)public static int getAssetCategoriesCount()
public static AssetCategory getAssetCategory(long categoryId) throws PortalException
categoryId
- the primary key of the asset categoryPortalException
- if a asset category with the primary key could not be foundpublic static AssetCategory getAssetCategoryByUuidAndGroupId(String uuid, long groupId) throws PortalException
uuid
- the asset category's UUIDgroupId
- the primary key of the groupPortalException
- if a matching asset category could not be foundpublic static List<AssetCategory> getAssetEntryAssetCategories(long entryId)
public static List<AssetCategory> getAssetEntryAssetCategories(long entryId, int start, int end)
public static List<AssetCategory> getAssetEntryAssetCategories(long entryId, int start, int end, OrderByComparator<AssetCategory> orderByComparator)
public static int getAssetEntryAssetCategoriesCount(long entryId)
public static long[] getAssetEntryPrimaryKeys(long categoryId)
categoryId
- the categoryId of the asset categorypublic static List<AssetCategory> getCategories()
public static List<AssetCategory> getCategories(Hits hits) throws PortalException
PortalException
public static List<AssetCategory> getCategories(long classNameId, long classPK)
public static List<AssetCategory> getCategories(String className, long classPK)
public static AssetCategory getCategory(long categoryId) throws PortalException
PortalException
public static AssetCategory getCategory(String uuid, long groupId) throws PortalException
PortalException
public static long[] getCategoryIds(String className, long classPK)
public static String[] getCategoryNames()
public static String[] getCategoryNames(long classNameId, long classPK)
public static String[] getCategoryNames(String className, long classPK)
public static List<AssetCategory> getChildCategories(long parentCategoryId)
public static List<AssetCategory> getChildCategories(long parentCategoryId, int start, int end, OrderByComparator<AssetCategory> obc)
public static int getChildCategoriesCount(long parentCategoryId)
public static List<AssetCategory> getDescendantCategories(AssetCategory category)
public static List<AssetCategory> getEntryCategories(long entryId)
public static ExportActionableDynamicQuery getExportActionableDynamicQuery(PortletDataContext portletDataContext)
public static IndexableActionableDynamicQuery getIndexableActionableDynamicQuery()
public static String getOSGiServiceIdentifier()
public static PersistedModel getPersistedModel(Serializable primaryKeyObj) throws PortalException
PortalException
public static List<Long> getSubcategoryIds(long parentCategoryId)
public static long[] getViewableCategoryIds(String className, long classPK, long[] categoryIds) throws PortalException
PortalException
public static List<AssetCategory> getVocabularyCategories(long vocabularyId, int start, int end, OrderByComparator<AssetCategory> obc)
public static List<AssetCategory> getVocabularyCategories(long parentCategoryId, long vocabularyId, int start, int end, OrderByComparator<AssetCategory> obc)
public static int getVocabularyCategoriesCount(long vocabularyId)
public static List<AssetCategory> getVocabularyRootCategories(long vocabularyId, int start, int end, OrderByComparator<AssetCategory> obc)
public static int getVocabularyRootCategoriesCount(long vocabularyId)
public static boolean hasAssetEntryAssetCategories(long entryId)
public static boolean hasAssetEntryAssetCategory(long entryId, long categoryId)
public static AssetCategory mergeCategories(long fromCategoryId, long toCategoryId) throws PortalException
PortalException
public static AssetCategory moveCategory(long categoryId, long parentCategoryId, long vocabularyId, ServiceContext serviceContext) throws PortalException
PortalException
public static void rebuildTree(long groupId, boolean force)
public static List<AssetCategory> search(long groupId, String name, String[] categoryProperties, int start, int end)
public static BaseModelSearchResult<AssetCategory> searchCategories(long companyId, long groupIds, String title, long vocabularyId, int start, int end) throws PortalException
PortalException
public static BaseModelSearchResult<AssetCategory> searchCategories(long companyId, long[] groupIds, String title, long[] vocabularyIds, int start, int end) throws PortalException
PortalException
public static BaseModelSearchResult<AssetCategory> searchCategories(long companyId, long[] groupIds, String title, long[] parentCategoryIds, long[] vocabularyIds, int start, int end) throws PortalException
PortalException
public static BaseModelSearchResult<AssetCategory> searchCategories(long companyId, long[] groupIds, String title, long[] vocabularyIds, long[] parentCategoryIds, int start, int end, Sort sort) throws PortalException
PortalException
public static void setAssetEntryAssetCategories(long entryId, long[] categoryIds)
public static AssetCategory updateAssetCategory(AssetCategory assetCategory)
assetCategory
- the asset categorypublic static AssetCategory updateCategory(long userId, long categoryId, long parentCategoryId, Map<Locale,String> titleMap, Map<Locale,String> descriptionMap, long vocabularyId, String[] categoryProperties, ServiceContext serviceContext) throws PortalException
PortalException
public static AssetCategoryLocalService getService()