001
014
015 package com.liferay.portlet.documentlibrary.service;
016
017 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018 import com.liferay.portal.kernel.util.MethodCache;
019 import com.liferay.portal.kernel.util.ReferenceRegistry;
020
021
034 public class DLFileEntryTypeServiceUtil {
035
040 public static com.liferay.portlet.documentlibrary.model.DLFileEntryType addFileEntryType(
041 long groupId, java.lang.String name, java.lang.String description,
042 long[] ddmStructureIds,
043 com.liferay.portal.service.ServiceContext serviceContext)
044 throws com.liferay.portal.kernel.exception.PortalException,
045 com.liferay.portal.kernel.exception.SystemException {
046 return getService()
047 .addFileEntryType(groupId, name, description,
048 ddmStructureIds, serviceContext);
049 }
050
051 public static void deleteFileEntryType(long fileEntryTypeId)
052 throws com.liferay.portal.kernel.exception.PortalException,
053 com.liferay.portal.kernel.exception.SystemException {
054 getService().deleteFileEntryType(fileEntryTypeId);
055 }
056
057 public static com.liferay.portlet.documentlibrary.model.DLFileEntryType getFileEntryType(
058 long fileEntryTypeId)
059 throws com.liferay.portal.kernel.exception.PortalException,
060 com.liferay.portal.kernel.exception.SystemException {
061 return getService().getFileEntryType(fileEntryTypeId);
062 }
063
064 public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntryType> getFileEntryTypes(
065 long[] groupIds)
066 throws com.liferay.portal.kernel.exception.SystemException {
067 return getService().getFileEntryTypes(groupIds);
068 }
069
070 public static int getFileEntryTypesCount(long[] groupIds)
071 throws com.liferay.portal.kernel.exception.SystemException {
072 return getService().getFileEntryTypesCount(groupIds);
073 }
074
075 public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntryType> search(
076 long companyId, long[] groupIds, java.lang.String keywords,
077 boolean includeBasicFileEntryType, int start, int end,
078 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
079 throws com.liferay.portal.kernel.exception.SystemException {
080 return getService()
081 .search(companyId, groupIds, keywords,
082 includeBasicFileEntryType, start, end, orderByComparator);
083 }
084
085 public static int searchCount(long companyId, long[] groupIds,
086 java.lang.String keywords, boolean includeBasicFileEntryType)
087 throws com.liferay.portal.kernel.exception.SystemException {
088 return getService()
089 .searchCount(companyId, groupIds, keywords,
090 includeBasicFileEntryType);
091 }
092
093 public static void updateFileEntryType(long fileEntryTypeId,
094 java.lang.String name, java.lang.String description,
095 long[] ddmStructureIds,
096 com.liferay.portal.service.ServiceContext serviceContext)
097 throws com.liferay.portal.kernel.exception.PortalException,
098 com.liferay.portal.kernel.exception.SystemException {
099 getService()
100 .updateFileEntryType(fileEntryTypeId, name, description,
101 ddmStructureIds, serviceContext);
102 }
103
104 public static DLFileEntryTypeService getService() {
105 if (_service == null) {
106 _service = (DLFileEntryTypeService)PortalBeanLocatorUtil.locate(DLFileEntryTypeService.class.getName());
107
108 ReferenceRegistry.registerReference(DLFileEntryTypeServiceUtil.class,
109 "_service");
110 MethodCache.remove(DLFileEntryTypeService.class);
111 }
112
113 return _service;
114 }
115
116 public void setService(DLFileEntryTypeService service) {
117 MethodCache.remove(DLFileEntryTypeService.class);
118
119 _service = service;
120
121 ReferenceRegistry.registerReference(DLFileEntryTypeServiceUtil.class,
122 "_service");
123 MethodCache.remove(DLFileEntryTypeService.class);
124 }
125
126 private static DLFileEntryTypeService _service;
127 }