001
014
015 package com.liferay.portal.service;
016
017 import aQute.bnd.annotation.ProviderType;
018
019 import com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery;
020 import com.liferay.portal.kernel.dao.orm.DynamicQuery;
021 import com.liferay.portal.kernel.dao.orm.IndexableActionableDynamicQuery;
022 import com.liferay.portal.kernel.dao.orm.Projection;
023 import com.liferay.portal.kernel.exception.PortalException;
024 import com.liferay.portal.kernel.exception.SystemException;
025 import com.liferay.portal.kernel.search.Indexable;
026 import com.liferay.portal.kernel.search.IndexableType;
027 import com.liferay.portal.kernel.spring.aop.Property;
028 import com.liferay.portal.kernel.spring.aop.Retry;
029 import com.liferay.portal.kernel.spring.aop.Skip;
030 import com.liferay.portal.kernel.transaction.Isolation;
031 import com.liferay.portal.kernel.transaction.Propagation;
032 import com.liferay.portal.kernel.transaction.Transactional;
033 import com.liferay.portal.kernel.util.OrderByComparator;
034 import com.liferay.portal.model.PersistedModel;
035 import com.liferay.portal.model.Portlet;
036 import com.liferay.portal.model.PortletPreferences;
037 import com.liferay.portal.model.PortletPreferencesIds;
038
039 import java.io.Serializable;
040
041 import java.util.List;
042
043
055 @ProviderType
056 @Transactional(isolation = Isolation.PORTAL, rollbackFor = {
057 PortalException.class, SystemException.class})
058 public interface PortletPreferencesLocalService extends BaseLocalService,
059 PersistedModelLocalService {
060
065 public PortletPreferences addPortletPreferences(long companyId,
066 long ownerId, int ownerType, long plid, java.lang.String portletId,
067 Portlet portlet, java.lang.String defaultPreferences);
068
069
075 @Indexable(type = IndexableType.REINDEX)
076 public PortletPreferences addPortletPreferences(
077 PortletPreferences portletPreferences);
078
079
085 public PortletPreferences createPortletPreferences(
086 long portletPreferencesId);
087
088
091 @Override
092 public PersistedModel deletePersistedModel(PersistedModel persistedModel)
093 throws PortalException;
094
095 public void deletePortletPreferences(long ownerId, int ownerType, long plid);
096
097 public void deletePortletPreferences(long ownerId, int ownerType,
098 long plid, java.lang.String portletId) throws PortalException;
099
100
106 @Indexable(type = IndexableType.DELETE)
107 public PortletPreferences deletePortletPreferences(
108 PortletPreferences portletPreferences);
109
110
117 @Indexable(type = IndexableType.DELETE)
118 public PortletPreferences deletePortletPreferences(
119 long portletPreferencesId) throws PortalException;
120
121 public void deletePortletPreferencesByPlid(long plid);
122
123 public DynamicQuery dynamicQuery();
124
125
131 public <T> List<T> dynamicQuery(DynamicQuery dynamicQuery);
132
133
145 public <T> List<T> dynamicQuery(DynamicQuery dynamicQuery, int start,
146 int end);
147
148
161 public <T> List<T> dynamicQuery(DynamicQuery dynamicQuery, int start,
162 int end, OrderByComparator<T> orderByComparator);
163
164
170 public long dynamicQueryCount(DynamicQuery dynamicQuery);
171
172
179 public long dynamicQueryCount(DynamicQuery dynamicQuery,
180 Projection projection);
181
182 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
183 public PortletPreferences fetchPortletPreferences(long portletPreferencesId);
184
185 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
186 public javax.portlet.PortletPreferences fetchPreferences(long companyId,
187 long ownerId, int ownerType, long plid, java.lang.String portletId);
188
189 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
190 public javax.portlet.PortletPreferences fetchPreferences(
191 PortletPreferencesIds portletPreferencesIds);
192
193 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
194 public ActionableDynamicQuery getActionableDynamicQuery();
195
196 @Skip
197 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
198 public javax.portlet.PortletPreferences getDefaultPreferences(
199 long companyId, java.lang.String portletId);
200
201 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
202 public IndexableActionableDynamicQuery getIndexableActionableDynamicQuery();
203
204
209 public java.lang.String getOSGiServiceIdentifier();
210
211 @Override
212 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
213 public PersistedModel getPersistedModel(Serializable primaryKeyObj)
214 throws PortalException;
215
216 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
217 public List<PortletPreferences> getPortletPreferences();
218
219 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
220 public List<PortletPreferences> getPortletPreferences(long companyId,
221 long groupId, long ownerId, int ownerType, java.lang.String portletId,
222 boolean privateLayout);
223
224 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
225 public List<PortletPreferences> getPortletPreferences(long ownerId,
226 int ownerType, long plid);
227
228 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
229 public PortletPreferences getPortletPreferences(long ownerId,
230 int ownerType, long plid, java.lang.String portletId)
231 throws PortalException;
232
233 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
234 public List<PortletPreferences> getPortletPreferences(int ownerType,
235 long plid, java.lang.String portletId);
236
237 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
238 public List<PortletPreferences> getPortletPreferences(long plid,
239 java.lang.String portletId);
240
241
248 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
249 public PortletPreferences getPortletPreferences(long portletPreferencesId)
250 throws PortalException;
251
252 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
253 public List<PortletPreferences> getPortletPreferencesByPlid(long plid);
254
255 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
256 public long getPortletPreferencesCount(long ownerId, int ownerType,
257 long plid, Portlet portlet, boolean excludeDefaultPreferences);
258
259 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
260 public long getPortletPreferencesCount(long ownerId, int ownerType,
261 java.lang.String portletId, boolean excludeDefaultPreferences);
262
263 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
264 public long getPortletPreferencesCount(int ownerType, long plid,
265 java.lang.String portletId);
266
267 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
268 public long getPortletPreferencesCount(int ownerType,
269 java.lang.String portletId);
270
271
282 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
283 public List<PortletPreferences> getPortletPreferenceses(int start, int end);
284
285
290 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
291 public int getPortletPreferencesesCount();
292
293 @Retry(acceptor = com.liferay.portal.service.ExceptionRetryAcceptor.class, properties = {
294 @Property(name = ExceptionRetryAcceptor.EXCEPTION_NAME, value = "org.springframework.dao.DataIntegrityViolationException")
295 }
296 )
297 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
298 public javax.portlet.PortletPreferences getPreferences(long companyId,
299 long ownerId, int ownerType, long plid, java.lang.String portletId);
300
301 @Retry(acceptor = com.liferay.portal.service.ExceptionRetryAcceptor.class, properties = {
302 @Property(name = ExceptionRetryAcceptor.EXCEPTION_NAME, value = "org.springframework.dao.DataIntegrityViolationException")
303 }
304 )
305 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
306 public javax.portlet.PortletPreferences getPreferences(long companyId,
307 long ownerId, int ownerType, long plid, java.lang.String portletId,
308 java.lang.String defaultPreferences);
309
310 @Retry(acceptor = com.liferay.portal.service.ExceptionRetryAcceptor.class, properties = {
311 @Property(name = ExceptionRetryAcceptor.EXCEPTION_NAME, value = "org.springframework.dao.DataIntegrityViolationException")
312 }
313 )
314 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
315 public javax.portlet.PortletPreferences getPreferences(
316 PortletPreferencesIds portletPreferencesIds);
317
318 @Retry(acceptor = com.liferay.portal.service.ExceptionRetryAcceptor.class, properties = {
319 @Property(name = ExceptionRetryAcceptor.EXCEPTION_NAME, value = "org.springframework.dao.DataIntegrityViolationException")
320 }
321 )
322 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
323 public javax.portlet.PortletPreferences getStrictPreferences(
324 long companyId, long ownerId, int ownerType, long plid,
325 java.lang.String portletId);
326
327 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
328 public javax.portlet.PortletPreferences getStrictPreferences(
329 PortletPreferencesIds portletPreferencesIds);
330
331
337 @Indexable(type = IndexableType.REINDEX)
338 public PortletPreferences updatePortletPreferences(
339 PortletPreferences portletPreferences);
340
341 public PortletPreferences updatePreferences(long ownerId, int ownerType,
342 long plid, java.lang.String portletId,
343 javax.portlet.PortletPreferences portletPreferences);
344
345 public PortletPreferences updatePreferences(long ownerId, int ownerType,
346 long plid, java.lang.String portletId, java.lang.String xml);
347 }