001
014
015 package com.liferay.portlet.asset.service.http;
016
017 import com.liferay.portal.kernel.log.Log;
018 import com.liferay.portal.kernel.log.LogFactoryUtil;
019 import com.liferay.portal.kernel.util.LocalizationUtil;
020
021 import com.liferay.portlet.asset.service.AssetVocabularyServiceUtil;
022
023 import java.rmi.RemoteException;
024
025 import java.util.Locale;
026 import java.util.Map;
027
028
070 public class AssetVocabularyServiceSoap {
071
074 public static com.liferay.portlet.asset.model.AssetVocabularySoap addVocabulary(
075 java.lang.String[] titleMapLanguageIds,
076 java.lang.String[] titleMapValues,
077 java.lang.String[] descriptionMapLanguageIds,
078 java.lang.String[] descriptionMapValues, java.lang.String settings,
079 com.liferay.portal.service.ServiceContext serviceContext)
080 throws RemoteException {
081 try {
082 Map<Locale, String> titleMap = LocalizationUtil.getLocalizationMap(titleMapLanguageIds,
083 titleMapValues);
084 Map<Locale, String> descriptionMap = LocalizationUtil.getLocalizationMap(descriptionMapLanguageIds,
085 descriptionMapValues);
086
087 com.liferay.portlet.asset.model.AssetVocabulary returnValue = AssetVocabularyServiceUtil.addVocabulary(titleMap,
088 descriptionMap, settings, serviceContext);
089
090 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModel(returnValue);
091 }
092 catch (Exception e) {
093 _log.error(e, e);
094
095 throw new RemoteException(e.getMessage());
096 }
097 }
098
099 public static com.liferay.portlet.asset.model.AssetVocabularySoap addVocabulary(
100 java.lang.String title, java.lang.String[] titleMapLanguageIds,
101 java.lang.String[] titleMapValues,
102 java.lang.String[] descriptionMapLanguageIds,
103 java.lang.String[] descriptionMapValues, java.lang.String settings,
104 com.liferay.portal.service.ServiceContext serviceContext)
105 throws RemoteException {
106 try {
107 Map<Locale, String> titleMap = LocalizationUtil.getLocalizationMap(titleMapLanguageIds,
108 titleMapValues);
109 Map<Locale, String> descriptionMap = LocalizationUtil.getLocalizationMap(descriptionMapLanguageIds,
110 descriptionMapValues);
111
112 com.liferay.portlet.asset.model.AssetVocabulary returnValue = AssetVocabularyServiceUtil.addVocabulary(title,
113 titleMap, descriptionMap, settings, serviceContext);
114
115 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModel(returnValue);
116 }
117 catch (Exception e) {
118 _log.error(e, e);
119
120 throw new RemoteException(e.getMessage());
121 }
122 }
123
124 public static com.liferay.portlet.asset.model.AssetVocabularySoap addVocabulary(
125 java.lang.String title,
126 com.liferay.portal.service.ServiceContext serviceContext)
127 throws RemoteException {
128 try {
129 com.liferay.portlet.asset.model.AssetVocabulary returnValue = AssetVocabularyServiceUtil.addVocabulary(title,
130 serviceContext);
131
132 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModel(returnValue);
133 }
134 catch (Exception e) {
135 _log.error(e, e);
136
137 throw new RemoteException(e.getMessage());
138 }
139 }
140
141 public static com.liferay.portlet.asset.model.AssetVocabularySoap[] deleteVocabularies(
142 long[] vocabularyIds,
143 com.liferay.portal.service.ServiceContext serviceContext)
144 throws RemoteException {
145 try {
146 java.util.List<com.liferay.portlet.asset.model.AssetVocabulary> returnValue =
147 AssetVocabularyServiceUtil.deleteVocabularies(vocabularyIds,
148 serviceContext);
149
150 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModels(returnValue);
151 }
152 catch (Exception e) {
153 _log.error(e, e);
154
155 throw new RemoteException(e.getMessage());
156 }
157 }
158
159 public static void deleteVocabulary(long vocabularyId)
160 throws RemoteException {
161 try {
162 AssetVocabularyServiceUtil.deleteVocabulary(vocabularyId);
163 }
164 catch (Exception e) {
165 _log.error(e, e);
166
167 throw new RemoteException(e.getMessage());
168 }
169 }
170
171 public static com.liferay.portlet.asset.model.AssetVocabularySoap[] getCompanyVocabularies(
172 long companyId) throws RemoteException {
173 try {
174 java.util.List<com.liferay.portlet.asset.model.AssetVocabulary> returnValue =
175 AssetVocabularyServiceUtil.getCompanyVocabularies(companyId);
176
177 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModels(returnValue);
178 }
179 catch (Exception e) {
180 _log.error(e, e);
181
182 throw new RemoteException(e.getMessage());
183 }
184 }
185
186 public static com.liferay.portlet.asset.model.AssetVocabularySoap[] getGroupsVocabularies(
187 long[] groupIds) throws RemoteException {
188 try {
189 java.util.List<com.liferay.portlet.asset.model.AssetVocabulary> returnValue =
190 AssetVocabularyServiceUtil.getGroupsVocabularies(groupIds);
191
192 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModels(returnValue);
193 }
194 catch (Exception e) {
195 _log.error(e, e);
196
197 throw new RemoteException(e.getMessage());
198 }
199 }
200
201 public static com.liferay.portlet.asset.model.AssetVocabularySoap[] getGroupsVocabularies(
202 long[] groupIds, java.lang.String className) throws RemoteException {
203 try {
204 java.util.List<com.liferay.portlet.asset.model.AssetVocabulary> returnValue =
205 AssetVocabularyServiceUtil.getGroupsVocabularies(groupIds,
206 className);
207
208 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModels(returnValue);
209 }
210 catch (Exception e) {
211 _log.error(e, e);
212
213 throw new RemoteException(e.getMessage());
214 }
215 }
216
217 public static com.liferay.portlet.asset.model.AssetVocabularySoap[] getGroupVocabularies(
218 long groupId) throws RemoteException {
219 try {
220 java.util.List<com.liferay.portlet.asset.model.AssetVocabulary> returnValue =
221 AssetVocabularyServiceUtil.getGroupVocabularies(groupId);
222
223 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModels(returnValue);
224 }
225 catch (Exception e) {
226 _log.error(e, e);
227
228 throw new RemoteException(e.getMessage());
229 }
230 }
231
232 public static com.liferay.portlet.asset.model.AssetVocabularySoap[] getGroupVocabularies(
233 long groupId, boolean createDefaultVocabulary)
234 throws RemoteException {
235 try {
236 java.util.List<com.liferay.portlet.asset.model.AssetVocabulary> returnValue =
237 AssetVocabularyServiceUtil.getGroupVocabularies(groupId,
238 createDefaultVocabulary);
239
240 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModels(returnValue);
241 }
242 catch (Exception e) {
243 _log.error(e, e);
244
245 throw new RemoteException(e.getMessage());
246 }
247 }
248
249 public static com.liferay.portlet.asset.model.AssetVocabularySoap[] getGroupVocabularies(
250 long groupId, int start, int end,
251 com.liferay.portal.kernel.util.OrderByComparator obc)
252 throws RemoteException {
253 try {
254 java.util.List<com.liferay.portlet.asset.model.AssetVocabulary> returnValue =
255 AssetVocabularyServiceUtil.getGroupVocabularies(groupId, start,
256 end, obc);
257
258 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModels(returnValue);
259 }
260 catch (Exception e) {
261 _log.error(e, e);
262
263 throw new RemoteException(e.getMessage());
264 }
265 }
266
267 public static com.liferay.portlet.asset.model.AssetVocabularySoap[] getGroupVocabularies(
268 long groupId, java.lang.String name, int start, int end,
269 com.liferay.portal.kernel.util.OrderByComparator obc)
270 throws RemoteException {
271 try {
272 java.util.List<com.liferay.portlet.asset.model.AssetVocabulary> returnValue =
273 AssetVocabularyServiceUtil.getGroupVocabularies(groupId, name,
274 start, end, obc);
275
276 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModels(returnValue);
277 }
278 catch (Exception e) {
279 _log.error(e, e);
280
281 throw new RemoteException(e.getMessage());
282 }
283 }
284
285 public static int getGroupVocabulariesCount(long groupId)
286 throws RemoteException {
287 try {
288 int returnValue = AssetVocabularyServiceUtil.getGroupVocabulariesCount(groupId);
289
290 return returnValue;
291 }
292 catch (Exception e) {
293 _log.error(e, e);
294
295 throw new RemoteException(e.getMessage());
296 }
297 }
298
299 public static int getGroupVocabulariesCount(long groupId,
300 java.lang.String name) throws RemoteException {
301 try {
302 int returnValue = AssetVocabularyServiceUtil.getGroupVocabulariesCount(groupId,
303 name);
304
305 return returnValue;
306 }
307 catch (Exception e) {
308 _log.error(e, e);
309
310 throw new RemoteException(e.getMessage());
311 }
312 }
313
314 public static com.liferay.portlet.asset.model.AssetVocabularyDisplay getGroupVocabulariesDisplay(
315 long groupId, java.lang.String name, int start, int end,
316 com.liferay.portal.kernel.util.OrderByComparator obc)
317 throws RemoteException {
318 try {
319 com.liferay.portlet.asset.model.AssetVocabularyDisplay returnValue = AssetVocabularyServiceUtil.getGroupVocabulariesDisplay(groupId,
320 name, start, end, obc);
321
322 return returnValue;
323 }
324 catch (Exception e) {
325 _log.error(e, e);
326
327 throw new RemoteException(e.getMessage());
328 }
329 }
330
331 public static java.lang.String getJSONGroupVocabularies(long groupId,
332 java.lang.String name, int start, int end,
333 com.liferay.portal.kernel.util.OrderByComparator obc)
334 throws RemoteException {
335 try {
336 com.liferay.portal.kernel.json.JSONObject returnValue = AssetVocabularyServiceUtil.getJSONGroupVocabularies(groupId,
337 name, start, end, obc);
338
339 return returnValue.toString();
340 }
341 catch (Exception e) {
342 _log.error(e, e);
343
344 throw new RemoteException(e.getMessage());
345 }
346 }
347
348 public static com.liferay.portlet.asset.model.AssetVocabularySoap[] getVocabularies(
349 long[] vocabularyIds) throws RemoteException {
350 try {
351 java.util.List<com.liferay.portlet.asset.model.AssetVocabulary> returnValue =
352 AssetVocabularyServiceUtil.getVocabularies(vocabularyIds);
353
354 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModels(returnValue);
355 }
356 catch (Exception e) {
357 _log.error(e, e);
358
359 throw new RemoteException(e.getMessage());
360 }
361 }
362
363 public static com.liferay.portlet.asset.model.AssetVocabularySoap getVocabulary(
364 long vocabularyId) throws RemoteException {
365 try {
366 com.liferay.portlet.asset.model.AssetVocabulary returnValue = AssetVocabularyServiceUtil.getVocabulary(vocabularyId);
367
368 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModel(returnValue);
369 }
370 catch (Exception e) {
371 _log.error(e, e);
372
373 throw new RemoteException(e.getMessage());
374 }
375 }
376
377
380 public static com.liferay.portlet.asset.model.AssetVocabularySoap updateVocabulary(
381 long vocabularyId, java.lang.String[] titleMapLanguageIds,
382 java.lang.String[] titleMapValues,
383 java.lang.String[] descriptionMapLanguageIds,
384 java.lang.String[] descriptionMapValues, java.lang.String settings,
385 com.liferay.portal.service.ServiceContext serviceContext)
386 throws RemoteException {
387 try {
388 Map<Locale, String> titleMap = LocalizationUtil.getLocalizationMap(titleMapLanguageIds,
389 titleMapValues);
390 Map<Locale, String> descriptionMap = LocalizationUtil.getLocalizationMap(descriptionMapLanguageIds,
391 descriptionMapValues);
392
393 com.liferay.portlet.asset.model.AssetVocabulary returnValue = AssetVocabularyServiceUtil.updateVocabulary(vocabularyId,
394 titleMap, descriptionMap, settings, serviceContext);
395
396 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModel(returnValue);
397 }
398 catch (Exception e) {
399 _log.error(e, e);
400
401 throw new RemoteException(e.getMessage());
402 }
403 }
404
405 public static com.liferay.portlet.asset.model.AssetVocabularySoap updateVocabulary(
406 long vocabularyId, java.lang.String title,
407 java.lang.String[] titleMapLanguageIds,
408 java.lang.String[] titleMapValues,
409 java.lang.String[] descriptionMapLanguageIds,
410 java.lang.String[] descriptionMapValues, java.lang.String settings,
411 com.liferay.portal.service.ServiceContext serviceContext)
412 throws RemoteException {
413 try {
414 Map<Locale, String> titleMap = LocalizationUtil.getLocalizationMap(titleMapLanguageIds,
415 titleMapValues);
416 Map<Locale, String> descriptionMap = LocalizationUtil.getLocalizationMap(descriptionMapLanguageIds,
417 descriptionMapValues);
418
419 com.liferay.portlet.asset.model.AssetVocabulary returnValue = AssetVocabularyServiceUtil.updateVocabulary(vocabularyId,
420 title, titleMap, descriptionMap, settings, serviceContext);
421
422 return com.liferay.portlet.asset.model.AssetVocabularySoap.toSoapModel(returnValue);
423 }
424 catch (Exception e) {
425 _log.error(e, e);
426
427 throw new RemoteException(e.getMessage());
428 }
429 }
430
431 private static Log _log = LogFactoryUtil.getLog(AssetVocabularyServiceSoap.class);
432 }