1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * The contents of this file are subject to the terms of the Liferay Enterprise
5    * Subscription License ("License"). You may not use this file except in
6    * compliance with the License. You can obtain a copy of the License by
7    * contacting Liferay, Inc. See the License for the specific language governing
8    * permissions and limitations under the License, including but not limited to
9    * distribution rights of the Software.
10   *
11   *
12   * 
13   */
14  
15  package com.liferay.portlet.expando.service.persistence;
16  
17  import com.liferay.portal.SystemException;
18  import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
19  import com.liferay.portal.kernel.dao.orm.DynamicQuery;
20  
21  import com.liferay.portlet.expando.model.ExpandoTable;
22  
23  import java.util.List;
24  
25  /**
26   * <a href="ExpandoTableUtil.java.html"><b><i>View Source</i></b></a>
27   *
28   * <p>
29   * ServiceBuilder generated this class. Modifications in this class will be
30   * overwritten the next time is generated.
31   * </p>
32   *
33   * @author    Brian Wing Shun Chan
34   * @see       ExpandoTablePersistence
35   * @see       ExpandoTablePersistenceImpl
36   * @generated
37   */
38  public class ExpandoTableUtil {
39      /**
40       * @see com.liferay.portal.service.persistence.BasePersistence#clearCache()
41       */
42      public static void clearCache() {
43          getPersistence().clearCache();
44      }
45  
46      /**
47       * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery)
48       */
49      public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery)
50          throws SystemException {
51          return getPersistence().findWithDynamicQuery(dynamicQuery);
52      }
53  
54      /**
55       * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int)
56       */
57      public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery,
58          int start, int end) throws SystemException {
59          return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
60      }
61  
62      /**
63       * @see com.liferay.portal.service.persistence.BasePersistence#remove(com.liferay.portal.model.BaseModel)
64       */
65      public static ExpandoTable remove(ExpandoTable expandoTable)
66          throws SystemException {
67          return getPersistence().remove(expandoTable);
68      }
69  
70      /**
71       * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean)
72       */
73      public static ExpandoTable update(ExpandoTable expandoTable, boolean merge)
74          throws SystemException {
75          return getPersistence().update(expandoTable, merge);
76      }
77  
78      public static void cacheResult(
79          com.liferay.portlet.expando.model.ExpandoTable expandoTable) {
80          getPersistence().cacheResult(expandoTable);
81      }
82  
83      public static void cacheResult(
84          java.util.List<com.liferay.portlet.expando.model.ExpandoTable> expandoTables) {
85          getPersistence().cacheResult(expandoTables);
86      }
87  
88      public static com.liferay.portlet.expando.model.ExpandoTable create(
89          long tableId) {
90          return getPersistence().create(tableId);
91      }
92  
93      public static com.liferay.portlet.expando.model.ExpandoTable remove(
94          long tableId)
95          throws com.liferay.portal.SystemException,
96              com.liferay.portlet.expando.NoSuchTableException {
97          return getPersistence().remove(tableId);
98      }
99  
100     /**
101      * @deprecated Use {@link com.liferay.portal.service.persistence.BasePersistence.#update(com.liferay.portal.model.BaseModel, boolean)}.
102      */
103     public static com.liferay.portlet.expando.model.ExpandoTable update(
104         com.liferay.portlet.expando.model.ExpandoTable expandoTable)
105         throws com.liferay.portal.SystemException {
106         return getPersistence().update(expandoTable);
107     }
108 
109     public static com.liferay.portlet.expando.model.ExpandoTable updateImpl(
110         com.liferay.portlet.expando.model.ExpandoTable expandoTable,
111         boolean merge) throws com.liferay.portal.SystemException {
112         return getPersistence().updateImpl(expandoTable, merge);
113     }
114 
115     public static com.liferay.portlet.expando.model.ExpandoTable findByPrimaryKey(
116         long tableId)
117         throws com.liferay.portal.SystemException,
118             com.liferay.portlet.expando.NoSuchTableException {
119         return getPersistence().findByPrimaryKey(tableId);
120     }
121 
122     public static com.liferay.portlet.expando.model.ExpandoTable fetchByPrimaryKey(
123         long tableId) throws com.liferay.portal.SystemException {
124         return getPersistence().fetchByPrimaryKey(tableId);
125     }
126 
127     public static java.util.List<com.liferay.portlet.expando.model.ExpandoTable> findByClassNameId(
128         long classNameId) throws com.liferay.portal.SystemException {
129         return getPersistence().findByClassNameId(classNameId);
130     }
131 
132     public static java.util.List<com.liferay.portlet.expando.model.ExpandoTable> findByClassNameId(
133         long classNameId, int start, int end)
134         throws com.liferay.portal.SystemException {
135         return getPersistence().findByClassNameId(classNameId, start, end);
136     }
137 
138     public static java.util.List<com.liferay.portlet.expando.model.ExpandoTable> findByClassNameId(
139         long classNameId, int start, int end,
140         com.liferay.portal.kernel.util.OrderByComparator obc)
141         throws com.liferay.portal.SystemException {
142         return getPersistence().findByClassNameId(classNameId, start, end, obc);
143     }
144 
145     public static com.liferay.portlet.expando.model.ExpandoTable findByClassNameId_First(
146         long classNameId, com.liferay.portal.kernel.util.OrderByComparator obc)
147         throws com.liferay.portal.SystemException,
148             com.liferay.portlet.expando.NoSuchTableException {
149         return getPersistence().findByClassNameId_First(classNameId, obc);
150     }
151 
152     public static com.liferay.portlet.expando.model.ExpandoTable findByClassNameId_Last(
153         long classNameId, com.liferay.portal.kernel.util.OrderByComparator obc)
154         throws com.liferay.portal.SystemException,
155             com.liferay.portlet.expando.NoSuchTableException {
156         return getPersistence().findByClassNameId_Last(classNameId, obc);
157     }
158 
159     public static com.liferay.portlet.expando.model.ExpandoTable[] findByClassNameId_PrevAndNext(
160         long tableId, long classNameId,
161         com.liferay.portal.kernel.util.OrderByComparator obc)
162         throws com.liferay.portal.SystemException,
163             com.liferay.portlet.expando.NoSuchTableException {
164         return getPersistence()
165                    .findByClassNameId_PrevAndNext(tableId, classNameId, obc);
166     }
167 
168     public static com.liferay.portlet.expando.model.ExpandoTable findByC_N(
169         long classNameId, java.lang.String name)
170         throws com.liferay.portal.SystemException,
171             com.liferay.portlet.expando.NoSuchTableException {
172         return getPersistence().findByC_N(classNameId, name);
173     }
174 
175     public static com.liferay.portlet.expando.model.ExpandoTable fetchByC_N(
176         long classNameId, java.lang.String name)
177         throws com.liferay.portal.SystemException {
178         return getPersistence().fetchByC_N(classNameId, name);
179     }
180 
181     public static com.liferay.portlet.expando.model.ExpandoTable fetchByC_N(
182         long classNameId, java.lang.String name, boolean retrieveFromCache)
183         throws com.liferay.portal.SystemException {
184         return getPersistence().fetchByC_N(classNameId, name, retrieveFromCache);
185     }
186 
187     public static java.util.List<com.liferay.portlet.expando.model.ExpandoTable> findAll()
188         throws com.liferay.portal.SystemException {
189         return getPersistence().findAll();
190     }
191 
192     public static java.util.List<com.liferay.portlet.expando.model.ExpandoTable> findAll(
193         int start, int end) throws com.liferay.portal.SystemException {
194         return getPersistence().findAll(start, end);
195     }
196 
197     public static java.util.List<com.liferay.portlet.expando.model.ExpandoTable> findAll(
198         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
199         throws com.liferay.portal.SystemException {
200         return getPersistence().findAll(start, end, obc);
201     }
202 
203     public static void removeByClassNameId(long classNameId)
204         throws com.liferay.portal.SystemException {
205         getPersistence().removeByClassNameId(classNameId);
206     }
207 
208     public static void removeByC_N(long classNameId, java.lang.String name)
209         throws com.liferay.portal.SystemException,
210             com.liferay.portlet.expando.NoSuchTableException {
211         getPersistence().removeByC_N(classNameId, name);
212     }
213 
214     public static void removeAll() throws com.liferay.portal.SystemException {
215         getPersistence().removeAll();
216     }
217 
218     public static int countByClassNameId(long classNameId)
219         throws com.liferay.portal.SystemException {
220         return getPersistence().countByClassNameId(classNameId);
221     }
222 
223     public static int countByC_N(long classNameId, java.lang.String name)
224         throws com.liferay.portal.SystemException {
225         return getPersistence().countByC_N(classNameId, name);
226     }
227 
228     public static int countAll() throws com.liferay.portal.SystemException {
229         return getPersistence().countAll();
230     }
231 
232     public static ExpandoTablePersistence getPersistence() {
233         if (_persistence == null) {
234             _persistence = (ExpandoTablePersistence)PortalBeanLocatorUtil.locate(ExpandoTablePersistence.class.getName());
235         }
236 
237         return _persistence;
238     }
239 
240     public void setPersistence(ExpandoTablePersistence persistence) {
241         _persistence = persistence;
242     }
243 
244     private static ExpandoTablePersistence _persistence;
245 }