001 /** 002 * Copyright (c) 2000-2013 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.trash.service; 016 017 import com.liferay.portal.service.ServiceWrapper; 018 019 /** 020 * <p> 021 * This class is a wrapper for {@link TrashEntryLocalService}. 022 * </p> 023 * 024 * @author Brian Wing Shun Chan 025 * @see TrashEntryLocalService 026 * @generated 027 */ 028 public class TrashEntryLocalServiceWrapper implements TrashEntryLocalService, 029 ServiceWrapper<TrashEntryLocalService> { 030 public TrashEntryLocalServiceWrapper( 031 TrashEntryLocalService trashEntryLocalService) { 032 _trashEntryLocalService = trashEntryLocalService; 033 } 034 035 /** 036 * Adds the trash entry to the database. Also notifies the appropriate model listeners. 037 * 038 * @param trashEntry the trash entry 039 * @return the trash entry that was added 040 * @throws SystemException if a system exception occurred 041 */ 042 public com.liferay.portlet.trash.model.TrashEntry addTrashEntry( 043 com.liferay.portlet.trash.model.TrashEntry trashEntry) 044 throws com.liferay.portal.kernel.exception.SystemException { 045 return _trashEntryLocalService.addTrashEntry(trashEntry); 046 } 047 048 /** 049 * Creates a new trash entry with the primary key. Does not add the trash entry to the database. 050 * 051 * @param entryId the primary key for the new trash entry 052 * @return the new trash entry 053 */ 054 public com.liferay.portlet.trash.model.TrashEntry createTrashEntry( 055 long entryId) { 056 return _trashEntryLocalService.createTrashEntry(entryId); 057 } 058 059 /** 060 * Deletes the trash entry with the primary key from the database. Also notifies the appropriate model listeners. 061 * 062 * @param entryId the primary key of the trash entry 063 * @return the trash entry that was removed 064 * @throws PortalException if a trash entry with the primary key could not be found 065 * @throws SystemException if a system exception occurred 066 */ 067 public com.liferay.portlet.trash.model.TrashEntry deleteTrashEntry( 068 long entryId) 069 throws com.liferay.portal.kernel.exception.PortalException, 070 com.liferay.portal.kernel.exception.SystemException { 071 return _trashEntryLocalService.deleteTrashEntry(entryId); 072 } 073 074 /** 075 * Deletes the trash entry from the database. Also notifies the appropriate model listeners. 076 * 077 * @param trashEntry the trash entry 078 * @return the trash entry that was removed 079 * @throws SystemException if a system exception occurred 080 */ 081 public com.liferay.portlet.trash.model.TrashEntry deleteTrashEntry( 082 com.liferay.portlet.trash.model.TrashEntry trashEntry) 083 throws com.liferay.portal.kernel.exception.SystemException { 084 return _trashEntryLocalService.deleteTrashEntry(trashEntry); 085 } 086 087 public com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery() { 088 return _trashEntryLocalService.dynamicQuery(); 089 } 090 091 /** 092 * Performs a dynamic query on the database and returns the matching rows. 093 * 094 * @param dynamicQuery the dynamic query 095 * @return the matching rows 096 * @throws SystemException if a system exception occurred 097 */ 098 @SuppressWarnings("rawtypes") 099 public java.util.List dynamicQuery( 100 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) 101 throws com.liferay.portal.kernel.exception.SystemException { 102 return _trashEntryLocalService.dynamicQuery(dynamicQuery); 103 } 104 105 /** 106 * Performs a dynamic query on the database and returns a range of the matching rows. 107 * 108 * <p> 109 * 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.trash.model.impl.TrashEntryModelImpl}. 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. 110 * </p> 111 * 112 * @param dynamicQuery the dynamic query 113 * @param start the lower bound of the range of model instances 114 * @param end the upper bound of the range of model instances (not inclusive) 115 * @return the range of matching rows 116 * @throws SystemException if a system exception occurred 117 */ 118 @SuppressWarnings("rawtypes") 119 public java.util.List dynamicQuery( 120 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 121 int end) throws com.liferay.portal.kernel.exception.SystemException { 122 return _trashEntryLocalService.dynamicQuery(dynamicQuery, start, end); 123 } 124 125 /** 126 * Performs a dynamic query on the database and returns an ordered 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.trash.model.impl.TrashEntryModelImpl}. 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 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 136 * @return the ordered range of matching rows 137 * @throws SystemException if a system exception occurred 138 */ 139 @SuppressWarnings("rawtypes") 140 public java.util.List dynamicQuery( 141 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 142 int end, 143 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 144 throws com.liferay.portal.kernel.exception.SystemException { 145 return _trashEntryLocalService.dynamicQuery(dynamicQuery, start, end, 146 orderByComparator); 147 } 148 149 /** 150 * Returns the number of rows that match the dynamic query. 151 * 152 * @param dynamicQuery the dynamic query 153 * @return the number of rows that match the dynamic query 154 * @throws SystemException if a system exception occurred 155 */ 156 public long dynamicQueryCount( 157 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) 158 throws com.liferay.portal.kernel.exception.SystemException { 159 return _trashEntryLocalService.dynamicQueryCount(dynamicQuery); 160 } 161 162 public com.liferay.portlet.trash.model.TrashEntry fetchTrashEntry( 163 long entryId) 164 throws com.liferay.portal.kernel.exception.SystemException { 165 return _trashEntryLocalService.fetchTrashEntry(entryId); 166 } 167 168 /** 169 * Returns the trash entry with the primary key. 170 * 171 * @param entryId the primary key of the trash entry 172 * @return the trash entry 173 * @throws PortalException if a trash entry with the primary key could not be found 174 * @throws SystemException if a system exception occurred 175 */ 176 public com.liferay.portlet.trash.model.TrashEntry getTrashEntry( 177 long entryId) 178 throws com.liferay.portal.kernel.exception.PortalException, 179 com.liferay.portal.kernel.exception.SystemException { 180 return _trashEntryLocalService.getTrashEntry(entryId); 181 } 182 183 public com.liferay.portal.model.PersistedModel getPersistedModel( 184 java.io.Serializable primaryKeyObj) 185 throws com.liferay.portal.kernel.exception.PortalException, 186 com.liferay.portal.kernel.exception.SystemException { 187 return _trashEntryLocalService.getPersistedModel(primaryKeyObj); 188 } 189 190 /** 191 * Returns a range of all the trash entries. 192 * 193 * <p> 194 * 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.trash.model.impl.TrashEntryModelImpl}. 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. 195 * </p> 196 * 197 * @param start the lower bound of the range of trash entries 198 * @param end the upper bound of the range of trash entries (not inclusive) 199 * @return the range of trash entries 200 * @throws SystemException if a system exception occurred 201 */ 202 public java.util.List<com.liferay.portlet.trash.model.TrashEntry> getTrashEntries( 203 int start, int end) 204 throws com.liferay.portal.kernel.exception.SystemException { 205 return _trashEntryLocalService.getTrashEntries(start, end); 206 } 207 208 /** 209 * Returns the number of trash entries. 210 * 211 * @return the number of trash entries 212 * @throws SystemException if a system exception occurred 213 */ 214 public int getTrashEntriesCount() 215 throws com.liferay.portal.kernel.exception.SystemException { 216 return _trashEntryLocalService.getTrashEntriesCount(); 217 } 218 219 /** 220 * Updates the trash entry in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners. 221 * 222 * @param trashEntry the trash entry 223 * @return the trash entry that was updated 224 * @throws SystemException if a system exception occurred 225 */ 226 public com.liferay.portlet.trash.model.TrashEntry updateTrashEntry( 227 com.liferay.portlet.trash.model.TrashEntry trashEntry) 228 throws com.liferay.portal.kernel.exception.SystemException { 229 return _trashEntryLocalService.updateTrashEntry(trashEntry); 230 } 231 232 /** 233 * Returns the Spring bean ID for this bean. 234 * 235 * @return the Spring bean ID for this bean 236 */ 237 public java.lang.String getBeanIdentifier() { 238 return _trashEntryLocalService.getBeanIdentifier(); 239 } 240 241 /** 242 * Sets the Spring bean ID for this bean. 243 * 244 * @param beanIdentifier the Spring bean ID for this bean 245 */ 246 public void setBeanIdentifier(java.lang.String beanIdentifier) { 247 _trashEntryLocalService.setBeanIdentifier(beanIdentifier); 248 } 249 250 /** 251 * Moves an entry to trash. 252 * 253 * @param userId the primary key of the user removing the entity 254 * @param groupId the primary key of the entry's group 255 * @param className the class name of the entity 256 * @param classPK the primary key of the entity 257 * @param status the status of the entity prior to being moved to trash 258 * @param statusOVPs the primary keys and statuses of any of the entry's 259 versions (e.g., {@link 260 com.liferay.portlet.documentlibrary.model.DLFileVersion}) 261 * @param typeSettingsProperties the type settings properties 262 * @return the trashEntry 263 * @throws PortalException if a user with the primary key could not be found 264 * @throws SystemException if a system exception occurred 265 */ 266 public com.liferay.portlet.trash.model.TrashEntry addTrashEntry( 267 long userId, long groupId, java.lang.String className, long classPK, 268 int status, 269 java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<java.lang.Long, java.lang.Integer>> statusOVPs, 270 com.liferay.portal.kernel.util.UnicodeProperties typeSettingsProperties) 271 throws com.liferay.portal.kernel.exception.PortalException, 272 com.liferay.portal.kernel.exception.SystemException { 273 return _trashEntryLocalService.addTrashEntry(userId, groupId, 274 className, classPK, status, statusOVPs, typeSettingsProperties); 275 } 276 277 public void checkEntries() 278 throws com.liferay.portal.kernel.exception.PortalException, 279 com.liferay.portal.kernel.exception.SystemException { 280 _trashEntryLocalService.checkEntries(); 281 } 282 283 /** 284 * Deletes the trash entry with the primary key. 285 * 286 * @param entryId the primary key of the trash entry 287 * @throws PortalException if a trash entry with the primary key could not 288 be found 289 * @throws SystemException if a system exception occurred 290 */ 291 public com.liferay.portlet.trash.model.TrashEntry deleteEntry(long entryId) 292 throws com.liferay.portal.kernel.exception.PortalException, 293 com.liferay.portal.kernel.exception.SystemException { 294 return _trashEntryLocalService.deleteEntry(entryId); 295 } 296 297 /** 298 * Deletes the trash entry with the entity class name and primary key. 299 * 300 * @param className the class name of entity 301 * @param classPK the primary key of the entry 302 * @throws PortalException if a trash entry with the primary key could not 303 be found 304 * @throws SystemException if a system exception occurred 305 */ 306 public com.liferay.portlet.trash.model.TrashEntry deleteEntry( 307 java.lang.String className, long classPK) 308 throws com.liferay.portal.kernel.exception.PortalException, 309 com.liferay.portal.kernel.exception.SystemException { 310 return _trashEntryLocalService.deleteEntry(className, classPK); 311 } 312 313 public com.liferay.portlet.trash.model.TrashEntry deleteEntry( 314 com.liferay.portlet.trash.model.TrashEntry trashEntry) 315 throws com.liferay.portal.kernel.exception.SystemException { 316 return _trashEntryLocalService.deleteEntry(trashEntry); 317 } 318 319 /** 320 * Returns the trash entry with the primary key. 321 * 322 * @param entryId the primary key of the entry 323 * @return the trash entry with the primary key 324 * @throws SystemException if a system exception occurred 325 */ 326 public com.liferay.portlet.trash.model.TrashEntry fetchEntry(long entryId) 327 throws com.liferay.portal.kernel.exception.SystemException { 328 return _trashEntryLocalService.fetchEntry(entryId); 329 } 330 331 /** 332 * Returns the trash entry with the entity class name and primary key. 333 * 334 * @param className the class name of the entity 335 * @param classPK the primary key of the entity 336 * @return the trash entry with the entity class name and primary key 337 * @throws SystemException if a system exception occurred 338 */ 339 public com.liferay.portlet.trash.model.TrashEntry fetchEntry( 340 java.lang.String className, long classPK) 341 throws com.liferay.portal.kernel.exception.SystemException { 342 return _trashEntryLocalService.fetchEntry(className, classPK); 343 } 344 345 /** 346 * Returns the trash entries with the matching group ID. 347 * 348 * @param groupId the primary key of the group 349 * @return the trash entries with the group ID 350 * @throws SystemException if a system exception occurred 351 */ 352 public java.util.List<com.liferay.portlet.trash.model.TrashEntry> getEntries( 353 long groupId) 354 throws com.liferay.portal.kernel.exception.SystemException { 355 return _trashEntryLocalService.getEntries(groupId); 356 } 357 358 /** 359 * Returns a range of all the trash entries matching the group ID. 360 * 361 * @param groupId the primary key of the group 362 * @param start the lower bound of the range of trash entries to return 363 * @param end the upper bound of the range of trash entries to return (not 364 inclusive) 365 * @return the range of matching trash entries 366 * @throws SystemException if a system exception occurred 367 */ 368 public java.util.List<com.liferay.portlet.trash.model.TrashEntry> getEntries( 369 long groupId, int start, int end) 370 throws com.liferay.portal.kernel.exception.SystemException { 371 return _trashEntryLocalService.getEntries(groupId, start, end); 372 } 373 374 /** 375 * Returns a range of all the trash entries matching the group ID. 376 * 377 * @param groupId the primary key of the group 378 * @param start the lower bound of the range of trash entries to return 379 * @param end the upper bound of the range of trash entries to return (not 380 inclusive) 381 * @param obc the comparator to order the trash entries (optionally 382 <code>null</code>) 383 * @return the range of matching trash entries ordered by comparator 384 <code>obc</code> 385 * @throws SystemException if a system exception occurred 386 */ 387 public java.util.List<com.liferay.portlet.trash.model.TrashEntry> getEntries( 388 long groupId, int start, int end, 389 com.liferay.portal.kernel.util.OrderByComparator obc) 390 throws com.liferay.portal.kernel.exception.SystemException { 391 return _trashEntryLocalService.getEntries(groupId, start, end, obc); 392 } 393 394 /** 395 * Returns the number of trash entries with the group ID. 396 * 397 * @param groupId the primary key of the group 398 * @return the number of matching trash entries 399 * @throws SystemException if a system exception occurred 400 */ 401 public int getEntriesCount(long groupId) 402 throws com.liferay.portal.kernel.exception.SystemException { 403 return _trashEntryLocalService.getEntriesCount(groupId); 404 } 405 406 /** 407 * Returns the trash entry with the primary key. 408 * 409 * @param entryId the primary key of the trash entry 410 * @return the trash entry with the primary key 411 * @throws PortalException if a trash entry with the primary key could not 412 be found 413 * @throws SystemException if a system exception occurred 414 */ 415 public com.liferay.portlet.trash.model.TrashEntry getEntry(long entryId) 416 throws com.liferay.portal.kernel.exception.PortalException, 417 com.liferay.portal.kernel.exception.SystemException { 418 return _trashEntryLocalService.getEntry(entryId); 419 } 420 421 /** 422 * Returns the entry with the entity class name and primary key. 423 * 424 * @param className the class name of the entity 425 * @param classPK the primary key of the entity 426 * @return the trash entry with the entity class name and primary key 427 * @throws PortalException if a trash entry with the primary key could not 428 be found 429 * @throws SystemException if a system exception occurred 430 */ 431 public com.liferay.portlet.trash.model.TrashEntry getEntry( 432 java.lang.String className, long classPK) 433 throws com.liferay.portal.kernel.exception.PortalException, 434 com.liferay.portal.kernel.exception.SystemException { 435 return _trashEntryLocalService.getEntry(className, classPK); 436 } 437 438 /** 439 * Returns all the trash versions associated with the trash entry. 440 * 441 * @param entryId the primary key of the trash entry 442 * @return all the trash versions associated with the trash entry 443 * @throws SystemException if a system exception occurred 444 */ 445 public java.util.List<com.liferay.portlet.trash.model.TrashVersion> getVersions( 446 long entryId) 447 throws com.liferay.portal.kernel.exception.SystemException { 448 return _trashEntryLocalService.getVersions(entryId); 449 } 450 451 /** 452 * Returns all the trash versions associated with the trash entry. 453 * 454 * @param className the class name of the trash entity 455 * @param classPK the primary key of the trash entity 456 * @return all the trash versions associated with the trash entry 457 * @throws SystemException if a system exception occurred 458 */ 459 public java.util.List<com.liferay.portlet.trash.model.TrashVersion> getVersions( 460 java.lang.String className, long classPK) 461 throws com.liferay.portal.kernel.exception.SystemException { 462 return _trashEntryLocalService.getVersions(className, classPK); 463 } 464 465 public com.liferay.portal.kernel.search.Hits search(long companyId, 466 long groupId, long userId, java.lang.String keywords, int start, 467 int end, com.liferay.portal.kernel.search.Sort sort) 468 throws com.liferay.portal.kernel.exception.SystemException { 469 return _trashEntryLocalService.search(companyId, groupId, userId, 470 keywords, start, end, sort); 471 } 472 473 /** 474 * @deprecated As of 6.1.0, replaced by {@link #getWrappedService} 475 */ 476 public TrashEntryLocalService getWrappedTrashEntryLocalService() { 477 return _trashEntryLocalService; 478 } 479 480 /** 481 * @deprecated As of 6.1.0, replaced by {@link #setWrappedService} 482 */ 483 public void setWrappedTrashEntryLocalService( 484 TrashEntryLocalService trashEntryLocalService) { 485 _trashEntryLocalService = trashEntryLocalService; 486 } 487 488 public TrashEntryLocalService getWrappedService() { 489 return _trashEntryLocalService; 490 } 491 492 public void setWrappedService(TrashEntryLocalService trashEntryLocalService) { 493 _trashEntryLocalService = trashEntryLocalService; 494 } 495 496 private TrashEntryLocalService _trashEntryLocalService; 497 }