001
014
015 package com.liferay.portal.service;
016
017 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018 import com.liferay.portal.kernel.util.ReferenceRegistry;
019
020
033 public class RepositoryServiceUtil {
034
039
040
045 public static java.lang.String getBeanIdentifier() {
046 return getService().getBeanIdentifier();
047 }
048
049
054 public static void setBeanIdentifier(java.lang.String beanIdentifier) {
055 getService().setBeanIdentifier(beanIdentifier);
056 }
057
058 public static com.liferay.portal.model.Repository addRepository(
059 long groupId, long classNameId, long parentFolderId,
060 java.lang.String name, java.lang.String description,
061 java.lang.String portletId,
062 com.liferay.portal.kernel.util.UnicodeProperties typeSettingsProperties,
063 com.liferay.portal.service.ServiceContext serviceContext)
064 throws com.liferay.portal.kernel.exception.PortalException,
065 com.liferay.portal.kernel.exception.SystemException {
066 return getService()
067 .addRepository(groupId, classNameId, parentFolderId, name,
068 description, portletId, typeSettingsProperties, serviceContext);
069 }
070
071 public static void checkRepository(long repositoryId)
072 throws com.liferay.portal.kernel.exception.PortalException,
073 com.liferay.portal.kernel.exception.SystemException {
074 getService().checkRepository(repositoryId);
075 }
076
077 public static void deleteRepository(long repositoryId)
078 throws com.liferay.portal.kernel.exception.PortalException,
079 com.liferay.portal.kernel.exception.SystemException {
080 getService().deleteRepository(repositoryId);
081 }
082
083 public static com.liferay.portal.kernel.repository.LocalRepository getLocalRepositoryImpl(
084 long repositoryId)
085 throws com.liferay.portal.kernel.exception.PortalException,
086 com.liferay.portal.kernel.exception.SystemException {
087 return getService().getLocalRepositoryImpl(repositoryId);
088 }
089
090 public static com.liferay.portal.kernel.repository.LocalRepository getLocalRepositoryImpl(
091 long folderId, long fileEntryId, long fileVersionId)
092 throws com.liferay.portal.kernel.exception.PortalException,
093 com.liferay.portal.kernel.exception.SystemException {
094 return getService()
095 .getLocalRepositoryImpl(folderId, fileEntryId, fileVersionId);
096 }
097
098 public static com.liferay.portal.model.Repository getRepository(
099 long repositoryId)
100 throws com.liferay.portal.kernel.exception.PortalException,
101 com.liferay.portal.kernel.exception.SystemException {
102 return getService().getRepository(repositoryId);
103 }
104
105 public static com.liferay.portal.kernel.repository.Repository getRepositoryImpl(
106 long repositoryId)
107 throws com.liferay.portal.kernel.exception.PortalException,
108 com.liferay.portal.kernel.exception.SystemException {
109 return getService().getRepositoryImpl(repositoryId);
110 }
111
112 public static com.liferay.portal.kernel.repository.Repository getRepositoryImpl(
113 long folderId, long fileEntryId, long fileVersionId)
114 throws com.liferay.portal.kernel.exception.PortalException,
115 com.liferay.portal.kernel.exception.SystemException {
116 return getService()
117 .getRepositoryImpl(folderId, fileEntryId, fileVersionId);
118 }
119
120 public static java.lang.String[] getSupportedConfigurations(
121 long classNameId)
122 throws com.liferay.portal.kernel.exception.SystemException {
123 return getService().getSupportedConfigurations(classNameId);
124 }
125
126 public static java.lang.String[] getSupportedParameters(long classNameId,
127 java.lang.String configuration)
128 throws com.liferay.portal.kernel.exception.SystemException {
129 return getService().getSupportedParameters(classNameId, configuration);
130 }
131
132 public static com.liferay.portal.kernel.util.UnicodeProperties getTypeSettingsProperties(
133 long repositoryId)
134 throws com.liferay.portal.kernel.exception.PortalException,
135 com.liferay.portal.kernel.exception.SystemException {
136 return getService().getTypeSettingsProperties(repositoryId);
137 }
138
139 public static void updateRepository(long repositoryId,
140 java.lang.String name, java.lang.String description)
141 throws com.liferay.portal.kernel.exception.PortalException,
142 com.liferay.portal.kernel.exception.SystemException {
143 getService().updateRepository(repositoryId, name, description);
144 }
145
146 public static RepositoryService getService() {
147 if (_service == null) {
148 _service = (RepositoryService)PortalBeanLocatorUtil.locate(RepositoryService.class.getName());
149
150 ReferenceRegistry.registerReference(RepositoryServiceUtil.class,
151 "_service");
152 }
153
154 return _service;
155 }
156
157
160 public void setService(RepositoryService service) {
161 }
162
163 private static RepositoryService _service;
164 }