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.portlet.mobiledevicerules.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 MDRRuleGroup. This utility wraps
024     * {@link com.liferay.portlet.mobiledevicerules.service.impl.MDRRuleGroupLocalServiceImpl} 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 Edward C. Han
031     * @see MDRRuleGroupLocalService
032     * @see com.liferay.portlet.mobiledevicerules.service.base.MDRRuleGroupLocalServiceBaseImpl
033     * @see com.liferay.portlet.mobiledevicerules.service.impl.MDRRuleGroupLocalServiceImpl
034     * @generated
035     */
036    @ProviderType
037    public class MDRRuleGroupLocalServiceUtil {
038            /*
039             * NOTE FOR DEVELOPERS:
040             *
041             * Never modify this class directly. Add custom service methods to {@link com.liferay.portlet.mobiledevicerules.service.impl.MDRRuleGroupLocalServiceImpl} and rerun ServiceBuilder to regenerate this class.
042             */
043    
044            /**
045            * Adds the m d r rule group to the database. Also notifies the appropriate model listeners.
046            *
047            * @param mdrRuleGroup the m d r rule group
048            * @return the m d r rule group that was added
049            */
050            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup addMDRRuleGroup(
051                    com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup mdrRuleGroup) {
052                    return getService().addMDRRuleGroup(mdrRuleGroup);
053            }
054    
055            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup addRuleGroup(
056                    long groupId,
057                    java.util.Map<java.util.Locale, java.lang.String> nameMap,
058                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
059                    com.liferay.portal.service.ServiceContext serviceContext)
060                    throws com.liferay.portal.kernel.exception.PortalException {
061                    return getService()
062                                       .addRuleGroup(groupId, nameMap, descriptionMap,
063                            serviceContext);
064            }
065    
066            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup copyRuleGroup(
067                    com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup ruleGroup,
068                    long groupId, com.liferay.portal.service.ServiceContext serviceContext)
069                    throws com.liferay.portal.kernel.exception.PortalException {
070                    return getService().copyRuleGroup(ruleGroup, groupId, serviceContext);
071            }
072    
073            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup copyRuleGroup(
074                    long ruleGroupId, long groupId,
075                    com.liferay.portal.service.ServiceContext serviceContext)
076                    throws com.liferay.portal.kernel.exception.PortalException {
077                    return getService().copyRuleGroup(ruleGroupId, groupId, serviceContext);
078            }
079    
080            /**
081            * Creates a new m d r rule group with the primary key. Does not add the m d r rule group to the database.
082            *
083            * @param ruleGroupId the primary key for the new m d r rule group
084            * @return the new m d r rule group
085            */
086            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup createMDRRuleGroup(
087                    long ruleGroupId) {
088                    return getService().createMDRRuleGroup(ruleGroupId);
089            }
090    
091            /**
092            * Deletes the m d r rule group from the database. Also notifies the appropriate model listeners.
093            *
094            * @param mdrRuleGroup the m d r rule group
095            * @return the m d r rule group that was removed
096            */
097            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup deleteMDRRuleGroup(
098                    com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup mdrRuleGroup) {
099                    return getService().deleteMDRRuleGroup(mdrRuleGroup);
100            }
101    
102            /**
103            * Deletes the m d r rule group with the primary key from the database. Also notifies the appropriate model listeners.
104            *
105            * @param ruleGroupId the primary key of the m d r rule group
106            * @return the m d r rule group that was removed
107            * @throws PortalException if a m d r rule group with the primary key could not be found
108            */
109            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup deleteMDRRuleGroup(
110                    long ruleGroupId)
111                    throws com.liferay.portal.kernel.exception.PortalException {
112                    return getService().deleteMDRRuleGroup(ruleGroupId);
113            }
114    
115            /**
116            * @throws PortalException
117            */
118            public static com.liferay.portal.model.PersistedModel deletePersistedModel(
119                    com.liferay.portal.model.PersistedModel persistedModel)
120                    throws com.liferay.portal.kernel.exception.PortalException {
121                    return getService().deletePersistedModel(persistedModel);
122            }
123    
124            public static void deleteRuleGroup(
125                    com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup ruleGroup) {
126                    getService().deleteRuleGroup(ruleGroup);
127            }
128    
129            public static void deleteRuleGroup(long ruleGroupId) {
130                    getService().deleteRuleGroup(ruleGroupId);
131            }
132    
133            public static void deleteRuleGroups(long groupId) {
134                    getService().deleteRuleGroups(groupId);
135            }
136    
137            public static com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery() {
138                    return getService().dynamicQuery();
139            }
140    
141            /**
142            * Performs a dynamic query on the database and returns the matching rows.
143            *
144            * @param dynamicQuery the dynamic query
145            * @return the matching rows
146            */
147            public static <T> java.util.List<T> dynamicQuery(
148                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) {
149                    return getService().dynamicQuery(dynamicQuery);
150            }
151    
152            /**
153            * Performs a dynamic query on the database and returns a range of the matching rows.
154            *
155            * <p>
156            * 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.portlet.mobiledevicerules.model.impl.MDRRuleGroupModelImpl}. 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.
157            * </p>
158            *
159            * @param dynamicQuery the dynamic query
160            * @param start the lower bound of the range of model instances
161            * @param end the upper bound of the range of model instances (not inclusive)
162            * @return the range of matching rows
163            */
164            public static <T> java.util.List<T> dynamicQuery(
165                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
166                    int end) {
167                    return getService().dynamicQuery(dynamicQuery, start, end);
168            }
169    
170            /**
171            * Performs a dynamic query on the database and returns an ordered range of the matching rows.
172            *
173            * <p>
174            * 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.portlet.mobiledevicerules.model.impl.MDRRuleGroupModelImpl}. 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.
175            * </p>
176            *
177            * @param dynamicQuery the dynamic query
178            * @param start the lower bound of the range of model instances
179            * @param end the upper bound of the range of model instances (not inclusive)
180            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
181            * @return the ordered range of matching rows
182            */
183            public static <T> java.util.List<T> dynamicQuery(
184                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
185                    int end,
186                    com.liferay.portal.kernel.util.OrderByComparator<T> orderByComparator) {
187                    return getService()
188                                       .dynamicQuery(dynamicQuery, start, end, orderByComparator);
189            }
190    
191            /**
192            * Returns the number of rows matching the dynamic query.
193            *
194            * @param dynamicQuery the dynamic query
195            * @return the number of rows matching the dynamic query
196            */
197            public static long dynamicQueryCount(
198                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) {
199                    return getService().dynamicQueryCount(dynamicQuery);
200            }
201    
202            /**
203            * Returns the number of rows matching the dynamic query.
204            *
205            * @param dynamicQuery the dynamic query
206            * @param projection the projection to apply to the query
207            * @return the number of rows matching the dynamic query
208            */
209            public static long dynamicQueryCount(
210                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery,
211                    com.liferay.portal.kernel.dao.orm.Projection projection) {
212                    return getService().dynamicQueryCount(dynamicQuery, projection);
213            }
214    
215            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup fetchMDRRuleGroup(
216                    long ruleGroupId) {
217                    return getService().fetchMDRRuleGroup(ruleGroupId);
218            }
219    
220            /**
221            * Returns the m d r rule group matching the UUID and group.
222            *
223            * @param uuid the m d r rule group's UUID
224            * @param groupId the primary key of the group
225            * @return the matching m d r rule group, or <code>null</code> if a matching m d r rule group could not be found
226            */
227            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup fetchMDRRuleGroupByUuidAndGroupId(
228                    java.lang.String uuid, long groupId) {
229                    return getService().fetchMDRRuleGroupByUuidAndGroupId(uuid, groupId);
230            }
231    
232            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup fetchRuleGroup(
233                    long ruleGroupId) {
234                    return getService().fetchRuleGroup(ruleGroupId);
235            }
236    
237            public static com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery getActionableDynamicQuery() {
238                    return getService().getActionableDynamicQuery();
239            }
240    
241            /**
242            * Returns the Spring bean ID for this bean.
243            *
244            * @return the Spring bean ID for this bean
245            */
246            public static java.lang.String getBeanIdentifier() {
247                    return getService().getBeanIdentifier();
248            }
249    
250            public static com.liferay.portal.kernel.dao.orm.ExportActionableDynamicQuery getExportActionableDynamicQuery(
251                    com.liferay.portlet.exportimport.lar.PortletDataContext portletDataContext) {
252                    return getService().getExportActionableDynamicQuery(portletDataContext);
253            }
254    
255            /**
256            * Returns the m d r rule group with the primary key.
257            *
258            * @param ruleGroupId the primary key of the m d r rule group
259            * @return the m d r rule group
260            * @throws PortalException if a m d r rule group with the primary key could not be found
261            */
262            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup getMDRRuleGroup(
263                    long ruleGroupId)
264                    throws com.liferay.portal.kernel.exception.PortalException {
265                    return getService().getMDRRuleGroup(ruleGroupId);
266            }
267    
268            /**
269            * Returns the m d r rule group matching the UUID and group.
270            *
271            * @param uuid the m d r rule group's UUID
272            * @param groupId the primary key of the group
273            * @return the matching m d r rule group
274            * @throws PortalException if a matching m d r rule group could not be found
275            */
276            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup getMDRRuleGroupByUuidAndGroupId(
277                    java.lang.String uuid, long groupId)
278                    throws com.liferay.portal.kernel.exception.PortalException {
279                    return getService().getMDRRuleGroupByUuidAndGroupId(uuid, groupId);
280            }
281    
282            /**
283            * Returns a range of all the m d r rule groups.
284            *
285            * <p>
286            * 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.portlet.mobiledevicerules.model.impl.MDRRuleGroupModelImpl}. 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.
287            * </p>
288            *
289            * @param start the lower bound of the range of m d r rule groups
290            * @param end the upper bound of the range of m d r rule groups (not inclusive)
291            * @return the range of m d r rule groups
292            */
293            public static java.util.List<com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup> getMDRRuleGroups(
294                    int start, int end) {
295                    return getService().getMDRRuleGroups(start, end);
296            }
297    
298            /**
299            * Returns all the m d r rule groups matching the UUID and company.
300            *
301            * @param uuid the UUID of the m d r rule groups
302            * @param companyId the primary key of the company
303            * @return the matching m d r rule groups, or an empty list if no matches were found
304            */
305            public static java.util.List<com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup> getMDRRuleGroupsByUuidAndCompanyId(
306                    java.lang.String uuid, long companyId) {
307                    return getService().getMDRRuleGroupsByUuidAndCompanyId(uuid, companyId);
308            }
309    
310            /**
311            * Returns a range of m d r rule groups matching the UUID and company.
312            *
313            * @param uuid the UUID of the m d r rule groups
314            * @param companyId the primary key of the company
315            * @param start the lower bound of the range of m d r rule groups
316            * @param end the upper bound of the range of m d r rule groups (not inclusive)
317            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
318            * @return the range of matching m d r rule groups, or an empty list if no matches were found
319            */
320            public static java.util.List<com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup> getMDRRuleGroupsByUuidAndCompanyId(
321                    java.lang.String uuid, long companyId, int start, int end,
322                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup> orderByComparator) {
323                    return getService()
324                                       .getMDRRuleGroupsByUuidAndCompanyId(uuid, companyId, start,
325                            end, orderByComparator);
326            }
327    
328            /**
329            * Returns the number of m d r rule groups.
330            *
331            * @return the number of m d r rule groups
332            */
333            public static int getMDRRuleGroupsCount() {
334                    return getService().getMDRRuleGroupsCount();
335            }
336    
337            public static com.liferay.portal.model.PersistedModel getPersistedModel(
338                    java.io.Serializable primaryKeyObj)
339                    throws com.liferay.portal.kernel.exception.PortalException {
340                    return getService().getPersistedModel(primaryKeyObj);
341            }
342    
343            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup getRuleGroup(
344                    long ruleGroupId)
345                    throws com.liferay.portal.kernel.exception.PortalException {
346                    return getService().getRuleGroup(ruleGroupId);
347            }
348    
349            public static java.util.List<com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup> getRuleGroups(
350                    long groupId) {
351                    return getService().getRuleGroups(groupId);
352            }
353    
354            public static java.util.List<com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup> getRuleGroups(
355                    long groupId, int start, int end) {
356                    return getService().getRuleGroups(groupId, start, end);
357            }
358    
359            public static java.util.List<com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup> getRuleGroups(
360                    long[] groupIds, int start, int end) {
361                    return getService().getRuleGroups(groupIds, start, end);
362            }
363    
364            public static int getRuleGroupsCount(long groupId) {
365                    return getService().getRuleGroupsCount(groupId);
366            }
367    
368            public static int getRuleGroupsCount(long[] groupIds) {
369                    return getService().getRuleGroupsCount(groupIds);
370            }
371    
372            /**
373            * @deprecated As of 6.2.0, replaced by {@link #search(long, String,
374            LinkedHashMap, boolean, int, int)}
375            */
376            @Deprecated
377            public static java.util.List<com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup> search(
378                    long groupId, java.lang.String name, boolean andOperator, int start,
379                    int end) {
380                    return getService().search(groupId, name, andOperator, start, end);
381            }
382    
383            public static java.util.List<com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup> search(
384                    long groupId, java.lang.String name,
385                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params,
386                    boolean andOperator, int start, int end) {
387                    return getService()
388                                       .search(groupId, name, params, andOperator, start, end);
389            }
390    
391            /**
392            * @deprecated As of 6.2.0, replaced by {@link #searchByKeywords(long,
393            String, LinkedHashMap, boolean, int, int)}
394            */
395            @Deprecated
396            public static java.util.List<com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup> searchByKeywords(
397                    long groupId, java.lang.String keywords, boolean andOperator,
398                    int start, int end) {
399                    return getService()
400                                       .searchByKeywords(groupId, keywords, andOperator, start, end);
401            }
402    
403            public static java.util.List<com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup> searchByKeywords(
404                    long groupId, java.lang.String keywords,
405                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params,
406                    boolean andOperator, int start, int end) {
407                    return getService()
408                                       .searchByKeywords(groupId, keywords, params, andOperator,
409                            start, end);
410            }
411    
412            /**
413            * @deprecated As of 6.2.0, replaced by {@link #searchByKeywordsCount(long,
414            String, LinkedHashMap, boolean)}
415            */
416            @Deprecated
417            public static int searchByKeywordsCount(long groupId,
418                    java.lang.String keywords, boolean andOperator) {
419                    return getService().searchByKeywordsCount(groupId, keywords, andOperator);
420            }
421    
422            public static int searchByKeywordsCount(long groupId,
423                    java.lang.String keywords,
424                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params,
425                    boolean andOperator) {
426                    return getService()
427                                       .searchByKeywordsCount(groupId, keywords, params, andOperator);
428            }
429    
430            /**
431            * @deprecated As of 6.2.0, replaced by {@link #searchCount(long, String,
432            LinkedHashMap, boolean)}
433            */
434            @Deprecated
435            public static int searchCount(long groupId, java.lang.String name,
436                    boolean andOperator) {
437                    return getService().searchCount(groupId, name, andOperator);
438            }
439    
440            public static int searchCount(long groupId, java.lang.String name,
441                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params,
442                    boolean andOperator) {
443                    return getService().searchCount(groupId, name, params, andOperator);
444            }
445    
446            /**
447            * Sets the Spring bean ID for this bean.
448            *
449            * @param beanIdentifier the Spring bean ID for this bean
450            */
451            public static void setBeanIdentifier(java.lang.String beanIdentifier) {
452                    getService().setBeanIdentifier(beanIdentifier);
453            }
454    
455            /**
456            * Updates the m d r rule group in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
457            *
458            * @param mdrRuleGroup the m d r rule group
459            * @return the m d r rule group that was updated
460            */
461            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup updateMDRRuleGroup(
462                    com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup mdrRuleGroup) {
463                    return getService().updateMDRRuleGroup(mdrRuleGroup);
464            }
465    
466            public static com.liferay.portlet.mobiledevicerules.model.MDRRuleGroup updateRuleGroup(
467                    long ruleGroupId,
468                    java.util.Map<java.util.Locale, java.lang.String> nameMap,
469                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
470                    com.liferay.portal.service.ServiceContext serviceContext)
471                    throws com.liferay.portal.kernel.exception.PortalException {
472                    return getService()
473                                       .updateRuleGroup(ruleGroupId, nameMap, descriptionMap,
474                            serviceContext);
475            }
476    
477            public static MDRRuleGroupLocalService getService() {
478                    if (_service == null) {
479                            _service = (MDRRuleGroupLocalService)PortalBeanLocatorUtil.locate(MDRRuleGroupLocalService.class.getName());
480    
481                            ReferenceRegistry.registerReference(MDRRuleGroupLocalServiceUtil.class,
482                                    "_service");
483                    }
484    
485                    return _service;
486            }
487    
488            /**
489             * @deprecated As of 6.2.0
490             */
491            @Deprecated
492            public void setService(MDRRuleGroupLocalService service) {
493            }
494    
495            private static MDRRuleGroupLocalService _service;
496    }