1
22
23 package com.liferay.portal.service.persistence;
24
25
26
39 public class PortletUtil {
40 public static void cacheResult(com.liferay.portal.model.Portlet portlet) {
41 getPersistence().cacheResult(portlet);
42 }
43
44 public static void cacheResult(
45 java.util.List<com.liferay.portal.model.Portlet> portlets) {
46 getPersistence().cacheResult(portlets);
47 }
48
49 public static void clearCache() {
50 getPersistence().clearCache();
51 }
52
53 public static com.liferay.portal.model.Portlet create(long id) {
54 return getPersistence().create(id);
55 }
56
57 public static com.liferay.portal.model.Portlet remove(long id)
58 throws com.liferay.portal.NoSuchPortletException,
59 com.liferay.portal.SystemException {
60 return getPersistence().remove(id);
61 }
62
63 public static com.liferay.portal.model.Portlet remove(
64 com.liferay.portal.model.Portlet portlet)
65 throws com.liferay.portal.SystemException {
66 return getPersistence().remove(portlet);
67 }
68
69
72 public static com.liferay.portal.model.Portlet update(
73 com.liferay.portal.model.Portlet portlet)
74 throws com.liferay.portal.SystemException {
75 return getPersistence().update(portlet);
76 }
77
78
90 public static com.liferay.portal.model.Portlet update(
91 com.liferay.portal.model.Portlet portlet, boolean merge)
92 throws com.liferay.portal.SystemException {
93 return getPersistence().update(portlet, merge);
94 }
95
96 public static com.liferay.portal.model.Portlet updateImpl(
97 com.liferay.portal.model.Portlet portlet, boolean merge)
98 throws com.liferay.portal.SystemException {
99 return getPersistence().updateImpl(portlet, merge);
100 }
101
102 public static com.liferay.portal.model.Portlet findByPrimaryKey(long id)
103 throws com.liferay.portal.NoSuchPortletException,
104 com.liferay.portal.SystemException {
105 return getPersistence().findByPrimaryKey(id);
106 }
107
108 public static com.liferay.portal.model.Portlet fetchByPrimaryKey(long id)
109 throws com.liferay.portal.SystemException {
110 return getPersistence().fetchByPrimaryKey(id);
111 }
112
113 public static java.util.List<com.liferay.portal.model.Portlet> findByCompanyId(
114 long companyId) throws com.liferay.portal.SystemException {
115 return getPersistence().findByCompanyId(companyId);
116 }
117
118 public static java.util.List<com.liferay.portal.model.Portlet> findByCompanyId(
119 long companyId, int start, int end)
120 throws com.liferay.portal.SystemException {
121 return getPersistence().findByCompanyId(companyId, start, end);
122 }
123
124 public static java.util.List<com.liferay.portal.model.Portlet> findByCompanyId(
125 long companyId, int start, int end,
126 com.liferay.portal.kernel.util.OrderByComparator obc)
127 throws com.liferay.portal.SystemException {
128 return getPersistence().findByCompanyId(companyId, start, end, obc);
129 }
130
131 public static com.liferay.portal.model.Portlet findByCompanyId_First(
132 long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
133 throws com.liferay.portal.NoSuchPortletException,
134 com.liferay.portal.SystemException {
135 return getPersistence().findByCompanyId_First(companyId, obc);
136 }
137
138 public static com.liferay.portal.model.Portlet findByCompanyId_Last(
139 long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
140 throws com.liferay.portal.NoSuchPortletException,
141 com.liferay.portal.SystemException {
142 return getPersistence().findByCompanyId_Last(companyId, obc);
143 }
144
145 public static com.liferay.portal.model.Portlet[] findByCompanyId_PrevAndNext(
146 long id, long companyId,
147 com.liferay.portal.kernel.util.OrderByComparator obc)
148 throws com.liferay.portal.NoSuchPortletException,
149 com.liferay.portal.SystemException {
150 return getPersistence().findByCompanyId_PrevAndNext(id, companyId, obc);
151 }
152
153 public static com.liferay.portal.model.Portlet findByC_P(long companyId,
154 java.lang.String portletId)
155 throws com.liferay.portal.NoSuchPortletException,
156 com.liferay.portal.SystemException {
157 return getPersistence().findByC_P(companyId, portletId);
158 }
159
160 public static com.liferay.portal.model.Portlet fetchByC_P(long companyId,
161 java.lang.String portletId) throws com.liferay.portal.SystemException {
162 return getPersistence().fetchByC_P(companyId, portletId);
163 }
164
165 public static com.liferay.portal.model.Portlet fetchByC_P(long companyId,
166 java.lang.String portletId, boolean retrieveFromCache)
167 throws com.liferay.portal.SystemException {
168 return getPersistence()
169 .fetchByC_P(companyId, portletId, retrieveFromCache);
170 }
171
172 public static java.util.List<Object> findWithDynamicQuery(
173 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
174 throws com.liferay.portal.SystemException {
175 return getPersistence().findWithDynamicQuery(dynamicQuery);
176 }
177
178 public static java.util.List<Object> findWithDynamicQuery(
179 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
180 int end) throws com.liferay.portal.SystemException {
181 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
182 }
183
184 public static java.util.List<com.liferay.portal.model.Portlet> findAll()
185 throws com.liferay.portal.SystemException {
186 return getPersistence().findAll();
187 }
188
189 public static java.util.List<com.liferay.portal.model.Portlet> findAll(
190 int start, int end) throws com.liferay.portal.SystemException {
191 return getPersistence().findAll(start, end);
192 }
193
194 public static java.util.List<com.liferay.portal.model.Portlet> findAll(
195 int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
196 throws com.liferay.portal.SystemException {
197 return getPersistence().findAll(start, end, obc);
198 }
199
200 public static void removeByCompanyId(long companyId)
201 throws com.liferay.portal.SystemException {
202 getPersistence().removeByCompanyId(companyId);
203 }
204
205 public static void removeByC_P(long companyId, java.lang.String portletId)
206 throws com.liferay.portal.NoSuchPortletException,
207 com.liferay.portal.SystemException {
208 getPersistence().removeByC_P(companyId, portletId);
209 }
210
211 public static void removeAll() throws com.liferay.portal.SystemException {
212 getPersistence().removeAll();
213 }
214
215 public static int countByCompanyId(long companyId)
216 throws com.liferay.portal.SystemException {
217 return getPersistence().countByCompanyId(companyId);
218 }
219
220 public static int countByC_P(long companyId, java.lang.String portletId)
221 throws com.liferay.portal.SystemException {
222 return getPersistence().countByC_P(companyId, portletId);
223 }
224
225 public static int countAll() throws com.liferay.portal.SystemException {
226 return getPersistence().countAll();
227 }
228
229 public static PortletPersistence getPersistence() {
230 return _persistence;
231 }
232
233 public void setPersistence(PortletPersistence persistence) {
234 _persistence = persistence;
235 }
236
237 private static PortletPersistence _persistence;
238 }