public void testConnection() throws SVNException { try { openConnection(); } finally { closeConnection(); } }
public void testConnection() throws SVNException { try { openConnection(); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } }
public void testConnection() throws SVNException { try { openConnection(); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } }
public void testConnection() throws SVNException { try { openConnection(); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } }
public boolean hasCapability(SVNCapability capability) throws SVNException { if (capability == null) { return false; } try { openConnection(); return myConnection.hasCapability(capability.toString()); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } }
public boolean hasCapability(SVNCapability capability) throws SVNException { if (capability == null) { return false; } try { openConnection(); return myConnection.hasCapability(capability.toString()); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } }
public boolean hasCapability(SVNCapability capability) throws SVNException { if (capability == null) { return false; } try { openConnection(); return myConnection.hasCapability(capability.toString()); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } }
public long getLatestRevision() throws SVNException { Object[] buffer = new Object[] { "get-latest-rev" }; try { openConnection(); write("(w())", buffer); authenticate(); buffer = read("[(N)]", buffer, true); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } return SVNReader.getLong(buffer, 0); }
public long getLatestRevision() throws SVNException { Object[] buffer = new Object[]{"get-latest-rev"}; List values = null; try { openConnection(); write("(w())", buffer); authenticate(); values = read("r", null, false); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } return SVNReader.getLong(values, 0); }
public long getLatestRevision() throws SVNException { Object[] buffer = new Object[]{"get-latest-rev"}; List values = null; try { openConnection(); write("(w())", buffer); authenticate(); values = read("r", null, false); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } return SVNReader.getLong(values, 0); }
public long getLatestRevision() throws SVNException { Object[] buffer = new Object[]{"get-latest-rev"}; List values = null; try { openConnection(); write("(w())", buffer); authenticate(); values = read("r", null, false); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } return SVNReader.getLong(values, 0); }
public void replay(long lowRevision, long highRevision, boolean sendDeltas, ISVNEditor editor) throws SVNException { Object[] buffer = new Object[]{"replay", getRevisionObject(highRevision), getRevisionObject(lowRevision), Boolean.valueOf(sendDeltas)}; try { openConnection(); write("(w(nnw))", buffer); authenticate(); SVNEditModeReader editReader = new SVNEditModeReader(myConnection, editor, true); editReader.driveEditor(); read("", null, false); } catch (SVNException e) { closeSession(); handleUnsupportedCommand(e, "Server doesn't support the replay command"); } finally { closeConnection(); } }
public void replay(long lowRevision, long highRevision, boolean sendDeltas, ISVNEditor editor) throws SVNException { Object[] buffer = new Object[]{"replay", getRevisionObject(highRevision), getRevisionObject(lowRevision), Boolean.valueOf(sendDeltas)}; try { openConnection(); write("(w(nnw))", buffer); authenticate(); SVNEditModeReader editReader = new SVNEditModeReader(myConnection, editor, true); editReader.driveEditor(); read("", null, false); } catch (SVNException e) { closeSession(); handleUnsupportedCommand(e, "Server doesn't support the replay command"); } finally { closeConnection(); } }
public void replay(long lowRevision, long highRevision, boolean sendDeltas, ISVNEditor editor) throws SVNException { Object[] buffer = new Object[]{"replay", getRevisionObject(highRevision), getRevisionObject(lowRevision), Boolean.valueOf(sendDeltas)}; try { openConnection(); write("(w(nnw))", buffer); authenticate(); SVNEditModeReader editReader = new SVNEditModeReader(myConnection, editor, true); editReader.driveEditor(); read("", null, false); } catch (SVNException e) { closeSession(); handleUnsupportedCommand(e, "Server doesn't support the replay command"); } finally { closeConnection(); } }
public void setRevisionPropertyValue(long revision, String propertyName, String propertyValue) throws SVNException { assertValidRevision(revision); Object[] buffer = new Object[] { "change-rev-prop", getRevisionObject(revision), propertyName, propertyValue }; try { openConnection(); write("(w(nss))", buffer); authenticate(); read("[()]", buffer, true); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } }
public SVNNodeKind checkPath(String path, long revision) throws SVNException { try { openConnection(); path = getRepositoryPath(path); Object[] buffer = new Object[] { "check-path", path, getRevisionObject(revision) }; write("(w(s(n)))", buffer); authenticate(); read("[(W)]", buffer, true); return SVNNodeKind.parseKind((String) buffer[0]); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } }
public void setRevisionPropertyValue(long revision, String propertyName, SVNPropertyValue propertyValue) throws SVNException { assertValidRevision(revision); byte[] bytes = SVNPropertyValue.getPropertyAsBytes(propertyValue); Object[] buffer = new Object[]{"change-rev-prop", getRevisionObject(revision), propertyName, bytes}; try { openConnection(); write("(w(nsb))", buffer); authenticate(); read("", null, false); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } }
public SVNNodeKind checkPath(String path, long revision) throws SVNException { try { openConnection(); path = getLocationRelativePath(path); Object[] buffer = new Object[]{"check-path", path, getRevisionObject(revision)}; write("(w(s(n)))", buffer); authenticate(); List values = read("w", null, false); return SVNNodeKind.parseKind(SVNReader.getString(values, 0)); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } }
public SVNNodeKind checkPath(String path, long revision) throws SVNException { try { openConnection(); path = getRepositoryPath(path); Object[] buffer = new Object[]{"check-path", path, getRevisionObject(revision)}; write("(w(s(n)))", buffer); authenticate(); List values = read("w", null, false); return SVNNodeKind.parseKind(SVNReader.getString(values, 0)); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } }
public SVNNodeKind checkPath(String path, long revision) throws SVNException { try { openConnection(); path = getRepositoryPath(path); Object[] buffer = new Object[]{"check-path", path, getRevisionObject(revision)}; write("(w(s(n)))", buffer); authenticate(); List values = read("w", null, false); return SVNNodeKind.parseKind(SVNReader.getString(values, 0)); } catch (SVNException e) { closeSession(); throw e; } finally { closeConnection(); } }