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.persistence; 016 017 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil; 018 import com.liferay.portal.kernel.dao.orm.DynamicQuery; 019 import com.liferay.portal.kernel.exception.SystemException; 020 import com.liferay.portal.kernel.util.OrderByComparator; 021 import com.liferay.portal.kernel.util.ReferenceRegistry; 022 import com.liferay.portal.model.WebDAVProps; 023 import com.liferay.portal.service.ServiceContext; 024 025 import java.util.List; 026 027 /** 028 * The persistence utility for the web d a v props service. This utility wraps {@link WebDAVPropsPersistenceImpl} and provides direct access to the database for CRUD operations. This utility should only be used by the service layer, as it must operate within a transaction. Never access this utility in a JSP, controller, model, or other front-end class. 029 * 030 * <p> 031 * Caching information and settings can be found in <code>portal.properties</code> 032 * </p> 033 * 034 * @author Brian Wing Shun Chan 035 * @see WebDAVPropsPersistence 036 * @see WebDAVPropsPersistenceImpl 037 * @generated 038 */ 039 public class WebDAVPropsUtil { 040 /* 041 * NOTE FOR DEVELOPERS: 042 * 043 * Never modify this class directly. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this class. 044 */ 045 046 /** 047 * @see com.liferay.portal.service.persistence.BasePersistence#clearCache() 048 */ 049 public static void clearCache() { 050 getPersistence().clearCache(); 051 } 052 053 /** 054 * @see com.liferay.portal.service.persistence.BasePersistence#clearCache(com.liferay.portal.model.BaseModel) 055 */ 056 public static void clearCache(WebDAVProps webDAVProps) { 057 getPersistence().clearCache(webDAVProps); 058 } 059 060 /** 061 * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery) 062 */ 063 public long countWithDynamicQuery(DynamicQuery dynamicQuery) 064 throws SystemException { 065 return getPersistence().countWithDynamicQuery(dynamicQuery); 066 } 067 068 /** 069 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery) 070 */ 071 public static List<WebDAVProps> findWithDynamicQuery( 072 DynamicQuery dynamicQuery) throws SystemException { 073 return getPersistence().findWithDynamicQuery(dynamicQuery); 074 } 075 076 /** 077 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int) 078 */ 079 public static List<WebDAVProps> findWithDynamicQuery( 080 DynamicQuery dynamicQuery, int start, int end) 081 throws SystemException { 082 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end); 083 } 084 085 /** 086 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator) 087 */ 088 public static List<WebDAVProps> findWithDynamicQuery( 089 DynamicQuery dynamicQuery, int start, int end, 090 OrderByComparator orderByComparator) throws SystemException { 091 return getPersistence() 092 .findWithDynamicQuery(dynamicQuery, start, end, 093 orderByComparator); 094 } 095 096 /** 097 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel) 098 */ 099 public static WebDAVProps update(WebDAVProps webDAVProps) 100 throws SystemException { 101 return getPersistence().update(webDAVProps); 102 } 103 104 /** 105 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, ServiceContext) 106 */ 107 public static WebDAVProps update(WebDAVProps webDAVProps, 108 ServiceContext serviceContext) throws SystemException { 109 return getPersistence().update(webDAVProps, serviceContext); 110 } 111 112 /** 113 * Returns the web d a v props where classNameId = ? and classPK = ? or throws a {@link com.liferay.portal.NoSuchWebDAVPropsException} if it could not be found. 114 * 115 * @param classNameId the class name ID 116 * @param classPK the class p k 117 * @return the matching web d a v props 118 * @throws com.liferay.portal.NoSuchWebDAVPropsException if a matching web d a v props could not be found 119 * @throws SystemException if a system exception occurred 120 */ 121 public static com.liferay.portal.model.WebDAVProps findByC_C( 122 long classNameId, long classPK) 123 throws com.liferay.portal.NoSuchWebDAVPropsException, 124 com.liferay.portal.kernel.exception.SystemException { 125 return getPersistence().findByC_C(classNameId, classPK); 126 } 127 128 /** 129 * Returns the web d a v props where classNameId = ? and classPK = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 130 * 131 * @param classNameId the class name ID 132 * @param classPK the class p k 133 * @return the matching web d a v props, or <code>null</code> if a matching web d a v props could not be found 134 * @throws SystemException if a system exception occurred 135 */ 136 public static com.liferay.portal.model.WebDAVProps fetchByC_C( 137 long classNameId, long classPK) 138 throws com.liferay.portal.kernel.exception.SystemException { 139 return getPersistence().fetchByC_C(classNameId, classPK); 140 } 141 142 /** 143 * Returns the web d a v props where classNameId = ? and classPK = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 144 * 145 * @param classNameId the class name ID 146 * @param classPK the class p k 147 * @param retrieveFromCache whether to use the finder cache 148 * @return the matching web d a v props, or <code>null</code> if a matching web d a v props could not be found 149 * @throws SystemException if a system exception occurred 150 */ 151 public static com.liferay.portal.model.WebDAVProps fetchByC_C( 152 long classNameId, long classPK, boolean retrieveFromCache) 153 throws com.liferay.portal.kernel.exception.SystemException { 154 return getPersistence() 155 .fetchByC_C(classNameId, classPK, retrieveFromCache); 156 } 157 158 /** 159 * Removes the web d a v props where classNameId = ? and classPK = ? from the database. 160 * 161 * @param classNameId the class name ID 162 * @param classPK the class p k 163 * @return the web d a v props that was removed 164 * @throws SystemException if a system exception occurred 165 */ 166 public static com.liferay.portal.model.WebDAVProps removeByC_C( 167 long classNameId, long classPK) 168 throws com.liferay.portal.NoSuchWebDAVPropsException, 169 com.liferay.portal.kernel.exception.SystemException { 170 return getPersistence().removeByC_C(classNameId, classPK); 171 } 172 173 /** 174 * Returns the number of web d a v propses where classNameId = ? and classPK = ?. 175 * 176 * @param classNameId the class name ID 177 * @param classPK the class p k 178 * @return the number of matching web d a v propses 179 * @throws SystemException if a system exception occurred 180 */ 181 public static int countByC_C(long classNameId, long classPK) 182 throws com.liferay.portal.kernel.exception.SystemException { 183 return getPersistence().countByC_C(classNameId, classPK); 184 } 185 186 /** 187 * Caches the web d a v props in the entity cache if it is enabled. 188 * 189 * @param webDAVProps the web d a v props 190 */ 191 public static void cacheResult( 192 com.liferay.portal.model.WebDAVProps webDAVProps) { 193 getPersistence().cacheResult(webDAVProps); 194 } 195 196 /** 197 * Caches the web d a v propses in the entity cache if it is enabled. 198 * 199 * @param webDAVPropses the web d a v propses 200 */ 201 public static void cacheResult( 202 java.util.List<com.liferay.portal.model.WebDAVProps> webDAVPropses) { 203 getPersistence().cacheResult(webDAVPropses); 204 } 205 206 /** 207 * Creates a new web d a v props with the primary key. Does not add the web d a v props to the database. 208 * 209 * @param webDavPropsId the primary key for the new web d a v props 210 * @return the new web d a v props 211 */ 212 public static com.liferay.portal.model.WebDAVProps create( 213 long webDavPropsId) { 214 return getPersistence().create(webDavPropsId); 215 } 216 217 /** 218 * Removes the web d a v props with the primary key from the database. Also notifies the appropriate model listeners. 219 * 220 * @param webDavPropsId the primary key of the web d a v props 221 * @return the web d a v props that was removed 222 * @throws com.liferay.portal.NoSuchWebDAVPropsException if a web d a v props with the primary key could not be found 223 * @throws SystemException if a system exception occurred 224 */ 225 public static com.liferay.portal.model.WebDAVProps remove( 226 long webDavPropsId) 227 throws com.liferay.portal.NoSuchWebDAVPropsException, 228 com.liferay.portal.kernel.exception.SystemException { 229 return getPersistence().remove(webDavPropsId); 230 } 231 232 public static com.liferay.portal.model.WebDAVProps updateImpl( 233 com.liferay.portal.model.WebDAVProps webDAVProps) 234 throws com.liferay.portal.kernel.exception.SystemException { 235 return getPersistence().updateImpl(webDAVProps); 236 } 237 238 /** 239 * Returns the web d a v props with the primary key or throws a {@link com.liferay.portal.NoSuchWebDAVPropsException} if it could not be found. 240 * 241 * @param webDavPropsId the primary key of the web d a v props 242 * @return the web d a v props 243 * @throws com.liferay.portal.NoSuchWebDAVPropsException if a web d a v props with the primary key could not be found 244 * @throws SystemException if a system exception occurred 245 */ 246 public static com.liferay.portal.model.WebDAVProps findByPrimaryKey( 247 long webDavPropsId) 248 throws com.liferay.portal.NoSuchWebDAVPropsException, 249 com.liferay.portal.kernel.exception.SystemException { 250 return getPersistence().findByPrimaryKey(webDavPropsId); 251 } 252 253 /** 254 * Returns the web d a v props with the primary key or returns <code>null</code> if it could not be found. 255 * 256 * @param webDavPropsId the primary key of the web d a v props 257 * @return the web d a v props, or <code>null</code> if a web d a v props with the primary key could not be found 258 * @throws SystemException if a system exception occurred 259 */ 260 public static com.liferay.portal.model.WebDAVProps fetchByPrimaryKey( 261 long webDavPropsId) 262 throws com.liferay.portal.kernel.exception.SystemException { 263 return getPersistence().fetchByPrimaryKey(webDavPropsId); 264 } 265 266 /** 267 * Returns all the web d a v propses. 268 * 269 * @return the web d a v propses 270 * @throws SystemException if a system exception occurred 271 */ 272 public static java.util.List<com.liferay.portal.model.WebDAVProps> findAll() 273 throws com.liferay.portal.kernel.exception.SystemException { 274 return getPersistence().findAll(); 275 } 276 277 /** 278 * Returns a range of all the web d a v propses. 279 * 280 * <p> 281 * 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.portal.model.impl.WebDAVPropsModelImpl}. 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. 282 * </p> 283 * 284 * @param start the lower bound of the range of web d a v propses 285 * @param end the upper bound of the range of web d a v propses (not inclusive) 286 * @return the range of web d a v propses 287 * @throws SystemException if a system exception occurred 288 */ 289 public static java.util.List<com.liferay.portal.model.WebDAVProps> findAll( 290 int start, int end) 291 throws com.liferay.portal.kernel.exception.SystemException { 292 return getPersistence().findAll(start, end); 293 } 294 295 /** 296 * Returns an ordered range of all the web d a v propses. 297 * 298 * <p> 299 * 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.portal.model.impl.WebDAVPropsModelImpl}. 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. 300 * </p> 301 * 302 * @param start the lower bound of the range of web d a v propses 303 * @param end the upper bound of the range of web d a v propses (not inclusive) 304 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 305 * @return the ordered range of web d a v propses 306 * @throws SystemException if a system exception occurred 307 */ 308 public static java.util.List<com.liferay.portal.model.WebDAVProps> findAll( 309 int start, int end, 310 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 311 throws com.liferay.portal.kernel.exception.SystemException { 312 return getPersistence().findAll(start, end, orderByComparator); 313 } 314 315 /** 316 * Removes all the web d a v propses from the database. 317 * 318 * @throws SystemException if a system exception occurred 319 */ 320 public static void removeAll() 321 throws com.liferay.portal.kernel.exception.SystemException { 322 getPersistence().removeAll(); 323 } 324 325 /** 326 * Returns the number of web d a v propses. 327 * 328 * @return the number of web d a v propses 329 * @throws SystemException if a system exception occurred 330 */ 331 public static int countAll() 332 throws com.liferay.portal.kernel.exception.SystemException { 333 return getPersistence().countAll(); 334 } 335 336 public static WebDAVPropsPersistence getPersistence() { 337 if (_persistence == null) { 338 _persistence = (WebDAVPropsPersistence)PortalBeanLocatorUtil.locate(WebDAVPropsPersistence.class.getName()); 339 340 ReferenceRegistry.registerReference(WebDAVPropsUtil.class, 341 "_persistence"); 342 } 343 344 return _persistence; 345 } 346 347 /** 348 * @deprecated 349 */ 350 public void setPersistence(WebDAVPropsPersistence persistence) { 351 } 352 353 private static WebDAVPropsPersistence _persistence; 354 }