}
myAuthorOfInterest = getSVNEnvironment().getAuthorOfInterest();
myLogRegularExpression = getSVNEnvironment().getRegularExpression();
SVNLogClient client = getSVNEnvironment().getClientManager().getLogClient();
if (!getSVNEnvironment().isQuiet()) {
client.setEventHandler(new SVNNotifyPrinter(getSVNEnvironment()));
}
String[] revProps = null;
if (getSVNEnvironment().isXML()) {
if (!getSVNEnvironment().isIncremental()) {
printXMLHeader("log");
}
if (!getSVNEnvironment().isAllRevisionProperties() &&
getSVNEnvironment().getRevisionProperties() != null &&
!getSVNEnvironment().getRevisionProperties().isEmpty()) {
SVNProperties revPropNames = getSVNEnvironment().getRevisionProperties();
revProps = new String[revPropNames.size()];
int i = 0;
for (Iterator propNames = revPropNames.nameSet().iterator(); propNames.hasNext();) {
String propName = (String) propNames.next();
String propVal = revPropNames.getStringValue(propName);
if (propVal.length() > 0) {
SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.CL_ARG_PARSING_ERROR,
"cannot assign with 'with-revprop' option (drop the '=')");
SVNErrorManager.error(err, SVNLogType.CLIENT);
}
revProps[i++] = propName;
}
} else if (!getSVNEnvironment().isAllRevisionProperties()) {
if (!getSVNEnvironment().isQuiet()) {
revProps = new String[3];
revProps[0] = SVNRevisionProperty.AUTHOR;
revProps[1] = SVNRevisionProperty.DATE;
revProps[2] = SVNRevisionProperty.LOG;
} else {
revProps = new String[2];
revProps[0] = SVNRevisionProperty.AUTHOR;
revProps[1] = SVNRevisionProperty.DATE;
}
}
} else {
if (!getSVNEnvironment().isQuiet()) {
revProps = new String[3];
revProps[0] = SVNRevisionProperty.AUTHOR;
revProps[1] = SVNRevisionProperty.DATE;
revProps[2] = SVNRevisionProperty.LOG;
} else {
revProps = new String[2];
revProps[0] = SVNRevisionProperty.AUTHOR;
revProps[1] = SVNRevisionProperty.DATE;
}
}
if (target.isFile()) {
client.doLog(new File[] {target.getFile()}, editedRevisionRangesList, target.getPegRevision(),
getSVNEnvironment().isStopOnCopy(), getSVNEnvironment().isVerbose(),
getSVNEnvironment().isUseMergeHistory(), getSVNEnvironment().getLimit(),
revProps, this);
} else {
targets.remove(0);
String[] paths = (String[]) targets.toArray(new String[targets.size()]);
client.doLog(target.getURL(), paths, target.getPegRevision(), editedRevisionRangesList,
getSVNEnvironment().isStopOnCopy(),
getSVNEnvironment().isVerbose(),
getSVNEnvironment().isUseMergeHistory(),
getSVNEnvironment().getLimit(), revProps, this);