1   /**
2    * Copyright (c) 2000-2009 Liferay, Inc. All rights reserved.
3    *
4    *
5    *
6    *
7    * The contents of this file are subject to the terms of the Liferay Enterprise
8    * Subscription License ("License"). You may not use this file except in
9    * compliance with the License. You can obtain a copy of the License by
10   * contacting Liferay, Inc. See the License for the specific language governing
11   * permissions and limitations under the License, including but not limited to
12   * distribution rights of the Software.
13   *
14   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15   * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16   * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17   * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18   * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19   * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20   * SOFTWARE.
21   */
22  
23  package com.liferay.portlet.journal.service.persistence;
24  
25  
26  /**
27   * <a href="JournalArticleImageUtil.java.html"><b><i>View Source</i></b></a>
28   *
29   * <p>
30   * ServiceBuilder generated this class. Modifications in this class will be
31   * overwritten the next time is generated.
32   * </p>
33   *
34   * @author    Brian Wing Shun Chan
35   * @see       JournalArticleImagePersistence
36   * @see       JournalArticleImagePersistenceImpl
37   * @generated
38   */
39  public class JournalArticleImageUtil {
40      public static void cacheResult(
41          com.liferay.portlet.journal.model.JournalArticleImage journalArticleImage) {
42          getPersistence().cacheResult(journalArticleImage);
43      }
44  
45      public static void cacheResult(
46          java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> journalArticleImages) {
47          getPersistence().cacheResult(journalArticleImages);
48      }
49  
50      public static void clearCache() {
51          getPersistence().clearCache();
52      }
53  
54      public static com.liferay.portlet.journal.model.JournalArticleImage create(
55          long articleImageId) {
56          return getPersistence().create(articleImageId);
57      }
58  
59      public static com.liferay.portlet.journal.model.JournalArticleImage remove(
60          long articleImageId)
61          throws com.liferay.portal.SystemException,
62              com.liferay.portlet.journal.NoSuchArticleImageException {
63          return getPersistence().remove(articleImageId);
64      }
65  
66      public static com.liferay.portlet.journal.model.JournalArticleImage remove(
67          com.liferay.portlet.journal.model.JournalArticleImage journalArticleImage)
68          throws com.liferay.portal.SystemException {
69          return getPersistence().remove(journalArticleImage);
70      }
71  
72      /**
73       * @deprecated Use {@link #update(JournalArticleImage, boolean merge)}.
74       */
75      public static com.liferay.portlet.journal.model.JournalArticleImage update(
76          com.liferay.portlet.journal.model.JournalArticleImage journalArticleImage)
77          throws com.liferay.portal.SystemException {
78          return getPersistence().update(journalArticleImage);
79      }
80  
81      /**
82       * Add, update, or merge, the entity. This method also calls the model
83       * listeners to trigger the proper events associated with adding, deleting,
84       * or updating an entity.
85       *
86       * @param  journalArticleImage the entity to add, update, or merge
87       * @param  merge boolean value for whether to merge the entity. The default
88       *         value is false. Setting merge to true is more expensive and
89       *         should only be true when journalArticleImage is transient. See
90       *         LEP-5473 for a detailed discussion of this method.
91       * @return the entity that was added, updated, or merged
92       */
93      public static com.liferay.portlet.journal.model.JournalArticleImage update(
94          com.liferay.portlet.journal.model.JournalArticleImage journalArticleImage,
95          boolean merge) throws com.liferay.portal.SystemException {
96          return getPersistence().update(journalArticleImage, merge);
97      }
98  
99      public static com.liferay.portlet.journal.model.JournalArticleImage updateImpl(
100         com.liferay.portlet.journal.model.JournalArticleImage journalArticleImage,
101         boolean merge) throws com.liferay.portal.SystemException {
102         return getPersistence().updateImpl(journalArticleImage, merge);
103     }
104 
105     public static com.liferay.portlet.journal.model.JournalArticleImage findByPrimaryKey(
106         long articleImageId)
107         throws com.liferay.portal.SystemException,
108             com.liferay.portlet.journal.NoSuchArticleImageException {
109         return getPersistence().findByPrimaryKey(articleImageId);
110     }
111 
112     public static com.liferay.portlet.journal.model.JournalArticleImage fetchByPrimaryKey(
113         long articleImageId) throws com.liferay.portal.SystemException {
114         return getPersistence().fetchByPrimaryKey(articleImageId);
115     }
116 
117     public static java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> findByGroupId(
118         long groupId) throws com.liferay.portal.SystemException {
119         return getPersistence().findByGroupId(groupId);
120     }
121 
122     public static java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> findByGroupId(
123         long groupId, int start, int end)
124         throws com.liferay.portal.SystemException {
125         return getPersistence().findByGroupId(groupId, start, end);
126     }
127 
128     public static java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> findByGroupId(
129         long groupId, int start, int end,
130         com.liferay.portal.kernel.util.OrderByComparator obc)
131         throws com.liferay.portal.SystemException {
132         return getPersistence().findByGroupId(groupId, start, end, obc);
133     }
134 
135     public static com.liferay.portlet.journal.model.JournalArticleImage findByGroupId_First(
136         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
137         throws com.liferay.portal.SystemException,
138             com.liferay.portlet.journal.NoSuchArticleImageException {
139         return getPersistence().findByGroupId_First(groupId, obc);
140     }
141 
142     public static com.liferay.portlet.journal.model.JournalArticleImage findByGroupId_Last(
143         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
144         throws com.liferay.portal.SystemException,
145             com.liferay.portlet.journal.NoSuchArticleImageException {
146         return getPersistence().findByGroupId_Last(groupId, obc);
147     }
148 
149     public static com.liferay.portlet.journal.model.JournalArticleImage[] findByGroupId_PrevAndNext(
150         long articleImageId, long groupId,
151         com.liferay.portal.kernel.util.OrderByComparator obc)
152         throws com.liferay.portal.SystemException,
153             com.liferay.portlet.journal.NoSuchArticleImageException {
154         return getPersistence()
155                    .findByGroupId_PrevAndNext(articleImageId, groupId, obc);
156     }
157 
158     public static java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> findByTempImage(
159         boolean tempImage) throws com.liferay.portal.SystemException {
160         return getPersistence().findByTempImage(tempImage);
161     }
162 
163     public static java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> findByTempImage(
164         boolean tempImage, int start, int end)
165         throws com.liferay.portal.SystemException {
166         return getPersistence().findByTempImage(tempImage, start, end);
167     }
168 
169     public static java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> findByTempImage(
170         boolean tempImage, int start, int end,
171         com.liferay.portal.kernel.util.OrderByComparator obc)
172         throws com.liferay.portal.SystemException {
173         return getPersistence().findByTempImage(tempImage, start, end, obc);
174     }
175 
176     public static com.liferay.portlet.journal.model.JournalArticleImage findByTempImage_First(
177         boolean tempImage, com.liferay.portal.kernel.util.OrderByComparator obc)
178         throws com.liferay.portal.SystemException,
179             com.liferay.portlet.journal.NoSuchArticleImageException {
180         return getPersistence().findByTempImage_First(tempImage, obc);
181     }
182 
183     public static com.liferay.portlet.journal.model.JournalArticleImage findByTempImage_Last(
184         boolean tempImage, com.liferay.portal.kernel.util.OrderByComparator obc)
185         throws com.liferay.portal.SystemException,
186             com.liferay.portlet.journal.NoSuchArticleImageException {
187         return getPersistence().findByTempImage_Last(tempImage, obc);
188     }
189 
190     public static com.liferay.portlet.journal.model.JournalArticleImage[] findByTempImage_PrevAndNext(
191         long articleImageId, boolean tempImage,
192         com.liferay.portal.kernel.util.OrderByComparator obc)
193         throws com.liferay.portal.SystemException,
194             com.liferay.portlet.journal.NoSuchArticleImageException {
195         return getPersistence()
196                    .findByTempImage_PrevAndNext(articleImageId, tempImage, obc);
197     }
198 
199     public static java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> findByG_A_V(
200         long groupId, java.lang.String articleId, double version)
201         throws com.liferay.portal.SystemException {
202         return getPersistence().findByG_A_V(groupId, articleId, version);
203     }
204 
205     public static java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> findByG_A_V(
206         long groupId, java.lang.String articleId, double version, int start,
207         int end) throws com.liferay.portal.SystemException {
208         return getPersistence()
209                    .findByG_A_V(groupId, articleId, version, start, end);
210     }
211 
212     public static java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> findByG_A_V(
213         long groupId, java.lang.String articleId, double version, int start,
214         int end, com.liferay.portal.kernel.util.OrderByComparator obc)
215         throws com.liferay.portal.SystemException {
216         return getPersistence()
217                    .findByG_A_V(groupId, articleId, version, start, end, obc);
218     }
219 
220     public static com.liferay.portlet.journal.model.JournalArticleImage findByG_A_V_First(
221         long groupId, java.lang.String articleId, double version,
222         com.liferay.portal.kernel.util.OrderByComparator obc)
223         throws com.liferay.portal.SystemException,
224             com.liferay.portlet.journal.NoSuchArticleImageException {
225         return getPersistence()
226                    .findByG_A_V_First(groupId, articleId, version, obc);
227     }
228 
229     public static com.liferay.portlet.journal.model.JournalArticleImage findByG_A_V_Last(
230         long groupId, java.lang.String articleId, double version,
231         com.liferay.portal.kernel.util.OrderByComparator obc)
232         throws com.liferay.portal.SystemException,
233             com.liferay.portlet.journal.NoSuchArticleImageException {
234         return getPersistence()
235                    .findByG_A_V_Last(groupId, articleId, version, obc);
236     }
237 
238     public static com.liferay.portlet.journal.model.JournalArticleImage[] findByG_A_V_PrevAndNext(
239         long articleImageId, long groupId, java.lang.String articleId,
240         double version, com.liferay.portal.kernel.util.OrderByComparator obc)
241         throws com.liferay.portal.SystemException,
242             com.liferay.portlet.journal.NoSuchArticleImageException {
243         return getPersistence()
244                    .findByG_A_V_PrevAndNext(articleImageId, groupId, articleId,
245             version, obc);
246     }
247 
248     public static com.liferay.portlet.journal.model.JournalArticleImage findByG_A_V_E_E_L(
249         long groupId, java.lang.String articleId, double version,
250         java.lang.String elInstanceId, java.lang.String elName,
251         java.lang.String languageId)
252         throws com.liferay.portal.SystemException,
253             com.liferay.portlet.journal.NoSuchArticleImageException {
254         return getPersistence()
255                    .findByG_A_V_E_E_L(groupId, articleId, version,
256             elInstanceId, elName, languageId);
257     }
258 
259     public static com.liferay.portlet.journal.model.JournalArticleImage fetchByG_A_V_E_E_L(
260         long groupId, java.lang.String articleId, double version,
261         java.lang.String elInstanceId, java.lang.String elName,
262         java.lang.String languageId) throws com.liferay.portal.SystemException {
263         return getPersistence()
264                    .fetchByG_A_V_E_E_L(groupId, articleId, version,
265             elInstanceId, elName, languageId);
266     }
267 
268     public static com.liferay.portlet.journal.model.JournalArticleImage fetchByG_A_V_E_E_L(
269         long groupId, java.lang.String articleId, double version,
270         java.lang.String elInstanceId, java.lang.String elName,
271         java.lang.String languageId, boolean retrieveFromCache)
272         throws com.liferay.portal.SystemException {
273         return getPersistence()
274                    .fetchByG_A_V_E_E_L(groupId, articleId, version,
275             elInstanceId, elName, languageId, retrieveFromCache);
276     }
277 
278     public static java.util.List<Object> findWithDynamicQuery(
279         com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
280         throws com.liferay.portal.SystemException {
281         return getPersistence().findWithDynamicQuery(dynamicQuery);
282     }
283 
284     public static java.util.List<Object> findWithDynamicQuery(
285         com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
286         int end) throws com.liferay.portal.SystemException {
287         return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
288     }
289 
290     public static java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> findAll()
291         throws com.liferay.portal.SystemException {
292         return getPersistence().findAll();
293     }
294 
295     public static java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> findAll(
296         int start, int end) throws com.liferay.portal.SystemException {
297         return getPersistence().findAll(start, end);
298     }
299 
300     public static java.util.List<com.liferay.portlet.journal.model.JournalArticleImage> findAll(
301         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
302         throws com.liferay.portal.SystemException {
303         return getPersistence().findAll(start, end, obc);
304     }
305 
306     public static void removeByGroupId(long groupId)
307         throws com.liferay.portal.SystemException {
308         getPersistence().removeByGroupId(groupId);
309     }
310 
311     public static void removeByTempImage(boolean tempImage)
312         throws com.liferay.portal.SystemException {
313         getPersistence().removeByTempImage(tempImage);
314     }
315 
316     public static void removeByG_A_V(long groupId, java.lang.String articleId,
317         double version) throws com.liferay.portal.SystemException {
318         getPersistence().removeByG_A_V(groupId, articleId, version);
319     }
320 
321     public static void removeByG_A_V_E_E_L(long groupId,
322         java.lang.String articleId, double version,
323         java.lang.String elInstanceId, java.lang.String elName,
324         java.lang.String languageId)
325         throws com.liferay.portal.SystemException,
326             com.liferay.portlet.journal.NoSuchArticleImageException {
327         getPersistence()
328             .removeByG_A_V_E_E_L(groupId, articleId, version, elInstanceId,
329             elName, languageId);
330     }
331 
332     public static void removeAll() throws com.liferay.portal.SystemException {
333         getPersistence().removeAll();
334     }
335 
336     public static int countByGroupId(long groupId)
337         throws com.liferay.portal.SystemException {
338         return getPersistence().countByGroupId(groupId);
339     }
340 
341     public static int countByTempImage(boolean tempImage)
342         throws com.liferay.portal.SystemException {
343         return getPersistence().countByTempImage(tempImage);
344     }
345 
346     public static int countByG_A_V(long groupId, java.lang.String articleId,
347         double version) throws com.liferay.portal.SystemException {
348         return getPersistence().countByG_A_V(groupId, articleId, version);
349     }
350 
351     public static int countByG_A_V_E_E_L(long groupId,
352         java.lang.String articleId, double version,
353         java.lang.String elInstanceId, java.lang.String elName,
354         java.lang.String languageId) throws com.liferay.portal.SystemException {
355         return getPersistence()
356                    .countByG_A_V_E_E_L(groupId, articleId, version,
357             elInstanceId, elName, languageId);
358     }
359 
360     public static int countAll() throws com.liferay.portal.SystemException {
361         return getPersistence().countAll();
362     }
363 
364     public static JournalArticleImagePersistence getPersistence() {
365         return _persistence;
366     }
367 
368     public void setPersistence(JournalArticleImagePersistence persistence) {
369         _persistence = persistence;
370     }
371 
372     private static JournalArticleImagePersistence _persistence;
373 }