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.Release;
020    
021    /**
022     * The persistence interface for the release 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 ReleasePersistenceImpl
030     * @see ReleaseUtil
031     * @generated
032     */
033    @ProviderType
034    public interface ReleasePersistence extends BasePersistence<Release> {
035            /*
036             * NOTE FOR DEVELOPERS:
037             *
038             * Never modify or reference this interface directly. Always use {@link ReleaseUtil} to access the release persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
039             */
040    
041            /**
042            * Returns the release where servletContextName = &#63; or throws a {@link com.liferay.portal.NoSuchReleaseException} if it could not be found.
043            *
044            * @param servletContextName the servlet context name
045            * @return the matching release
046            * @throws com.liferay.portal.NoSuchReleaseException if a matching release could not be found
047            */
048            public com.liferay.portal.model.Release findByServletContextName(
049                    java.lang.String servletContextName)
050                    throws com.liferay.portal.NoSuchReleaseException;
051    
052            /**
053            * Returns the release where servletContextName = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
054            *
055            * @param servletContextName the servlet context name
056            * @return the matching release, or <code>null</code> if a matching release could not be found
057            */
058            public com.liferay.portal.model.Release fetchByServletContextName(
059                    java.lang.String servletContextName);
060    
061            /**
062            * Returns the release where servletContextName = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
063            *
064            * @param servletContextName the servlet context name
065            * @param retrieveFromCache whether to use the finder cache
066            * @return the matching release, or <code>null</code> if a matching release could not be found
067            */
068            public com.liferay.portal.model.Release fetchByServletContextName(
069                    java.lang.String servletContextName, boolean retrieveFromCache);
070    
071            /**
072            * Removes the release where servletContextName = &#63; from the database.
073            *
074            * @param servletContextName the servlet context name
075            * @return the release that was removed
076            */
077            public com.liferay.portal.model.Release removeByServletContextName(
078                    java.lang.String servletContextName)
079                    throws com.liferay.portal.NoSuchReleaseException;
080    
081            /**
082            * Returns the number of releases where servletContextName = &#63;.
083            *
084            * @param servletContextName the servlet context name
085            * @return the number of matching releases
086            */
087            public int countByServletContextName(java.lang.String servletContextName);
088    
089            /**
090            * Caches the release in the entity cache if it is enabled.
091            *
092            * @param release the release
093            */
094            public void cacheResult(com.liferay.portal.model.Release release);
095    
096            /**
097            * Caches the releases in the entity cache if it is enabled.
098            *
099            * @param releases the releases
100            */
101            public void cacheResult(
102                    java.util.List<com.liferay.portal.model.Release> releases);
103    
104            /**
105            * Creates a new release with the primary key. Does not add the release to the database.
106            *
107            * @param releaseId the primary key for the new release
108            * @return the new release
109            */
110            public com.liferay.portal.model.Release create(long releaseId);
111    
112            /**
113            * Removes the release with the primary key from the database. Also notifies the appropriate model listeners.
114            *
115            * @param releaseId the primary key of the release
116            * @return the release that was removed
117            * @throws com.liferay.portal.NoSuchReleaseException if a release with the primary key could not be found
118            */
119            public com.liferay.portal.model.Release remove(long releaseId)
120                    throws com.liferay.portal.NoSuchReleaseException;
121    
122            public com.liferay.portal.model.Release updateImpl(
123                    com.liferay.portal.model.Release release);
124    
125            /**
126            * Returns the release with the primary key or throws a {@link com.liferay.portal.NoSuchReleaseException} if it could not be found.
127            *
128            * @param releaseId the primary key of the release
129            * @return the release
130            * @throws com.liferay.portal.NoSuchReleaseException if a release with the primary key could not be found
131            */
132            public com.liferay.portal.model.Release findByPrimaryKey(long releaseId)
133                    throws com.liferay.portal.NoSuchReleaseException;
134    
135            /**
136            * Returns the release with the primary key or returns <code>null</code> if it could not be found.
137            *
138            * @param releaseId the primary key of the release
139            * @return the release, or <code>null</code> if a release with the primary key could not be found
140            */
141            public com.liferay.portal.model.Release fetchByPrimaryKey(long releaseId);
142    
143            @Override
144            public java.util.Map<java.io.Serializable, com.liferay.portal.model.Release> fetchByPrimaryKeys(
145                    java.util.Set<java.io.Serializable> primaryKeys);
146    
147            /**
148            * Returns all the releases.
149            *
150            * @return the releases
151            */
152            public java.util.List<com.liferay.portal.model.Release> findAll();
153    
154            /**
155            * Returns a range of all the releases.
156            *
157            * <p>
158            * 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.ReleaseModelImpl}. 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.
159            * </p>
160            *
161            * @param start the lower bound of the range of releases
162            * @param end the upper bound of the range of releases (not inclusive)
163            * @return the range of releases
164            */
165            public java.util.List<com.liferay.portal.model.Release> findAll(int start,
166                    int end);
167    
168            /**
169            * Returns an ordered range of all the releases.
170            *
171            * <p>
172            * 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.ReleaseModelImpl}. 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.
173            * </p>
174            *
175            * @param start the lower bound of the range of releases
176            * @param end the upper bound of the range of releases (not inclusive)
177            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
178            * @return the ordered range of releases
179            */
180            public java.util.List<com.liferay.portal.model.Release> findAll(int start,
181                    int end,
182                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.Release> orderByComparator);
183    
184            /**
185            * Removes all the releases from the database.
186            */
187            public void removeAll();
188    
189            /**
190            * Returns the number of releases.
191            *
192            * @return the number of releases
193            */
194            public int countAll();
195    }