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