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;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    import com.liferay.portal.kernel.util.MethodCache;
019    import com.liferay.portal.kernel.util.ReferenceRegistry;
020    
021    /**
022     * The utility for the org labor remote service. This utility wraps {@link com.liferay.portal.service.impl.OrgLaborServiceImpl} and is the primary access point for service operations in application layer code running on a remote server.
023     *
024     * <p>
025     * This is a remote service. Methods of this service are expected to have security checks based on the propagated JAAS credentials because this service can be accessed remotely.
026     * </p>
027     *
028     * @author Brian Wing Shun Chan
029     * @see OrgLaborService
030     * @see com.liferay.portal.service.base.OrgLaborServiceBaseImpl
031     * @see com.liferay.portal.service.impl.OrgLaborServiceImpl
032     * @generated
033     */
034    public class OrgLaborServiceUtil {
035            /*
036             * NOTE FOR DEVELOPERS:
037             *
038             * Never modify this class directly. Add custom service methods to {@link com.liferay.portal.service.impl.OrgLaborServiceImpl} and rerun ServiceBuilder to regenerate this class.
039             */
040            public static com.liferay.portal.model.OrgLabor addOrgLabor(
041                    long organizationId, int typeId, int sunOpen, int sunClose,
042                    int monOpen, int monClose, int tueOpen, int tueClose, int wedOpen,
043                    int wedClose, int thuOpen, int thuClose, int friOpen, int friClose,
044                    int satOpen, int satClose)
045                    throws com.liferay.portal.kernel.exception.PortalException,
046                            com.liferay.portal.kernel.exception.SystemException {
047                    return getService()
048                                       .addOrgLabor(organizationId, typeId, sunOpen, sunClose,
049                            monOpen, monClose, tueOpen, tueClose, wedOpen, wedClose, thuOpen,
050                            thuClose, friOpen, friClose, satOpen, satClose);
051            }
052    
053            public static void deleteOrgLabor(long orgLaborId)
054                    throws com.liferay.portal.kernel.exception.PortalException,
055                            com.liferay.portal.kernel.exception.SystemException {
056                    getService().deleteOrgLabor(orgLaborId);
057            }
058    
059            public static com.liferay.portal.model.OrgLabor getOrgLabor(long orgLaborId)
060                    throws com.liferay.portal.kernel.exception.PortalException,
061                            com.liferay.portal.kernel.exception.SystemException {
062                    return getService().getOrgLabor(orgLaborId);
063            }
064    
065            public static java.util.List<com.liferay.portal.model.OrgLabor> getOrgLabors(
066                    long organizationId)
067                    throws com.liferay.portal.kernel.exception.PortalException,
068                            com.liferay.portal.kernel.exception.SystemException {
069                    return getService().getOrgLabors(organizationId);
070            }
071    
072            public static com.liferay.portal.model.OrgLabor updateOrgLabor(
073                    long orgLaborId, int typeId, int sunOpen, int sunClose, int monOpen,
074                    int monClose, int tueOpen, int tueClose, int wedOpen, int wedClose,
075                    int thuOpen, int thuClose, int friOpen, int friClose, int satOpen,
076                    int satClose)
077                    throws com.liferay.portal.kernel.exception.PortalException,
078                            com.liferay.portal.kernel.exception.SystemException {
079                    return getService()
080                                       .updateOrgLabor(orgLaborId, typeId, sunOpen, sunClose,
081                            monOpen, monClose, tueOpen, tueClose, wedOpen, wedClose, thuOpen,
082                            thuClose, friOpen, friClose, satOpen, satClose);
083            }
084    
085            public static OrgLaborService getService() {
086                    if (_service == null) {
087                            _service = (OrgLaborService)PortalBeanLocatorUtil.locate(OrgLaborService.class.getName());
088    
089                            ReferenceRegistry.registerReference(OrgLaborServiceUtil.class,
090                                    "_service");
091                            MethodCache.remove(OrgLaborService.class);
092                    }
093    
094                    return _service;
095            }
096    
097            public void setService(OrgLaborService service) {
098                    MethodCache.remove(OrgLaborService.class);
099    
100                    _service = service;
101    
102                    ReferenceRegistry.registerReference(OrgLaborServiceUtil.class,
103                            "_service");
104                    MethodCache.remove(OrgLaborService.class);
105            }
106    
107            private static OrgLaborService _service;
108    }