001    /**
002     * Copyright (c) 2000-2010 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.softwarecatalog.service;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    
019    /**
020     * <p>
021     * This class provides static methods for the
022     * {@link SCProductVersionService} bean. The static methods of
023     * this class calls the same methods of the bean instance. It's convenient to be
024     * able to just write one line to call a method on a bean instead of writing a
025     * lookup call and a method call.
026     * </p>
027     *
028     * @author    Brian Wing Shun Chan
029     * @see       SCProductVersionService
030     * @generated
031     */
032    public class SCProductVersionServiceUtil {
033            public static com.liferay.portlet.softwarecatalog.model.SCProductVersion addProductVersion(
034                    long productEntryId, java.lang.String version,
035                    java.lang.String changeLog, java.lang.String downloadPageURL,
036                    java.lang.String directDownloadURL, boolean testDirectDownloadURL,
037                    boolean repoStoreArtifact, long[] frameworkVersionIds,
038                    com.liferay.portal.service.ServiceContext serviceContext)
039                    throws com.liferay.portal.kernel.exception.PortalException,
040                            com.liferay.portal.kernel.exception.SystemException {
041                    return getService()
042                                       .addProductVersion(productEntryId, version, changeLog,
043                            downloadPageURL, directDownloadURL, testDirectDownloadURL,
044                            repoStoreArtifact, frameworkVersionIds, serviceContext);
045            }
046    
047            public static void deleteProductVersion(long productVersionId)
048                    throws com.liferay.portal.kernel.exception.PortalException,
049                            com.liferay.portal.kernel.exception.SystemException {
050                    getService().deleteProductVersion(productVersionId);
051            }
052    
053            public static com.liferay.portlet.softwarecatalog.model.SCProductVersion getProductVersion(
054                    long productVersionId)
055                    throws com.liferay.portal.kernel.exception.PortalException,
056                            com.liferay.portal.kernel.exception.SystemException {
057                    return getService().getProductVersion(productVersionId);
058            }
059    
060            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductVersion> getProductVersions(
061                    long productEntryId, int start, int end)
062                    throws com.liferay.portal.kernel.exception.PortalException,
063                            com.liferay.portal.kernel.exception.SystemException {
064                    return getService().getProductVersions(productEntryId, start, end);
065            }
066    
067            public static int getProductVersionsCount(long productEntryId)
068                    throws com.liferay.portal.kernel.exception.PortalException,
069                            com.liferay.portal.kernel.exception.SystemException {
070                    return getService().getProductVersionsCount(productEntryId);
071            }
072    
073            public static com.liferay.portlet.softwarecatalog.model.SCProductVersion updateProductVersion(
074                    long productVersionId, java.lang.String version,
075                    java.lang.String changeLog, java.lang.String downloadPageURL,
076                    java.lang.String directDownloadURL, boolean testDirectDownloadURL,
077                    boolean repoStoreArtifact, long[] frameworkVersionIds)
078                    throws com.liferay.portal.kernel.exception.PortalException,
079                            com.liferay.portal.kernel.exception.SystemException {
080                    return getService()
081                                       .updateProductVersion(productVersionId, version, changeLog,
082                            downloadPageURL, directDownloadURL, testDirectDownloadURL,
083                            repoStoreArtifact, frameworkVersionIds);
084            }
085    
086            public static SCProductVersionService getService() {
087                    if (_service == null) {
088                            _service = (SCProductVersionService)PortalBeanLocatorUtil.locate(SCProductVersionService.class.getName());
089                    }
090    
091                    return _service;
092            }
093    
094            public void setService(SCProductVersionService service) {
095                    _service = service;
096            }
097    
098            private static SCProductVersionService _service;
099    }