1
14
15 package com.liferay.portal.service.http;
16
17 import com.liferay.portal.kernel.log.Log;
18 import com.liferay.portal.kernel.log.LogFactoryUtil;
19 import com.liferay.portal.kernel.util.LongWrapper;
20 import com.liferay.portal.kernel.util.MethodWrapper;
21 import com.liferay.portal.security.auth.HttpPrincipal;
22 import com.liferay.portal.service.ThemeServiceUtil;
23
24
61 public class ThemeServiceHttp {
62 public static java.util.List<com.liferay.portal.model.Theme> getThemes(
63 HttpPrincipal httpPrincipal, long companyId)
64 throws com.liferay.portal.kernel.exception.SystemException {
65 try {
66 Object paramObj0 = new LongWrapper(companyId);
67
68 MethodWrapper methodWrapper = new MethodWrapper(ThemeServiceUtil.class.getName(),
69 "getThemes", new Object[] { paramObj0 });
70
71 Object returnObj = null;
72
73 try {
74 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
75 }
76 catch (Exception e) {
77 throw new com.liferay.portal.kernel.exception.SystemException(e);
78 }
79
80 return (java.util.List<com.liferay.portal.model.Theme>)returnObj;
81 }
82 catch (com.liferay.portal.kernel.exception.SystemException se) {
83 _log.error(se, se);
84
85 throw se;
86 }
87 }
88
89 public static com.liferay.portal.kernel.json.JSONArray getWARThemes(
90 HttpPrincipal httpPrincipal)
91 throws com.liferay.portal.kernel.exception.SystemException {
92 try {
93 MethodWrapper methodWrapper = new MethodWrapper(ThemeServiceUtil.class.getName(),
94 "getWARThemes", new Object[0]);
95
96 Object returnObj = null;
97
98 try {
99 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
100 }
101 catch (Exception e) {
102 throw new com.liferay.portal.kernel.exception.SystemException(e);
103 }
104
105 return (com.liferay.portal.kernel.json.JSONArray)returnObj;
106 }
107 catch (com.liferay.portal.kernel.exception.SystemException se) {
108 _log.error(se, se);
109
110 throw se;
111 }
112 }
113
114 private static Log _log = LogFactoryUtil.getLog(ThemeServiceHttp.class);
115 }