001    /**
002     * Copyright (c) 2000-2012 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 com.liferay.portal.model.WorkflowInstanceLink;
018    
019    /**
020     * The persistence interface for the workflow instance link service.
021     *
022     * <p>
023     * Caching information and settings can be found in <code>portal.properties</code>
024     * </p>
025     *
026     * @author Brian Wing Shun Chan
027     * @see WorkflowInstanceLinkPersistenceImpl
028     * @see WorkflowInstanceLinkUtil
029     * @generated
030     */
031    public interface WorkflowInstanceLinkPersistence extends BasePersistence<WorkflowInstanceLink> {
032            /*
033             * NOTE FOR DEVELOPERS:
034             *
035             * Never modify or reference this interface directly. Always use {@link WorkflowInstanceLinkUtil} to access the workflow instance link persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
036             */
037    
038            /**
039            * Caches the workflow instance link in the entity cache if it is enabled.
040            *
041            * @param workflowInstanceLink the workflow instance link
042            */
043            public void cacheResult(
044                    com.liferay.portal.model.WorkflowInstanceLink workflowInstanceLink);
045    
046            /**
047            * Caches the workflow instance links in the entity cache if it is enabled.
048            *
049            * @param workflowInstanceLinks the workflow instance links
050            */
051            public void cacheResult(
052                    java.util.List<com.liferay.portal.model.WorkflowInstanceLink> workflowInstanceLinks);
053    
054            /**
055            * Creates a new workflow instance link with the primary key. Does not add the workflow instance link to the database.
056            *
057            * @param workflowInstanceLinkId the primary key for the new workflow instance link
058            * @return the new workflow instance link
059            */
060            public com.liferay.portal.model.WorkflowInstanceLink create(
061                    long workflowInstanceLinkId);
062    
063            /**
064            * Removes the workflow instance link with the primary key from the database. Also notifies the appropriate model listeners.
065            *
066            * @param workflowInstanceLinkId the primary key of the workflow instance link
067            * @return the workflow instance link that was removed
068            * @throws com.liferay.portal.NoSuchWorkflowInstanceLinkException if a workflow instance link with the primary key could not be found
069            * @throws SystemException if a system exception occurred
070            */
071            public com.liferay.portal.model.WorkflowInstanceLink remove(
072                    long workflowInstanceLinkId)
073                    throws com.liferay.portal.NoSuchWorkflowInstanceLinkException,
074                            com.liferay.portal.kernel.exception.SystemException;
075    
076            public com.liferay.portal.model.WorkflowInstanceLink updateImpl(
077                    com.liferay.portal.model.WorkflowInstanceLink workflowInstanceLink)
078                    throws com.liferay.portal.kernel.exception.SystemException;
079    
080            /**
081            * Returns the workflow instance link with the primary key or throws a {@link com.liferay.portal.NoSuchWorkflowInstanceLinkException} if it could not be found.
082            *
083            * @param workflowInstanceLinkId the primary key of the workflow instance link
084            * @return the workflow instance link
085            * @throws com.liferay.portal.NoSuchWorkflowInstanceLinkException if a workflow instance link with the primary key could not be found
086            * @throws SystemException if a system exception occurred
087            */
088            public com.liferay.portal.model.WorkflowInstanceLink findByPrimaryKey(
089                    long workflowInstanceLinkId)
090                    throws com.liferay.portal.NoSuchWorkflowInstanceLinkException,
091                            com.liferay.portal.kernel.exception.SystemException;
092    
093            /**
094            * Returns the workflow instance link with the primary key or returns <code>null</code> if it could not be found.
095            *
096            * @param workflowInstanceLinkId the primary key of the workflow instance link
097            * @return the workflow instance link, or <code>null</code> if a workflow instance link with the primary key could not be found
098            * @throws SystemException if a system exception occurred
099            */
100            public com.liferay.portal.model.WorkflowInstanceLink fetchByPrimaryKey(
101                    long workflowInstanceLinkId)
102                    throws com.liferay.portal.kernel.exception.SystemException;
103    
104            /**
105            * Returns all the workflow instance links where groupId = &#63; and companyId = &#63; and classNameId = &#63; and classPK = &#63;.
106            *
107            * @param groupId the group ID
108            * @param companyId the company ID
109            * @param classNameId the class name ID
110            * @param classPK the class p k
111            * @return the matching workflow instance links
112            * @throws SystemException if a system exception occurred
113            */
114            public java.util.List<com.liferay.portal.model.WorkflowInstanceLink> findByG_C_C_C(
115                    long groupId, long companyId, long classNameId, long classPK)
116                    throws com.liferay.portal.kernel.exception.SystemException;
117    
118            /**
119            * Returns a range of all the workflow instance links where groupId = &#63; and companyId = &#63; and classNameId = &#63; and classPK = &#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 groupId the group ID
126            * @param companyId the company ID
127            * @param classNameId the class name ID
128            * @param classPK the class p k
129            * @param start the lower bound of the range of workflow instance links
130            * @param end the upper bound of the range of workflow instance links (not inclusive)
131            * @return the range of matching workflow instance links
132            * @throws SystemException if a system exception occurred
133            */
134            public java.util.List<com.liferay.portal.model.WorkflowInstanceLink> findByG_C_C_C(
135                    long groupId, long companyId, long classNameId, long classPK,
136                    int start, int end)
137                    throws com.liferay.portal.kernel.exception.SystemException;
138    
139            /**
140            * Returns an ordered range of all the workflow instance links where groupId = &#63; and companyId = &#63; and classNameId = &#63; and classPK = &#63;.
141            *
142            * <p>
143            * 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.
144            * </p>
145            *
146            * @param groupId the group ID
147            * @param companyId the company ID
148            * @param classNameId the class name ID
149            * @param classPK the class p k
150            * @param start the lower bound of the range of workflow instance links
151            * @param end the upper bound of the range of workflow instance links (not inclusive)
152            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
153            * @return the ordered range of matching workflow instance links
154            * @throws SystemException if a system exception occurred
155            */
156            public java.util.List<com.liferay.portal.model.WorkflowInstanceLink> findByG_C_C_C(
157                    long groupId, long companyId, long classNameId, long classPK,
158                    int start, int end,
159                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
160                    throws com.liferay.portal.kernel.exception.SystemException;
161    
162            /**
163            * Returns the first workflow instance link in the ordered set where groupId = &#63; and companyId = &#63; and classNameId = &#63; and classPK = &#63;.
164            *
165            * @param groupId the group ID
166            * @param companyId the company ID
167            * @param classNameId the class name ID
168            * @param classPK the class p k
169            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
170            * @return the first matching workflow instance link
171            * @throws com.liferay.portal.NoSuchWorkflowInstanceLinkException if a matching workflow instance link could not be found
172            * @throws SystemException if a system exception occurred
173            */
174            public com.liferay.portal.model.WorkflowInstanceLink findByG_C_C_C_First(
175                    long groupId, long companyId, long classNameId, long classPK,
176                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
177                    throws com.liferay.portal.NoSuchWorkflowInstanceLinkException,
178                            com.liferay.portal.kernel.exception.SystemException;
179    
180            /**
181            * Returns the first workflow instance link in the ordered set where groupId = &#63; and companyId = &#63; and classNameId = &#63; and classPK = &#63;.
182            *
183            * @param groupId the group ID
184            * @param companyId the company ID
185            * @param classNameId the class name ID
186            * @param classPK the class p k
187            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
188            * @return the first matching workflow instance link, or <code>null</code> if a matching workflow instance link could not be found
189            * @throws SystemException if a system exception occurred
190            */
191            public com.liferay.portal.model.WorkflowInstanceLink fetchByG_C_C_C_First(
192                    long groupId, long companyId, long classNameId, long classPK,
193                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
194                    throws com.liferay.portal.kernel.exception.SystemException;
195    
196            /**
197            * Returns the last workflow instance link in the ordered set where groupId = &#63; and companyId = &#63; and classNameId = &#63; and classPK = &#63;.
198            *
199            * @param groupId the group ID
200            * @param companyId the company ID
201            * @param classNameId the class name ID
202            * @param classPK the class p k
203            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
204            * @return the last matching workflow instance link
205            * @throws com.liferay.portal.NoSuchWorkflowInstanceLinkException if a matching workflow instance link could not be found
206            * @throws SystemException if a system exception occurred
207            */
208            public com.liferay.portal.model.WorkflowInstanceLink findByG_C_C_C_Last(
209                    long groupId, long companyId, long classNameId, long classPK,
210                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
211                    throws com.liferay.portal.NoSuchWorkflowInstanceLinkException,
212                            com.liferay.portal.kernel.exception.SystemException;
213    
214            /**
215            * Returns the last workflow instance link in the ordered set where groupId = &#63; and companyId = &#63; and classNameId = &#63; and classPK = &#63;.
216            *
217            * @param groupId the group ID
218            * @param companyId the company ID
219            * @param classNameId the class name ID
220            * @param classPK the class p k
221            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
222            * @return the last matching workflow instance link, or <code>null</code> if a matching workflow instance link could not be found
223            * @throws SystemException if a system exception occurred
224            */
225            public com.liferay.portal.model.WorkflowInstanceLink fetchByG_C_C_C_Last(
226                    long groupId, long companyId, long classNameId, long classPK,
227                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
228                    throws com.liferay.portal.kernel.exception.SystemException;
229    
230            /**
231            * Returns the workflow instance links before and after the current workflow instance link in the ordered set where groupId = &#63; and companyId = &#63; and classNameId = &#63; and classPK = &#63;.
232            *
233            * @param workflowInstanceLinkId the primary key of the current workflow instance link
234            * @param groupId the group ID
235            * @param companyId the company ID
236            * @param classNameId the class name ID
237            * @param classPK the class p k
238            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
239            * @return the previous, current, and next workflow instance link
240            * @throws com.liferay.portal.NoSuchWorkflowInstanceLinkException if a workflow instance link with the primary key could not be found
241            * @throws SystemException if a system exception occurred
242            */
243            public com.liferay.portal.model.WorkflowInstanceLink[] findByG_C_C_C_PrevAndNext(
244                    long workflowInstanceLinkId, long groupId, long companyId,
245                    long classNameId, long classPK,
246                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
247                    throws com.liferay.portal.NoSuchWorkflowInstanceLinkException,
248                            com.liferay.portal.kernel.exception.SystemException;
249    
250            /**
251            * Returns all the workflow instance links.
252            *
253            * @return the workflow instance links
254            * @throws SystemException if a system exception occurred
255            */
256            public java.util.List<com.liferay.portal.model.WorkflowInstanceLink> findAll()
257                    throws com.liferay.portal.kernel.exception.SystemException;
258    
259            /**
260            * Returns a range of all the workflow instance links.
261            *
262            * <p>
263            * 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.
264            * </p>
265            *
266            * @param start the lower bound of the range of workflow instance links
267            * @param end the upper bound of the range of workflow instance links (not inclusive)
268            * @return the range of workflow instance links
269            * @throws SystemException if a system exception occurred
270            */
271            public java.util.List<com.liferay.portal.model.WorkflowInstanceLink> findAll(
272                    int start, int end)
273                    throws com.liferay.portal.kernel.exception.SystemException;
274    
275            /**
276            * Returns an ordered range of all the workflow instance links.
277            *
278            * <p>
279            * 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.
280            * </p>
281            *
282            * @param start the lower bound of the range of workflow instance links
283            * @param end the upper bound of the range of workflow instance links (not inclusive)
284            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
285            * @return the ordered range of workflow instance links
286            * @throws SystemException if a system exception occurred
287            */
288            public java.util.List<com.liferay.portal.model.WorkflowInstanceLink> findAll(
289                    int start, int end,
290                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
291                    throws com.liferay.portal.kernel.exception.SystemException;
292    
293            /**
294            * Removes all the workflow instance links where groupId = &#63; and companyId = &#63; and classNameId = &#63; and classPK = &#63; from the database.
295            *
296            * @param groupId the group ID
297            * @param companyId the company ID
298            * @param classNameId the class name ID
299            * @param classPK the class p k
300            * @throws SystemException if a system exception occurred
301            */
302            public void removeByG_C_C_C(long groupId, long companyId, long classNameId,
303                    long classPK)
304                    throws com.liferay.portal.kernel.exception.SystemException;
305    
306            /**
307            * Removes all the workflow instance links from the database.
308            *
309            * @throws SystemException if a system exception occurred
310            */
311            public void removeAll()
312                    throws com.liferay.portal.kernel.exception.SystemException;
313    
314            /**
315            * Returns the number of workflow instance links where groupId = &#63; and companyId = &#63; and classNameId = &#63; and classPK = &#63;.
316            *
317            * @param groupId the group ID
318            * @param companyId the company ID
319            * @param classNameId the class name ID
320            * @param classPK the class p k
321            * @return the number of matching workflow instance links
322            * @throws SystemException if a system exception occurred
323            */
324            public int countByG_C_C_C(long groupId, long companyId, long classNameId,
325                    long classPK)
326                    throws com.liferay.portal.kernel.exception.SystemException;
327    
328            /**
329            * Returns the number of workflow instance links.
330            *
331            * @return the number of workflow instance links
332            * @throws SystemException if a system exception occurred
333            */
334            public int countAll()
335                    throws com.liferay.portal.kernel.exception.SystemException;
336    }