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.portal.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  import com.liferay.portal.kernel.util.ReferenceRegistry;
21  import com.liferay.portal.model.BrowserTracker;
22  
23  import java.util.List;
24  
25  /**
26   * <a href="BrowserTrackerUtil.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       BrowserTrackerPersistence
35   * @see       BrowserTrackerPersistenceImpl
36   * @generated
37   */
38  public class BrowserTrackerUtil {
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#clearCache(BrowserTracker)
48       */
49      public static void clearCache(BrowserTracker browserTracker) {
50          getPersistence().clearCache(browserTracker);
51      }
52  
53      /**
54       * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery)
55       */
56      public int countWithDynamicQuery(DynamicQuery dynamicQuery)
57          throws SystemException {
58          return getPersistence().countWithDynamicQuery(dynamicQuery);
59      }
60  
61      /**
62       * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery)
63       */
64      public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery)
65          throws SystemException {
66          return getPersistence().findWithDynamicQuery(dynamicQuery);
67      }
68  
69      /**
70       * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int)
71       */
72      public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery,
73          int start, int end) throws SystemException {
74          return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
75      }
76  
77      /**
78       * @see com.liferay.portal.service.persistence.BasePersistence#remove(com.liferay.portal.model.BaseModel)
79       */
80      public static BrowserTracker remove(BrowserTracker browserTracker)
81          throws SystemException {
82          return getPersistence().remove(browserTracker);
83      }
84  
85      /**
86       * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean)
87       */
88      public static BrowserTracker update(BrowserTracker browserTracker,
89          boolean merge) throws SystemException {
90          return getPersistence().update(browserTracker, merge);
91      }
92  
93      public static void cacheResult(
94          com.liferay.portal.model.BrowserTracker browserTracker) {
95          getPersistence().cacheResult(browserTracker);
96      }
97  
98      public static void cacheResult(
99          java.util.List<com.liferay.portal.model.BrowserTracker> browserTrackers) {
100         getPersistence().cacheResult(browserTrackers);
101     }
102 
103     public static com.liferay.portal.model.BrowserTracker create(
104         long browserTrackerId) {
105         return getPersistence().create(browserTrackerId);
106     }
107 
108     public static com.liferay.portal.model.BrowserTracker remove(
109         long browserTrackerId)
110         throws com.liferay.portal.NoSuchBrowserTrackerException,
111             com.liferay.portal.SystemException {
112         return getPersistence().remove(browserTrackerId);
113     }
114 
115     /**
116      * @deprecated Use {@link com.liferay.portal.service.persistence.BasePersistence.#update(com.liferay.portal.model.BaseModel, boolean)}.
117      */
118     public static com.liferay.portal.model.BrowserTracker update(
119         com.liferay.portal.model.BrowserTracker browserTracker)
120         throws com.liferay.portal.SystemException {
121         return getPersistence().update(browserTracker);
122     }
123 
124     public static com.liferay.portal.model.BrowserTracker updateImpl(
125         com.liferay.portal.model.BrowserTracker browserTracker, boolean merge)
126         throws com.liferay.portal.SystemException {
127         return getPersistence().updateImpl(browserTracker, merge);
128     }
129 
130     public static com.liferay.portal.model.BrowserTracker findByPrimaryKey(
131         long browserTrackerId)
132         throws com.liferay.portal.NoSuchBrowserTrackerException,
133             com.liferay.portal.SystemException {
134         return getPersistence().findByPrimaryKey(browserTrackerId);
135     }
136 
137     public static com.liferay.portal.model.BrowserTracker fetchByPrimaryKey(
138         long browserTrackerId) throws com.liferay.portal.SystemException {
139         return getPersistence().fetchByPrimaryKey(browserTrackerId);
140     }
141 
142     public static com.liferay.portal.model.BrowserTracker findByUserId(
143         long userId)
144         throws com.liferay.portal.NoSuchBrowserTrackerException,
145             com.liferay.portal.SystemException {
146         return getPersistence().findByUserId(userId);
147     }
148 
149     public static com.liferay.portal.model.BrowserTracker fetchByUserId(
150         long userId) throws com.liferay.portal.SystemException {
151         return getPersistence().fetchByUserId(userId);
152     }
153 
154     public static com.liferay.portal.model.BrowserTracker fetchByUserId(
155         long userId, boolean retrieveFromCache)
156         throws com.liferay.portal.SystemException {
157         return getPersistence().fetchByUserId(userId, retrieveFromCache);
158     }
159 
160     public static java.util.List<com.liferay.portal.model.BrowserTracker> findAll()
161         throws com.liferay.portal.SystemException {
162         return getPersistence().findAll();
163     }
164 
165     public static java.util.List<com.liferay.portal.model.BrowserTracker> findAll(
166         int start, int end) throws com.liferay.portal.SystemException {
167         return getPersistence().findAll(start, end);
168     }
169 
170     public static java.util.List<com.liferay.portal.model.BrowserTracker> findAll(
171         int start, int end,
172         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
173         throws com.liferay.portal.SystemException {
174         return getPersistence().findAll(start, end, orderByComparator);
175     }
176 
177     public static void removeByUserId(long userId)
178         throws com.liferay.portal.NoSuchBrowserTrackerException,
179             com.liferay.portal.SystemException {
180         getPersistence().removeByUserId(userId);
181     }
182 
183     public static void removeAll() throws com.liferay.portal.SystemException {
184         getPersistence().removeAll();
185     }
186 
187     public static int countByUserId(long userId)
188         throws com.liferay.portal.SystemException {
189         return getPersistence().countByUserId(userId);
190     }
191 
192     public static int countAll() throws com.liferay.portal.SystemException {
193         return getPersistence().countAll();
194     }
195 
196     public static BrowserTrackerPersistence getPersistence() {
197         if (_persistence == null) {
198             _persistence = (BrowserTrackerPersistence)PortalBeanLocatorUtil.locate(BrowserTrackerPersistence.class.getName());
199 
200             ReferenceRegistry.registerReference(BrowserTrackerUtil.class,
201                 "_persistence");
202         }
203 
204         return _persistence;
205     }
206 
207     public void setPersistence(BrowserTrackerPersistence persistence) {
208         _persistence = persistence;
209 
210         ReferenceRegistry.registerReference(BrowserTrackerUtil.class,
211             "_persistence");
212     }
213 
214     private static BrowserTrackerPersistence _persistence;
215 }