1   /**
2    * Copyright (c) 2000-2008 Liferay, Inc. All rights reserved.
3    *
4    * Permission is hereby granted, free of charge, to any person obtaining a copy
5    * of this software and associated documentation files (the "Software"), to deal
6    * in the Software without restriction, including without limitation the rights
7    * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8    * copies of the Software, and to permit persons to whom the Software is
9    * furnished to do so, subject to the following conditions:
10   *
11   * The above copyright notice and this permission notice shall be included in
12   * all copies or substantial portions 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.portal.service.persistence;
24  
25  /**
26   * <a href="ServiceComponentUtil.java.html"><b><i>View Source</i></b></a>
27   *
28   * @author Brian Wing Shun Chan
29   *
30   */
31  public class ServiceComponentUtil {
32      public static com.liferay.portal.model.ServiceComponent create(
33          long serviceComponentId) {
34          return getPersistence().create(serviceComponentId);
35      }
36  
37      public static com.liferay.portal.model.ServiceComponent remove(
38          long serviceComponentId)
39          throws com.liferay.portal.NoSuchServiceComponentException, 
40              com.liferay.portal.SystemException {
41          return getPersistence().remove(serviceComponentId);
42      }
43  
44      public static com.liferay.portal.model.ServiceComponent remove(
45          com.liferay.portal.model.ServiceComponent serviceComponent)
46          throws com.liferay.portal.SystemException {
47          return getPersistence().remove(serviceComponent);
48      }
49  
50      public static com.liferay.portal.model.ServiceComponent update(
51          com.liferay.portal.model.ServiceComponent serviceComponent)
52          throws com.liferay.portal.SystemException {
53          return getPersistence().update(serviceComponent);
54      }
55  
56      public static com.liferay.portal.model.ServiceComponent update(
57          com.liferay.portal.model.ServiceComponent serviceComponent,
58          boolean merge) throws com.liferay.portal.SystemException {
59          return getPersistence().update(serviceComponent, merge);
60      }
61  
62      public static com.liferay.portal.model.ServiceComponent updateImpl(
63          com.liferay.portal.model.ServiceComponent serviceComponent,
64          boolean merge) throws com.liferay.portal.SystemException {
65          return getPersistence().updateImpl(serviceComponent, merge);
66      }
67  
68      public static com.liferay.portal.model.ServiceComponent findByPrimaryKey(
69          long serviceComponentId)
70          throws com.liferay.portal.NoSuchServiceComponentException, 
71              com.liferay.portal.SystemException {
72          return getPersistence().findByPrimaryKey(serviceComponentId);
73      }
74  
75      public static com.liferay.portal.model.ServiceComponent fetchByPrimaryKey(
76          long serviceComponentId) throws com.liferay.portal.SystemException {
77          return getPersistence().fetchByPrimaryKey(serviceComponentId);
78      }
79  
80      public static java.util.List findByBuildNamespace(
81          java.lang.String buildNamespace)
82          throws com.liferay.portal.SystemException {
83          return getPersistence().findByBuildNamespace(buildNamespace);
84      }
85  
86      public static java.util.List findByBuildNamespace(
87          java.lang.String buildNamespace, int begin, int end)
88          throws com.liferay.portal.SystemException {
89          return getPersistence().findByBuildNamespace(buildNamespace, begin, end);
90      }
91  
92      public static java.util.List findByBuildNamespace(
93          java.lang.String buildNamespace, int begin, int end,
94          com.liferay.portal.kernel.util.OrderByComparator obc)
95          throws com.liferay.portal.SystemException {
96          return getPersistence().findByBuildNamespace(buildNamespace, begin,
97              end, obc);
98      }
99  
100     public static com.liferay.portal.model.ServiceComponent findByBuildNamespace_First(
101         java.lang.String buildNamespace,
102         com.liferay.portal.kernel.util.OrderByComparator obc)
103         throws com.liferay.portal.NoSuchServiceComponentException, 
104             com.liferay.portal.SystemException {
105         return getPersistence().findByBuildNamespace_First(buildNamespace, obc);
106     }
107 
108     public static com.liferay.portal.model.ServiceComponent findByBuildNamespace_Last(
109         java.lang.String buildNamespace,
110         com.liferay.portal.kernel.util.OrderByComparator obc)
111         throws com.liferay.portal.NoSuchServiceComponentException, 
112             com.liferay.portal.SystemException {
113         return getPersistence().findByBuildNamespace_Last(buildNamespace, obc);
114     }
115 
116     public static com.liferay.portal.model.ServiceComponent[] findByBuildNamespace_PrevAndNext(
117         long serviceComponentId, java.lang.String buildNamespace,
118         com.liferay.portal.kernel.util.OrderByComparator obc)
119         throws com.liferay.portal.NoSuchServiceComponentException, 
120             com.liferay.portal.SystemException {
121         return getPersistence().findByBuildNamespace_PrevAndNext(serviceComponentId,
122             buildNamespace, obc);
123     }
124 
125     public static com.liferay.portal.model.ServiceComponent findByBNS_BNU(
126         java.lang.String buildNamespace, long buildNumber)
127         throws com.liferay.portal.NoSuchServiceComponentException, 
128             com.liferay.portal.SystemException {
129         return getPersistence().findByBNS_BNU(buildNamespace, buildNumber);
130     }
131 
132     public static com.liferay.portal.model.ServiceComponent fetchByBNS_BNU(
133         java.lang.String buildNamespace, long buildNumber)
134         throws com.liferay.portal.SystemException {
135         return getPersistence().fetchByBNS_BNU(buildNamespace, buildNumber);
136     }
137 
138     public static java.util.List findWithDynamicQuery(
139         com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer)
140         throws com.liferay.portal.SystemException {
141         return getPersistence().findWithDynamicQuery(queryInitializer);
142     }
143 
144     public static java.util.List findWithDynamicQuery(
145         com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer,
146         int begin, int end) throws com.liferay.portal.SystemException {
147         return getPersistence().findWithDynamicQuery(queryInitializer, begin,
148             end);
149     }
150 
151     public static java.util.List findAll()
152         throws com.liferay.portal.SystemException {
153         return getPersistence().findAll();
154     }
155 
156     public static java.util.List findAll(int begin, int end)
157         throws com.liferay.portal.SystemException {
158         return getPersistence().findAll(begin, end);
159     }
160 
161     public static java.util.List findAll(int begin, int end,
162         com.liferay.portal.kernel.util.OrderByComparator obc)
163         throws com.liferay.portal.SystemException {
164         return getPersistence().findAll(begin, end, obc);
165     }
166 
167     public static void removeByBuildNamespace(java.lang.String buildNamespace)
168         throws com.liferay.portal.SystemException {
169         getPersistence().removeByBuildNamespace(buildNamespace);
170     }
171 
172     public static void removeByBNS_BNU(java.lang.String buildNamespace,
173         long buildNumber)
174         throws com.liferay.portal.NoSuchServiceComponentException, 
175             com.liferay.portal.SystemException {
176         getPersistence().removeByBNS_BNU(buildNamespace, buildNumber);
177     }
178 
179     public static void removeAll() throws com.liferay.portal.SystemException {
180         getPersistence().removeAll();
181     }
182 
183     public static int countByBuildNamespace(java.lang.String buildNamespace)
184         throws com.liferay.portal.SystemException {
185         return getPersistence().countByBuildNamespace(buildNamespace);
186     }
187 
188     public static int countByBNS_BNU(java.lang.String buildNamespace,
189         long buildNumber) throws com.liferay.portal.SystemException {
190         return getPersistence().countByBNS_BNU(buildNamespace, buildNumber);
191     }
192 
193     public static int countAll() throws com.liferay.portal.SystemException {
194         return getPersistence().countAll();
195     }
196 
197     public static ServiceComponentPersistence getPersistence() {
198         return _getUtil()._persistence;
199     }
200 
201     public void setPersistence(ServiceComponentPersistence persistence) {
202         _persistence = persistence;
203     }
204 
205     private static ServiceComponentUtil _getUtil() {
206         if (_util == null) {
207             _util = (ServiceComponentUtil)com.liferay.portal.kernel.bean.BeanLocatorUtil.locate(_UTIL);
208         }
209 
210         return _util;
211     }
212 
213     private static final String _UTIL = ServiceComponentUtil.class.getName();
214     private static ServiceComponentUtil _util;
215     private ServiceComponentPersistence _persistence;
216 }