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.PasswordTracker;
020    
021    /**
022     * The persistence interface for the password tracker 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 PasswordTrackerPersistenceImpl
030     * @see PasswordTrackerUtil
031     * @generated
032     */
033    @ProviderType
034    public interface PasswordTrackerPersistence extends BasePersistence<PasswordTracker> {
035            /*
036             * NOTE FOR DEVELOPERS:
037             *
038             * Never modify or reference this interface directly. Always use {@link PasswordTrackerUtil} to access the password tracker persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
039             */
040    
041            /**
042            * Returns all the password trackers where userId = &#63;.
043            *
044            * @param userId the user ID
045            * @return the matching password trackers
046            */
047            public java.util.List<com.liferay.portal.model.PasswordTracker> findByUserId(
048                    long userId);
049    
050            /**
051            * Returns a range of all the password trackers where userId = &#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.PasswordTrackerModelImpl}. 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 userId the user ID
058            * @param start the lower bound of the range of password trackers
059            * @param end the upper bound of the range of password trackers (not inclusive)
060            * @return the range of matching password trackers
061            */
062            public java.util.List<com.liferay.portal.model.PasswordTracker> findByUserId(
063                    long userId, int start, int end);
064    
065            /**
066            * Returns an ordered range of all the password trackers where userId = &#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.PasswordTrackerModelImpl}. 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 userId the user ID
073            * @param start the lower bound of the range of password trackers
074            * @param end the upper bound of the range of password trackers (not inclusive)
075            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
076            * @return the ordered range of matching password trackers
077            */
078            public java.util.List<com.liferay.portal.model.PasswordTracker> findByUserId(
079                    long userId, int start, int end,
080                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordTracker> orderByComparator);
081    
082            /**
083            * Returns the first password tracker in the ordered set where userId = &#63;.
084            *
085            * @param userId the user ID
086            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
087            * @return the first matching password tracker
088            * @throws com.liferay.portal.NoSuchPasswordTrackerException if a matching password tracker could not be found
089            */
090            public com.liferay.portal.model.PasswordTracker findByUserId_First(
091                    long userId,
092                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordTracker> orderByComparator)
093                    throws com.liferay.portal.NoSuchPasswordTrackerException;
094    
095            /**
096            * Returns the first password tracker in the ordered set where userId = &#63;.
097            *
098            * @param userId the user ID
099            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
100            * @return the first matching password tracker, or <code>null</code> if a matching password tracker could not be found
101            */
102            public com.liferay.portal.model.PasswordTracker fetchByUserId_First(
103                    long userId,
104                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordTracker> orderByComparator);
105    
106            /**
107            * Returns the last password tracker in the ordered set where userId = &#63;.
108            *
109            * @param userId the user ID
110            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
111            * @return the last matching password tracker
112            * @throws com.liferay.portal.NoSuchPasswordTrackerException if a matching password tracker could not be found
113            */
114            public com.liferay.portal.model.PasswordTracker findByUserId_Last(
115                    long userId,
116                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordTracker> orderByComparator)
117                    throws com.liferay.portal.NoSuchPasswordTrackerException;
118    
119            /**
120            * Returns the last password tracker in the ordered set where userId = &#63;.
121            *
122            * @param userId the user ID
123            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
124            * @return the last matching password tracker, or <code>null</code> if a matching password tracker could not be found
125            */
126            public com.liferay.portal.model.PasswordTracker fetchByUserId_Last(
127                    long userId,
128                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordTracker> orderByComparator);
129    
130            /**
131            * Returns the password trackers before and after the current password tracker in the ordered set where userId = &#63;.
132            *
133            * @param passwordTrackerId the primary key of the current password tracker
134            * @param userId the user ID
135            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
136            * @return the previous, current, and next password tracker
137            * @throws com.liferay.portal.NoSuchPasswordTrackerException if a password tracker with the primary key could not be found
138            */
139            public com.liferay.portal.model.PasswordTracker[] findByUserId_PrevAndNext(
140                    long passwordTrackerId, long userId,
141                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordTracker> orderByComparator)
142                    throws com.liferay.portal.NoSuchPasswordTrackerException;
143    
144            /**
145            * Removes all the password trackers where userId = &#63; from the database.
146            *
147            * @param userId the user ID
148            */
149            public void removeByUserId(long userId);
150    
151            /**
152            * Returns the number of password trackers where userId = &#63;.
153            *
154            * @param userId the user ID
155            * @return the number of matching password trackers
156            */
157            public int countByUserId(long userId);
158    
159            /**
160            * Caches the password tracker in the entity cache if it is enabled.
161            *
162            * @param passwordTracker the password tracker
163            */
164            public void cacheResult(
165                    com.liferay.portal.model.PasswordTracker passwordTracker);
166    
167            /**
168            * Caches the password trackers in the entity cache if it is enabled.
169            *
170            * @param passwordTrackers the password trackers
171            */
172            public void cacheResult(
173                    java.util.List<com.liferay.portal.model.PasswordTracker> passwordTrackers);
174    
175            /**
176            * Creates a new password tracker with the primary key. Does not add the password tracker to the database.
177            *
178            * @param passwordTrackerId the primary key for the new password tracker
179            * @return the new password tracker
180            */
181            public com.liferay.portal.model.PasswordTracker create(
182                    long passwordTrackerId);
183    
184            /**
185            * Removes the password tracker with the primary key from the database. Also notifies the appropriate model listeners.
186            *
187            * @param passwordTrackerId the primary key of the password tracker
188            * @return the password tracker that was removed
189            * @throws com.liferay.portal.NoSuchPasswordTrackerException if a password tracker with the primary key could not be found
190            */
191            public com.liferay.portal.model.PasswordTracker remove(
192                    long passwordTrackerId)
193                    throws com.liferay.portal.NoSuchPasswordTrackerException;
194    
195            public com.liferay.portal.model.PasswordTracker updateImpl(
196                    com.liferay.portal.model.PasswordTracker passwordTracker);
197    
198            /**
199            * Returns the password tracker with the primary key or throws a {@link com.liferay.portal.NoSuchPasswordTrackerException} if it could not be found.
200            *
201            * @param passwordTrackerId the primary key of the password tracker
202            * @return the password tracker
203            * @throws com.liferay.portal.NoSuchPasswordTrackerException if a password tracker with the primary key could not be found
204            */
205            public com.liferay.portal.model.PasswordTracker findByPrimaryKey(
206                    long passwordTrackerId)
207                    throws com.liferay.portal.NoSuchPasswordTrackerException;
208    
209            /**
210            * Returns the password tracker with the primary key or returns <code>null</code> if it could not be found.
211            *
212            * @param passwordTrackerId the primary key of the password tracker
213            * @return the password tracker, or <code>null</code> if a password tracker with the primary key could not be found
214            */
215            public com.liferay.portal.model.PasswordTracker fetchByPrimaryKey(
216                    long passwordTrackerId);
217    
218            @Override
219            public java.util.Map<java.io.Serializable, com.liferay.portal.model.PasswordTracker> fetchByPrimaryKeys(
220                    java.util.Set<java.io.Serializable> primaryKeys);
221    
222            /**
223            * Returns all the password trackers.
224            *
225            * @return the password trackers
226            */
227            public java.util.List<com.liferay.portal.model.PasswordTracker> findAll();
228    
229            /**
230            * Returns a range of all the password trackers.
231            *
232            * <p>
233            * 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.PasswordTrackerModelImpl}. 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.
234            * </p>
235            *
236            * @param start the lower bound of the range of password trackers
237            * @param end the upper bound of the range of password trackers (not inclusive)
238            * @return the range of password trackers
239            */
240            public java.util.List<com.liferay.portal.model.PasswordTracker> findAll(
241                    int start, int end);
242    
243            /**
244            * Returns an ordered range of all the password trackers.
245            *
246            * <p>
247            * 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.PasswordTrackerModelImpl}. 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.
248            * </p>
249            *
250            * @param start the lower bound of the range of password trackers
251            * @param end the upper bound of the range of password trackers (not inclusive)
252            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
253            * @return the ordered range of password trackers
254            */
255            public java.util.List<com.liferay.portal.model.PasswordTracker> findAll(
256                    int start, int end,
257                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.PasswordTracker> orderByComparator);
258    
259            /**
260            * Removes all the password trackers from the database.
261            */
262            public void removeAll();
263    
264            /**
265            * Returns the number of password trackers.
266            *
267            * @return the number of password trackers
268            */
269            public int countAll();
270    }