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.portal.service.persistence;
24  
25  
26  /**
27   * <a href="EmailAddressPersistence.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       EmailAddressPersistenceImpl
36   * @see       EmailAddressUtil
37   * @generated
38   */
39  public interface EmailAddressPersistence extends BasePersistence {
40      public void cacheResult(com.liferay.portal.model.EmailAddress emailAddress);
41  
42      public void cacheResult(
43          java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses);
44  
45      public void clearCache();
46  
47      public com.liferay.portal.model.EmailAddress create(long emailAddressId);
48  
49      public com.liferay.portal.model.EmailAddress remove(long emailAddressId)
50          throws com.liferay.portal.NoSuchEmailAddressException,
51              com.liferay.portal.SystemException;
52  
53      public com.liferay.portal.model.EmailAddress remove(
54          com.liferay.portal.model.EmailAddress emailAddress)
55          throws com.liferay.portal.SystemException;
56  
57      /**
58       * @deprecated Use {@link #update(EmailAddress, boolean merge)}.
59       */
60      public com.liferay.portal.model.EmailAddress update(
61          com.liferay.portal.model.EmailAddress emailAddress)
62          throws com.liferay.portal.SystemException;
63  
64      /**
65       * Add, update, or merge, the entity. This method also calls the model
66       * listeners to trigger the proper events associated with adding, deleting,
67       * or updating an entity.
68       *
69       * @param  emailAddress the entity to add, update, or merge
70       * @param  merge boolean value for whether to merge the entity. The default
71       *         value is false. Setting merge to true is more expensive and
72       *         should only be true when emailAddress is transient. See
73       *         LEP-5473 for a detailed discussion of this method.
74       * @return the entity that was added, updated, or merged
75       */
76      public com.liferay.portal.model.EmailAddress update(
77          com.liferay.portal.model.EmailAddress emailAddress, boolean merge)
78          throws com.liferay.portal.SystemException;
79  
80      public com.liferay.portal.model.EmailAddress updateImpl(
81          com.liferay.portal.model.EmailAddress emailAddress, boolean merge)
82          throws com.liferay.portal.SystemException;
83  
84      public com.liferay.portal.model.EmailAddress findByPrimaryKey(
85          long emailAddressId)
86          throws com.liferay.portal.NoSuchEmailAddressException,
87              com.liferay.portal.SystemException;
88  
89      public com.liferay.portal.model.EmailAddress fetchByPrimaryKey(
90          long emailAddressId) throws com.liferay.portal.SystemException;
91  
92      public java.util.List<com.liferay.portal.model.EmailAddress> findByCompanyId(
93          long companyId) throws com.liferay.portal.SystemException;
94  
95      public java.util.List<com.liferay.portal.model.EmailAddress> findByCompanyId(
96          long companyId, int start, int end)
97          throws com.liferay.portal.SystemException;
98  
99      public java.util.List<com.liferay.portal.model.EmailAddress> findByCompanyId(
100         long companyId, int start, int end,
101         com.liferay.portal.kernel.util.OrderByComparator obc)
102         throws com.liferay.portal.SystemException;
103 
104     public com.liferay.portal.model.EmailAddress findByCompanyId_First(
105         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
106         throws com.liferay.portal.NoSuchEmailAddressException,
107             com.liferay.portal.SystemException;
108 
109     public com.liferay.portal.model.EmailAddress findByCompanyId_Last(
110         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
111         throws com.liferay.portal.NoSuchEmailAddressException,
112             com.liferay.portal.SystemException;
113 
114     public com.liferay.portal.model.EmailAddress[] findByCompanyId_PrevAndNext(
115         long emailAddressId, long companyId,
116         com.liferay.portal.kernel.util.OrderByComparator obc)
117         throws com.liferay.portal.NoSuchEmailAddressException,
118             com.liferay.portal.SystemException;
119 
120     public java.util.List<com.liferay.portal.model.EmailAddress> findByUserId(
121         long userId) throws com.liferay.portal.SystemException;
122 
123     public java.util.List<com.liferay.portal.model.EmailAddress> findByUserId(
124         long userId, int start, int end)
125         throws com.liferay.portal.SystemException;
126 
127     public java.util.List<com.liferay.portal.model.EmailAddress> findByUserId(
128         long userId, int start, int end,
129         com.liferay.portal.kernel.util.OrderByComparator obc)
130         throws com.liferay.portal.SystemException;
131 
132     public com.liferay.portal.model.EmailAddress findByUserId_First(
133         long userId, com.liferay.portal.kernel.util.OrderByComparator obc)
134         throws com.liferay.portal.NoSuchEmailAddressException,
135             com.liferay.portal.SystemException;
136 
137     public com.liferay.portal.model.EmailAddress findByUserId_Last(
138         long userId, com.liferay.portal.kernel.util.OrderByComparator obc)
139         throws com.liferay.portal.NoSuchEmailAddressException,
140             com.liferay.portal.SystemException;
141 
142     public com.liferay.portal.model.EmailAddress[] findByUserId_PrevAndNext(
143         long emailAddressId, long userId,
144         com.liferay.portal.kernel.util.OrderByComparator obc)
145         throws com.liferay.portal.NoSuchEmailAddressException,
146             com.liferay.portal.SystemException;
147 
148     public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C(
149         long companyId, long classNameId)
150         throws com.liferay.portal.SystemException;
151 
152     public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C(
153         long companyId, long classNameId, int start, int end)
154         throws com.liferay.portal.SystemException;
155 
156     public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C(
157         long companyId, long classNameId, int start, int end,
158         com.liferay.portal.kernel.util.OrderByComparator obc)
159         throws com.liferay.portal.SystemException;
160 
161     public com.liferay.portal.model.EmailAddress findByC_C_First(
162         long companyId, long classNameId,
163         com.liferay.portal.kernel.util.OrderByComparator obc)
164         throws com.liferay.portal.NoSuchEmailAddressException,
165             com.liferay.portal.SystemException;
166 
167     public com.liferay.portal.model.EmailAddress findByC_C_Last(
168         long companyId, long classNameId,
169         com.liferay.portal.kernel.util.OrderByComparator obc)
170         throws com.liferay.portal.NoSuchEmailAddressException,
171             com.liferay.portal.SystemException;
172 
173     public com.liferay.portal.model.EmailAddress[] findByC_C_PrevAndNext(
174         long emailAddressId, long companyId, long classNameId,
175         com.liferay.portal.kernel.util.OrderByComparator obc)
176         throws com.liferay.portal.NoSuchEmailAddressException,
177             com.liferay.portal.SystemException;
178 
179     public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C_C(
180         long companyId, long classNameId, long classPK)
181         throws com.liferay.portal.SystemException;
182 
183     public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C_C(
184         long companyId, long classNameId, long classPK, int start, int end)
185         throws com.liferay.portal.SystemException;
186 
187     public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C_C(
188         long companyId, long classNameId, long classPK, int start, int end,
189         com.liferay.portal.kernel.util.OrderByComparator obc)
190         throws com.liferay.portal.SystemException;
191 
192     public com.liferay.portal.model.EmailAddress findByC_C_C_First(
193         long companyId, long classNameId, long classPK,
194         com.liferay.portal.kernel.util.OrderByComparator obc)
195         throws com.liferay.portal.NoSuchEmailAddressException,
196             com.liferay.portal.SystemException;
197 
198     public com.liferay.portal.model.EmailAddress findByC_C_C_Last(
199         long companyId, long classNameId, long classPK,
200         com.liferay.portal.kernel.util.OrderByComparator obc)
201         throws com.liferay.portal.NoSuchEmailAddressException,
202             com.liferay.portal.SystemException;
203 
204     public com.liferay.portal.model.EmailAddress[] findByC_C_C_PrevAndNext(
205         long emailAddressId, long companyId, long classNameId, long classPK,
206         com.liferay.portal.kernel.util.OrderByComparator obc)
207         throws com.liferay.portal.NoSuchEmailAddressException,
208             com.liferay.portal.SystemException;
209 
210     public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C_C_P(
211         long companyId, long classNameId, long classPK, boolean primary)
212         throws com.liferay.portal.SystemException;
213 
214     public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C_C_P(
215         long companyId, long classNameId, long classPK, boolean primary,
216         int start, int end) throws com.liferay.portal.SystemException;
217 
218     public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C_C_P(
219         long companyId, long classNameId, long classPK, boolean primary,
220         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
221         throws com.liferay.portal.SystemException;
222 
223     public com.liferay.portal.model.EmailAddress findByC_C_C_P_First(
224         long companyId, long classNameId, long classPK, boolean primary,
225         com.liferay.portal.kernel.util.OrderByComparator obc)
226         throws com.liferay.portal.NoSuchEmailAddressException,
227             com.liferay.portal.SystemException;
228 
229     public com.liferay.portal.model.EmailAddress findByC_C_C_P_Last(
230         long companyId, long classNameId, long classPK, boolean primary,
231         com.liferay.portal.kernel.util.OrderByComparator obc)
232         throws com.liferay.portal.NoSuchEmailAddressException,
233             com.liferay.portal.SystemException;
234 
235     public com.liferay.portal.model.EmailAddress[] findByC_C_C_P_PrevAndNext(
236         long emailAddressId, long companyId, long classNameId, long classPK,
237         boolean primary, com.liferay.portal.kernel.util.OrderByComparator obc)
238         throws com.liferay.portal.NoSuchEmailAddressException,
239             com.liferay.portal.SystemException;
240 
241     public java.util.List<Object> findWithDynamicQuery(
242         com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
243         throws com.liferay.portal.SystemException;
244 
245     public java.util.List<Object> findWithDynamicQuery(
246         com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
247         int end) throws com.liferay.portal.SystemException;
248 
249     public java.util.List<com.liferay.portal.model.EmailAddress> findAll()
250         throws com.liferay.portal.SystemException;
251 
252     public java.util.List<com.liferay.portal.model.EmailAddress> findAll(
253         int start, int end) throws com.liferay.portal.SystemException;
254 
255     public java.util.List<com.liferay.portal.model.EmailAddress> findAll(
256         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
257         throws com.liferay.portal.SystemException;
258 
259     public void removeByCompanyId(long companyId)
260         throws com.liferay.portal.SystemException;
261 
262     public void removeByUserId(long userId)
263         throws com.liferay.portal.SystemException;
264 
265     public void removeByC_C(long companyId, long classNameId)
266         throws com.liferay.portal.SystemException;
267 
268     public void removeByC_C_C(long companyId, long classNameId, long classPK)
269         throws com.liferay.portal.SystemException;
270 
271     public void removeByC_C_C_P(long companyId, long classNameId, long classPK,
272         boolean primary) throws com.liferay.portal.SystemException;
273 
274     public void removeAll() throws com.liferay.portal.SystemException;
275 
276     public int countByCompanyId(long companyId)
277         throws com.liferay.portal.SystemException;
278 
279     public int countByUserId(long userId)
280         throws com.liferay.portal.SystemException;
281 
282     public int countByC_C(long companyId, long classNameId)
283         throws com.liferay.portal.SystemException;
284 
285     public int countByC_C_C(long companyId, long classNameId, long classPK)
286         throws com.liferay.portal.SystemException;
287 
288     public int countByC_C_C_P(long companyId, long classNameId, long classPK,
289         boolean primary) throws com.liferay.portal.SystemException;
290 
291     public int countAll() throws com.liferay.portal.SystemException;
292 }