1
22
23 package com.liferay.portal.service;
24
25
26
47 public class LayoutServiceUtil {
48 public static com.liferay.portal.model.Layout addLayout(long groupId,
49 boolean privateLayout, long parentLayoutId, java.lang.String name,
50 java.lang.String title, java.lang.String description,
51 java.lang.String type, boolean hidden, java.lang.String friendlyURL)
52 throws com.liferay.portal.PortalException,
53 com.liferay.portal.SystemException, java.rmi.RemoteException {
54 return getService()
55 .addLayout(groupId, privateLayout, parentLayoutId, name,
56 title, description, type, hidden, friendlyURL);
57 }
58
59 public static com.liferay.portal.model.Layout addLayout(long groupId,
60 boolean privateLayout, long parentLayoutId,
61 java.util.Map<java.util.Locale, String> localeNamesMap,
62 java.util.Map<java.util.Locale, String> localeTitlesMap,
63 java.lang.String description, java.lang.String type, boolean hidden,
64 java.lang.String friendlyURL)
65 throws com.liferay.portal.PortalException,
66 com.liferay.portal.SystemException, java.rmi.RemoteException {
67 return getService()
68 .addLayout(groupId, privateLayout, parentLayoutId,
69 localeNamesMap, localeTitlesMap, description, type, hidden,
70 friendlyURL);
71 }
72
73 public static void deleteLayout(long plid)
74 throws com.liferay.portal.PortalException,
75 com.liferay.portal.SystemException, java.rmi.RemoteException {
76 getService().deleteLayout(plid);
77 }
78
79 public static void deleteLayout(long groupId, boolean privateLayout,
80 long layoutId)
81 throws com.liferay.portal.PortalException,
82 com.liferay.portal.SystemException, java.rmi.RemoteException {
83 getService().deleteLayout(groupId, privateLayout, layoutId);
84 }
85
86 public static java.lang.String getLayoutName(long groupId,
87 boolean privateLayout, long layoutId, java.lang.String languageId)
88 throws com.liferay.portal.PortalException,
89 com.liferay.portal.SystemException, java.rmi.RemoteException {
90 return getService()
91 .getLayoutName(groupId, privateLayout, layoutId, languageId);
92 }
93
94 public static com.liferay.portal.model.LayoutReference[] getLayoutReferences(
95 long companyId, java.lang.String portletId, java.lang.String prefsKey,
96 java.lang.String prefsValue)
97 throws com.liferay.portal.SystemException, java.rmi.RemoteException {
98 return getService()
99 .getLayoutReferences(companyId, portletId, prefsKey,
100 prefsValue);
101 }
102
103 public static byte[] exportLayouts(long groupId, boolean privateLayout,
104 java.util.Map<String, String[]> parameterMap, java.util.Date startDate,
105 java.util.Date endDate)
106 throws com.liferay.portal.PortalException,
107 com.liferay.portal.SystemException, java.rmi.RemoteException {
108 return getService()
109 .exportLayouts(groupId, privateLayout, parameterMap,
110 startDate, endDate);
111 }
112
113 public static byte[] exportLayouts(long groupId, boolean privateLayout,
114 long[] layoutIds, java.util.Map<String, String[]> parameterMap,
115 java.util.Date startDate, java.util.Date endDate)
116 throws com.liferay.portal.PortalException,
117 com.liferay.portal.SystemException, java.rmi.RemoteException {
118 return getService()
119 .exportLayouts(groupId, privateLayout, layoutIds,
120 parameterMap, startDate, endDate);
121 }
122
123 public static byte[] exportPortletInfo(long plid,
124 java.lang.String portletId,
125 java.util.Map<String, String[]> parameterMap, java.util.Date startDate,
126 java.util.Date endDate)
127 throws com.liferay.portal.PortalException,
128 com.liferay.portal.SystemException, java.rmi.RemoteException {
129 return getService()
130 .exportPortletInfo(plid, portletId, parameterMap, startDate,
131 endDate);
132 }
133
134 public static void importLayouts(long groupId, boolean privateLayout,
135 java.util.Map<String, String[]> parameterMap, java.io.File file)
136 throws com.liferay.portal.PortalException,
137 com.liferay.portal.SystemException, java.rmi.RemoteException {
138 getService().importLayouts(groupId, privateLayout, parameterMap, file);
139 }
140
141 public static void importLayouts(long groupId, boolean privateLayout,
142 java.util.Map<String, String[]> parameterMap, byte[] bytes)
143 throws com.liferay.portal.PortalException,
144 com.liferay.portal.SystemException, java.rmi.RemoteException {
145 getService().importLayouts(groupId, privateLayout, parameterMap, bytes);
146 }
147
148 public static void importLayouts(long groupId, boolean privateLayout,
149 java.util.Map<String, String[]> parameterMap, java.io.InputStream is)
150 throws com.liferay.portal.PortalException,
151 com.liferay.portal.SystemException, java.rmi.RemoteException {
152 getService().importLayouts(groupId, privateLayout, parameterMap, is);
153 }
154
155 public static void importPortletInfo(long plid, java.lang.String portletId,
156 java.util.Map<String, String[]> parameterMap, java.io.File file)
157 throws com.liferay.portal.PortalException,
158 com.liferay.portal.SystemException, java.rmi.RemoteException {
159 getService().importPortletInfo(plid, portletId, parameterMap, file);
160 }
161
162 public static void importPortletInfo(long plid, java.lang.String portletId,
163 java.util.Map<String, String[]> parameterMap, java.io.InputStream is)
164 throws com.liferay.portal.PortalException,
165 com.liferay.portal.SystemException, java.rmi.RemoteException {
166 getService().importPortletInfo(plid, portletId, parameterMap, is);
167 }
168
169 public static void schedulePublishToLive(long sourceGroupId,
170 long targetGroupId, boolean privateLayout,
171 java.util.Map<Long, Boolean> layoutIdMap,
172 java.util.Map<String, String[]> parameterMap, java.lang.String scope,
173 java.util.Date startDate, java.util.Date endDate,
174 java.lang.String groupName, java.lang.String cronText,
175 java.util.Date schedulerStartDate, java.util.Date schedulerEndDate,
176 java.lang.String description)
177 throws com.liferay.portal.PortalException,
178 com.liferay.portal.SystemException, java.rmi.RemoteException {
179 getService()
180 .schedulePublishToLive(sourceGroupId, targetGroupId, privateLayout,
181 layoutIdMap, parameterMap, scope, startDate, endDate, groupName,
182 cronText, schedulerStartDate, schedulerEndDate, description);
183 }
184
185 public static void schedulePublishToRemote(long sourceGroupId,
186 boolean privateLayout, java.util.Map<Long, Boolean> layoutIdMap,
187 java.util.Map<String, String[]> parameterMap,
188 java.lang.String remoteAddress, int remotePort,
189 boolean secureConnection, long remoteGroupId,
190 boolean remotePrivateLayout, java.util.Date startDate,
191 java.util.Date endDate, java.lang.String groupName,
192 java.lang.String cronText, java.util.Date schedulerStartDate,
193 java.util.Date schedulerEndDate, java.lang.String description)
194 throws com.liferay.portal.PortalException,
195 com.liferay.portal.SystemException, java.rmi.RemoteException {
196 getService()
197 .schedulePublishToRemote(sourceGroupId, privateLayout, layoutIdMap,
198 parameterMap, remoteAddress, remotePort, secureConnection,
199 remoteGroupId, remotePrivateLayout, startDate, endDate, groupName,
200 cronText, schedulerStartDate, schedulerEndDate, description);
201 }
202
203 public static void setLayouts(long groupId, boolean privateLayout,
204 long parentLayoutId, long[] layoutIds)
205 throws com.liferay.portal.PortalException,
206 com.liferay.portal.SystemException, java.rmi.RemoteException {
207 getService()
208 .setLayouts(groupId, privateLayout, parentLayoutId, layoutIds);
209 }
210
211 public static void unschedulePublishToLive(long groupId,
212 java.lang.String jobName, java.lang.String groupName)
213 throws com.liferay.portal.PortalException,
214 com.liferay.portal.SystemException, java.rmi.RemoteException {
215 getService().unschedulePublishToLive(groupId, jobName, groupName);
216 }
217
218 public static void unschedulePublishToRemote(long groupId,
219 java.lang.String jobName, java.lang.String groupName)
220 throws com.liferay.portal.PortalException,
221 com.liferay.portal.SystemException, java.rmi.RemoteException {
222 getService().unschedulePublishToRemote(groupId, jobName, groupName);
223 }
224
225 public static com.liferay.portal.model.Layout updateLayout(long groupId,
226 boolean privateLayout, long layoutId, long parentLayoutId,
227 java.util.Map<java.util.Locale, String> localeNamesMap,
228 java.util.Map<java.util.Locale, String> localeTitlesMap,
229 java.lang.String description, java.lang.String type, boolean hidden,
230 java.lang.String friendlyURL)
231 throws com.liferay.portal.PortalException,
232 com.liferay.portal.SystemException, java.rmi.RemoteException {
233 return getService()
234 .updateLayout(groupId, privateLayout, layoutId,
235 parentLayoutId, localeNamesMap, localeTitlesMap, description, type,
236 hidden, friendlyURL);
237 }
238
239 public static com.liferay.portal.model.Layout updateLayout(long groupId,
240 boolean privateLayout, long layoutId, long parentLayoutId,
241 java.util.Map<java.util.Locale, String> localeNamesMap,
242 java.util.Map<java.util.Locale, String> localeTitlesMap,
243 java.lang.String description, java.lang.String type, boolean hidden,
244 java.lang.String friendlyURL, java.lang.Boolean iconImage,
245 byte[] iconBytes)
246 throws com.liferay.portal.PortalException,
247 com.liferay.portal.SystemException, java.rmi.RemoteException {
248 return getService()
249 .updateLayout(groupId, privateLayout, layoutId,
250 parentLayoutId, localeNamesMap, localeTitlesMap, description, type,
251 hidden, friendlyURL, iconImage, iconBytes);
252 }
253
254 public static com.liferay.portal.model.Layout updateLayout(long groupId,
255 boolean privateLayout, long layoutId, java.lang.String typeSettings)
256 throws com.liferay.portal.PortalException,
257 com.liferay.portal.SystemException, java.rmi.RemoteException {
258 return getService()
259 .updateLayout(groupId, privateLayout, layoutId, typeSettings);
260 }
261
262 public static com.liferay.portal.model.Layout updateLookAndFeel(
263 long groupId, boolean privateLayout, long layoutId,
264 java.lang.String themeId, java.lang.String colorSchemeId,
265 java.lang.String css, boolean wapTheme)
266 throws com.liferay.portal.PortalException,
267 com.liferay.portal.SystemException, java.rmi.RemoteException {
268 return getService()
269 .updateLookAndFeel(groupId, privateLayout, layoutId,
270 themeId, colorSchemeId, css, wapTheme);
271 }
272
273 public static com.liferay.portal.model.Layout updateName(long plid,
274 java.lang.String name, java.lang.String languageId)
275 throws com.liferay.portal.PortalException,
276 com.liferay.portal.SystemException, java.rmi.RemoteException {
277 return getService().updateName(plid, name, languageId);
278 }
279
280 public static com.liferay.portal.model.Layout updateName(long groupId,
281 boolean privateLayout, long layoutId, java.lang.String name,
282 java.lang.String languageId)
283 throws com.liferay.portal.PortalException,
284 com.liferay.portal.SystemException, java.rmi.RemoteException {
285 return getService()
286 .updateName(groupId, privateLayout, layoutId, name,
287 languageId);
288 }
289
290 public static com.liferay.portal.model.Layout updateParentLayoutId(
291 long plid, long parentPlid)
292 throws com.liferay.portal.PortalException,
293 com.liferay.portal.SystemException, java.rmi.RemoteException {
294 return getService().updateParentLayoutId(plid, parentPlid);
295 }
296
297 public static com.liferay.portal.model.Layout updateParentLayoutId(
298 long groupId, boolean privateLayout, long layoutId, long parentLayoutId)
299 throws com.liferay.portal.PortalException,
300 com.liferay.portal.SystemException, java.rmi.RemoteException {
301 return getService()
302 .updateParentLayoutId(groupId, privateLayout, layoutId,
303 parentLayoutId);
304 }
305
306 public static com.liferay.portal.model.Layout updatePriority(long plid,
307 int priority)
308 throws com.liferay.portal.PortalException,
309 com.liferay.portal.SystemException, java.rmi.RemoteException {
310 return getService().updatePriority(plid, priority);
311 }
312
313 public static com.liferay.portal.model.Layout updatePriority(long groupId,
314 boolean privateLayout, long layoutId, int priority)
315 throws com.liferay.portal.PortalException,
316 com.liferay.portal.SystemException, java.rmi.RemoteException {
317 return getService()
318 .updatePriority(groupId, privateLayout, layoutId, priority);
319 }
320
321 public static LayoutService getService() {
322 if (_service == null) {
323 throw new RuntimeException("LayoutService is not set");
324 }
325
326 return _service;
327 }
328
329 public void setService(LayoutService service) {
330 _service = service;
331 }
332
333 private static LayoutService _service;
334 }