001
014
015 package com.liferay.portlet.dynamicdatalists.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.dynamicdatalists.service.DDLRecordSetServiceUtil;
022
023 import java.rmi.RemoteException;
024
025 import java.util.Locale;
026 import java.util.Map;
027
028
068 public class DDLRecordSetServiceSoap {
069 public static com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap addRecordSet(
070 long groupId, long ddmStructureId, java.lang.String recordSetKey,
071 java.lang.String[] nameMapLanguageIds,
072 java.lang.String[] nameMapValues,
073 java.lang.String[] descriptionMapLanguageIds,
074 java.lang.String[] descriptionMapValues, int minDisplayRows, int scope,
075 com.liferay.portal.service.ServiceContext serviceContext)
076 throws RemoteException {
077 try {
078 Map<Locale, String> nameMap = LocalizationUtil.getLocalizationMap(nameMapLanguageIds,
079 nameMapValues);
080 Map<Locale, String> descriptionMap = LocalizationUtil.getLocalizationMap(descriptionMapLanguageIds,
081 descriptionMapValues);
082
083 com.liferay.portlet.dynamicdatalists.model.DDLRecordSet returnValue = DDLRecordSetServiceUtil.addRecordSet(groupId,
084 ddmStructureId, recordSetKey, nameMap, descriptionMap,
085 minDisplayRows, scope, serviceContext);
086
087 return com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap.toSoapModel(returnValue);
088 }
089 catch (Exception e) {
090 _log.error(e, e);
091
092 throw new RemoteException(e.getMessage());
093 }
094 }
095
096 public static void deleteRecordSet(long recordSetId)
097 throws RemoteException {
098 try {
099 DDLRecordSetServiceUtil.deleteRecordSet(recordSetId);
100 }
101 catch (Exception e) {
102 _log.error(e, e);
103
104 throw new RemoteException(e.getMessage());
105 }
106 }
107
108 public static com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap getRecordSet(
109 long recordSetId) throws RemoteException {
110 try {
111 com.liferay.portlet.dynamicdatalists.model.DDLRecordSet returnValue = DDLRecordSetServiceUtil.getRecordSet(recordSetId);
112
113 return com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap.toSoapModel(returnValue);
114 }
115 catch (Exception e) {
116 _log.error(e, e);
117
118 throw new RemoteException(e.getMessage());
119 }
120 }
121
122 public static com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap[] search(
123 long companyId, long groupId, java.lang.String keywords, int scope,
124 int start, int end,
125 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
126 throws RemoteException {
127 try {
128 java.util.List<com.liferay.portlet.dynamicdatalists.model.DDLRecordSet> returnValue =
129 DDLRecordSetServiceUtil.search(companyId, groupId, keywords,
130 scope, start, end, orderByComparator);
131
132 return com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap.toSoapModels(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.dynamicdatalists.model.DDLRecordSetSoap[] search(
142 long companyId, long groupId, java.lang.String name,
143 java.lang.String description, int scope, boolean andOperator,
144 int start, int end,
145 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
146 throws RemoteException {
147 try {
148 java.util.List<com.liferay.portlet.dynamicdatalists.model.DDLRecordSet> returnValue =
149 DDLRecordSetServiceUtil.search(companyId, groupId, name,
150 description, scope, andOperator, start, end,
151 orderByComparator);
152
153 return com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap.toSoapModels(returnValue);
154 }
155 catch (Exception e) {
156 _log.error(e, e);
157
158 throw new RemoteException(e.getMessage());
159 }
160 }
161
162 public static int searchCount(long companyId, long groupId,
163 java.lang.String keywords, int scope) throws RemoteException {
164 try {
165 int returnValue = DDLRecordSetServiceUtil.searchCount(companyId,
166 groupId, keywords, scope);
167
168 return returnValue;
169 }
170 catch (Exception e) {
171 _log.error(e, e);
172
173 throw new RemoteException(e.getMessage());
174 }
175 }
176
177 public static int searchCount(long companyId, long groupId,
178 java.lang.String name, java.lang.String description, int scope,
179 boolean andOperator) throws RemoteException {
180 try {
181 int returnValue = DDLRecordSetServiceUtil.searchCount(companyId,
182 groupId, name, description, scope, andOperator);
183
184 return returnValue;
185 }
186 catch (Exception e) {
187 _log.error(e, e);
188
189 throw new RemoteException(e.getMessage());
190 }
191 }
192
193 public static com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap updateMinDisplayRows(
194 long recordSetId, int minDisplayRows,
195 com.liferay.portal.service.ServiceContext serviceContext)
196 throws RemoteException {
197 try {
198 com.liferay.portlet.dynamicdatalists.model.DDLRecordSet returnValue = DDLRecordSetServiceUtil.updateMinDisplayRows(recordSetId,
199 minDisplayRows, serviceContext);
200
201 return com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap.toSoapModel(returnValue);
202 }
203 catch (Exception e) {
204 _log.error(e, e);
205
206 throw new RemoteException(e.getMessage());
207 }
208 }
209
210 public static com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap updateRecordSet(
211 long recordSetId, long ddmStructureId,
212 java.lang.String[] nameMapLanguageIds,
213 java.lang.String[] nameMapValues,
214 java.lang.String[] descriptionMapLanguageIds,
215 java.lang.String[] descriptionMapValues, int minDisplayRows,
216 com.liferay.portal.service.ServiceContext serviceContext)
217 throws RemoteException {
218 try {
219 Map<Locale, String> nameMap = LocalizationUtil.getLocalizationMap(nameMapLanguageIds,
220 nameMapValues);
221 Map<Locale, String> descriptionMap = LocalizationUtil.getLocalizationMap(descriptionMapLanguageIds,
222 descriptionMapValues);
223
224 com.liferay.portlet.dynamicdatalists.model.DDLRecordSet returnValue = DDLRecordSetServiceUtil.updateRecordSet(recordSetId,
225 ddmStructureId, nameMap, descriptionMap, minDisplayRows,
226 serviceContext);
227
228 return com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap.toSoapModel(returnValue);
229 }
230 catch (Exception e) {
231 _log.error(e, e);
232
233 throw new RemoteException(e.getMessage());
234 }
235 }
236
237 public static com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap updateRecordSet(
238 long groupId, long ddmStructureId, java.lang.String recordSetKey,
239 java.lang.String[] nameMapLanguageIds,
240 java.lang.String[] nameMapValues,
241 java.lang.String[] descriptionMapLanguageIds,
242 java.lang.String[] descriptionMapValues, int minDisplayRows,
243 com.liferay.portal.service.ServiceContext serviceContext)
244 throws RemoteException {
245 try {
246 Map<Locale, String> nameMap = LocalizationUtil.getLocalizationMap(nameMapLanguageIds,
247 nameMapValues);
248 Map<Locale, String> descriptionMap = LocalizationUtil.getLocalizationMap(descriptionMapLanguageIds,
249 descriptionMapValues);
250
251 com.liferay.portlet.dynamicdatalists.model.DDLRecordSet returnValue = DDLRecordSetServiceUtil.updateRecordSet(groupId,
252 ddmStructureId, recordSetKey, nameMap, descriptionMap,
253 minDisplayRows, serviceContext);
254
255 return com.liferay.portlet.dynamicdatalists.model.DDLRecordSetSoap.toSoapModel(returnValue);
256 }
257 catch (Exception e) {
258 _log.error(e, e);
259
260 throw new RemoteException(e.getMessage());
261 }
262 }
263
264 private static Log _log = LogFactoryUtil.getLog(DDLRecordSetServiceSoap.class);
265 }