public class SVNAdmin
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static interface |
SVNAdmin.MessageReceiver
interface to receive the messages
|
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
BDB
Filesystem in a Berkeley DB
|
protected long |
cppAddr
slot for the adress of the native peer.
|
static java.lang.String |
FSFS
Filesystem in the filesystem
|
Constructor and Description |
---|
SVNAdmin()
Standard empty constructor, builds just the native peer.
|
Modifier and Type | Method and Description |
---|---|
void |
create(java.lang.String path,
boolean disableFsyncCommit,
boolean keepLog,
java.lang.String configPath,
java.lang.String fstype)
create a subversion repository.
|
void |
deltify(java.lang.String path,
Revision start,
Revision end)
deltify the revisions in the repository
|
void |
dispose()
release the native peer (should not depend on finalize)
|
void |
dump(java.lang.String path,
OutputInterface dataOut,
OutputInterface errorOut,
Revision start,
Revision end,
boolean incremental)
dump the data in a repository
|
void |
dump(java.lang.String path,
OutputInterface dataOut,
OutputInterface errorOut,
Revision start,
Revision end,
boolean incremental,
boolean useDeltas)
dump the data in a repository
|
protected void |
finalize()
release the native peer (should use dispose instead)
|
Version |
getVersion() |
void |
hotcopy(java.lang.String path,
java.lang.String targetPath,
boolean cleanLogs)
make a hot copy of the repository
|
void |
listDBLogs(java.lang.String path,
SVNAdmin.MessageReceiver receiver)
list all logfiles (BDB) in use or not)
|
void |
listUnusedDBLogs(java.lang.String path,
SVNAdmin.MessageReceiver receiver)
list unused logfiles
|
void |
load(java.lang.String path,
InputInterface dataInput,
OutputInterface messageOutput,
boolean ignoreUUID,
boolean forceUUID,
boolean usePreCommitHook,
boolean usePostCommitHook,
java.lang.String relativePath)
load the data of a dump into a repository,
|
void |
load(java.lang.String path,
InputInterface dataInput,
OutputInterface messageOutput,
boolean ignoreUUID,
boolean forceUUID,
java.lang.String relativePath)
load the data of a dump into a repository,
|
Lock[] |
lslocks(java.lang.String path)
list all locks in the repository
|
void |
lstxns(java.lang.String path,
SVNAdmin.MessageReceiver receiver)
list all open transactions in a repository
|
long |
recover(java.lang.String path)
recover the berkeley db of a repository, returns youngest revision
|
void |
rmlocks(java.lang.String path,
java.lang.String[] locks)
remove multiple locks from the repository
|
void |
rmtxns(java.lang.String path,
java.lang.String[] transactions)
remove open transaction in a repository
|
void |
setLog(java.lang.String path,
Revision rev,
java.lang.String message,
boolean bypassHooks)
Deprecated.
Use setRevProp() instead.
|
void |
setRevProp(java.lang.String path,
Revision rev,
java.lang.String propName,
java.lang.String propValue,
boolean usePreRevPropChangeHook,
boolean usePostRevPropChangeHook)
Change the value of the revision property
propName
to propValue . |
void |
verify(java.lang.String path,
OutputInterface messageOut,
Revision start,
Revision end)
Verify the repository at
path between revisions
start and end . |
protected long cppAddr
public static final java.lang.String BDB
public static final java.lang.String FSFS
public SVNAdmin()
public void dispose()
protected void finalize()
finalize
in class java.lang.Object
public Version getVersion()
public void create(java.lang.String path, boolean disableFsyncCommit, boolean keepLog, java.lang.String configPath, java.lang.String fstype) throws ClientException
path
- the path where the repository will been
created.disableFsyncCommit
- disable to fsync at the commit (BDB).keepLog
- keep the log files (BDB).configPath
- optional path for user configuration files.fstype
- the type of the filesystem (BDB or FSFS)ClientException
- throw in case of problempublic void deltify(java.lang.String path, Revision start, Revision end) throws ClientException
path
- the path to the repositorystart
- start revisionend
- end revisionClientException
- throw in case of problempublic void dump(java.lang.String path, OutputInterface dataOut, OutputInterface errorOut, Revision start, Revision end, boolean incremental) throws ClientException
path
- the path to the repositorydataOut
- the data will be outputed hereerrorOut
- the messages will be outputed herestart
- the first revision to be dumpedend
- the last revision to be dumpedincremental
- the dump will be incremantalClientException
- throw in case of problempublic void dump(java.lang.String path, OutputInterface dataOut, OutputInterface errorOut, Revision start, Revision end, boolean incremental, boolean useDeltas) throws ClientException
path
- the path to the repositorydataOut
- the data will be outputed hereerrorOut
- the messages will be outputed herestart
- the first revision to be dumpedend
- the last revision to be dumpedincremental
- the dump will be incremantaluseDeltas
- the dump will contain deltas between nodesClientException
- throw in case of problempublic void hotcopy(java.lang.String path, java.lang.String targetPath, boolean cleanLogs) throws ClientException
path
- the path to the source repositorytargetPath
- the path to the target repositorycleanLogs
- clean the unused log files in the source
repositoryClientException
- throw in case of problempublic void listDBLogs(java.lang.String path, SVNAdmin.MessageReceiver receiver) throws ClientException
path
- the path to the repositoryreceiver
- interface to receive the logfile namesClientException
- throw in case of problempublic void listUnusedDBLogs(java.lang.String path, SVNAdmin.MessageReceiver receiver) throws ClientException
path
- the path to the repositoryreceiver
- interface to receive the logfile namesClientException
- throw in case of problempublic void load(java.lang.String path, InputInterface dataInput, OutputInterface messageOutput, boolean ignoreUUID, boolean forceUUID, java.lang.String relativePath) throws ClientException
path
- the path to the repositorydataInput
- the data input sourcemessageOutput
- the target for processing messagesignoreUUID
- ignore any UUID found in the input streamforceUUID
- set the repository UUID to any found in the
streamrelativePath
- the directory in the repository, where the data
in put optional.ClientException
- throw in case of problempublic void load(java.lang.String path, InputInterface dataInput, OutputInterface messageOutput, boolean ignoreUUID, boolean forceUUID, boolean usePreCommitHook, boolean usePostCommitHook, java.lang.String relativePath) throws ClientException
path
- the path to the repositorydataInput
- the data input sourcemessageOutput
- the target for processing messagesignoreUUID
- ignore any UUID found in the input streamforceUUID
- set the repository UUID to any found in the
streamusePreCommitHook
- use the pre-commit hook when processing commitsusePostCommitHook
- use the post-commit hook when processing commitsrelativePath
- the directory in the repository, where the data
in put optional.ClientException
- throw in case of problempublic void lstxns(java.lang.String path, SVNAdmin.MessageReceiver receiver) throws ClientException
path
- the path to the repositoryreceiver
- receives one transaction name per callClientException
- throw in case of problempublic long recover(java.lang.String path) throws ClientException
path
- the path to the repositoryClientException
- throw in case of problempublic void rmtxns(java.lang.String path, java.lang.String[] transactions) throws ClientException
path
- the path to the repositorytransactions
- the transactions to be removedClientException
- throw in case of problempublic void setLog(java.lang.String path, Revision rev, java.lang.String message, boolean bypassHooks) throws ClientException
path
- the path to the repositoryrev
- the revision to be changedmessage
- the message to be setbypassHooks
- if to bypass all repository hooksClientException
- throw in case of problempublic void setRevProp(java.lang.String path, Revision rev, java.lang.String propName, java.lang.String propValue, boolean usePreRevPropChangeHook, boolean usePostRevPropChangeHook) throws SubversionException
propName
to propValue
. By default, does not run
pre-/post-revprop-change hook scripts.path
- The path to the repository.rev
- The revision for which to change a property value.propName
- The name of the property to change.propValue
- The new value to set for the property.usePreRevPropChangeHook
- Whether to run the
pre-revprop-change hook script.usePostRevPropChangeHook
- Whether to run the
post-revprop-change hook script.SubversionException
- If a problem occurs.public void verify(java.lang.String path, OutputInterface messageOut, Revision start, Revision end) throws ClientException
path
between revisions
start
and end
.path
- the path to the repositorymessageOut
- the receiver of all messagesstart
- the first revisionend
- the last revisionClientException
- If an error occurred.public Lock[] lslocks(java.lang.String path) throws ClientException
path
- the path to the repositoryClientException
- throw in case of problempublic void rmlocks(java.lang.String path, java.lang.String[] locks) throws ClientException
path
- the path to the repositorylocks
- the name of the locked itemsClientException
- throw in case of problem