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.MethodHandler;
20 import com.liferay.portal.kernel.util.MethodKey;
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.SystemException {
65 try {
66 MethodKey methodKey = new MethodKey(ThemeServiceUtil.class.getName(),
67 "getThemes", _getThemesParameterTypes0);
68
69 MethodHandler methodHandler = new MethodHandler(methodKey, companyId);
70
71 Object returnObj = null;
72
73 try {
74 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
75 }
76 catch (Exception e) {
77 throw new com.liferay.portal.SystemException(e);
78 }
79
80 return (java.util.List<com.liferay.portal.model.Theme>)returnObj;
81 }
82 catch (com.liferay.portal.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) throws com.liferay.portal.SystemException {
91 try {
92 MethodKey methodKey = new MethodKey(ThemeServiceUtil.class.getName(),
93 "getWARThemes", _getWARThemesParameterTypes1);
94
95 MethodHandler methodHandler = new MethodHandler(methodKey);
96
97 Object returnObj = null;
98
99 try {
100 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
101 }
102 catch (Exception e) {
103 throw new com.liferay.portal.SystemException(e);
104 }
105
106 return (com.liferay.portal.kernel.json.JSONArray)returnObj;
107 }
108 catch (com.liferay.portal.SystemException se) {
109 _log.error(se, se);
110
111 throw se;
112 }
113 }
114
115 private static Log _log = LogFactoryUtil.getLog(ThemeServiceHttp.class);
116 private static final Class<?>[] _getThemesParameterTypes0 = new Class[] {
117 long.class
118 };
119 private static final Class<?>[] _getWARThemesParameterTypes1 = new Class[] { };
120 }