1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * This library is free software; you can redistribute it and/or modify it under
5    * the terms of the GNU Lesser General Public License as published by the Free
6    * Software Foundation; either version 2.1 of the License, or (at your option)
7    * any later version.
8    *
9    * This library is distributed in the hope that it will be useful, but WITHOUT
10   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11   * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
12   * details.
13   */
14  
15  package com.liferay.portal.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  import com.liferay.portal.model.LayoutSet;
21  
22  import java.util.List;
23  
24  /**
25   * <a href="LayoutSetUtil.java.html"><b><i>View Source</i></b></a>
26   *
27   * <p>
28   * ServiceBuilder generated this class. Modifications in this class will be
29   * overwritten the next time is generated.
30   * </p>
31   *
32   * @author    Brian Wing Shun Chan
33   * @see       LayoutSetPersistence
34   * @see       LayoutSetPersistenceImpl
35   * @generated
36   */
37  public class LayoutSetUtil {
38      /**
39       * @see com.liferay.portal.service.persistence.BasePersistence#clearCache()
40       */
41      public static void clearCache() {
42          getPersistence().clearCache();
43      }
44  
45      /**
46       * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery)
47       */
48      public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery)
49          throws SystemException {
50          return getPersistence().findWithDynamicQuery(dynamicQuery);
51      }
52  
53      /**
54       * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int)
55       */
56      public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery,
57          int start, int end) throws SystemException {
58          return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
59      }
60  
61      /**
62       * @see com.liferay.portal.service.persistence.BasePersistence#remove(com.liferay.portal.model.BaseModel)
63       */
64      public static LayoutSet remove(LayoutSet layoutSet)
65          throws SystemException {
66          return getPersistence().remove(layoutSet);
67      }
68  
69      /**
70       * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean)
71       */
72      public static LayoutSet update(LayoutSet layoutSet, boolean merge)
73          throws SystemException {
74          return getPersistence().update(layoutSet, merge);
75      }
76  
77      public static void cacheResult(com.liferay.portal.model.LayoutSet layoutSet) {
78          getPersistence().cacheResult(layoutSet);
79      }
80  
81      public static void cacheResult(
82          java.util.List<com.liferay.portal.model.LayoutSet> layoutSets) {
83          getPersistence().cacheResult(layoutSets);
84      }
85  
86      public static com.liferay.portal.model.LayoutSet create(long layoutSetId) {
87          return getPersistence().create(layoutSetId);
88      }
89  
90      public static com.liferay.portal.model.LayoutSet remove(long layoutSetId)
91          throws com.liferay.portal.NoSuchLayoutSetException,
92              com.liferay.portal.kernel.exception.SystemException {
93          return getPersistence().remove(layoutSetId);
94      }
95  
96      public static com.liferay.portal.model.LayoutSet updateImpl(
97          com.liferay.portal.model.LayoutSet layoutSet, boolean merge)
98          throws com.liferay.portal.kernel.exception.SystemException {
99          return getPersistence().updateImpl(layoutSet, merge);
100     }
101 
102     public static com.liferay.portal.model.LayoutSet findByPrimaryKey(
103         long layoutSetId)
104         throws com.liferay.portal.NoSuchLayoutSetException,
105             com.liferay.portal.kernel.exception.SystemException {
106         return getPersistence().findByPrimaryKey(layoutSetId);
107     }
108 
109     public static com.liferay.portal.model.LayoutSet fetchByPrimaryKey(
110         long layoutSetId)
111         throws com.liferay.portal.kernel.exception.SystemException {
112         return getPersistence().fetchByPrimaryKey(layoutSetId);
113     }
114 
115     public static java.util.List<com.liferay.portal.model.LayoutSet> findByGroupId(
116         long groupId)
117         throws com.liferay.portal.kernel.exception.SystemException {
118         return getPersistence().findByGroupId(groupId);
119     }
120 
121     public static java.util.List<com.liferay.portal.model.LayoutSet> findByGroupId(
122         long groupId, int start, int end)
123         throws com.liferay.portal.kernel.exception.SystemException {
124         return getPersistence().findByGroupId(groupId, start, end);
125     }
126 
127     public static java.util.List<com.liferay.portal.model.LayoutSet> findByGroupId(
128         long groupId, int start, int end,
129         com.liferay.portal.kernel.util.OrderByComparator obc)
130         throws com.liferay.portal.kernel.exception.SystemException {
131         return getPersistence().findByGroupId(groupId, start, end, obc);
132     }
133 
134     public static com.liferay.portal.model.LayoutSet findByGroupId_First(
135         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
136         throws com.liferay.portal.NoSuchLayoutSetException,
137             com.liferay.portal.kernel.exception.SystemException {
138         return getPersistence().findByGroupId_First(groupId, obc);
139     }
140 
141     public static com.liferay.portal.model.LayoutSet findByGroupId_Last(
142         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
143         throws com.liferay.portal.NoSuchLayoutSetException,
144             com.liferay.portal.kernel.exception.SystemException {
145         return getPersistence().findByGroupId_Last(groupId, obc);
146     }
147 
148     public static com.liferay.portal.model.LayoutSet[] findByGroupId_PrevAndNext(
149         long layoutSetId, long groupId,
150         com.liferay.portal.kernel.util.OrderByComparator obc)
151         throws com.liferay.portal.NoSuchLayoutSetException,
152             com.liferay.portal.kernel.exception.SystemException {
153         return getPersistence()
154                    .findByGroupId_PrevAndNext(layoutSetId, groupId, obc);
155     }
156 
157     public static com.liferay.portal.model.LayoutSet findByVirtualHost(
158         java.lang.String virtualHost)
159         throws com.liferay.portal.NoSuchLayoutSetException,
160             com.liferay.portal.kernel.exception.SystemException {
161         return getPersistence().findByVirtualHost(virtualHost);
162     }
163 
164     public static com.liferay.portal.model.LayoutSet fetchByVirtualHost(
165         java.lang.String virtualHost)
166         throws com.liferay.portal.kernel.exception.SystemException {
167         return getPersistence().fetchByVirtualHost(virtualHost);
168     }
169 
170     public static com.liferay.portal.model.LayoutSet fetchByVirtualHost(
171         java.lang.String virtualHost, boolean retrieveFromCache)
172         throws com.liferay.portal.kernel.exception.SystemException {
173         return getPersistence()
174                    .fetchByVirtualHost(virtualHost, retrieveFromCache);
175     }
176 
177     public static com.liferay.portal.model.LayoutSet findByG_P(long groupId,
178         boolean privateLayout)
179         throws com.liferay.portal.NoSuchLayoutSetException,
180             com.liferay.portal.kernel.exception.SystemException {
181         return getPersistence().findByG_P(groupId, privateLayout);
182     }
183 
184     public static com.liferay.portal.model.LayoutSet fetchByG_P(long groupId,
185         boolean privateLayout)
186         throws com.liferay.portal.kernel.exception.SystemException {
187         return getPersistence().fetchByG_P(groupId, privateLayout);
188     }
189 
190     public static com.liferay.portal.model.LayoutSet fetchByG_P(long groupId,
191         boolean privateLayout, boolean retrieveFromCache)
192         throws com.liferay.portal.kernel.exception.SystemException {
193         return getPersistence()
194                    .fetchByG_P(groupId, privateLayout, retrieveFromCache);
195     }
196 
197     public static java.util.List<com.liferay.portal.model.LayoutSet> findAll()
198         throws com.liferay.portal.kernel.exception.SystemException {
199         return getPersistence().findAll();
200     }
201 
202     public static java.util.List<com.liferay.portal.model.LayoutSet> findAll(
203         int start, int end)
204         throws com.liferay.portal.kernel.exception.SystemException {
205         return getPersistence().findAll(start, end);
206     }
207 
208     public static java.util.List<com.liferay.portal.model.LayoutSet> findAll(
209         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
210         throws com.liferay.portal.kernel.exception.SystemException {
211         return getPersistence().findAll(start, end, obc);
212     }
213 
214     public static void removeByGroupId(long groupId)
215         throws com.liferay.portal.kernel.exception.SystemException {
216         getPersistence().removeByGroupId(groupId);
217     }
218 
219     public static void removeByVirtualHost(java.lang.String virtualHost)
220         throws com.liferay.portal.NoSuchLayoutSetException,
221             com.liferay.portal.kernel.exception.SystemException {
222         getPersistence().removeByVirtualHost(virtualHost);
223     }
224 
225     public static void removeByG_P(long groupId, boolean privateLayout)
226         throws com.liferay.portal.NoSuchLayoutSetException,
227             com.liferay.portal.kernel.exception.SystemException {
228         getPersistence().removeByG_P(groupId, privateLayout);
229     }
230 
231     public static void removeAll()
232         throws com.liferay.portal.kernel.exception.SystemException {
233         getPersistence().removeAll();
234     }
235 
236     public static int countByGroupId(long groupId)
237         throws com.liferay.portal.kernel.exception.SystemException {
238         return getPersistence().countByGroupId(groupId);
239     }
240 
241     public static int countByVirtualHost(java.lang.String virtualHost)
242         throws com.liferay.portal.kernel.exception.SystemException {
243         return getPersistence().countByVirtualHost(virtualHost);
244     }
245 
246     public static int countByG_P(long groupId, boolean privateLayout)
247         throws com.liferay.portal.kernel.exception.SystemException {
248         return getPersistence().countByG_P(groupId, privateLayout);
249     }
250 
251     public static int countAll()
252         throws com.liferay.portal.kernel.exception.SystemException {
253         return getPersistence().countAll();
254     }
255 
256     public static LayoutSetPersistence getPersistence() {
257         if (_persistence == null) {
258             _persistence = (LayoutSetPersistence)PortalBeanLocatorUtil.locate(LayoutSetPersistence.class.getName());
259         }
260 
261         return _persistence;
262     }
263 
264     public void setPersistence(LayoutSetPersistence persistence) {
265         _persistence = persistence;
266     }
267 
268     private static LayoutSetPersistence _persistence;
269 }