Class Importer
- java.lang.Object
-
- com.atlassian.confluence.importexport.Importer
-
- Direct Known Subclasses:
BackupImporter
@Deprecated public abstract class Importer extends Object
Deprecated.since 7.17.0. UseBackupRestoreManager
insteadAn importer is a single-use object for performing an import with a givenImportContext
.Subclasses must implement the
doImportInternal()
method to perform the actual import, and may optionally overridepreImport()
andpostImportAndCleanUp()
to do additional processing.- See Also:
ImportExportManager
-
-
Field Summary
Fields Modifier and Type Field Description protected ImportContext
context
Deprecated.protected org.hibernate.SessionFactory
sessionFactory
Deprecated.
-
Constructor Summary
Constructors Constructor Description Importer()
Deprecated.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected void
completeProgessMeter()
Deprecated.ImportProcessorSummary
doImport()
Deprecated.Executes an import with this importer.protected abstract ImportProcessorSummary
doImportInternal()
Deprecated.Performs the actual import.protected com.atlassian.event.api.EventPublisher
getEventPublisher()
Deprecated.protected void
postImportAndCleanUp()
Deprecated.Perform any special logic after the import and post-import tasks are complete.protected void
preImport()
Deprecated.Perform any special logic prior to the import starting.protected void
publishEvent(Object event)
Deprecated.Publish an event to the rest of the system.void
setContext(ImportContext context)
Deprecated.void
setEventPublisher(com.atlassian.event.api.EventPublisher eventPublisher)
Deprecated.void
setPostImportTasks(List<PostImportTask> postImportTasks)
Deprecated.void
setSessionFactory(org.hibernate.SessionFactory sessionFactory)
Deprecated.
-
-
-
Field Detail
-
context
protected ImportContext context
Deprecated.
-
sessionFactory
protected org.hibernate.SessionFactory sessionFactory
Deprecated.
-
-
Method Detail
-
setContext
public final void setContext(ImportContext context)
Deprecated.
-
setSessionFactory
public final void setSessionFactory(org.hibernate.SessionFactory sessionFactory)
Deprecated.
-
setPostImportTasks
public final void setPostImportTasks(List<PostImportTask> postImportTasks)
Deprecated.
-
setEventPublisher
public final void setEventPublisher(com.atlassian.event.api.EventPublisher eventPublisher)
Deprecated.
-
doImport
public final ImportProcessorSummary doImport() throws ImportExportException
Deprecated.Executes an import with this importer. Clients should not normally call this method directly, but instead use theImportExportManager
.After the import is complete, runs the post-import tasks, published a
ImportFinishedEvent
, and deletes the import working file.- Throws:
ImportExportException
- if there was a problem during the import or any of the post-import tasks failed.
-
completeProgessMeter
protected void completeProgessMeter()
Deprecated.
-
preImport
protected void preImport() throws ImportExportException
Deprecated.Perform any special logic prior to the import starting. Default implementation does nothing.- Throws:
ImportExportException
- if the import should be aborted
-
postImportAndCleanUp
protected void postImportAndCleanUp() throws ImportExportException
Deprecated.Perform any special logic after the import and post-import tasks are complete. This method will run even if the import fails. The default implementation does nothing.- Throws:
ImportExportException
- if the import process should be aborted
-
doImportInternal
protected abstract ImportProcessorSummary doImportInternal() throws ImportExportException
Deprecated.Performs the actual import.- Throws:
ImportExportException
- if there was a problem executing the import- See Also:
ImportExportManager.performImport(ImportContext)
-
publishEvent
protected final void publishEvent(Object event)
Deprecated.Publish an event to the rest of the system.- Parameters:
event
- the event to publish
-
getEventPublisher
protected com.atlassian.event.api.EventPublisher getEventPublisher()
Deprecated.
-
-