001
014
015 package com.liferay.portlet.dynamicdatamapping.service;
016
017 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018 import com.liferay.portal.kernel.util.ReferenceRegistry;
019
020
033 public class DDMTemplateServiceUtil {
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.portlet.dynamicdatamapping.model.DDMTemplate addTemplate(
059 long groupId, long structureId,
060 java.util.Map<java.util.Locale, java.lang.String> nameMap,
061 java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
062 java.lang.String type, java.lang.String mode,
063 java.lang.String language, java.lang.String script,
064 com.liferay.portal.service.ServiceContext serviceContext)
065 throws com.liferay.portal.kernel.exception.PortalException,
066 com.liferay.portal.kernel.exception.SystemException {
067 return getService()
068 .addTemplate(groupId, structureId, nameMap, descriptionMap,
069 type, mode, language, script, serviceContext);
070 }
071
072 public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> copyTemplates(
073 long structureId, long newStructureId, java.lang.String type,
074 com.liferay.portal.service.ServiceContext serviceContext)
075 throws com.liferay.portal.kernel.exception.PortalException,
076 com.liferay.portal.kernel.exception.SystemException {
077 return getService()
078 .copyTemplates(structureId, newStructureId, type,
079 serviceContext);
080 }
081
082 public static void deleteTemplate(long templateId)
083 throws com.liferay.portal.kernel.exception.PortalException,
084 com.liferay.portal.kernel.exception.SystemException {
085 getService().deleteTemplate(templateId);
086 }
087
088 public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate getTemplate(
089 long templateId)
090 throws com.liferay.portal.kernel.exception.PortalException,
091 com.liferay.portal.kernel.exception.SystemException {
092 return getService().getTemplate(templateId);
093 }
094
095 public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> getTemplates(
096 long structureId, java.lang.String type, java.lang.String mode)
097 throws com.liferay.portal.kernel.exception.SystemException {
098 return getService().getTemplates(structureId, type, mode);
099 }
100
101 public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> search(
102 long companyId, long groupId, long structureId,
103 java.lang.String keywords, java.lang.String type,
104 java.lang.String mode, int start, int end,
105 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
106 throws com.liferay.portal.kernel.exception.SystemException {
107 return getService()
108 .search(companyId, groupId, structureId, keywords, type,
109 mode, start, end, orderByComparator);
110 }
111
112 public static java.util.List<com.liferay.portlet.dynamicdatamapping.model.DDMTemplate> search(
113 long companyId, long groupId, long structureId, java.lang.String name,
114 java.lang.String description, java.lang.String type,
115 java.lang.String mode, java.lang.String language, boolean andOperator,
116 int start, int end,
117 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
118 throws com.liferay.portal.kernel.exception.SystemException {
119 return getService()
120 .search(companyId, groupId, structureId, name, description,
121 type, mode, language, andOperator, start, end, orderByComparator);
122 }
123
124 public static int searchCount(long companyId, long groupId,
125 long structureId, java.lang.String keywords, java.lang.String type,
126 java.lang.String mode)
127 throws com.liferay.portal.kernel.exception.SystemException {
128 return getService()
129 .searchCount(companyId, groupId, structureId, keywords,
130 type, mode);
131 }
132
133 public static int searchCount(long companyId, long groupId,
134 long structureId, java.lang.String name, java.lang.String description,
135 java.lang.String type, java.lang.String mode,
136 java.lang.String language, boolean andOperator)
137 throws com.liferay.portal.kernel.exception.SystemException {
138 return getService()
139 .searchCount(companyId, groupId, structureId, name,
140 description, type, mode, language, andOperator);
141 }
142
143 public static com.liferay.portlet.dynamicdatamapping.model.DDMTemplate updateTemplate(
144 long templateId,
145 java.util.Map<java.util.Locale, java.lang.String> nameMap,
146 java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
147 java.lang.String type, java.lang.String mode,
148 java.lang.String language, java.lang.String script,
149 com.liferay.portal.service.ServiceContext serviceContext)
150 throws com.liferay.portal.kernel.exception.PortalException,
151 com.liferay.portal.kernel.exception.SystemException {
152 return getService()
153 .updateTemplate(templateId, nameMap, descriptionMap, type,
154 mode, language, script, serviceContext);
155 }
156
157 public static DDMTemplateService getService() {
158 if (_service == null) {
159 _service = (DDMTemplateService)PortalBeanLocatorUtil.locate(DDMTemplateService.class.getName());
160
161 ReferenceRegistry.registerReference(DDMTemplateServiceUtil.class,
162 "_service");
163 }
164
165 return _service;
166 }
167
168
171 public void setService(DDMTemplateService service) {
172 }
173
174 private static DDMTemplateService _service;
175 }