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.softwarecatalog.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 SCProductScreenshot. This utility wraps 024 * {@link com.liferay.portlet.softwarecatalog.service.impl.SCProductScreenshotLocalServiceImpl} 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 SCProductScreenshotLocalService 032 * @see com.liferay.portlet.softwarecatalog.service.base.SCProductScreenshotLocalServiceBaseImpl 033 * @see com.liferay.portlet.softwarecatalog.service.impl.SCProductScreenshotLocalServiceImpl 034 * @generated 035 */ 036 @ProviderType 037 public class SCProductScreenshotLocalServiceUtil { 038 /* 039 * NOTE FOR DEVELOPERS: 040 * 041 * Never modify this class directly. Add custom service methods to {@link com.liferay.portlet.softwarecatalog.service.impl.SCProductScreenshotLocalServiceImpl} and rerun ServiceBuilder to regenerate this class. 042 */ 043 044 /** 045 * Adds the s c product screenshot to the database. Also notifies the appropriate model listeners. 046 * 047 * @param scProductScreenshot the s c product screenshot 048 * @return the s c product screenshot that was added 049 */ 050 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot addSCProductScreenshot( 051 com.liferay.portlet.softwarecatalog.model.SCProductScreenshot scProductScreenshot) { 052 return getService().addSCProductScreenshot(scProductScreenshot); 053 } 054 055 /** 056 * Creates a new s c product screenshot with the primary key. Does not add the s c product screenshot to the database. 057 * 058 * @param productScreenshotId the primary key for the new s c product screenshot 059 * @return the new s c product screenshot 060 */ 061 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot createSCProductScreenshot( 062 long productScreenshotId) { 063 return getService().createSCProductScreenshot(productScreenshotId); 064 } 065 066 /** 067 * @throws PortalException 068 */ 069 public static com.liferay.portal.model.PersistedModel deletePersistedModel( 070 com.liferay.portal.model.PersistedModel persistedModel) 071 throws com.liferay.portal.kernel.exception.PortalException { 072 return getService().deletePersistedModel(persistedModel); 073 } 074 075 public static void deleteProductScreenshot( 076 com.liferay.portlet.softwarecatalog.model.SCProductScreenshot productScreenshot) 077 throws com.liferay.portal.kernel.exception.PortalException { 078 getService().deleteProductScreenshot(productScreenshot); 079 } 080 081 public static void deleteProductScreenshots(long productEntryId) 082 throws com.liferay.portal.kernel.exception.PortalException { 083 getService().deleteProductScreenshots(productEntryId); 084 } 085 086 /** 087 * Deletes the s c product screenshot with the primary key from the database. Also notifies the appropriate model listeners. 088 * 089 * @param productScreenshotId the primary key of the s c product screenshot 090 * @return the s c product screenshot that was removed 091 * @throws PortalException if a s c product screenshot with the primary key could not be found 092 */ 093 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot deleteSCProductScreenshot( 094 long productScreenshotId) 095 throws com.liferay.portal.kernel.exception.PortalException { 096 return getService().deleteSCProductScreenshot(productScreenshotId); 097 } 098 099 /** 100 * Deletes the s c product screenshot from the database. Also notifies the appropriate model listeners. 101 * 102 * @param scProductScreenshot the s c product screenshot 103 * @return the s c product screenshot that was removed 104 */ 105 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot deleteSCProductScreenshot( 106 com.liferay.portlet.softwarecatalog.model.SCProductScreenshot scProductScreenshot) { 107 return getService().deleteSCProductScreenshot(scProductScreenshot); 108 } 109 110 public static com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery() { 111 return getService().dynamicQuery(); 112 } 113 114 /** 115 * Performs a dynamic query on the database and returns the matching rows. 116 * 117 * @param dynamicQuery the dynamic query 118 * @return the matching rows 119 */ 120 public static <T> java.util.List<T> dynamicQuery( 121 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) { 122 return getService().dynamicQuery(dynamicQuery); 123 } 124 125 /** 126 * Performs a dynamic query on the database and returns a range of the matching rows. 127 * 128 * <p> 129 * 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.softwarecatalog.model.impl.SCProductScreenshotModelImpl}. 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. 130 * </p> 131 * 132 * @param dynamicQuery the dynamic query 133 * @param start the lower bound of the range of model instances 134 * @param end the upper bound of the range of model instances (not inclusive) 135 * @return the range of matching rows 136 */ 137 public static <T> java.util.List<T> dynamicQuery( 138 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 139 int end) { 140 return getService().dynamicQuery(dynamicQuery, start, end); 141 } 142 143 /** 144 * Performs a dynamic query on the database and returns an ordered range of the matching rows. 145 * 146 * <p> 147 * 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.softwarecatalog.model.impl.SCProductScreenshotModelImpl}. 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. 148 * </p> 149 * 150 * @param dynamicQuery the dynamic query 151 * @param start the lower bound of the range of model instances 152 * @param end the upper bound of the range of model instances (not inclusive) 153 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 154 * @return the ordered range of matching rows 155 */ 156 public static <T> java.util.List<T> dynamicQuery( 157 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 158 int end, 159 com.liferay.portal.kernel.util.OrderByComparator<T> orderByComparator) { 160 return getService() 161 .dynamicQuery(dynamicQuery, start, end, orderByComparator); 162 } 163 164 /** 165 * Returns the number of rows matching the dynamic query. 166 * 167 * @param dynamicQuery the dynamic query 168 * @return the number of rows matching the dynamic query 169 */ 170 public static long dynamicQueryCount( 171 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) { 172 return getService().dynamicQueryCount(dynamicQuery); 173 } 174 175 /** 176 * Returns the number of rows matching the dynamic query. 177 * 178 * @param dynamicQuery the dynamic query 179 * @param projection the projection to apply to the query 180 * @return the number of rows matching the dynamic query 181 */ 182 public static long dynamicQueryCount( 183 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, 184 com.liferay.portal.kernel.dao.orm.Projection projection) { 185 return getService().dynamicQueryCount(dynamicQuery, projection); 186 } 187 188 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot fetchSCProductScreenshot( 189 long productScreenshotId) { 190 return getService().fetchSCProductScreenshot(productScreenshotId); 191 } 192 193 public static com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery getActionableDynamicQuery() { 194 return getService().getActionableDynamicQuery(); 195 } 196 197 /** 198 * Returns the Spring bean ID for this bean. 199 * 200 * @return the Spring bean ID for this bean 201 */ 202 public static java.lang.String getBeanIdentifier() { 203 return getService().getBeanIdentifier(); 204 } 205 206 public static com.liferay.portal.model.PersistedModel getPersistedModel( 207 java.io.Serializable primaryKeyObj) 208 throws com.liferay.portal.kernel.exception.PortalException { 209 return getService().getPersistedModel(primaryKeyObj); 210 } 211 212 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot getProductScreenshot( 213 long productEntryId, int priority) 214 throws com.liferay.portal.kernel.exception.PortalException { 215 return getService().getProductScreenshot(productEntryId, priority); 216 } 217 218 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot getProductScreenshotByFullImageId( 219 long fullImageId) 220 throws com.liferay.portal.kernel.exception.PortalException { 221 return getService().getProductScreenshotByFullImageId(fullImageId); 222 } 223 224 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot getProductScreenshotByThumbnailId( 225 long thumbnailId) 226 throws com.liferay.portal.kernel.exception.PortalException { 227 return getService().getProductScreenshotByThumbnailId(thumbnailId); 228 } 229 230 public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductScreenshot> getProductScreenshots( 231 long productEntryId) { 232 return getService().getProductScreenshots(productEntryId); 233 } 234 235 /** 236 * Returns the s c product screenshot with the primary key. 237 * 238 * @param productScreenshotId the primary key of the s c product screenshot 239 * @return the s c product screenshot 240 * @throws PortalException if a s c product screenshot with the primary key could not be found 241 */ 242 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot getSCProductScreenshot( 243 long productScreenshotId) 244 throws com.liferay.portal.kernel.exception.PortalException { 245 return getService().getSCProductScreenshot(productScreenshotId); 246 } 247 248 /** 249 * Returns a range of all the s c product screenshots. 250 * 251 * <p> 252 * 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.softwarecatalog.model.impl.SCProductScreenshotModelImpl}. 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. 253 * </p> 254 * 255 * @param start the lower bound of the range of s c product screenshots 256 * @param end the upper bound of the range of s c product screenshots (not inclusive) 257 * @return the range of s c product screenshots 258 */ 259 public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductScreenshot> getSCProductScreenshots( 260 int start, int end) { 261 return getService().getSCProductScreenshots(start, end); 262 } 263 264 /** 265 * Returns the number of s c product screenshots. 266 * 267 * @return the number of s c product screenshots 268 */ 269 public static int getSCProductScreenshotsCount() { 270 return getService().getSCProductScreenshotsCount(); 271 } 272 273 /** 274 * Sets the Spring bean ID for this bean. 275 * 276 * @param beanIdentifier the Spring bean ID for this bean 277 */ 278 public static void setBeanIdentifier(java.lang.String beanIdentifier) { 279 getService().setBeanIdentifier(beanIdentifier); 280 } 281 282 /** 283 * Updates the s c product screenshot in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners. 284 * 285 * @param scProductScreenshot the s c product screenshot 286 * @return the s c product screenshot that was updated 287 */ 288 public static com.liferay.portlet.softwarecatalog.model.SCProductScreenshot updateSCProductScreenshot( 289 com.liferay.portlet.softwarecatalog.model.SCProductScreenshot scProductScreenshot) { 290 return getService().updateSCProductScreenshot(scProductScreenshot); 291 } 292 293 public static SCProductScreenshotLocalService getService() { 294 if (_service == null) { 295 _service = (SCProductScreenshotLocalService)PortalBeanLocatorUtil.locate(SCProductScreenshotLocalService.class.getName()); 296 297 ReferenceRegistry.registerReference(SCProductScreenshotLocalServiceUtil.class, 298 "_service"); 299 } 300 301 return _service; 302 } 303 304 /** 305 * @deprecated As of 6.2.0 306 */ 307 @Deprecated 308 public void setService(SCProductScreenshotLocalService service) { 309 } 310 311 private static SCProductScreenshotLocalService _service; 312 }