001    /**
002     * Copyright (c) 2000-2013 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.portlet.wiki.service.persistence;
016    
017    import com.liferay.portal.service.persistence.BasePersistence;
018    
019    import com.liferay.portlet.wiki.model.WikiPageResource;
020    
021    /**
022     * The persistence interface for the wiki page resource 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 WikiPageResourcePersistenceImpl
030     * @see WikiPageResourceUtil
031     * @generated
032     */
033    public interface WikiPageResourcePersistence extends BasePersistence<WikiPageResource> {
034            /*
035             * NOTE FOR DEVELOPERS:
036             *
037             * Never modify or reference this interface directly. Always use {@link WikiPageResourceUtil} to access the wiki page resource persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
038             */
039    
040            /**
041            * Caches the wiki page resource in the entity cache if it is enabled.
042            *
043            * @param wikiPageResource the wiki page resource
044            */
045            public void cacheResult(
046                    com.liferay.portlet.wiki.model.WikiPageResource wikiPageResource);
047    
048            /**
049            * Caches the wiki page resources in the entity cache if it is enabled.
050            *
051            * @param wikiPageResources the wiki page resources
052            */
053            public void cacheResult(
054                    java.util.List<com.liferay.portlet.wiki.model.WikiPageResource> wikiPageResources);
055    
056            /**
057            * Creates a new wiki page resource with the primary key. Does not add the wiki page resource to the database.
058            *
059            * @param resourcePrimKey the primary key for the new wiki page resource
060            * @return the new wiki page resource
061            */
062            public com.liferay.portlet.wiki.model.WikiPageResource create(
063                    long resourcePrimKey);
064    
065            /**
066            * Removes the wiki page resource with the primary key from the database. Also notifies the appropriate model listeners.
067            *
068            * @param resourcePrimKey the primary key of the wiki page resource
069            * @return the wiki page resource that was removed
070            * @throws com.liferay.portlet.wiki.NoSuchPageResourceException if a wiki page resource with the primary key could not be found
071            * @throws SystemException if a system exception occurred
072            */
073            public com.liferay.portlet.wiki.model.WikiPageResource remove(
074                    long resourcePrimKey)
075                    throws com.liferay.portal.kernel.exception.SystemException,
076                            com.liferay.portlet.wiki.NoSuchPageResourceException;
077    
078            public com.liferay.portlet.wiki.model.WikiPageResource updateImpl(
079                    com.liferay.portlet.wiki.model.WikiPageResource wikiPageResource,
080                    boolean merge)
081                    throws com.liferay.portal.kernel.exception.SystemException;
082    
083            /**
084            * Returns the wiki page resource with the primary key or throws a {@link com.liferay.portlet.wiki.NoSuchPageResourceException} if it could not be found.
085            *
086            * @param resourcePrimKey the primary key of the wiki page resource
087            * @return the wiki page resource
088            * @throws com.liferay.portlet.wiki.NoSuchPageResourceException if a wiki page resource with the primary key could not be found
089            * @throws SystemException if a system exception occurred
090            */
091            public com.liferay.portlet.wiki.model.WikiPageResource findByPrimaryKey(
092                    long resourcePrimKey)
093                    throws com.liferay.portal.kernel.exception.SystemException,
094                            com.liferay.portlet.wiki.NoSuchPageResourceException;
095    
096            /**
097            * Returns the wiki page resource with the primary key or returns <code>null</code> if it could not be found.
098            *
099            * @param resourcePrimKey the primary key of the wiki page resource
100            * @return the wiki page resource, or <code>null</code> if a wiki page resource with the primary key could not be found
101            * @throws SystemException if a system exception occurred
102            */
103            public com.liferay.portlet.wiki.model.WikiPageResource fetchByPrimaryKey(
104                    long resourcePrimKey)
105                    throws com.liferay.portal.kernel.exception.SystemException;
106    
107            /**
108            * Returns all the wiki page resources where uuid = &#63;.
109            *
110            * @param uuid the uuid
111            * @return the matching wiki page resources
112            * @throws SystemException if a system exception occurred
113            */
114            public java.util.List<com.liferay.portlet.wiki.model.WikiPageResource> findByUuid(
115                    java.lang.String uuid)
116                    throws com.liferay.portal.kernel.exception.SystemException;
117    
118            /**
119            * Returns a range of all the wiki page resources where uuid = &#63;.
120            *
121            * <p>
122            * 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.
123            * </p>
124            *
125            * @param uuid the uuid
126            * @param start the lower bound of the range of wiki page resources
127            * @param end the upper bound of the range of wiki page resources (not inclusive)
128            * @return the range of matching wiki page resources
129            * @throws SystemException if a system exception occurred
130            */
131            public java.util.List<com.liferay.portlet.wiki.model.WikiPageResource> findByUuid(
132                    java.lang.String uuid, int start, int end)
133                    throws com.liferay.portal.kernel.exception.SystemException;
134    
135            /**
136            * Returns an ordered range of all the wiki page resources where uuid = &#63;.
137            *
138            * <p>
139            * 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.
140            * </p>
141            *
142            * @param uuid the uuid
143            * @param start the lower bound of the range of wiki page resources
144            * @param end the upper bound of the range of wiki page resources (not inclusive)
145            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
146            * @return the ordered range of matching wiki page resources
147            * @throws SystemException if a system exception occurred
148            */
149            public java.util.List<com.liferay.portlet.wiki.model.WikiPageResource> findByUuid(
150                    java.lang.String uuid, int start, int end,
151                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
152                    throws com.liferay.portal.kernel.exception.SystemException;
153    
154            /**
155            * Returns the first wiki page resource in the ordered set where uuid = &#63;.
156            *
157            * @param uuid the uuid
158            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
159            * @return the first matching wiki page resource
160            * @throws com.liferay.portlet.wiki.NoSuchPageResourceException if a matching wiki page resource could not be found
161            * @throws SystemException if a system exception occurred
162            */
163            public com.liferay.portlet.wiki.model.WikiPageResource findByUuid_First(
164                    java.lang.String uuid,
165                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
166                    throws com.liferay.portal.kernel.exception.SystemException,
167                            com.liferay.portlet.wiki.NoSuchPageResourceException;
168    
169            /**
170            * Returns the first wiki page resource in the ordered set where uuid = &#63;.
171            *
172            * @param uuid the uuid
173            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
174            * @return the first matching wiki page resource, or <code>null</code> if a matching wiki page resource could not be found
175            * @throws SystemException if a system exception occurred
176            */
177            public com.liferay.portlet.wiki.model.WikiPageResource fetchByUuid_First(
178                    java.lang.String uuid,
179                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
180                    throws com.liferay.portal.kernel.exception.SystemException;
181    
182            /**
183            * Returns the last wiki page resource in the ordered set where uuid = &#63;.
184            *
185            * @param uuid the uuid
186            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
187            * @return the last matching wiki page resource
188            * @throws com.liferay.portlet.wiki.NoSuchPageResourceException if a matching wiki page resource could not be found
189            * @throws SystemException if a system exception occurred
190            */
191            public com.liferay.portlet.wiki.model.WikiPageResource findByUuid_Last(
192                    java.lang.String uuid,
193                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
194                    throws com.liferay.portal.kernel.exception.SystemException,
195                            com.liferay.portlet.wiki.NoSuchPageResourceException;
196    
197            /**
198            * Returns the last wiki page resource in the ordered set where uuid = &#63;.
199            *
200            * @param uuid the uuid
201            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
202            * @return the last matching wiki page resource, or <code>null</code> if a matching wiki page resource could not be found
203            * @throws SystemException if a system exception occurred
204            */
205            public com.liferay.portlet.wiki.model.WikiPageResource fetchByUuid_Last(
206                    java.lang.String uuid,
207                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
208                    throws com.liferay.portal.kernel.exception.SystemException;
209    
210            /**
211            * Returns the wiki page resources before and after the current wiki page resource in the ordered set where uuid = &#63;.
212            *
213            * @param resourcePrimKey the primary key of the current wiki page resource
214            * @param uuid the uuid
215            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
216            * @return the previous, current, and next wiki page resource
217            * @throws com.liferay.portlet.wiki.NoSuchPageResourceException if a wiki page resource with the primary key could not be found
218            * @throws SystemException if a system exception occurred
219            */
220            public com.liferay.portlet.wiki.model.WikiPageResource[] findByUuid_PrevAndNext(
221                    long resourcePrimKey, java.lang.String uuid,
222                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
223                    throws com.liferay.portal.kernel.exception.SystemException,
224                            com.liferay.portlet.wiki.NoSuchPageResourceException;
225    
226            /**
227            * Returns the wiki page resource where nodeId = &#63; and title = &#63; or throws a {@link com.liferay.portlet.wiki.NoSuchPageResourceException} if it could not be found.
228            *
229            * @param nodeId the node ID
230            * @param title the title
231            * @return the matching wiki page resource
232            * @throws com.liferay.portlet.wiki.NoSuchPageResourceException if a matching wiki page resource could not be found
233            * @throws SystemException if a system exception occurred
234            */
235            public com.liferay.portlet.wiki.model.WikiPageResource findByN_T(
236                    long nodeId, java.lang.String title)
237                    throws com.liferay.portal.kernel.exception.SystemException,
238                            com.liferay.portlet.wiki.NoSuchPageResourceException;
239    
240            /**
241            * Returns the wiki page resource where nodeId = &#63; and title = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
242            *
243            * @param nodeId the node ID
244            * @param title the title
245            * @return the matching wiki page resource, or <code>null</code> if a matching wiki page resource could not be found
246            * @throws SystemException if a system exception occurred
247            */
248            public com.liferay.portlet.wiki.model.WikiPageResource fetchByN_T(
249                    long nodeId, java.lang.String title)
250                    throws com.liferay.portal.kernel.exception.SystemException;
251    
252            /**
253            * Returns the wiki page resource where nodeId = &#63; and title = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
254            *
255            * @param nodeId the node ID
256            * @param title the title
257            * @param retrieveFromCache whether to use the finder cache
258            * @return the matching wiki page resource, or <code>null</code> if a matching wiki page resource could not be found
259            * @throws SystemException if a system exception occurred
260            */
261            public com.liferay.portlet.wiki.model.WikiPageResource fetchByN_T(
262                    long nodeId, java.lang.String title, boolean retrieveFromCache)
263                    throws com.liferay.portal.kernel.exception.SystemException;
264    
265            /**
266            * Returns all the wiki page resources.
267            *
268            * @return the wiki page resources
269            * @throws SystemException if a system exception occurred
270            */
271            public java.util.List<com.liferay.portlet.wiki.model.WikiPageResource> findAll()
272                    throws com.liferay.portal.kernel.exception.SystemException;
273    
274            /**
275            * Returns a range of all the wiki page resources.
276            *
277            * <p>
278            * 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.
279            * </p>
280            *
281            * @param start the lower bound of the range of wiki page resources
282            * @param end the upper bound of the range of wiki page resources (not inclusive)
283            * @return the range of wiki page resources
284            * @throws SystemException if a system exception occurred
285            */
286            public java.util.List<com.liferay.portlet.wiki.model.WikiPageResource> findAll(
287                    int start, int end)
288                    throws com.liferay.portal.kernel.exception.SystemException;
289    
290            /**
291            * Returns an ordered range of all the wiki page resources.
292            *
293            * <p>
294            * 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.
295            * </p>
296            *
297            * @param start the lower bound of the range of wiki page resources
298            * @param end the upper bound of the range of wiki page resources (not inclusive)
299            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
300            * @return the ordered range of wiki page resources
301            * @throws SystemException if a system exception occurred
302            */
303            public java.util.List<com.liferay.portlet.wiki.model.WikiPageResource> findAll(
304                    int start, int end,
305                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
306                    throws com.liferay.portal.kernel.exception.SystemException;
307    
308            /**
309            * Removes all the wiki page resources where uuid = &#63; from the database.
310            *
311            * @param uuid the uuid
312            * @throws SystemException if a system exception occurred
313            */
314            public void removeByUuid(java.lang.String uuid)
315                    throws com.liferay.portal.kernel.exception.SystemException;
316    
317            /**
318            * Removes the wiki page resource where nodeId = &#63; and title = &#63; from the database.
319            *
320            * @param nodeId the node ID
321            * @param title the title
322            * @return the wiki page resource that was removed
323            * @throws SystemException if a system exception occurred
324            */
325            public com.liferay.portlet.wiki.model.WikiPageResource removeByN_T(
326                    long nodeId, java.lang.String title)
327                    throws com.liferay.portal.kernel.exception.SystemException,
328                            com.liferay.portlet.wiki.NoSuchPageResourceException;
329    
330            /**
331            * Removes all the wiki page resources from the database.
332            *
333            * @throws SystemException if a system exception occurred
334            */
335            public void removeAll()
336                    throws com.liferay.portal.kernel.exception.SystemException;
337    
338            /**
339            * Returns the number of wiki page resources where uuid = &#63;.
340            *
341            * @param uuid the uuid
342            * @return the number of matching wiki page resources
343            * @throws SystemException if a system exception occurred
344            */
345            public int countByUuid(java.lang.String uuid)
346                    throws com.liferay.portal.kernel.exception.SystemException;
347    
348            /**
349            * Returns the number of wiki page resources where nodeId = &#63; and title = &#63;.
350            *
351            * @param nodeId the node ID
352            * @param title the title
353            * @return the number of matching wiki page resources
354            * @throws SystemException if a system exception occurred
355            */
356            public int countByN_T(long nodeId, java.lang.String title)
357                    throws com.liferay.portal.kernel.exception.SystemException;
358    
359            /**
360            * Returns the number of wiki page resources.
361            *
362            * @return the number of wiki page resources
363            * @throws SystemException if a system exception occurred
364            */
365            public int countAll()
366                    throws com.liferay.portal.kernel.exception.SystemException;
367    }