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 remote service utility for Website. This utility wraps
024     * {@link com.liferay.portal.service.impl.WebsiteServiceImpl} and is the
025     * primary access point for service operations in application layer code running
026     * on a remote server. Methods of this service are expected to have security
027     * checks based on the propagated JAAS credentials because this service can be
028     * accessed remotely.
029     *
030     * @author Brian Wing Shun Chan
031     * @see WebsiteService
032     * @see com.liferay.portal.service.base.WebsiteServiceBaseImpl
033     * @see com.liferay.portal.service.impl.WebsiteServiceImpl
034     * @generated
035     */
036    @ProviderType
037    public class WebsiteServiceUtil {
038            /*
039             * NOTE FOR DEVELOPERS:
040             *
041             * Never modify this class directly. Add custom service methods to {@link com.liferay.portal.service.impl.WebsiteServiceImpl} and rerun ServiceBuilder to regenerate this class.
042             */
043    
044            /**
045            * @deprecated As of 6.2.0, replaced by {@link #addWebsite(String, long,
046            String, int, boolean, ServiceContext)}
047            */
048            @Deprecated
049            public static com.liferay.portal.model.Website addWebsite(
050                    java.lang.String className, long classPK, java.lang.String url,
051                    long typeId, boolean primary)
052                    throws com.liferay.portal.kernel.exception.PortalException {
053                    return getService().addWebsite(className, classPK, url, typeId, primary);
054            }
055    
056            public static com.liferay.portal.model.Website addWebsite(
057                    java.lang.String className, long classPK, java.lang.String url,
058                    long typeId, boolean primary,
059                    com.liferay.portal.service.ServiceContext serviceContext)
060                    throws com.liferay.portal.kernel.exception.PortalException {
061                    return getService()
062                                       .addWebsite(className, classPK, url, typeId, primary,
063                            serviceContext);
064            }
065    
066            public static void deleteWebsite(long websiteId)
067                    throws com.liferay.portal.kernel.exception.PortalException {
068                    getService().deleteWebsite(websiteId);
069            }
070    
071            /**
072            * Returns the Spring bean ID for this bean.
073            *
074            * @return the Spring bean ID for this bean
075            */
076            public static java.lang.String getBeanIdentifier() {
077                    return getService().getBeanIdentifier();
078            }
079    
080            public static com.liferay.portal.model.Website getWebsite(long websiteId)
081                    throws com.liferay.portal.kernel.exception.PortalException {
082                    return getService().getWebsite(websiteId);
083            }
084    
085            public static java.util.List<com.liferay.portal.model.Website> getWebsites(
086                    java.lang.String className, long classPK)
087                    throws com.liferay.portal.kernel.exception.PortalException {
088                    return getService().getWebsites(className, classPK);
089            }
090    
091            /**
092            * Sets the Spring bean ID for this bean.
093            *
094            * @param beanIdentifier the Spring bean ID for this bean
095            */
096            public static void setBeanIdentifier(java.lang.String beanIdentifier) {
097                    getService().setBeanIdentifier(beanIdentifier);
098            }
099    
100            public static com.liferay.portal.model.Website updateWebsite(
101                    long websiteId, java.lang.String url, long typeId, boolean primary)
102                    throws com.liferay.portal.kernel.exception.PortalException {
103                    return getService().updateWebsite(websiteId, url, typeId, primary);
104            }
105    
106            public static WebsiteService getService() {
107                    if (_service == null) {
108                            _service = (WebsiteService)PortalBeanLocatorUtil.locate(WebsiteService.class.getName());
109    
110                            ReferenceRegistry.registerReference(WebsiteServiceUtil.class,
111                                    "_service");
112                    }
113    
114                    return _service;
115            }
116    
117            /**
118             * @deprecated As of 6.2.0
119             */
120            @Deprecated
121            public void setService(WebsiteService service) {
122            }
123    
124            private static WebsiteService _service;
125    }