public class ReferenceAoImport extends Object implements PluggableImportAoEntityHandler
WEIGHT_NONE
Constructor and Description |
---|
ReferenceAoImport(com.atlassian.activeobjects.external.ActiveObjects ao) |
Modifier and Type | Method and Description |
---|---|
void |
endDocument()
Provides the implementation an opportunity to perform some action when the document is finished being read.
|
void |
endTable(String tableName)
Provides the implementation an opportunity to perform some action once all rows of a table are processed.
|
BackupProject |
getBackupProject() |
BackupSystemInformation |
getBackupSystemInformation() |
Long |
getEntityWeight(String entityName)
Return the weight for this entity.
|
ProjectImportMapper |
getProjectImportMapper() |
ProjectImportResults |
getProjectImportResults() |
List<String> |
getTables() |
void |
handleEntity(String entityName,
Map<String,Object> attributes)
This is the main method to implement when using this ImportEntityHandler.
|
boolean |
handlesEntity(String entityName)
Return true if the handler should handle this entity.
|
boolean |
isDocEnded() |
boolean |
isDocStarted() |
void |
setBackupProject(BackupProject backupProject)
Set the backup project.
|
void |
setBackupSystemInformation(BackupSystemInformation backupSystemInformation)
Set the backup system information.
|
void |
setProjectImportMapper(ProjectImportMapper projectImportMapper)
Set the project import mapper.
|
void |
setProjectImportResults(ProjectImportResults projectImportResults)
Set the project import results.
|
void |
startDocument()
Provides the implementation an opportunity to perform some action when the document is starting to
be read.
|
public ReferenceAoImport(com.atlassian.activeobjects.external.ActiveObjects ao)
public void handleEntity(String entityName, Map<String,Object> attributes) throws ParseException, AbortImportException
AoEntityHandler
handleEntity
in interface AoEntityHandler
entityName
- identifies the entity (i.e. Issue)attributes
- complete list of the attributes listed in the XML element including the nested
elements.ParseException
- if the entity is invalid a ParseException will be thrown.AbortImportException
- to indicate to Project Import
that it should abort its SAX parsing.public boolean handlesEntity(String entityName)
AoEntityHandler
handlesEntity
in interface AoEntityHandler
public Long getEntityWeight(String entityName)
PluggableImportAoEntityHandler
PluggableImportAoEntityHandler.WEIGHT_NONE
.
This is ignored (not called) during the pre-import stage where the entities are supplied in the backup XML order.getEntityWeight
in interface PluggableImportAoEntityHandler
public void startDocument()
AoEntityHandler
startDocument
in interface AoEntityHandler
public void endDocument()
AoEntityHandler
endDocument
in interface AoEntityHandler
public void endTable(String tableName)
AoEntityHandler
endTable
in interface AoEntityHandler
public void setBackupProject(BackupProject backupProject)
PluggableImportHandler
setBackupProject
in interface PluggableImportHandler
backupProject
- The backup projectpublic void setBackupSystemInformation(BackupSystemInformation backupSystemInformation)
PluggableImportHandler
setBackupSystemInformation
in interface PluggableImportHandler
backupSystemInformation
- The backup system informationpublic void setProjectImportMapper(ProjectImportMapper projectImportMapper)
PluggableImportHandler
setProjectImportMapper
in interface PluggableImportHandler
projectImportMapper
- The project import mapperpublic void setProjectImportResults(@Nullable ProjectImportResults projectImportResults)
PluggableImportHandler
setProjectImportResults
in interface PluggableImportHandler
projectImportResults
- The project import resultspublic boolean isDocStarted()
public boolean isDocEnded()
public BackupProject getBackupProject()
public BackupSystemInformation getBackupSystemInformation()
public ProjectImportMapper getProjectImportMapper()
@Nullable public ProjectImportResults getProjectImportResults()
Copyright © 2002-2015 Atlassian. All Rights Reserved.