001: /**
002: * Copyright (c) 2000-2008 Liferay, Inc. All rights reserved.
003: *
004: * Permission is hereby granted, free of charge, to any person obtaining a copy
005: * of this software and associated documentation files (the "Software"), to deal
006: * in the Software without restriction, including without limitation the rights
007: * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
008: * copies of the Software, and to permit persons to whom the Software is
009: * furnished to do so, subject to the following conditions:
010: *
011: * The above copyright notice and this permission notice shall be included in
012: * all copies or substantial portions of the Software.
013: *
014: * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
015: * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
016: * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
017: * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
018: * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
019: * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
020: * SOFTWARE.
021: */package com.liferay.portal.service.persistence;
022:
023: /**
024: * <a href="PortletPreferencesUtil.java.html"><b><i>View Source</i></b></a>
025: *
026: * @author Brian Wing Shun Chan
027: *
028: */
029: public class PortletPreferencesUtil {
030: public static com.liferay.portal.model.PortletPreferences create(
031: long portletPreferencesId) {
032: return getPersistence().create(portletPreferencesId);
033: }
034:
035: public static com.liferay.portal.model.PortletPreferences remove(
036: long portletPreferencesId)
037: throws com.liferay.portal.SystemException,
038: com.liferay.portal.NoSuchPortletPreferencesException {
039: return getPersistence().remove(portletPreferencesId);
040: }
041:
042: public static com.liferay.portal.model.PortletPreferences remove(
043: com.liferay.portal.model.PortletPreferences portletPreferences)
044: throws com.liferay.portal.SystemException {
045: return getPersistence().remove(portletPreferences);
046: }
047:
048: public static com.liferay.portal.model.PortletPreferences update(
049: com.liferay.portal.model.PortletPreferences portletPreferences)
050: throws com.liferay.portal.SystemException {
051: return getPersistence().update(portletPreferences);
052: }
053:
054: public static com.liferay.portal.model.PortletPreferences update(
055: com.liferay.portal.model.PortletPreferences portletPreferences,
056: boolean merge) throws com.liferay.portal.SystemException {
057: return getPersistence().update(portletPreferences, merge);
058: }
059:
060: public static com.liferay.portal.model.PortletPreferences updateImpl(
061: com.liferay.portal.model.PortletPreferences portletPreferences,
062: boolean merge) throws com.liferay.portal.SystemException {
063: return getPersistence().updateImpl(portletPreferences, merge);
064: }
065:
066: public static com.liferay.portal.model.PortletPreferences findByPrimaryKey(
067: long portletPreferencesId)
068: throws com.liferay.portal.SystemException,
069: com.liferay.portal.NoSuchPortletPreferencesException {
070: return getPersistence().findByPrimaryKey(portletPreferencesId);
071: }
072:
073: public static com.liferay.portal.model.PortletPreferences fetchByPrimaryKey(
074: long portletPreferencesId)
075: throws com.liferay.portal.SystemException {
076: return getPersistence().fetchByPrimaryKey(portletPreferencesId);
077: }
078:
079: public static java.util.List findByPlid(long plid)
080: throws com.liferay.portal.SystemException {
081: return getPersistence().findByPlid(plid);
082: }
083:
084: public static java.util.List findByPlid(long plid, int begin,
085: int end) throws com.liferay.portal.SystemException {
086: return getPersistence().findByPlid(plid, begin, end);
087: }
088:
089: public static java.util.List findByPlid(long plid, int begin,
090: int end,
091: com.liferay.portal.kernel.util.OrderByComparator obc)
092: throws com.liferay.portal.SystemException {
093: return getPersistence().findByPlid(plid, begin, end, obc);
094: }
095:
096: public static com.liferay.portal.model.PortletPreferences findByPlid_First(
097: long plid,
098: com.liferay.portal.kernel.util.OrderByComparator obc)
099: throws com.liferay.portal.SystemException,
100: com.liferay.portal.NoSuchPortletPreferencesException {
101: return getPersistence().findByPlid_First(plid, obc);
102: }
103:
104: public static com.liferay.portal.model.PortletPreferences findByPlid_Last(
105: long plid,
106: com.liferay.portal.kernel.util.OrderByComparator obc)
107: throws com.liferay.portal.SystemException,
108: com.liferay.portal.NoSuchPortletPreferencesException {
109: return getPersistence().findByPlid_Last(plid, obc);
110: }
111:
112: public static com.liferay.portal.model.PortletPreferences[] findByPlid_PrevAndNext(
113: long portletPreferencesId, long plid,
114: com.liferay.portal.kernel.util.OrderByComparator obc)
115: throws com.liferay.portal.SystemException,
116: com.liferay.portal.NoSuchPortletPreferencesException {
117: return getPersistence().findByPlid_PrevAndNext(
118: portletPreferencesId, plid, obc);
119: }
120:
121: public static java.util.List findByP_P(long plid,
122: java.lang.String portletId)
123: throws com.liferay.portal.SystemException {
124: return getPersistence().findByP_P(plid, portletId);
125: }
126:
127: public static java.util.List findByP_P(long plid,
128: java.lang.String portletId, int begin, int end)
129: throws com.liferay.portal.SystemException {
130: return getPersistence().findByP_P(plid, portletId, begin, end);
131: }
132:
133: public static java.util.List findByP_P(long plid,
134: java.lang.String portletId, int begin, int end,
135: com.liferay.portal.kernel.util.OrderByComparator obc)
136: throws com.liferay.portal.SystemException {
137: return getPersistence().findByP_P(plid, portletId, begin, end,
138: obc);
139: }
140:
141: public static com.liferay.portal.model.PortletPreferences findByP_P_First(
142: long plid, java.lang.String portletId,
143: com.liferay.portal.kernel.util.OrderByComparator obc)
144: throws com.liferay.portal.SystemException,
145: com.liferay.portal.NoSuchPortletPreferencesException {
146: return getPersistence().findByP_P_First(plid, portletId, obc);
147: }
148:
149: public static com.liferay.portal.model.PortletPreferences findByP_P_Last(
150: long plid, java.lang.String portletId,
151: com.liferay.portal.kernel.util.OrderByComparator obc)
152: throws com.liferay.portal.SystemException,
153: com.liferay.portal.NoSuchPortletPreferencesException {
154: return getPersistence().findByP_P_Last(plid, portletId, obc);
155: }
156:
157: public static com.liferay.portal.model.PortletPreferences[] findByP_P_PrevAndNext(
158: long portletPreferencesId, long plid,
159: java.lang.String portletId,
160: com.liferay.portal.kernel.util.OrderByComparator obc)
161: throws com.liferay.portal.SystemException,
162: com.liferay.portal.NoSuchPortletPreferencesException {
163: return getPersistence().findByP_P_PrevAndNext(
164: portletPreferencesId, plid, portletId, obc);
165: }
166:
167: public static java.util.List findByO_O_P(long ownerId,
168: int ownerType, long plid)
169: throws com.liferay.portal.SystemException {
170: return getPersistence().findByO_O_P(ownerId, ownerType, plid);
171: }
172:
173: public static java.util.List findByO_O_P(long ownerId,
174: int ownerType, long plid, int begin, int end)
175: throws com.liferay.portal.SystemException {
176: return getPersistence().findByO_O_P(ownerId, ownerType, plid,
177: begin, end);
178: }
179:
180: public static java.util.List findByO_O_P(long ownerId,
181: int ownerType, long plid, int begin, int end,
182: com.liferay.portal.kernel.util.OrderByComparator obc)
183: throws com.liferay.portal.SystemException {
184: return getPersistence().findByO_O_P(ownerId, ownerType, plid,
185: begin, end, obc);
186: }
187:
188: public static com.liferay.portal.model.PortletPreferences findByO_O_P_First(
189: long ownerId, int ownerType, long plid,
190: com.liferay.portal.kernel.util.OrderByComparator obc)
191: throws com.liferay.portal.SystemException,
192: com.liferay.portal.NoSuchPortletPreferencesException {
193: return getPersistence().findByO_O_P_First(ownerId, ownerType,
194: plid, obc);
195: }
196:
197: public static com.liferay.portal.model.PortletPreferences findByO_O_P_Last(
198: long ownerId, int ownerType, long plid,
199: com.liferay.portal.kernel.util.OrderByComparator obc)
200: throws com.liferay.portal.SystemException,
201: com.liferay.portal.NoSuchPortletPreferencesException {
202: return getPersistence().findByO_O_P_Last(ownerId, ownerType,
203: plid, obc);
204: }
205:
206: public static com.liferay.portal.model.PortletPreferences[] findByO_O_P_PrevAndNext(
207: long portletPreferencesId, long ownerId, int ownerType,
208: long plid,
209: com.liferay.portal.kernel.util.OrderByComparator obc)
210: throws com.liferay.portal.SystemException,
211: com.liferay.portal.NoSuchPortletPreferencesException {
212: return getPersistence().findByO_O_P_PrevAndNext(
213: portletPreferencesId, ownerId, ownerType, plid, obc);
214: }
215:
216: public static com.liferay.portal.model.PortletPreferences findByO_O_P_P(
217: long ownerId, int ownerType, long plid,
218: java.lang.String portletId)
219: throws com.liferay.portal.SystemException,
220: com.liferay.portal.NoSuchPortletPreferencesException {
221: return getPersistence().findByO_O_P_P(ownerId, ownerType, plid,
222: portletId);
223: }
224:
225: public static com.liferay.portal.model.PortletPreferences fetchByO_O_P_P(
226: long ownerId, int ownerType, long plid,
227: java.lang.String portletId)
228: throws com.liferay.portal.SystemException {
229: return getPersistence().fetchByO_O_P_P(ownerId, ownerType,
230: plid, portletId);
231: }
232:
233: public static java.util.List findWithDynamicQuery(
234: com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer)
235: throws com.liferay.portal.SystemException {
236: return getPersistence().findWithDynamicQuery(queryInitializer);
237: }
238:
239: public static java.util.List findWithDynamicQuery(
240: com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer,
241: int begin, int end)
242: throws com.liferay.portal.SystemException {
243: return getPersistence().findWithDynamicQuery(queryInitializer,
244: begin, end);
245: }
246:
247: public static java.util.List findAll()
248: throws com.liferay.portal.SystemException {
249: return getPersistence().findAll();
250: }
251:
252: public static java.util.List findAll(int begin, int end)
253: throws com.liferay.portal.SystemException {
254: return getPersistence().findAll(begin, end);
255: }
256:
257: public static java.util.List findAll(int begin, int end,
258: com.liferay.portal.kernel.util.OrderByComparator obc)
259: throws com.liferay.portal.SystemException {
260: return getPersistence().findAll(begin, end, obc);
261: }
262:
263: public static void removeByPlid(long plid)
264: throws com.liferay.portal.SystemException {
265: getPersistence().removeByPlid(plid);
266: }
267:
268: public static void removeByP_P(long plid, java.lang.String portletId)
269: throws com.liferay.portal.SystemException {
270: getPersistence().removeByP_P(plid, portletId);
271: }
272:
273: public static void removeByO_O_P(long ownerId, int ownerType,
274: long plid) throws com.liferay.portal.SystemException {
275: getPersistence().removeByO_O_P(ownerId, ownerType, plid);
276: }
277:
278: public static void removeByO_O_P_P(long ownerId, int ownerType,
279: long plid, java.lang.String portletId)
280: throws com.liferay.portal.SystemException,
281: com.liferay.portal.NoSuchPortletPreferencesException {
282: getPersistence().removeByO_O_P_P(ownerId, ownerType, plid,
283: portletId);
284: }
285:
286: public static void removeAll()
287: throws com.liferay.portal.SystemException {
288: getPersistence().removeAll();
289: }
290:
291: public static int countByPlid(long plid)
292: throws com.liferay.portal.SystemException {
293: return getPersistence().countByPlid(plid);
294: }
295:
296: public static int countByP_P(long plid, java.lang.String portletId)
297: throws com.liferay.portal.SystemException {
298: return getPersistence().countByP_P(plid, portletId);
299: }
300:
301: public static int countByO_O_P(long ownerId, int ownerType,
302: long plid) throws com.liferay.portal.SystemException {
303: return getPersistence().countByO_O_P(ownerId, ownerType, plid);
304: }
305:
306: public static int countByO_O_P_P(long ownerId, int ownerType,
307: long plid, java.lang.String portletId)
308: throws com.liferay.portal.SystemException {
309: return getPersistence().countByO_O_P_P(ownerId, ownerType,
310: plid, portletId);
311: }
312:
313: public static int countAll()
314: throws com.liferay.portal.SystemException {
315: return getPersistence().countAll();
316: }
317:
318: public static PortletPreferencesPersistence getPersistence() {
319: return _getUtil()._persistence;
320: }
321:
322: public void setPersistence(PortletPreferencesPersistence persistence) {
323: _persistence = persistence;
324: }
325:
326: private static PortletPreferencesUtil _getUtil() {
327: if (_util == null) {
328: _util = (PortletPreferencesUtil) com.liferay.portal.kernel.bean.BeanLocatorUtil
329: .locate(_UTIL);
330: }
331:
332: return _util;
333: }
334:
335: private static final String _UTIL = PortletPreferencesUtil.class
336: .getName();
337: private static PortletPreferencesUtil _util;
338: private PortletPreferencesPersistence _persistence;
339: }
|