1
14
15 package com.liferay.portlet.polls.service.persistence;
16
17 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
18 import com.liferay.portal.kernel.dao.orm.DynamicQuery;
19 import com.liferay.portal.kernel.exception.SystemException;
20
21 import com.liferay.portlet.polls.model.PollsChoice;
22
23 import java.util.List;
24
25
38 public class PollsChoiceUtil {
39
42 public static void clearCache() {
43 getPersistence().clearCache();
44 }
45
46
49 public static void clearCache(PollsChoice pollsChoice) {
50 getPersistence().clearCache(pollsChoice);
51 }
52
53
56 public long countWithDynamicQuery(DynamicQuery dynamicQuery)
57 throws SystemException {
58 return getPersistence().countWithDynamicQuery(dynamicQuery);
59 }
60
61
64 public static List<PollsChoice> findWithDynamicQuery(
65 DynamicQuery dynamicQuery) throws SystemException {
66 return getPersistence().findWithDynamicQuery(dynamicQuery);
67 }
68
69
72 public static List<PollsChoice> findWithDynamicQuery(
73 DynamicQuery dynamicQuery, int start, int end)
74 throws SystemException {
75 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
76 }
77
78
81 public static PollsChoice remove(PollsChoice pollsChoice)
82 throws SystemException {
83 return getPersistence().remove(pollsChoice);
84 }
85
86
89 public static PollsChoice update(PollsChoice pollsChoice, boolean merge)
90 throws SystemException {
91 return getPersistence().update(pollsChoice, merge);
92 }
93
94 public static void cacheResult(
95 com.liferay.portlet.polls.model.PollsChoice pollsChoice) {
96 getPersistence().cacheResult(pollsChoice);
97 }
98
99 public static void cacheResult(
100 java.util.List<com.liferay.portlet.polls.model.PollsChoice> pollsChoices) {
101 getPersistence().cacheResult(pollsChoices);
102 }
103
104 public static com.liferay.portlet.polls.model.PollsChoice create(
105 long choiceId) {
106 return getPersistence().create(choiceId);
107 }
108
109 public static com.liferay.portlet.polls.model.PollsChoice remove(
110 long choiceId)
111 throws com.liferay.portal.kernel.exception.SystemException,
112 com.liferay.portlet.polls.NoSuchChoiceException {
113 return getPersistence().remove(choiceId);
114 }
115
116 public static com.liferay.portlet.polls.model.PollsChoice updateImpl(
117 com.liferay.portlet.polls.model.PollsChoice pollsChoice, boolean merge)
118 throws com.liferay.portal.kernel.exception.SystemException {
119 return getPersistence().updateImpl(pollsChoice, merge);
120 }
121
122 public static com.liferay.portlet.polls.model.PollsChoice findByPrimaryKey(
123 long choiceId)
124 throws com.liferay.portal.kernel.exception.SystemException,
125 com.liferay.portlet.polls.NoSuchChoiceException {
126 return getPersistence().findByPrimaryKey(choiceId);
127 }
128
129 public static com.liferay.portlet.polls.model.PollsChoice fetchByPrimaryKey(
130 long choiceId)
131 throws com.liferay.portal.kernel.exception.SystemException {
132 return getPersistence().fetchByPrimaryKey(choiceId);
133 }
134
135 public static java.util.List<com.liferay.portlet.polls.model.PollsChoice> findByUuid(
136 java.lang.String uuid)
137 throws com.liferay.portal.kernel.exception.SystemException {
138 return getPersistence().findByUuid(uuid);
139 }
140
141 public static java.util.List<com.liferay.portlet.polls.model.PollsChoice> findByUuid(
142 java.lang.String uuid, int start, int end)
143 throws com.liferay.portal.kernel.exception.SystemException {
144 return getPersistence().findByUuid(uuid, start, end);
145 }
146
147 public static java.util.List<com.liferay.portlet.polls.model.PollsChoice> findByUuid(
148 java.lang.String uuid, int start, int end,
149 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
150 throws com.liferay.portal.kernel.exception.SystemException {
151 return getPersistence().findByUuid(uuid, start, end, orderByComparator);
152 }
153
154 public static com.liferay.portlet.polls.model.PollsChoice findByUuid_First(
155 java.lang.String uuid,
156 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
157 throws com.liferay.portal.kernel.exception.SystemException,
158 com.liferay.portlet.polls.NoSuchChoiceException {
159 return getPersistence().findByUuid_First(uuid, orderByComparator);
160 }
161
162 public static com.liferay.portlet.polls.model.PollsChoice findByUuid_Last(
163 java.lang.String uuid,
164 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
165 throws com.liferay.portal.kernel.exception.SystemException,
166 com.liferay.portlet.polls.NoSuchChoiceException {
167 return getPersistence().findByUuid_Last(uuid, orderByComparator);
168 }
169
170 public static com.liferay.portlet.polls.model.PollsChoice[] findByUuid_PrevAndNext(
171 long choiceId, java.lang.String uuid,
172 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
173 throws com.liferay.portal.kernel.exception.SystemException,
174 com.liferay.portlet.polls.NoSuchChoiceException {
175 return getPersistence()
176 .findByUuid_PrevAndNext(choiceId, uuid, orderByComparator);
177 }
178
179 public static java.util.List<com.liferay.portlet.polls.model.PollsChoice> findByQuestionId(
180 long questionId)
181 throws com.liferay.portal.kernel.exception.SystemException {
182 return getPersistence().findByQuestionId(questionId);
183 }
184
185 public static java.util.List<com.liferay.portlet.polls.model.PollsChoice> findByQuestionId(
186 long questionId, int start, int end)
187 throws com.liferay.portal.kernel.exception.SystemException {
188 return getPersistence().findByQuestionId(questionId, start, end);
189 }
190
191 public static java.util.List<com.liferay.portlet.polls.model.PollsChoice> findByQuestionId(
192 long questionId, int start, int end,
193 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
194 throws com.liferay.portal.kernel.exception.SystemException {
195 return getPersistence()
196 .findByQuestionId(questionId, start, end, orderByComparator);
197 }
198
199 public static com.liferay.portlet.polls.model.PollsChoice findByQuestionId_First(
200 long questionId,
201 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
202 throws com.liferay.portal.kernel.exception.SystemException,
203 com.liferay.portlet.polls.NoSuchChoiceException {
204 return getPersistence()
205 .findByQuestionId_First(questionId, orderByComparator);
206 }
207
208 public static com.liferay.portlet.polls.model.PollsChoice findByQuestionId_Last(
209 long questionId,
210 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
211 throws com.liferay.portal.kernel.exception.SystemException,
212 com.liferay.portlet.polls.NoSuchChoiceException {
213 return getPersistence()
214 .findByQuestionId_Last(questionId, orderByComparator);
215 }
216
217 public static com.liferay.portlet.polls.model.PollsChoice[] findByQuestionId_PrevAndNext(
218 long choiceId, long questionId,
219 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
220 throws com.liferay.portal.kernel.exception.SystemException,
221 com.liferay.portlet.polls.NoSuchChoiceException {
222 return getPersistence()
223 .findByQuestionId_PrevAndNext(choiceId, questionId,
224 orderByComparator);
225 }
226
227 public static com.liferay.portlet.polls.model.PollsChoice findByQ_N(
228 long questionId, java.lang.String name)
229 throws com.liferay.portal.kernel.exception.SystemException,
230 com.liferay.portlet.polls.NoSuchChoiceException {
231 return getPersistence().findByQ_N(questionId, name);
232 }
233
234 public static com.liferay.portlet.polls.model.PollsChoice fetchByQ_N(
235 long questionId, java.lang.String name)
236 throws com.liferay.portal.kernel.exception.SystemException {
237 return getPersistence().fetchByQ_N(questionId, name);
238 }
239
240 public static com.liferay.portlet.polls.model.PollsChoice fetchByQ_N(
241 long questionId, java.lang.String name, boolean retrieveFromCache)
242 throws com.liferay.portal.kernel.exception.SystemException {
243 return getPersistence().fetchByQ_N(questionId, name, retrieveFromCache);
244 }
245
246 public static java.util.List<com.liferay.portlet.polls.model.PollsChoice> findAll()
247 throws com.liferay.portal.kernel.exception.SystemException {
248 return getPersistence().findAll();
249 }
250
251 public static java.util.List<com.liferay.portlet.polls.model.PollsChoice> findAll(
252 int start, int end)
253 throws com.liferay.portal.kernel.exception.SystemException {
254 return getPersistence().findAll(start, end);
255 }
256
257 public static java.util.List<com.liferay.portlet.polls.model.PollsChoice> findAll(
258 int start, int end,
259 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
260 throws com.liferay.portal.kernel.exception.SystemException {
261 return getPersistence().findAll(start, end, orderByComparator);
262 }
263
264 public static void removeByUuid(java.lang.String uuid)
265 throws com.liferay.portal.kernel.exception.SystemException {
266 getPersistence().removeByUuid(uuid);
267 }
268
269 public static void removeByQuestionId(long questionId)
270 throws com.liferay.portal.kernel.exception.SystemException {
271 getPersistence().removeByQuestionId(questionId);
272 }
273
274 public static void removeByQ_N(long questionId, java.lang.String name)
275 throws com.liferay.portal.kernel.exception.SystemException,
276 com.liferay.portlet.polls.NoSuchChoiceException {
277 getPersistence().removeByQ_N(questionId, name);
278 }
279
280 public static void removeAll()
281 throws com.liferay.portal.kernel.exception.SystemException {
282 getPersistence().removeAll();
283 }
284
285 public static int countByUuid(java.lang.String uuid)
286 throws com.liferay.portal.kernel.exception.SystemException {
287 return getPersistence().countByUuid(uuid);
288 }
289
290 public static int countByQuestionId(long questionId)
291 throws com.liferay.portal.kernel.exception.SystemException {
292 return getPersistence().countByQuestionId(questionId);
293 }
294
295 public static int countByQ_N(long questionId, java.lang.String name)
296 throws com.liferay.portal.kernel.exception.SystemException {
297 return getPersistence().countByQ_N(questionId, name);
298 }
299
300 public static int countAll()
301 throws com.liferay.portal.kernel.exception.SystemException {
302 return getPersistence().countAll();
303 }
304
305 public static PollsChoicePersistence getPersistence() {
306 if (_persistence == null) {
307 _persistence = (PollsChoicePersistence)PortalBeanLocatorUtil.locate(PollsChoicePersistence.class.getName());
308 }
309
310 return _persistence;
311 }
312
313 public void setPersistence(PollsChoicePersistence persistence) {
314 _persistence = persistence;
315 }
316
317 private static PollsChoicePersistence _persistence;
318 }