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;
016    
017    import aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
020    import com.liferay.portal.kernel.util.ReferenceRegistry;
021    
022    /**
023     * Provides the local service utility for LayoutSetPrototype. This utility wraps
024     * {@link com.liferay.portal.service.impl.LayoutSetPrototypeLocalServiceImpl} and is the
025     * primary access point for service operations in application layer code running
026     * on the local server. Methods of this service will not have security checks
027     * based on the propagated JAAS credentials because this service can only be
028     * accessed from within the same VM.
029     *
030     * @author Brian Wing Shun Chan
031     * @see LayoutSetPrototypeLocalService
032     * @see com.liferay.portal.service.base.LayoutSetPrototypeLocalServiceBaseImpl
033     * @see com.liferay.portal.service.impl.LayoutSetPrototypeLocalServiceImpl
034     * @generated
035     */
036    @ProviderType
037    public class LayoutSetPrototypeLocalServiceUtil {
038            /*
039             * NOTE FOR DEVELOPERS:
040             *
041             * Never modify this class directly. Add custom service methods to {@link com.liferay.portal.service.impl.LayoutSetPrototypeLocalServiceImpl} and rerun ServiceBuilder to regenerate this class.
042             */
043    
044            /**
045            * Adds the layout set prototype to the database. Also notifies the appropriate model listeners.
046            *
047            * @param layoutSetPrototype the layout set prototype
048            * @return the layout set prototype that was added
049            */
050            public static com.liferay.portal.model.LayoutSetPrototype addLayoutSetPrototype(
051                    com.liferay.portal.model.LayoutSetPrototype layoutSetPrototype) {
052                    return getService().addLayoutSetPrototype(layoutSetPrototype);
053            }
054    
055            /**
056            * @deprecated As of 7.0.0, replaced by {@link #addLayoutSetPrototype(long,
057            long, Map, Map, boolean, boolean, ServiceContext)}
058            */
059            @Deprecated
060            public static com.liferay.portal.model.LayoutSetPrototype addLayoutSetPrototype(
061                    long userId, long companyId,
062                    java.util.Map<java.util.Locale, java.lang.String> nameMap,
063                    java.lang.String description, boolean active,
064                    boolean layoutsUpdateable,
065                    com.liferay.portal.service.ServiceContext serviceContext)
066                    throws com.liferay.portal.kernel.exception.PortalException {
067                    return getService()
068                                       .addLayoutSetPrototype(userId, companyId, nameMap,
069                            description, active, layoutsUpdateable, serviceContext);
070            }
071    
072            public static com.liferay.portal.model.LayoutSetPrototype addLayoutSetPrototype(
073                    long userId, long companyId,
074                    java.util.Map<java.util.Locale, java.lang.String> nameMap,
075                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
076                    boolean active, boolean layoutsUpdateable,
077                    com.liferay.portal.service.ServiceContext serviceContext)
078                    throws com.liferay.portal.kernel.exception.PortalException {
079                    return getService()
080                                       .addLayoutSetPrototype(userId, companyId, nameMap,
081                            descriptionMap, active, layoutsUpdateable, serviceContext);
082            }
083    
084            /**
085            * Creates a new layout set prototype with the primary key. Does not add the layout set prototype to the database.
086            *
087            * @param layoutSetPrototypeId the primary key for the new layout set prototype
088            * @return the new layout set prototype
089            */
090            public static com.liferay.portal.model.LayoutSetPrototype createLayoutSetPrototype(
091                    long layoutSetPrototypeId) {
092                    return getService().createLayoutSetPrototype(layoutSetPrototypeId);
093            }
094    
095            /**
096            * Deletes the layout set prototype from the database. Also notifies the appropriate model listeners.
097            *
098            * @param layoutSetPrototype the layout set prototype
099            * @return the layout set prototype that was removed
100            * @throws PortalException
101            */
102            public static com.liferay.portal.model.LayoutSetPrototype deleteLayoutSetPrototype(
103                    com.liferay.portal.model.LayoutSetPrototype layoutSetPrototype)
104                    throws com.liferay.portal.kernel.exception.PortalException {
105                    return getService().deleteLayoutSetPrototype(layoutSetPrototype);
106            }
107    
108            /**
109            * Deletes the layout set prototype with the primary key from the database. Also notifies the appropriate model listeners.
110            *
111            * @param layoutSetPrototypeId the primary key of the layout set prototype
112            * @return the layout set prototype that was removed
113            * @throws PortalException if a layout set prototype with the primary key could not be found
114            */
115            public static com.liferay.portal.model.LayoutSetPrototype deleteLayoutSetPrototype(
116                    long layoutSetPrototypeId)
117                    throws com.liferay.portal.kernel.exception.PortalException {
118                    return getService().deleteLayoutSetPrototype(layoutSetPrototypeId);
119            }
120    
121            public static void deleteLayoutSetPrototypes()
122                    throws com.liferay.portal.kernel.exception.PortalException {
123                    getService().deleteLayoutSetPrototypes();
124            }
125    
126            public static void deleteNondefaultLayoutSetPrototypes(long companyId)
127                    throws com.liferay.portal.kernel.exception.PortalException {
128                    getService().deleteNondefaultLayoutSetPrototypes(companyId);
129            }
130    
131            /**
132            * @throws PortalException
133            */
134            public static com.liferay.portal.model.PersistedModel deletePersistedModel(
135                    com.liferay.portal.model.PersistedModel persistedModel)
136                    throws com.liferay.portal.kernel.exception.PortalException {
137                    return getService().deletePersistedModel(persistedModel);
138            }
139    
140            public static com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery() {
141                    return getService().dynamicQuery();
142            }
143    
144            /**
145            * Performs a dynamic query on the database and returns the matching rows.
146            *
147            * @param dynamicQuery the dynamic query
148            * @return the matching rows
149            */
150            public static <T> java.util.List<T> dynamicQuery(
151                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) {
152                    return getService().dynamicQuery(dynamicQuery);
153            }
154    
155            /**
156            * Performs a dynamic query on the database and returns a range of the matching rows.
157            *
158            * <p>
159            * 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.LayoutSetPrototypeModelImpl}. 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.
160            * </p>
161            *
162            * @param dynamicQuery the dynamic query
163            * @param start the lower bound of the range of model instances
164            * @param end the upper bound of the range of model instances (not inclusive)
165            * @return the range of matching rows
166            */
167            public static <T> java.util.List<T> dynamicQuery(
168                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
169                    int end) {
170                    return getService().dynamicQuery(dynamicQuery, start, end);
171            }
172    
173            /**
174            * Performs a dynamic query on the database and returns an ordered range of the matching rows.
175            *
176            * <p>
177            * 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.LayoutSetPrototypeModelImpl}. 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.
178            * </p>
179            *
180            * @param dynamicQuery the dynamic query
181            * @param start the lower bound of the range of model instances
182            * @param end the upper bound of the range of model instances (not inclusive)
183            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
184            * @return the ordered range of matching rows
185            */
186            public static <T> java.util.List<T> dynamicQuery(
187                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
188                    int end,
189                    com.liferay.portal.kernel.util.OrderByComparator<T> orderByComparator) {
190                    return getService()
191                                       .dynamicQuery(dynamicQuery, start, end, orderByComparator);
192            }
193    
194            /**
195            * Returns the number of rows matching the dynamic query.
196            *
197            * @param dynamicQuery the dynamic query
198            * @return the number of rows matching the dynamic query
199            */
200            public static long dynamicQueryCount(
201                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) {
202                    return getService().dynamicQueryCount(dynamicQuery);
203            }
204    
205            /**
206            * Returns the number of rows matching the dynamic query.
207            *
208            * @param dynamicQuery the dynamic query
209            * @param projection the projection to apply to the query
210            * @return the number of rows matching the dynamic query
211            */
212            public static long dynamicQueryCount(
213                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery,
214                    com.liferay.portal.kernel.dao.orm.Projection projection) {
215                    return getService().dynamicQueryCount(dynamicQuery, projection);
216            }
217    
218            public static com.liferay.portal.model.LayoutSetPrototype fetchLayoutSetPrototype(
219                    long layoutSetPrototypeId) {
220                    return getService().fetchLayoutSetPrototype(layoutSetPrototypeId);
221            }
222    
223            /**
224            * Returns the layout set prototype with the matching UUID and company.
225            *
226            * @param uuid the layout set prototype's UUID
227            * @param companyId the primary key of the company
228            * @return the matching layout set prototype, or <code>null</code> if a matching layout set prototype could not be found
229            */
230            public static com.liferay.portal.model.LayoutSetPrototype fetchLayoutSetPrototypeByUuidAndCompanyId(
231                    java.lang.String uuid, long companyId) {
232                    return getService()
233                                       .fetchLayoutSetPrototypeByUuidAndCompanyId(uuid, companyId);
234            }
235    
236            public static com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery getActionableDynamicQuery() {
237                    return getService().getActionableDynamicQuery();
238            }
239    
240            /**
241            * Returns the Spring bean ID for this bean.
242            *
243            * @return the Spring bean ID for this bean
244            */
245            public static java.lang.String getBeanIdentifier() {
246                    return getService().getBeanIdentifier();
247            }
248    
249            public static com.liferay.portal.kernel.dao.orm.ExportActionableDynamicQuery getExportActionableDynamicQuery(
250                    com.liferay.portlet.exportimport.lar.PortletDataContext portletDataContext) {
251                    return getService().getExportActionableDynamicQuery(portletDataContext);
252            }
253    
254            /**
255            * Returns the layout set prototype with the primary key.
256            *
257            * @param layoutSetPrototypeId the primary key of the layout set prototype
258            * @return the layout set prototype
259            * @throws PortalException if a layout set prototype with the primary key could not be found
260            */
261            public static com.liferay.portal.model.LayoutSetPrototype getLayoutSetPrototype(
262                    long layoutSetPrototypeId)
263                    throws com.liferay.portal.kernel.exception.PortalException {
264                    return getService().getLayoutSetPrototype(layoutSetPrototypeId);
265            }
266    
267            /**
268            * @deprecated As of 6.2.0, replaced by {@link
269            #getLayoutSetPrototypeByUuidAndCompanyId(String, long)}
270            */
271            @Deprecated
272            public static com.liferay.portal.model.LayoutSetPrototype getLayoutSetPrototypeByUuid(
273                    java.lang.String uuid)
274                    throws com.liferay.portal.kernel.exception.PortalException {
275                    return getService().getLayoutSetPrototypeByUuid(uuid);
276            }
277    
278            /**
279            * Returns the layout set prototype with the matching UUID and company.
280            *
281            * @param uuid the layout set prototype's UUID
282            * @param companyId the primary key of the company
283            * @return the matching layout set prototype
284            * @throws PortalException if a matching layout set prototype could not be found
285            */
286            public static com.liferay.portal.model.LayoutSetPrototype getLayoutSetPrototypeByUuidAndCompanyId(
287                    java.lang.String uuid, long companyId)
288                    throws com.liferay.portal.kernel.exception.PortalException {
289                    return getService()
290                                       .getLayoutSetPrototypeByUuidAndCompanyId(uuid, companyId);
291            }
292    
293            public static java.util.List<com.liferay.portal.model.LayoutSetPrototype> getLayoutSetPrototypes(
294                    long companyId) {
295                    return getService().getLayoutSetPrototypes(companyId);
296            }
297    
298            /**
299            * Returns a range of all the layout set prototypes.
300            *
301            * <p>
302            * 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.LayoutSetPrototypeModelImpl}. 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.
303            * </p>
304            *
305            * @param start the lower bound of the range of layout set prototypes
306            * @param end the upper bound of the range of layout set prototypes (not inclusive)
307            * @return the range of layout set prototypes
308            */
309            public static java.util.List<com.liferay.portal.model.LayoutSetPrototype> getLayoutSetPrototypes(
310                    int start, int end) {
311                    return getService().getLayoutSetPrototypes(start, end);
312            }
313    
314            /**
315            * Returns the number of layout set prototypes.
316            *
317            * @return the number of layout set prototypes
318            */
319            public static int getLayoutSetPrototypesCount() {
320                    return getService().getLayoutSetPrototypesCount();
321            }
322    
323            public static com.liferay.portal.model.PersistedModel getPersistedModel(
324                    java.io.Serializable primaryKeyObj)
325                    throws com.liferay.portal.kernel.exception.PortalException {
326                    return getService().getPersistedModel(primaryKeyObj);
327            }
328    
329            public static java.util.List<com.liferay.portal.model.LayoutSetPrototype> search(
330                    long companyId, java.lang.Boolean active, int start, int end,
331                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.LayoutSetPrototype> obc) {
332                    return getService().search(companyId, active, start, end, obc);
333            }
334    
335            public static int searchCount(long companyId, java.lang.Boolean active) {
336                    return getService().searchCount(companyId, active);
337            }
338    
339            /**
340            * Sets the Spring bean ID for this bean.
341            *
342            * @param beanIdentifier the Spring bean ID for this bean
343            */
344            public static void setBeanIdentifier(java.lang.String beanIdentifier) {
345                    getService().setBeanIdentifier(beanIdentifier);
346            }
347    
348            /**
349            * Updates the layout set prototype in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
350            *
351            * @param layoutSetPrototype the layout set prototype
352            * @return the layout set prototype that was updated
353            */
354            public static com.liferay.portal.model.LayoutSetPrototype updateLayoutSetPrototype(
355                    com.liferay.portal.model.LayoutSetPrototype layoutSetPrototype) {
356                    return getService().updateLayoutSetPrototype(layoutSetPrototype);
357            }
358    
359            /**
360            * @deprecated As of 7.0.0, replaced by {@link
361            #updateLayoutSetPrototype(long, Map, Map, boolean, boolean,
362            ServiceContext)}
363            */
364            @Deprecated
365            public static com.liferay.portal.model.LayoutSetPrototype updateLayoutSetPrototype(
366                    long layoutSetPrototypeId,
367                    java.util.Map<java.util.Locale, java.lang.String> nameMap,
368                    java.lang.String description, boolean active,
369                    boolean layoutsUpdateable,
370                    com.liferay.portal.service.ServiceContext serviceContext)
371                    throws com.liferay.portal.kernel.exception.PortalException {
372                    return getService()
373                                       .updateLayoutSetPrototype(layoutSetPrototypeId, nameMap,
374                            description, active, layoutsUpdateable, serviceContext);
375            }
376    
377            public static com.liferay.portal.model.LayoutSetPrototype updateLayoutSetPrototype(
378                    long layoutSetPrototypeId,
379                    java.util.Map<java.util.Locale, java.lang.String> nameMap,
380                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
381                    boolean active, boolean layoutsUpdateable,
382                    com.liferay.portal.service.ServiceContext serviceContext)
383                    throws com.liferay.portal.kernel.exception.PortalException {
384                    return getService()
385                                       .updateLayoutSetPrototype(layoutSetPrototypeId, nameMap,
386                            descriptionMap, active, layoutsUpdateable, serviceContext);
387            }
388    
389            public static com.liferay.portal.model.LayoutSetPrototype updateLayoutSetPrototype(
390                    long layoutSetPrototypeId, java.lang.String settings)
391                    throws com.liferay.portal.kernel.exception.PortalException {
392                    return getService()
393                                       .updateLayoutSetPrototype(layoutSetPrototypeId, settings);
394            }
395    
396            public static LayoutSetPrototypeLocalService getService() {
397                    if (_service == null) {
398                            _service = (LayoutSetPrototypeLocalService)PortalBeanLocatorUtil.locate(LayoutSetPrototypeLocalService.class.getName());
399    
400                            ReferenceRegistry.registerReference(LayoutSetPrototypeLocalServiceUtil.class,
401                                    "_service");
402                    }
403    
404                    return _service;
405            }
406    
407            /**
408             * @deprecated As of 6.2.0
409             */
410            @Deprecated
411            public void setService(LayoutSetPrototypeLocalService service) {
412            }
413    
414            private static LayoutSetPrototypeLocalService _service;
415    }