001    /**
002     * Copyright (c) 2000-present Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portal.service.persistence;
016    
017    import aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.model.EmailAddress;
020    
021    /**
022     * The persistence interface for the email address service.
023     *
024     * <p>
025     * Caching information and settings can be found in <code>portal.properties</code>
026     * </p>
027     *
028     * @author Brian Wing Shun Chan
029     * @see EmailAddressPersistenceImpl
030     * @see EmailAddressUtil
031     * @generated
032     */
033    @ProviderType
034    public interface EmailAddressPersistence extends BasePersistence<EmailAddress> {
035            /*
036             * NOTE FOR DEVELOPERS:
037             *
038             * Never modify or reference this interface directly. Always use {@link EmailAddressUtil} to access the email address persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
039             */
040    
041            /**
042            * Returns all the email addresses where uuid = &#63;.
043            *
044            * @param uuid the uuid
045            * @return the matching email addresses
046            */
047            public java.util.List<com.liferay.portal.model.EmailAddress> findByUuid(
048                    java.lang.String uuid);
049    
050            /**
051            * Returns a range of all the email addresses where uuid = &#63;.
052            *
053            * <p>
054            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
055            * </p>
056            *
057            * @param uuid the uuid
058            * @param start the lower bound of the range of email addresses
059            * @param end the upper bound of the range of email addresses (not inclusive)
060            * @return the range of matching email addresses
061            */
062            public java.util.List<com.liferay.portal.model.EmailAddress> findByUuid(
063                    java.lang.String uuid, int start, int end);
064    
065            /**
066            * Returns an ordered range of all the email addresses where uuid = &#63;.
067            *
068            * <p>
069            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
070            * </p>
071            *
072            * @param uuid the uuid
073            * @param start the lower bound of the range of email addresses
074            * @param end the upper bound of the range of email addresses (not inclusive)
075            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
076            * @return the ordered range of matching email addresses
077            */
078            public java.util.List<com.liferay.portal.model.EmailAddress> findByUuid(
079                    java.lang.String uuid, int start, int end,
080                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
081    
082            /**
083            * Returns the first email address in the ordered set where uuid = &#63;.
084            *
085            * @param uuid the uuid
086            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
087            * @return the first matching email address
088            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
089            */
090            public com.liferay.portal.model.EmailAddress findByUuid_First(
091                    java.lang.String uuid,
092                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
093                    throws com.liferay.portal.NoSuchEmailAddressException;
094    
095            /**
096            * Returns the first email address in the ordered set where uuid = &#63;.
097            *
098            * @param uuid the uuid
099            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
100            * @return the first matching email address, or <code>null</code> if a matching email address could not be found
101            */
102            public com.liferay.portal.model.EmailAddress fetchByUuid_First(
103                    java.lang.String uuid,
104                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
105    
106            /**
107            * Returns the last email address in the ordered set where uuid = &#63;.
108            *
109            * @param uuid the uuid
110            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
111            * @return the last matching email address
112            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
113            */
114            public com.liferay.portal.model.EmailAddress findByUuid_Last(
115                    java.lang.String uuid,
116                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
117                    throws com.liferay.portal.NoSuchEmailAddressException;
118    
119            /**
120            * Returns the last email address in the ordered set where uuid = &#63;.
121            *
122            * @param uuid the uuid
123            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
124            * @return the last matching email address, or <code>null</code> if a matching email address could not be found
125            */
126            public com.liferay.portal.model.EmailAddress fetchByUuid_Last(
127                    java.lang.String uuid,
128                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
129    
130            /**
131            * Returns the email addresses before and after the current email address in the ordered set where uuid = &#63;.
132            *
133            * @param emailAddressId the primary key of the current email address
134            * @param uuid the uuid
135            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
136            * @return the previous, current, and next email address
137            * @throws com.liferay.portal.NoSuchEmailAddressException if a email address with the primary key could not be found
138            */
139            public com.liferay.portal.model.EmailAddress[] findByUuid_PrevAndNext(
140                    long emailAddressId, java.lang.String uuid,
141                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
142                    throws com.liferay.portal.NoSuchEmailAddressException;
143    
144            /**
145            * Removes all the email addresses where uuid = &#63; from the database.
146            *
147            * @param uuid the uuid
148            */
149            public void removeByUuid(java.lang.String uuid);
150    
151            /**
152            * Returns the number of email addresses where uuid = &#63;.
153            *
154            * @param uuid the uuid
155            * @return the number of matching email addresses
156            */
157            public int countByUuid(java.lang.String uuid);
158    
159            /**
160            * Returns all the email addresses where uuid = &#63; and companyId = &#63;.
161            *
162            * @param uuid the uuid
163            * @param companyId the company ID
164            * @return the matching email addresses
165            */
166            public java.util.List<com.liferay.portal.model.EmailAddress> findByUuid_C(
167                    java.lang.String uuid, long companyId);
168    
169            /**
170            * Returns a range of all the email addresses where uuid = &#63; and companyId = &#63;.
171            *
172            * <p>
173            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
174            * </p>
175            *
176            * @param uuid the uuid
177            * @param companyId the company ID
178            * @param start the lower bound of the range of email addresses
179            * @param end the upper bound of the range of email addresses (not inclusive)
180            * @return the range of matching email addresses
181            */
182            public java.util.List<com.liferay.portal.model.EmailAddress> findByUuid_C(
183                    java.lang.String uuid, long companyId, int start, int end);
184    
185            /**
186            * Returns an ordered range of all the email addresses where uuid = &#63; and companyId = &#63;.
187            *
188            * <p>
189            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
190            * </p>
191            *
192            * @param uuid the uuid
193            * @param companyId the company ID
194            * @param start the lower bound of the range of email addresses
195            * @param end the upper bound of the range of email addresses (not inclusive)
196            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
197            * @return the ordered range of matching email addresses
198            */
199            public java.util.List<com.liferay.portal.model.EmailAddress> findByUuid_C(
200                    java.lang.String uuid, long companyId, int start, int end,
201                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
202    
203            /**
204            * Returns the first email address in the ordered set where uuid = &#63; and companyId = &#63;.
205            *
206            * @param uuid the uuid
207            * @param companyId the company ID
208            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
209            * @return the first matching email address
210            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
211            */
212            public com.liferay.portal.model.EmailAddress findByUuid_C_First(
213                    java.lang.String uuid, long companyId,
214                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
215                    throws com.liferay.portal.NoSuchEmailAddressException;
216    
217            /**
218            * Returns the first email address in the ordered set where uuid = &#63; and companyId = &#63;.
219            *
220            * @param uuid the uuid
221            * @param companyId the company ID
222            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
223            * @return the first matching email address, or <code>null</code> if a matching email address could not be found
224            */
225            public com.liferay.portal.model.EmailAddress fetchByUuid_C_First(
226                    java.lang.String uuid, long companyId,
227                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
228    
229            /**
230            * Returns the last email address in the ordered set where uuid = &#63; and companyId = &#63;.
231            *
232            * @param uuid the uuid
233            * @param companyId the company ID
234            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
235            * @return the last matching email address
236            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
237            */
238            public com.liferay.portal.model.EmailAddress findByUuid_C_Last(
239                    java.lang.String uuid, long companyId,
240                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
241                    throws com.liferay.portal.NoSuchEmailAddressException;
242    
243            /**
244            * Returns the last email address in the ordered set where uuid = &#63; and companyId = &#63;.
245            *
246            * @param uuid the uuid
247            * @param companyId the company ID
248            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
249            * @return the last matching email address, or <code>null</code> if a matching email address could not be found
250            */
251            public com.liferay.portal.model.EmailAddress fetchByUuid_C_Last(
252                    java.lang.String uuid, long companyId,
253                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
254    
255            /**
256            * Returns the email addresses before and after the current email address in the ordered set where uuid = &#63; and companyId = &#63;.
257            *
258            * @param emailAddressId the primary key of the current email address
259            * @param uuid the uuid
260            * @param companyId the company ID
261            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
262            * @return the previous, current, and next email address
263            * @throws com.liferay.portal.NoSuchEmailAddressException if a email address with the primary key could not be found
264            */
265            public com.liferay.portal.model.EmailAddress[] findByUuid_C_PrevAndNext(
266                    long emailAddressId, java.lang.String uuid, long companyId,
267                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
268                    throws com.liferay.portal.NoSuchEmailAddressException;
269    
270            /**
271            * Removes all the email addresses where uuid = &#63; and companyId = &#63; from the database.
272            *
273            * @param uuid the uuid
274            * @param companyId the company ID
275            */
276            public void removeByUuid_C(java.lang.String uuid, long companyId);
277    
278            /**
279            * Returns the number of email addresses where uuid = &#63; and companyId = &#63;.
280            *
281            * @param uuid the uuid
282            * @param companyId the company ID
283            * @return the number of matching email addresses
284            */
285            public int countByUuid_C(java.lang.String uuid, long companyId);
286    
287            /**
288            * Returns all the email addresses where companyId = &#63;.
289            *
290            * @param companyId the company ID
291            * @return the matching email addresses
292            */
293            public java.util.List<com.liferay.portal.model.EmailAddress> findByCompanyId(
294                    long companyId);
295    
296            /**
297            * Returns a range of all the email addresses where companyId = &#63;.
298            *
299            * <p>
300            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
301            * </p>
302            *
303            * @param companyId the company ID
304            * @param start the lower bound of the range of email addresses
305            * @param end the upper bound of the range of email addresses (not inclusive)
306            * @return the range of matching email addresses
307            */
308            public java.util.List<com.liferay.portal.model.EmailAddress> findByCompanyId(
309                    long companyId, int start, int end);
310    
311            /**
312            * Returns an ordered range of all the email addresses where companyId = &#63;.
313            *
314            * <p>
315            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
316            * </p>
317            *
318            * @param companyId the company ID
319            * @param start the lower bound of the range of email addresses
320            * @param end the upper bound of the range of email addresses (not inclusive)
321            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
322            * @return the ordered range of matching email addresses
323            */
324            public java.util.List<com.liferay.portal.model.EmailAddress> findByCompanyId(
325                    long companyId, int start, int end,
326                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
327    
328            /**
329            * Returns the first email address in the ordered set where companyId = &#63;.
330            *
331            * @param companyId the company ID
332            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
333            * @return the first matching email address
334            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
335            */
336            public com.liferay.portal.model.EmailAddress findByCompanyId_First(
337                    long companyId,
338                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
339                    throws com.liferay.portal.NoSuchEmailAddressException;
340    
341            /**
342            * Returns the first email address in the ordered set where companyId = &#63;.
343            *
344            * @param companyId the company ID
345            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
346            * @return the first matching email address, or <code>null</code> if a matching email address could not be found
347            */
348            public com.liferay.portal.model.EmailAddress fetchByCompanyId_First(
349                    long companyId,
350                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
351    
352            /**
353            * Returns the last email address in the ordered set where companyId = &#63;.
354            *
355            * @param companyId the company ID
356            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
357            * @return the last matching email address
358            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
359            */
360            public com.liferay.portal.model.EmailAddress findByCompanyId_Last(
361                    long companyId,
362                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
363                    throws com.liferay.portal.NoSuchEmailAddressException;
364    
365            /**
366            * Returns the last email address in the ordered set where companyId = &#63;.
367            *
368            * @param companyId the company ID
369            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
370            * @return the last matching email address, or <code>null</code> if a matching email address could not be found
371            */
372            public com.liferay.portal.model.EmailAddress fetchByCompanyId_Last(
373                    long companyId,
374                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
375    
376            /**
377            * Returns the email addresses before and after the current email address in the ordered set where companyId = &#63;.
378            *
379            * @param emailAddressId the primary key of the current email address
380            * @param companyId the company ID
381            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
382            * @return the previous, current, and next email address
383            * @throws com.liferay.portal.NoSuchEmailAddressException if a email address with the primary key could not be found
384            */
385            public com.liferay.portal.model.EmailAddress[] findByCompanyId_PrevAndNext(
386                    long emailAddressId, long companyId,
387                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
388                    throws com.liferay.portal.NoSuchEmailAddressException;
389    
390            /**
391            * Removes all the email addresses where companyId = &#63; from the database.
392            *
393            * @param companyId the company ID
394            */
395            public void removeByCompanyId(long companyId);
396    
397            /**
398            * Returns the number of email addresses where companyId = &#63;.
399            *
400            * @param companyId the company ID
401            * @return the number of matching email addresses
402            */
403            public int countByCompanyId(long companyId);
404    
405            /**
406            * Returns all the email addresses where userId = &#63;.
407            *
408            * @param userId the user ID
409            * @return the matching email addresses
410            */
411            public java.util.List<com.liferay.portal.model.EmailAddress> findByUserId(
412                    long userId);
413    
414            /**
415            * Returns a range of all the email addresses where userId = &#63;.
416            *
417            * <p>
418            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
419            * </p>
420            *
421            * @param userId the user ID
422            * @param start the lower bound of the range of email addresses
423            * @param end the upper bound of the range of email addresses (not inclusive)
424            * @return the range of matching email addresses
425            */
426            public java.util.List<com.liferay.portal.model.EmailAddress> findByUserId(
427                    long userId, int start, int end);
428    
429            /**
430            * Returns an ordered range of all the email addresses where userId = &#63;.
431            *
432            * <p>
433            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
434            * </p>
435            *
436            * @param userId the user ID
437            * @param start the lower bound of the range of email addresses
438            * @param end the upper bound of the range of email addresses (not inclusive)
439            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
440            * @return the ordered range of matching email addresses
441            */
442            public java.util.List<com.liferay.portal.model.EmailAddress> findByUserId(
443                    long userId, int start, int end,
444                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
445    
446            /**
447            * Returns the first email address in the ordered set where userId = &#63;.
448            *
449            * @param userId the user ID
450            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
451            * @return the first matching email address
452            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
453            */
454            public com.liferay.portal.model.EmailAddress findByUserId_First(
455                    long userId,
456                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
457                    throws com.liferay.portal.NoSuchEmailAddressException;
458    
459            /**
460            * Returns the first email address in the ordered set where userId = &#63;.
461            *
462            * @param userId the user ID
463            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
464            * @return the first matching email address, or <code>null</code> if a matching email address could not be found
465            */
466            public com.liferay.portal.model.EmailAddress fetchByUserId_First(
467                    long userId,
468                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
469    
470            /**
471            * Returns the last email address in the ordered set where userId = &#63;.
472            *
473            * @param userId the user ID
474            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
475            * @return the last matching email address
476            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
477            */
478            public com.liferay.portal.model.EmailAddress findByUserId_Last(
479                    long userId,
480                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
481                    throws com.liferay.portal.NoSuchEmailAddressException;
482    
483            /**
484            * Returns the last email address in the ordered set where userId = &#63;.
485            *
486            * @param userId the user ID
487            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
488            * @return the last matching email address, or <code>null</code> if a matching email address could not be found
489            */
490            public com.liferay.portal.model.EmailAddress fetchByUserId_Last(
491                    long userId,
492                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
493    
494            /**
495            * Returns the email addresses before and after the current email address in the ordered set where userId = &#63;.
496            *
497            * @param emailAddressId the primary key of the current email address
498            * @param userId the user ID
499            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
500            * @return the previous, current, and next email address
501            * @throws com.liferay.portal.NoSuchEmailAddressException if a email address with the primary key could not be found
502            */
503            public com.liferay.portal.model.EmailAddress[] findByUserId_PrevAndNext(
504                    long emailAddressId, long userId,
505                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
506                    throws com.liferay.portal.NoSuchEmailAddressException;
507    
508            /**
509            * Removes all the email addresses where userId = &#63; from the database.
510            *
511            * @param userId the user ID
512            */
513            public void removeByUserId(long userId);
514    
515            /**
516            * Returns the number of email addresses where userId = &#63;.
517            *
518            * @param userId the user ID
519            * @return the number of matching email addresses
520            */
521            public int countByUserId(long userId);
522    
523            /**
524            * Returns all the email addresses where companyId = &#63; and classNameId = &#63;.
525            *
526            * @param companyId the company ID
527            * @param classNameId the class name ID
528            * @return the matching email addresses
529            */
530            public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C(
531                    long companyId, long classNameId);
532    
533            /**
534            * Returns a range of all the email addresses where companyId = &#63; and classNameId = &#63;.
535            *
536            * <p>
537            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
538            * </p>
539            *
540            * @param companyId the company ID
541            * @param classNameId the class name ID
542            * @param start the lower bound of the range of email addresses
543            * @param end the upper bound of the range of email addresses (not inclusive)
544            * @return the range of matching email addresses
545            */
546            public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C(
547                    long companyId, long classNameId, int start, int end);
548    
549            /**
550            * Returns an ordered range of all the email addresses where companyId = &#63; and classNameId = &#63;.
551            *
552            * <p>
553            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
554            * </p>
555            *
556            * @param companyId the company ID
557            * @param classNameId the class name ID
558            * @param start the lower bound of the range of email addresses
559            * @param end the upper bound of the range of email addresses (not inclusive)
560            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
561            * @return the ordered range of matching email addresses
562            */
563            public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C(
564                    long companyId, long classNameId, int start, int end,
565                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
566    
567            /**
568            * Returns the first email address in the ordered set where companyId = &#63; and classNameId = &#63;.
569            *
570            * @param companyId the company ID
571            * @param classNameId the class name ID
572            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
573            * @return the first matching email address
574            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
575            */
576            public com.liferay.portal.model.EmailAddress findByC_C_First(
577                    long companyId, long classNameId,
578                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
579                    throws com.liferay.portal.NoSuchEmailAddressException;
580    
581            /**
582            * Returns the first email address in the ordered set where companyId = &#63; and classNameId = &#63;.
583            *
584            * @param companyId the company ID
585            * @param classNameId the class name ID
586            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
587            * @return the first matching email address, or <code>null</code> if a matching email address could not be found
588            */
589            public com.liferay.portal.model.EmailAddress fetchByC_C_First(
590                    long companyId, long classNameId,
591                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
592    
593            /**
594            * Returns the last email address in the ordered set where companyId = &#63; and classNameId = &#63;.
595            *
596            * @param companyId the company ID
597            * @param classNameId the class name ID
598            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
599            * @return the last matching email address
600            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
601            */
602            public com.liferay.portal.model.EmailAddress findByC_C_Last(
603                    long companyId, long classNameId,
604                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
605                    throws com.liferay.portal.NoSuchEmailAddressException;
606    
607            /**
608            * Returns the last email address in the ordered set where companyId = &#63; and classNameId = &#63;.
609            *
610            * @param companyId the company ID
611            * @param classNameId the class name ID
612            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
613            * @return the last matching email address, or <code>null</code> if a matching email address could not be found
614            */
615            public com.liferay.portal.model.EmailAddress fetchByC_C_Last(
616                    long companyId, long classNameId,
617                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
618    
619            /**
620            * Returns the email addresses before and after the current email address in the ordered set where companyId = &#63; and classNameId = &#63;.
621            *
622            * @param emailAddressId the primary key of the current email address
623            * @param companyId the company ID
624            * @param classNameId the class name ID
625            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
626            * @return the previous, current, and next email address
627            * @throws com.liferay.portal.NoSuchEmailAddressException if a email address with the primary key could not be found
628            */
629            public com.liferay.portal.model.EmailAddress[] findByC_C_PrevAndNext(
630                    long emailAddressId, long companyId, long classNameId,
631                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
632                    throws com.liferay.portal.NoSuchEmailAddressException;
633    
634            /**
635            * Removes all the email addresses where companyId = &#63; and classNameId = &#63; from the database.
636            *
637            * @param companyId the company ID
638            * @param classNameId the class name ID
639            */
640            public void removeByC_C(long companyId, long classNameId);
641    
642            /**
643            * Returns the number of email addresses where companyId = &#63; and classNameId = &#63;.
644            *
645            * @param companyId the company ID
646            * @param classNameId the class name ID
647            * @return the number of matching email addresses
648            */
649            public int countByC_C(long companyId, long classNameId);
650    
651            /**
652            * Returns all the email addresses where companyId = &#63; and classNameId = &#63; and classPK = &#63;.
653            *
654            * @param companyId the company ID
655            * @param classNameId the class name ID
656            * @param classPK the class p k
657            * @return the matching email addresses
658            */
659            public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C_C(
660                    long companyId, long classNameId, long classPK);
661    
662            /**
663            * Returns a range of all the email addresses where companyId = &#63; and classNameId = &#63; and classPK = &#63;.
664            *
665            * <p>
666            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
667            * </p>
668            *
669            * @param companyId the company ID
670            * @param classNameId the class name ID
671            * @param classPK the class p k
672            * @param start the lower bound of the range of email addresses
673            * @param end the upper bound of the range of email addresses (not inclusive)
674            * @return the range of matching email addresses
675            */
676            public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C_C(
677                    long companyId, long classNameId, long classPK, int start, int end);
678    
679            /**
680            * Returns an ordered range of all the email addresses where companyId = &#63; and classNameId = &#63; and classPK = &#63;.
681            *
682            * <p>
683            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
684            * </p>
685            *
686            * @param companyId the company ID
687            * @param classNameId the class name ID
688            * @param classPK the class p k
689            * @param start the lower bound of the range of email addresses
690            * @param end the upper bound of the range of email addresses (not inclusive)
691            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
692            * @return the ordered range of matching email addresses
693            */
694            public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C_C(
695                    long companyId, long classNameId, long classPK, int start, int end,
696                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
697    
698            /**
699            * Returns the first email address in the ordered set where companyId = &#63; and classNameId = &#63; and classPK = &#63;.
700            *
701            * @param companyId the company ID
702            * @param classNameId the class name ID
703            * @param classPK the class p k
704            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
705            * @return the first matching email address
706            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
707            */
708            public com.liferay.portal.model.EmailAddress findByC_C_C_First(
709                    long companyId, long classNameId, long classPK,
710                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
711                    throws com.liferay.portal.NoSuchEmailAddressException;
712    
713            /**
714            * Returns the first email address in the ordered set where companyId = &#63; and classNameId = &#63; and classPK = &#63;.
715            *
716            * @param companyId the company ID
717            * @param classNameId the class name ID
718            * @param classPK the class p k
719            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
720            * @return the first matching email address, or <code>null</code> if a matching email address could not be found
721            */
722            public com.liferay.portal.model.EmailAddress fetchByC_C_C_First(
723                    long companyId, long classNameId, long classPK,
724                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
725    
726            /**
727            * Returns the last email address in the ordered set where companyId = &#63; and classNameId = &#63; and classPK = &#63;.
728            *
729            * @param companyId the company ID
730            * @param classNameId the class name ID
731            * @param classPK the class p k
732            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
733            * @return the last matching email address
734            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
735            */
736            public com.liferay.portal.model.EmailAddress findByC_C_C_Last(
737                    long companyId, long classNameId, long classPK,
738                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
739                    throws com.liferay.portal.NoSuchEmailAddressException;
740    
741            /**
742            * Returns the last email address in the ordered set where companyId = &#63; and classNameId = &#63; and classPK = &#63;.
743            *
744            * @param companyId the company ID
745            * @param classNameId the class name ID
746            * @param classPK the class p k
747            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
748            * @return the last matching email address, or <code>null</code> if a matching email address could not be found
749            */
750            public com.liferay.portal.model.EmailAddress fetchByC_C_C_Last(
751                    long companyId, long classNameId, long classPK,
752                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
753    
754            /**
755            * Returns the email addresses before and after the current email address in the ordered set where companyId = &#63; and classNameId = &#63; and classPK = &#63;.
756            *
757            * @param emailAddressId the primary key of the current email address
758            * @param companyId the company ID
759            * @param classNameId the class name ID
760            * @param classPK the class p k
761            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
762            * @return the previous, current, and next email address
763            * @throws com.liferay.portal.NoSuchEmailAddressException if a email address with the primary key could not be found
764            */
765            public com.liferay.portal.model.EmailAddress[] findByC_C_C_PrevAndNext(
766                    long emailAddressId, long companyId, long classNameId, long classPK,
767                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
768                    throws com.liferay.portal.NoSuchEmailAddressException;
769    
770            /**
771            * Removes all the email addresses where companyId = &#63; and classNameId = &#63; and classPK = &#63; from the database.
772            *
773            * @param companyId the company ID
774            * @param classNameId the class name ID
775            * @param classPK the class p k
776            */
777            public void removeByC_C_C(long companyId, long classNameId, long classPK);
778    
779            /**
780            * Returns the number of email addresses where companyId = &#63; and classNameId = &#63; and classPK = &#63;.
781            *
782            * @param companyId the company ID
783            * @param classNameId the class name ID
784            * @param classPK the class p k
785            * @return the number of matching email addresses
786            */
787            public int countByC_C_C(long companyId, long classNameId, long classPK);
788    
789            /**
790            * Returns all the email addresses where companyId = &#63; and classNameId = &#63; and classPK = &#63; and primary = &#63;.
791            *
792            * @param companyId the company ID
793            * @param classNameId the class name ID
794            * @param classPK the class p k
795            * @param primary the primary
796            * @return the matching email addresses
797            */
798            public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C_C_P(
799                    long companyId, long classNameId, long classPK, boolean primary);
800    
801            /**
802            * Returns a range of all the email addresses where companyId = &#63; and classNameId = &#63; and classPK = &#63; and primary = &#63;.
803            *
804            * <p>
805            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
806            * </p>
807            *
808            * @param companyId the company ID
809            * @param classNameId the class name ID
810            * @param classPK the class p k
811            * @param primary the primary
812            * @param start the lower bound of the range of email addresses
813            * @param end the upper bound of the range of email addresses (not inclusive)
814            * @return the range of matching email addresses
815            */
816            public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C_C_P(
817                    long companyId, long classNameId, long classPK, boolean primary,
818                    int start, int end);
819    
820            /**
821            * Returns an ordered range of all the email addresses where companyId = &#63; and classNameId = &#63; and classPK = &#63; and primary = &#63;.
822            *
823            * <p>
824            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
825            * </p>
826            *
827            * @param companyId the company ID
828            * @param classNameId the class name ID
829            * @param classPK the class p k
830            * @param primary the primary
831            * @param start the lower bound of the range of email addresses
832            * @param end the upper bound of the range of email addresses (not inclusive)
833            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
834            * @return the ordered range of matching email addresses
835            */
836            public java.util.List<com.liferay.portal.model.EmailAddress> findByC_C_C_P(
837                    long companyId, long classNameId, long classPK, boolean primary,
838                    int start, int end,
839                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
840    
841            /**
842            * Returns the first email address in the ordered set where companyId = &#63; and classNameId = &#63; and classPK = &#63; and primary = &#63;.
843            *
844            * @param companyId the company ID
845            * @param classNameId the class name ID
846            * @param classPK the class p k
847            * @param primary the primary
848            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
849            * @return the first matching email address
850            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
851            */
852            public com.liferay.portal.model.EmailAddress findByC_C_C_P_First(
853                    long companyId, long classNameId, long classPK, boolean primary,
854                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
855                    throws com.liferay.portal.NoSuchEmailAddressException;
856    
857            /**
858            * Returns the first email address in the ordered set where companyId = &#63; and classNameId = &#63; and classPK = &#63; and primary = &#63;.
859            *
860            * @param companyId the company ID
861            * @param classNameId the class name ID
862            * @param classPK the class p k
863            * @param primary the primary
864            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
865            * @return the first matching email address, or <code>null</code> if a matching email address could not be found
866            */
867            public com.liferay.portal.model.EmailAddress fetchByC_C_C_P_First(
868                    long companyId, long classNameId, long classPK, boolean primary,
869                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
870    
871            /**
872            * Returns the last email address in the ordered set where companyId = &#63; and classNameId = &#63; and classPK = &#63; and primary = &#63;.
873            *
874            * @param companyId the company ID
875            * @param classNameId the class name ID
876            * @param classPK the class p k
877            * @param primary the primary
878            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
879            * @return the last matching email address
880            * @throws com.liferay.portal.NoSuchEmailAddressException if a matching email address could not be found
881            */
882            public com.liferay.portal.model.EmailAddress findByC_C_C_P_Last(
883                    long companyId, long classNameId, long classPK, boolean primary,
884                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
885                    throws com.liferay.portal.NoSuchEmailAddressException;
886    
887            /**
888            * Returns the last email address in the ordered set where companyId = &#63; and classNameId = &#63; and classPK = &#63; and primary = &#63;.
889            *
890            * @param companyId the company ID
891            * @param classNameId the class name ID
892            * @param classPK the class p k
893            * @param primary the primary
894            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
895            * @return the last matching email address, or <code>null</code> if a matching email address could not be found
896            */
897            public com.liferay.portal.model.EmailAddress fetchByC_C_C_P_Last(
898                    long companyId, long classNameId, long classPK, boolean primary,
899                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
900    
901            /**
902            * Returns the email addresses before and after the current email address in the ordered set where companyId = &#63; and classNameId = &#63; and classPK = &#63; and primary = &#63;.
903            *
904            * @param emailAddressId the primary key of the current email address
905            * @param companyId the company ID
906            * @param classNameId the class name ID
907            * @param classPK the class p k
908            * @param primary the primary
909            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
910            * @return the previous, current, and next email address
911            * @throws com.liferay.portal.NoSuchEmailAddressException if a email address with the primary key could not be found
912            */
913            public com.liferay.portal.model.EmailAddress[] findByC_C_C_P_PrevAndNext(
914                    long emailAddressId, long companyId, long classNameId, long classPK,
915                    boolean primary,
916                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator)
917                    throws com.liferay.portal.NoSuchEmailAddressException;
918    
919            /**
920            * Removes all the email addresses where companyId = &#63; and classNameId = &#63; and classPK = &#63; and primary = &#63; from the database.
921            *
922            * @param companyId the company ID
923            * @param classNameId the class name ID
924            * @param classPK the class p k
925            * @param primary the primary
926            */
927            public void removeByC_C_C_P(long companyId, long classNameId, long classPK,
928                    boolean primary);
929    
930            /**
931            * Returns the number of email addresses where companyId = &#63; and classNameId = &#63; and classPK = &#63; and primary = &#63;.
932            *
933            * @param companyId the company ID
934            * @param classNameId the class name ID
935            * @param classPK the class p k
936            * @param primary the primary
937            * @return the number of matching email addresses
938            */
939            public int countByC_C_C_P(long companyId, long classNameId, long classPK,
940                    boolean primary);
941    
942            /**
943            * Caches the email address in the entity cache if it is enabled.
944            *
945            * @param emailAddress the email address
946            */
947            public void cacheResult(com.liferay.portal.model.EmailAddress emailAddress);
948    
949            /**
950            * Caches the email addresses in the entity cache if it is enabled.
951            *
952            * @param emailAddresses the email addresses
953            */
954            public void cacheResult(
955                    java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses);
956    
957            /**
958            * Creates a new email address with the primary key. Does not add the email address to the database.
959            *
960            * @param emailAddressId the primary key for the new email address
961            * @return the new email address
962            */
963            public com.liferay.portal.model.EmailAddress create(long emailAddressId);
964    
965            /**
966            * Removes the email address with the primary key from the database. Also notifies the appropriate model listeners.
967            *
968            * @param emailAddressId the primary key of the email address
969            * @return the email address that was removed
970            * @throws com.liferay.portal.NoSuchEmailAddressException if a email address with the primary key could not be found
971            */
972            public com.liferay.portal.model.EmailAddress remove(long emailAddressId)
973                    throws com.liferay.portal.NoSuchEmailAddressException;
974    
975            public com.liferay.portal.model.EmailAddress updateImpl(
976                    com.liferay.portal.model.EmailAddress emailAddress);
977    
978            /**
979            * Returns the email address with the primary key or throws a {@link com.liferay.portal.NoSuchEmailAddressException} if it could not be found.
980            *
981            * @param emailAddressId the primary key of the email address
982            * @return the email address
983            * @throws com.liferay.portal.NoSuchEmailAddressException if a email address with the primary key could not be found
984            */
985            public com.liferay.portal.model.EmailAddress findByPrimaryKey(
986                    long emailAddressId)
987                    throws com.liferay.portal.NoSuchEmailAddressException;
988    
989            /**
990            * Returns the email address with the primary key or returns <code>null</code> if it could not be found.
991            *
992            * @param emailAddressId the primary key of the email address
993            * @return the email address, or <code>null</code> if a email address with the primary key could not be found
994            */
995            public com.liferay.portal.model.EmailAddress fetchByPrimaryKey(
996                    long emailAddressId);
997    
998            @Override
999            public java.util.Map<java.io.Serializable, com.liferay.portal.model.EmailAddress> fetchByPrimaryKeys(
1000                    java.util.Set<java.io.Serializable> primaryKeys);
1001    
1002            /**
1003            * Returns all the email addresses.
1004            *
1005            * @return the email addresses
1006            */
1007            public java.util.List<com.liferay.portal.model.EmailAddress> findAll();
1008    
1009            /**
1010            * Returns a range of all the email addresses.
1011            *
1012            * <p>
1013            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1014            * </p>
1015            *
1016            * @param start the lower bound of the range of email addresses
1017            * @param end the upper bound of the range of email addresses (not inclusive)
1018            * @return the range of email addresses
1019            */
1020            public java.util.List<com.liferay.portal.model.EmailAddress> findAll(
1021                    int start, int end);
1022    
1023            /**
1024            * Returns an ordered range of all the email addresses.
1025            *
1026            * <p>
1027            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.EmailAddressModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
1028            * </p>
1029            *
1030            * @param start the lower bound of the range of email addresses
1031            * @param end the upper bound of the range of email addresses (not inclusive)
1032            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1033            * @return the ordered range of email addresses
1034            */
1035            public java.util.List<com.liferay.portal.model.EmailAddress> findAll(
1036                    int start, int end,
1037                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.EmailAddress> orderByComparator);
1038    
1039            /**
1040            * Removes all the email addresses from the database.
1041            */
1042            public void removeAll();
1043    
1044            /**
1045            * Returns the number of email addresses.
1046            *
1047            * @return the number of email addresses
1048            */
1049            public int countAll();
1050    }