Interface EntityEraser
- All Known Implementing Classes:
ContentEntityObjectEraser
,GenericEraser
,PageTemplateEraser
,SpaceEraser
,SynchronyTablesEraser
public interface EntityEraser
Interface for erasers which ere responsible for removing data from tables.
Even though data from 95% of tables can be removed the same way, some tables has to be processed a special way,
for example, CONTENT, CONFANCESTORS bucket property sets etc.
- Since:
- 9.1.0
-
Method Summary
Modifier and TypeMethodDescriptiondeleteDataRecursively
(String columnName, Collection<Long> ids) Deletes records in the table where ids in columnName are in ids list.Class<?>
Get the class name of the Hibernate entity, for example, Label.class, Space.class etc.
-
Method Details
-
getEntityClass
Class<?> getEntityClass()Get the class name of the Hibernate entity, for example, Label.class, Space.class etc. Pages, blogpost etc use just one class, ConfluenceEntityObject.- Returns:
- hibernate entity class.
-
deleteDataRecursively
Deletes records in the table where ids in columnName are in ids list. Before this, it will call other erasers to remove their dependent data. For example, for space permissions, columnName will be SPACEID and ids will contain the list of space ids. In this case, this method will remove all space permissions where SPACEID in (ids)- Parameters:
columnName
- column name (referencing to some other parent entity)ids
- ids for removal (parent ids actually)- Returns:
- deletion result (number of deleted objects and finished/not finished state)
-