ISVNDeltaConsumer, ISVNEditorpublic class SVNReplicationEditor extends java.lang.Object implements ISVNEditor
SVNRepository| Constructor | Description |
|---|---|
SVNReplicationEditor(SVNRepository repository,
ISVNEditor commitEditor,
SVNLogEntry revision) |
Creates a new replication editor.
|
| Modifier and Type | Method | Description |
|---|---|---|
void |
abortEdit() |
Aborts the transaction.
|
void |
absentDir(java.lang.String path) |
Does nothing.
|
void |
absentFile(java.lang.String path) |
Does nothing.
|
void |
addDir(java.lang.String path,
java.lang.String copyFromPath,
long copyFromRevision) |
Adds a new directory under the specified
path to the target repository. |
void |
addFile(java.lang.String path,
java.lang.String copyFromPath,
long copyFromRevision) |
Adds a new file.
|
void |
applyTextDelta(java.lang.String path,
java.lang.String baseChecksum) |
Starts applying text delta.
|
void |
changeDirProperty(java.lang.String name,
SVNPropertyValue value) |
Changes a property of the current directory.
|
void |
changeFileProperty(java.lang.String path,
java.lang.String name,
SVNPropertyValue value) |
Changes file property.
|
void |
closeDir() |
Closes the current opened dir.
|
SVNCommitInfo |
closeEdit() |
Commits the transaction.
|
void |
closeFile(java.lang.String path,
java.lang.String textChecksum) |
Closes the current opened file.
|
void |
deleteEntry(java.lang.String path,
long revision) |
Removes
path from the paths to be committed. |
SVNCommitInfo |
getCommitInfo() |
Returns commit information on the revision
committed to the replication destination repository.
|
void |
openDir(java.lang.String path,
long revision) |
Opens a corresponding
path in the target repository. |
void |
openFile(java.lang.String path,
long revision) |
Opens a file.
|
void |
openRoot(long revision) |
Starts a next replication transaction.
|
void |
targetRevision(long revision) |
Saves the target
revision. |
java.io.OutputStream |
textDeltaChunk(java.lang.String path,
SVNDiffWindow diffWindow) |
Applies a next chunk of delta.
|
void |
textDeltaEnd(java.lang.String path) |
Handles text delta end.
|
public SVNReplicationEditor(SVNRepository repository, ISVNEditor commitEditor, SVNLogEntry revision)
repository must be created for the root location of
the source repository which is to be replicated.
repository - a source repositorycommitEditor - a commit editor received from the destination
repository driver (which also must be point to the
root location of the destination repository)revision - log information of the revision to be copiedpublic void targetRevision(long revision)
throws SVNException
revision.targetRevision in interface ISVNEditorrevision - revisionSVNExceptionpublic void openRoot(long revision)
throws SVNException
openRoot in interface ISVNEditorrevision - target revisionSVNExceptionpublic void deleteEntry(java.lang.String path,
long revision)
throws SVNException
path from the paths to be committed.deleteEntry in interface ISVNEditorpath - revision - SVNException - exception with SVNErrorCode.UNKNOWN error code - if somehow
chanded paths fetched from the log of the resource repository did not
reflect path deletion in revisionpublic void absentDir(java.lang.String path)
throws SVNException
absentDir in interface ISVNEditorpath - SVNExceptionpublic void absentFile(java.lang.String path)
throws SVNException
absentFile in interface ISVNEditorpath - SVNExceptionpublic void addDir(java.lang.String path,
java.lang.String copyFromPath,
long copyFromRevision)
throws SVNException
path to the target repository.addDir in interface ISVNEditorpath - target directory pathcopyFromPath - not usedcopyFromRevision - not usedSVNException - exception with SVNErrorCode.UNKNOWN error code - if somehow
chanded paths fetched from the log of the resource repository did not
reflect path additionpublic void openDir(java.lang.String path,
long revision)
throws SVNException
path in the target repository.openDir in interface ISVNEditorpath - target directory path relative to the root of the editrevision - target directory revisionSVNExceptionpublic void changeDirProperty(java.lang.String name,
SVNPropertyValue value)
throws SVNException
changeDirProperty in interface ISVNEditorname - value - SVNExceptionISVNEditor.openDir(String, long)public void closeDir()
throws SVNException
closeDir in interface ISVNEditorSVNExceptionpublic void addFile(java.lang.String path,
java.lang.String copyFromPath,
long copyFromRevision)
throws SVNException
addFile in interface ISVNEditorpath - copyFromPath - copyFromRevision - SVNExceptionpublic void openFile(java.lang.String path,
long revision)
throws SVNException
openFile in interface ISVNEditorpath - revision - SVNExceptionpublic void applyTextDelta(java.lang.String path,
java.lang.String baseChecksum)
throws SVNException
applyTextDelta in interface ISVNDeltaConsumerpath - baseChecksum - SVNExceptionpublic java.io.OutputStream textDeltaChunk(java.lang.String path,
SVNDiffWindow diffWindow)
throws SVNException
textDeltaChunk in interface ISVNDeltaConsumerpath - diffWindow - SVNExceptionpublic void textDeltaEnd(java.lang.String path)
throws SVNException
textDeltaEnd in interface ISVNDeltaConsumerpath - SVNExceptionpublic void changeFileProperty(java.lang.String path,
java.lang.String name,
SVNPropertyValue value)
throws SVNException
changeFileProperty in interface ISVNEditorpath - name - value - SVNExceptionpublic void closeFile(java.lang.String path,
java.lang.String textChecksum)
throws SVNException
closeFile in interface ISVNEditorpath - textChecksum - SVNExceptionpublic SVNCommitInfo closeEdit() throws SVNException
closeEdit in interface ISVNEditorSVNExceptionpublic void abortEdit()
throws SVNException
abortEdit in interface ISVNEditorSVNExceptionpublic SVNCommitInfo getCommitInfo()