public long[] commit(String[] path, String message, boolean recurse, boolean noUnlock, boolean atomicCommit) throws ClientException {
if(path == null || path.length == 0){
return new long[0];
}
SVNCommitClient client = getSVNCommitClient();
File[] files = new File[path.length];
for (int i = 0; i < path.length; i++) {
files[i] = new File(path[i]).getAbsoluteFile();
}
SVNCommitPacket[] packets = null;
SVNCommitInfo[] commitResults = null;
try {
if(myMessageHandler != null){
client.setCommitHandler(new ISVNCommitHandler(){
public String getCommitMessage(String cmessage, SVNCommitItem[] commitables) {
CommitItem[] items = JavaHLObjectFactory.getCommitItems(commitables);
return myMessageHandler.getLogMessage(items);
}
});
}
packets = client.doCollectCommitItems(files, noUnlock, !recurse, recurse, atomicCommit);
commitResults = client.doCommit(packets, noUnlock, message);
} catch (SVNException e) {
throwException(e);
}
if (commitResults != null && commitResults.length > 0) {
long[] revisions = new long[commitResults.length];