java.lang.Object |
↳ |
com.atlassian.jira.imports.project.handler.IssuePartitionHandler |
Class Overview
Parses an XML import file and creates a reduced XML file with just the Issues for the given project.
Summary
Fields |
protected
final
GenericDelegator |
delegator |
|
Public Methods |
void
|
assertModelEntityForName(ModelEntity modelEntity, String expectedName)
|
void
|
endDocument()
Provides the implementation an opportunity to perform some action when the document is finished being read.
|
int
|
getEntityCount()
|
void
|
handleEntity(String entityName, Map<String, String> attributes)
This is the main method to implement when using this ImportEntityHandler.
|
void
|
startDocument()
Provides the implementation an opportunity to perform some action when the document is starting to
be read.
|
Fields
protected
final
GenericDelegator
delegator
Public Constructors
public
IssuePartitionHandler
(BackupProject backupProject, ProjectImportTemporaryFiles projectImportTemporaryFiles, ModelEntity modelEntity, DelegatorInterface delegatorInterface)
Parameters
backupProject
| contains the issue id's that we are interested in partitioning. |
projectImportTemporaryFiles
| the temp files provider |
modelEntity
| is the ModelEntity for the "Issue" entity |
delegatorInterface
| required for persistence
|
Public Methods
public
void
assertModelEntityForName
(ModelEntity modelEntity, String expectedName)
public
void
endDocument
()
Provides the implementation an opportunity to perform some action when the document is finished being read.
public
int
getEntityCount
()
public
void
handleEntity
(String entityName, Map<String, String> attributes)
This is the main method to implement when using this ImportEntityHandler. This method will provide the
entity name and a complete map of attribute key/value pairs. This includes any nested element tags that
will have CDATA bodies.
Parameters
entityName
| identifies the entity (i.e. Issue) |
attributes
| complete list of the attributes listed in the XML element including the nested
elements. |
public
void
startDocument
()
Provides the implementation an opportunity to perform some action when the document is starting to
be read.