/** * Returns an instance of the {@link SVNDiffClient} class. * * <p> * If it's the first time this method is being called the object is * created, initialized and then returned. Further calls to this * method will get the same object instantiated at that moment of * the first call. <b>SVNClientManager</b> does not reinstantiate * its <b>SVN</b>*<b>Client</b> objects. * * @return an <b>SVNDiffClient</b> instance */ public SVNDiffClient getDiffClient() { if (myDiffClient == null) { myDiffClient = new SVNDiffClient(this, myOptions); myDiffClient.setEventHandler(myEventHandler); myDiffClient.setDebugLog(getDebugLog()); } return myDiffClient; }
/** * Returns an instance of the {@link SVNDiffClient} class. * * <p> * If it's the first time this method is being called the object is * created, initialized and then returned. Further calls to this * method will get the same object instantiated at that moment of * the first call. <b>SVNClientManager</b> does not reinstantiate * its <b>SVN</b>*<b>Client</b> objects. * * @return an <b>SVNDiffClient</b> instance */ public SVNDiffClient getDiffClient() { if (myDiffClient == null) { myDiffClient = new SVNDiffClient(this, myOptions); myDiffClient.setEventHandler(myEventHandler); myDiffClient.setDebugLog(getDebugLog()); myDiffClient.setIgnoreExternals(myIsIgnoreExternals); } return myDiffClient; }
/** * Returns an instance of the {@link SVNDiffClient} class. * * <p> * If it's the first time this method is being called the object is * created, initialized and then returned. Further calls to this * method will get the same object instantiated at that moment of * the first call. <b>SVNClientManager</b> does not reinstantiate * its <b>SVN</b>*<b>Client</b> objects. * * @return an <b>SVNDiffClient</b> instance */ public SVNDiffClient getDiffClient() { if (myDiffClient == null) { myDiffClient = new SVNDiffClient(this, myOptions); myDiffClient.setEventHandler(myEventHandler); myDiffClient.setDebugLog(getDebugLog()); myDiffClient.setIgnoreExternals(myIsIgnoreExternals); } return myDiffClient; }
javaRepo.getClientManager().getDiffClient().setEventHandler( handler ); javaRepo.getClientManager().getDiffClient().setEventHandler( null );
public void run() throws SVNException { final List targets = getSVNEnvironment().combineTargets(getSVNEnvironment().getTargets(), true); final int targetsCount = targets.size(); if (targetsCount < 1 || targetsCount > 2) { SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.CL_ARG_PARSING_ERROR); SVNErrorManager.error(err, SVNLogType.CLIENT); } final SVNDiffClient client = getSVNEnvironment().getClientManager().getDiffClient(); SVNNotifyPrinter printer = new SVNNotifyPrinter(getSVNEnvironment()); if (!getSVNEnvironment().isQuiet()) { client.setEventHandler(printer); } final File patchPath = new File((String) targets.get(0)); final File targetPath = new File(targetsCount != 2 ? "." : (String) targets.get(1)); try { client.doPatch(patchPath.getAbsoluteFile(), targetPath.getAbsoluteFile(), getSVNEnvironment().isDryRun(), getSVNEnvironment().getStripCount(), getSVNEnvironment().isIgnoreWhitespace(), true, getSVNEnvironment().isReverseDiff()); } catch (SVNException e) { getSVNEnvironment().handleWarning(e.getErrorMessage(), new SVNErrorCode[] { SVNErrorCode.ENTRY_EXISTS, SVNErrorCode.WC_PATH_NOT_FOUND }, getSVNEnvironment().isQuiet()); } finally { if (!getSVNEnvironment().isQuiet()) { StringBuffer status = new StringBuffer(); printer.printConflictStatus(status); getSVNEnvironment().getOut().print(status); } } }
public void run() throws SVNException { final List targets = getSVNEnvironment().combineTargets(getSVNEnvironment().getTargets(), true); final int targetsCount = targets.size(); if (targetsCount < 1 || targetsCount > 2) { SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.CL_ARG_PARSING_ERROR); SVNErrorManager.error(err, SVNLogType.CLIENT); } final SVNDiffClient client = getSVNEnvironment().getClientManager().getDiffClient(); SVNNotifyPrinter printer = new SVNNotifyPrinter(getSVNEnvironment()); if (!getSVNEnvironment().isQuiet()) { client.setEventHandler(printer); } final File patchPath = new File((String) targets.get(0)); final File targetPath = new File(targetsCount != 2 ? "." : (String) targets.get(1)); try { client.doPatch(patchPath.getAbsoluteFile(), targetPath.getAbsoluteFile(), getSVNEnvironment().isDryRun(), getSVNEnvironment().getStripCount(), getSVNEnvironment().isIgnoreWhitespace(), true, getSVNEnvironment().isReverseDiff()); } catch (SVNException e) { getSVNEnvironment().handleWarning(e.getErrorMessage(), new SVNErrorCode[] { SVNErrorCode.ENTRY_EXISTS, SVNErrorCode.WC_PATH_NOT_FOUND }, getSVNEnvironment().isQuiet()); } finally { if (!getSVNEnvironment().isQuiet()) { StringBuffer status = new StringBuffer(); printer.printConflictStatus(status); getSVNEnvironment().getOut().print(status); } } }
myDiffClient.setEventHandler(handler);
myDiffClient.setEventHandler(handler);
myDiffClient.setEventHandler(handler);
myDiffClient.setEventHandler(handler);
SVNDiffClient client = getSVNEnvironment().getClientManager().getDiffClient(); final SVNNotifyPrinter printer = new SVNNotifyPrinter(getSVNEnvironment()); client.setEventHandler(printer); SvnOperationFactory of = client.getOperationsFactory(); SVNDepth depth = getSVNEnvironment().getDepth();
SVNDiffClient client = getSVNEnvironment().getClientManager().getDiffClient(); final SVNNotifyPrinter printer = new SVNNotifyPrinter(getSVNEnvironment()); client.setEventHandler(printer); SvnOperationFactory of = client.getOperationsFactory(); SVNDepth depth = getSVNEnvironment().getDepth();
client.setEventHandler(printer); SVNCommandEnvironment environment = (SVNCommandEnvironment) getEnvironment(); client.setShowCopiesAsAdds(environment.isShowCopiesAsAdds());
SVNNotifyPrinter printer = new SVNNotifyPrinter(getSVNEnvironment()); if (!getSVNEnvironment().isQuiet()) { client.setEventHandler(printer);
SVNNotifyPrinter printer = new SVNNotifyPrinter(getSVNEnvironment()); if (!getSVNEnvironment().isQuiet()) { client.setEventHandler(printer);
client.setEventHandler(printer); SVNCommandEnvironment environment = (SVNCommandEnvironment) getEnvironment(); client.setShowCopiesAsAdds(environment.isShowCopiesAsAdds());