/** * Begins an XML tree with the target path/URL for which * annotating is run. * * @param pathOrURL a target file WC path or URL */ public void startTarget(String pathOrURL) { myLineNumber = 1; try { addAttribute(PATH_ATTR, pathOrURL); openTag(TARGET_TAG); } catch (SAXException e) { getDebugLog().logSevere(SVNLogType.DEFAULT, e); } }
/** * Closes the formatted XML output. * */ public void endTarget() { myLineNumber = 1; try { closeTag(TARGET_TAG); } catch (SAXException e) { getDebugLog().logSevere(SVNLogType.DEFAULT, e); } }
public void handleLine(Date date, long revision, String author, String line) throws SVNException { try { addAttribute(LINE_NUMBER_TAG, myLineNumber + ""); openTag(ENTRY_TAG); if (revision >= 0) { addAttribute(REVISION_ATTR, revision + ""); openTag(COMMIT_TAG); addTag(AUTHOR_TAG, author); addTag(DATE_TAG, SVNTimeUtil.formatDate(date)); closeTag(COMMIT_TAG); } closeTag(ENTRY_TAG); } catch (SAXException e) { getDebugLog().error(e); SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.XML_MALFORMED, e.getLocalizedMessage()); SVNErrorManager.error(err, e); } finally { myLineNumber++; } } }
String mergedPath, int lineNumber) throws SVNException { try { addAttribute(LINE_NUMBER_TAG, ++lineNumber + ""); openTag(ENTRY_TAG); if (revision >= 0) { addAttribute(REVISION_ATTR, revision + ""); openTag(COMMIT_TAG); addTag(AUTHOR_TAG, author); addTag(DATE_TAG, SVNDate.formatDate(date)); closeTag(COMMIT_TAG); addAttribute(PATH_ATTR, mergedPath); openTag(MERGED_TAG); addAttribute(REVISION_ATTR, mergedRevision + ""); openTag(COMMIT_TAG); addTag(AUTHOR_TAG, mergedAuthor); addTag(DATE_TAG, SVNDate.formatDate(mergedDate)); closeTag(COMMIT_TAG); closeTag(MERGED_TAG); closeTag(ENTRY_TAG); } catch (SAXException e) { getDebugLog().logSevere(SVNLogType.DEFAULT, e); SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.XML_MALFORMED, e.getLocalizedMessage()); SVNErrorManager.error(err, e, SVNLogType.DEFAULT);
/** * Handles line annotation producing corresponding xml tags. * * @param date * @param revision * @param author * @param line * @throws SVNException */ public void handleLine(Date date, long revision, String author, String line) throws SVNException { try { addAttribute(LINE_NUMBER_TAG, myLineNumber + ""); openTag(ENTRY_TAG); if (revision >= 0) { addAttribute(REVISION_ATTR, revision + ""); openTag(COMMIT_TAG); addTag(AUTHOR_TAG, author); addTag(DATE_TAG, SVNDate.formatDate(date)); closeTag(COMMIT_TAG); } closeTag(ENTRY_TAG); } catch (SAXException e) { getDebugLog().logSevere(SVNLogType.DEFAULT, e); SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.XML_MALFORMED, e.getLocalizedMessage()); SVNErrorManager.error(err, e, SVNLogType.DEFAULT); } finally { myLineNumber++; } }
/** * Begins an XML tree with the target path/URL for which * annotating is run. * * @param pathOrURL a target file WC path or URL */ public void startTarget(String pathOrURL) { myLineNumber = 1; try { addAttribute(PATH_ATTR, pathOrURL); openTag(TARGET_TAG); } catch (SAXException e) { getDebugLog().logSevere(SVNLogType.DEFAULT, e); } }
/** * Closes the formatted XML output. * */ public void endTarget() { myLineNumber = 1; try { closeTag(TARGET_TAG); } catch (SAXException e) { getDebugLog().logSevere(SVNLogType.DEFAULT, e); } }
String mergedPath, int lineNumber) throws SVNException { try { addAttribute(LINE_NUMBER_TAG, ++lineNumber + ""); openTag(ENTRY_TAG); if (revision >= 0) { addAttribute(REVISION_ATTR, revision + ""); openTag(COMMIT_TAG); addTag(AUTHOR_TAG, author); addTag(DATE_TAG, SVNDate.formatDate(date)); closeTag(COMMIT_TAG); addAttribute(PATH_ATTR, mergedPath); openTag(MERGED_TAG); addAttribute(REVISION_ATTR, mergedRevision + ""); openTag(COMMIT_TAG); addTag(AUTHOR_TAG, mergedAuthor); addTag(DATE_TAG, SVNDate.formatDate(mergedDate)); closeTag(COMMIT_TAG); closeTag(MERGED_TAG); closeTag(ENTRY_TAG); } catch (SAXException e) { getDebugLog().logSevere(SVNLogType.DEFAULT, e); SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.XML_MALFORMED, e.getLocalizedMessage()); SVNErrorManager.error(err, e, SVNLogType.DEFAULT);
/** * Begins an XML tree with the target path/URL for which * annotating is run. * * @param pathOrURL a target file WC path or URL */ public void startTarget(String pathOrURL) { myLineNumber = 1; try { addAttribute(PATH_ATTR, pathOrURL); openTag(TARGET_TAG); } catch (SAXException e) { getDebugLog().logSevere(SVNLogType.DEFAULT, e); } }
/** * Closes the formatted XML output. * */ public void endTarget() { myLineNumber = 1; try { closeTag(TARGET_TAG); } catch (SAXException e) { getDebugLog().logSevere(SVNLogType.DEFAULT, e); } }
/** * Handles line annotation producing corresponding xml tags. * * @param date * @param revision * @param author * @param line * @throws SVNException */ public void handleLine(Date date, long revision, String author, String line) throws SVNException { try { addAttribute(LINE_NUMBER_TAG, myLineNumber + ""); openTag(ENTRY_TAG); if (revision >= 0) { addAttribute(REVISION_ATTR, revision + ""); openTag(COMMIT_TAG); addTag(AUTHOR_TAG, author); addTag(DATE_TAG, SVNDate.formatDate(date)); closeTag(COMMIT_TAG); } closeTag(ENTRY_TAG); } catch (SAXException e) { getDebugLog().logSevere(SVNLogType.DEFAULT, e); SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.XML_MALFORMED, e.getLocalizedMessage()); SVNErrorManager.error(err, e, SVNLogType.DEFAULT); } finally { myLineNumber++; } }
/** * Begins an XML tree with the target path/URL for which * annotating is run. * * @param pathOrURL a target file WC path or URL */ public void startTarget(String pathOrURL) { myLineNumber = 1; try { addAttribute(PATH_ATTR, pathOrURL); openTag(TARGET_TAG); } catch (SAXException e) { getDebugLog().error(e); } }
/** * Closes the formatted XML output. * */ public void endTarget() { myLineNumber = 1; try { closeTag(TARGET_TAG); } catch (SAXException e) { getDebugLog().error(e); } }
/** * Handles line annotation producing corresponding xml tags. * * @param date * @param revision * @param author * @param line * @throws SVNException */ public void handleLine(Date date, long revision, String author, String line) throws SVNException { try { addAttribute(LINE_NUMBER_TAG, myLineNumber + ""); openTag(ENTRY_TAG); if (revision >= 0) { addAttribute(REVISION_ATTR, revision + ""); openTag(COMMIT_TAG); addTag(AUTHOR_TAG, author); addTag(DATE_TAG, SVNDate.formatDate(date)); closeTag(COMMIT_TAG); } closeTag(ENTRY_TAG); } catch (SAXException e) { getDebugLog().logSevere(SVNLogType.DEFAULT, e); SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.XML_MALFORMED, e.getLocalizedMessage()); SVNErrorManager.error(err, e, SVNLogType.DEFAULT); } finally { myLineNumber++; } }
String mergedPath, int lineNumber) throws SVNException { try { addAttribute(LINE_NUMBER_TAG, ++lineNumber + ""); openTag(ENTRY_TAG); if (revision >= 0) { addAttribute(REVISION_ATTR, revision + ""); openTag(COMMIT_TAG); addTag(AUTHOR_TAG, author); addTag(DATE_TAG, SVNDate.formatDate(date)); closeTag(COMMIT_TAG); addAttribute(PATH_ATTR, mergedPath); openTag(MERGED_TAG); addAttribute(REVISION_ATTR, mergedRevision + ""); openTag(COMMIT_TAG); addTag(AUTHOR_TAG, mergedAuthor); addTag(DATE_TAG, SVNDate.formatDate(mergedDate)); closeTag(COMMIT_TAG); closeTag(MERGED_TAG); closeTag(ENTRY_TAG); } catch (SAXException e) { getDebugLog().logSevere(SVNLogType.DEFAULT, e); SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.XML_MALFORMED, e.getLocalizedMessage()); SVNErrorManager.error(err, e, SVNLogType.DEFAULT);