public class DefaultTrashManager extends Object implements TrashManager
Constructor and Description |
---|
DefaultTrashManager(ContentEntityObjectDaoInternal<ContentEntityObject> contentEntityObjectDao,
ContentEntityManager contentEntityManager,
CustomContentManager customContentManager,
org.springframework.transaction.PlatformTransactionManager transactionManager,
PageManager pageManager,
com.atlassian.event.api.EventPublisher eventPublisher,
AttachmentManager attachmentManager) |
Modifier and Type | Method and Description |
---|---|
void |
emptyTrash(Space space)
Purge all of the trash in a given space.
|
int |
getNumberOfItemsInTrash(Space space)
Retrieve the total number of items in the trash for a given space.
|
List<ContentEntityObject> |
getTrashContents(Space space,
int offset,
int count)
Retrieve a subset of the contents of the trash for a particular space.
|
boolean |
purge(String spaceKey,
long contentId)
Remove one item from the trash.
|
public DefaultTrashManager(ContentEntityObjectDaoInternal<ContentEntityObject> contentEntityObjectDao, ContentEntityManager contentEntityManager, CustomContentManager customContentManager, org.springframework.transaction.PlatformTransactionManager transactionManager, PageManager pageManager, com.atlassian.event.api.EventPublisher eventPublisher, AttachmentManager attachmentManager)
public void emptyTrash(Space space)
TrashManager
emptyTrash
in interface TrashManager
public int getNumberOfItemsInTrash(Space space)
TrashManager
getNumberOfItemsInTrash
in interface TrashManager
public boolean purge(String spaceKey, long contentId)
TrashManager
purge
in interface TrashManager
spaceKey
- the space to purge the trash fromcontentId
- the id of the item to remove from the trash @return true if content was purged, false if no content was found with that IDpublic List<ContentEntityObject> getTrashContents(Space space, int offset, int count)
TrashManager
getTrashContents
in interface TrashManager
offset
- the offset of the first item to retrieve (0-based)count
- the maximum number of items to retrieveCopyright © 2003–2021 Atlassian. All rights reserved.