|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.atlassian.confluence.importexport.Importer
public abstract class Importer
An importer is a single-use object for performing an import with a given ImportContext
.
doImportInternal()
method to perform the actual import,
and may optionally override preImport()
and postImportAndCleanUp()
to do
additional processing.
ImportExportManager
Field Summary | |
---|---|
protected ImportContext |
context
|
protected net.sf.hibernate.SessionFactory |
sessionFactory
|
Constructor Summary | |
---|---|
Importer()
|
Method Summary | |
---|---|
ImportProcessorSummary |
doImport()
Executes an import with this importer. |
protected abstract ImportProcessorSummary |
doImportInternal()
Performs the actual import. |
protected com.atlassian.event.api.EventPublisher |
getEventPublisher()
|
protected void |
postImportAndCleanUp()
Perform any special logic after the import and post-import tasks are complete. |
protected void |
preImport()
Perform any special logic prior to the import starting. |
protected void |
publishEvent(java.lang.Object event)
Publish an event to the rest of the system. |
void |
setContext(ImportContext context)
|
void |
setEventPublisher(com.atlassian.event.api.EventPublisher eventPublisher)
|
void |
setPostImportTasks(java.util.List<PostImportTask> postImportTasks)
|
void |
setSessionFactory(net.sf.hibernate.SessionFactory sessionFactory)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected ImportContext context
protected net.sf.hibernate.SessionFactory sessionFactory
Constructor Detail |
---|
public Importer()
Method Detail |
---|
public final void setContext(ImportContext context)
public final void setSessionFactory(net.sf.hibernate.SessionFactory sessionFactory)
public final void setPostImportTasks(java.util.List<PostImportTask> postImportTasks)
public final void setEventPublisher(com.atlassian.event.api.EventPublisher eventPublisher)
public final ImportProcessorSummary doImport() throws ImportExportException
ImportExportManager
.
After the import is complete, runs the post-import tasks, published a ImportFinishedEvent
,
and deletes the import working file.
ImportExportException
- if there was a problem during the import or any of
the post-import tasks failed.protected void preImport() throws ImportExportException
ImportExportException
- if the import should be abortedprotected void postImportAndCleanUp() throws ImportExportException
ImportExportException
- if the import process should be abortedprotected abstract ImportProcessorSummary doImportInternal() throws ImportExportException
ImportExportException
- if there was a problem executing the importImportExportManager.performImport(ImportContext)
protected final void publishEvent(java.lang.Object event)
event
- the event to publishprotected com.atlassian.event.api.EventPublisher getEventPublisher()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |