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.PasswordPolicyRel;
020    
021    /**
022     * The persistence interface for the password policy rel 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 PasswordPolicyRelPersistenceImpl
030     * @see PasswordPolicyRelUtil
031     * @generated
032     */
033    @ProviderType
034    public interface PasswordPolicyRelPersistence extends BasePersistence<PasswordPolicyRel> {
035            /*
036             * NOTE FOR DEVELOPERS:
037             *
038             * Never modify or reference this interface directly. Always use {@link PasswordPolicyRelUtil} to access the password policy rel persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
039             */
040    
041            /**
042            * Returns all the password policy rels where passwordPolicyId = &#63;.
043            *
044            * @param passwordPolicyId the password policy ID
045            * @return the matching password policy rels
046            */
047            public java.util.List<com.liferay.portal.model.PasswordPolicyRel> findByPasswordPolicyId(
048                    long passwordPolicyId);
049    
050            /**
051            * Returns a range of all the password policy rels where passwordPolicyId = &#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.PasswordPolicyRelModelImpl}. 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 passwordPolicyId the password policy ID
058            * @param start the lower bound of the range of password policy rels
059            * @param end the upper bound of the range of password policy rels (not inclusive)
060            * @return the range of matching password policy rels
061            */
062            public java.util.List<com.liferay.portal.model.PasswordPolicyRel> findByPasswordPolicyId(
063                    long passwordPolicyId, int start, int end);
064    
065            /**
066            * Returns an ordered range of all the password policy rels where passwordPolicyId = &#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.PasswordPolicyRelModelImpl}. 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 passwordPolicyId the password policy ID
073            * @param start the lower bound of the range of password policy rels
074            * @param end the upper bound of the range of password policy rels (not inclusive)
075            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
076            * @return the ordered range of matching password policy rels
077            */
078            public java.util.List<com.liferay.portal.model.PasswordPolicyRel> findByPasswordPolicyId(
079                    long passwordPolicyId, int start, int end,
080                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordPolicyRel> orderByComparator);
081    
082            /**
083            * Returns the first password policy rel in the ordered set where passwordPolicyId = &#63;.
084            *
085            * @param passwordPolicyId the password policy ID
086            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
087            * @return the first matching password policy rel
088            * @throws com.liferay.portal.NoSuchPasswordPolicyRelException if a matching password policy rel could not be found
089            */
090            public com.liferay.portal.model.PasswordPolicyRel findByPasswordPolicyId_First(
091                    long passwordPolicyId,
092                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordPolicyRel> orderByComparator)
093                    throws com.liferay.portal.NoSuchPasswordPolicyRelException;
094    
095            /**
096            * Returns the first password policy rel in the ordered set where passwordPolicyId = &#63;.
097            *
098            * @param passwordPolicyId the password policy ID
099            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
100            * @return the first matching password policy rel, or <code>null</code> if a matching password policy rel could not be found
101            */
102            public com.liferay.portal.model.PasswordPolicyRel fetchByPasswordPolicyId_First(
103                    long passwordPolicyId,
104                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordPolicyRel> orderByComparator);
105    
106            /**
107            * Returns the last password policy rel in the ordered set where passwordPolicyId = &#63;.
108            *
109            * @param passwordPolicyId the password policy ID
110            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
111            * @return the last matching password policy rel
112            * @throws com.liferay.portal.NoSuchPasswordPolicyRelException if a matching password policy rel could not be found
113            */
114            public com.liferay.portal.model.PasswordPolicyRel findByPasswordPolicyId_Last(
115                    long passwordPolicyId,
116                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordPolicyRel> orderByComparator)
117                    throws com.liferay.portal.NoSuchPasswordPolicyRelException;
118    
119            /**
120            * Returns the last password policy rel in the ordered set where passwordPolicyId = &#63;.
121            *
122            * @param passwordPolicyId the password policy ID
123            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
124            * @return the last matching password policy rel, or <code>null</code> if a matching password policy rel could not be found
125            */
126            public com.liferay.portal.model.PasswordPolicyRel fetchByPasswordPolicyId_Last(
127                    long passwordPolicyId,
128                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordPolicyRel> orderByComparator);
129    
130            /**
131            * Returns the password policy rels before and after the current password policy rel in the ordered set where passwordPolicyId = &#63;.
132            *
133            * @param passwordPolicyRelId the primary key of the current password policy rel
134            * @param passwordPolicyId the password policy ID
135            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
136            * @return the previous, current, and next password policy rel
137            * @throws com.liferay.portal.NoSuchPasswordPolicyRelException if a password policy rel with the primary key could not be found
138            */
139            public com.liferay.portal.model.PasswordPolicyRel[] findByPasswordPolicyId_PrevAndNext(
140                    long passwordPolicyRelId, long passwordPolicyId,
141                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordPolicyRel> orderByComparator)
142                    throws com.liferay.portal.NoSuchPasswordPolicyRelException;
143    
144            /**
145            * Removes all the password policy rels where passwordPolicyId = &#63; from the database.
146            *
147            * @param passwordPolicyId the password policy ID
148            */
149            public void removeByPasswordPolicyId(long passwordPolicyId);
150    
151            /**
152            * Returns the number of password policy rels where passwordPolicyId = &#63;.
153            *
154            * @param passwordPolicyId the password policy ID
155            * @return the number of matching password policy rels
156            */
157            public int countByPasswordPolicyId(long passwordPolicyId);
158    
159            /**
160            * Returns the password policy rel where classNameId = &#63; and classPK = &#63; or throws a {@link com.liferay.portal.NoSuchPasswordPolicyRelException} if it could not be found.
161            *
162            * @param classNameId the class name ID
163            * @param classPK the class p k
164            * @return the matching password policy rel
165            * @throws com.liferay.portal.NoSuchPasswordPolicyRelException if a matching password policy rel could not be found
166            */
167            public com.liferay.portal.model.PasswordPolicyRel findByC_C(
168                    long classNameId, long classPK)
169                    throws com.liferay.portal.NoSuchPasswordPolicyRelException;
170    
171            /**
172            * Returns the password policy rel where classNameId = &#63; and classPK = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
173            *
174            * @param classNameId the class name ID
175            * @param classPK the class p k
176            * @return the matching password policy rel, or <code>null</code> if a matching password policy rel could not be found
177            */
178            public com.liferay.portal.model.PasswordPolicyRel fetchByC_C(
179                    long classNameId, long classPK);
180    
181            /**
182            * Returns the password policy rel where classNameId = &#63; and classPK = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
183            *
184            * @param classNameId the class name ID
185            * @param classPK the class p k
186            * @param retrieveFromCache whether to use the finder cache
187            * @return the matching password policy rel, or <code>null</code> if a matching password policy rel could not be found
188            */
189            public com.liferay.portal.model.PasswordPolicyRel fetchByC_C(
190                    long classNameId, long classPK, boolean retrieveFromCache);
191    
192            /**
193            * Removes the password policy rel where classNameId = &#63; and classPK = &#63; from the database.
194            *
195            * @param classNameId the class name ID
196            * @param classPK the class p k
197            * @return the password policy rel that was removed
198            */
199            public com.liferay.portal.model.PasswordPolicyRel removeByC_C(
200                    long classNameId, long classPK)
201                    throws com.liferay.portal.NoSuchPasswordPolicyRelException;
202    
203            /**
204            * Returns the number of password policy rels where classNameId = &#63; and classPK = &#63;.
205            *
206            * @param classNameId the class name ID
207            * @param classPK the class p k
208            * @return the number of matching password policy rels
209            */
210            public int countByC_C(long classNameId, long classPK);
211    
212            /**
213            * Caches the password policy rel in the entity cache if it is enabled.
214            *
215            * @param passwordPolicyRel the password policy rel
216            */
217            public void cacheResult(
218                    com.liferay.portal.model.PasswordPolicyRel passwordPolicyRel);
219    
220            /**
221            * Caches the password policy rels in the entity cache if it is enabled.
222            *
223            * @param passwordPolicyRels the password policy rels
224            */
225            public void cacheResult(
226                    java.util.List<com.liferay.portal.model.PasswordPolicyRel> passwordPolicyRels);
227    
228            /**
229            * Creates a new password policy rel with the primary key. Does not add the password policy rel to the database.
230            *
231            * @param passwordPolicyRelId the primary key for the new password policy rel
232            * @return the new password policy rel
233            */
234            public com.liferay.portal.model.PasswordPolicyRel create(
235                    long passwordPolicyRelId);
236    
237            /**
238            * Removes the password policy rel with the primary key from the database. Also notifies the appropriate model listeners.
239            *
240            * @param passwordPolicyRelId the primary key of the password policy rel
241            * @return the password policy rel that was removed
242            * @throws com.liferay.portal.NoSuchPasswordPolicyRelException if a password policy rel with the primary key could not be found
243            */
244            public com.liferay.portal.model.PasswordPolicyRel remove(
245                    long passwordPolicyRelId)
246                    throws com.liferay.portal.NoSuchPasswordPolicyRelException;
247    
248            public com.liferay.portal.model.PasswordPolicyRel updateImpl(
249                    com.liferay.portal.model.PasswordPolicyRel passwordPolicyRel);
250    
251            /**
252            * Returns the password policy rel with the primary key or throws a {@link com.liferay.portal.NoSuchPasswordPolicyRelException} if it could not be found.
253            *
254            * @param passwordPolicyRelId the primary key of the password policy rel
255            * @return the password policy rel
256            * @throws com.liferay.portal.NoSuchPasswordPolicyRelException if a password policy rel with the primary key could not be found
257            */
258            public com.liferay.portal.model.PasswordPolicyRel findByPrimaryKey(
259                    long passwordPolicyRelId)
260                    throws com.liferay.portal.NoSuchPasswordPolicyRelException;
261    
262            /**
263            * Returns the password policy rel with the primary key or returns <code>null</code> if it could not be found.
264            *
265            * @param passwordPolicyRelId the primary key of the password policy rel
266            * @return the password policy rel, or <code>null</code> if a password policy rel with the primary key could not be found
267            */
268            public com.liferay.portal.model.PasswordPolicyRel fetchByPrimaryKey(
269                    long passwordPolicyRelId);
270    
271            @Override
272            public java.util.Map<java.io.Serializable, com.liferay.portal.model.PasswordPolicyRel> fetchByPrimaryKeys(
273                    java.util.Set<java.io.Serializable> primaryKeys);
274    
275            /**
276            * Returns all the password policy rels.
277            *
278            * @return the password policy rels
279            */
280            public java.util.List<com.liferay.portal.model.PasswordPolicyRel> findAll();
281    
282            /**
283            * Returns a range of all the password policy rels.
284            *
285            * <p>
286            * 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.PasswordPolicyRelModelImpl}. 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.
287            * </p>
288            *
289            * @param start the lower bound of the range of password policy rels
290            * @param end the upper bound of the range of password policy rels (not inclusive)
291            * @return the range of password policy rels
292            */
293            public java.util.List<com.liferay.portal.model.PasswordPolicyRel> findAll(
294                    int start, int end);
295    
296            /**
297            * Returns an ordered range of all the password policy rels.
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.PasswordPolicyRelModelImpl}. 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 start the lower bound of the range of password policy rels
304            * @param end the upper bound of the range of password policy rels (not inclusive)
305            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
306            * @return the ordered range of password policy rels
307            */
308            public java.util.List<com.liferay.portal.model.PasswordPolicyRel> findAll(
309                    int start, int end,
310                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordPolicyRel> orderByComparator);
311    
312            /**
313            * Removes all the password policy rels from the database.
314            */
315            public void removeAll();
316    
317            /**
318            * Returns the number of password policy rels.
319            *
320            * @return the number of password policy rels
321            */
322            public int countAll();
323    }