/** * Returns the author of the revision that this object represents. * * @return the author of the revision */ public String getAuthor() { return myRevisionProperties.getStringValue(SVNRevisionProperty.AUTHOR); }
public String[] getMimeTypes() { String[] r = new String[2]; if (pristineProps != null) { r[0] = pristineProps.getStringValue(SVNProperty.MIME_TYPE); r[1] = r[0]; } if (propChanges != null) { r[1] = propChanges.getStringValue(SVNProperty.MIME_TYPE); } return r; } }
private String getAuthor(SVNProperties revisionProperties) { if (revisionProperties == null) { return null; } return revisionProperties.getStringValue(SVNRevisionProperty.AUTHOR); }
/** * Returns the author of the revision that this object represents. * * @return the author of the revision */ public String getAuthor() { return myRevisionProperties.getStringValue(SVNRevisionProperty.AUTHOR); }
/** * Gets the log message attached to the revision. * * @return the commit log message */ public String getMessage() { return myRevisionProperties.getStringValue(SVNRevisionProperty.LOG); }
public void receive(SvnTarget target, SVNProperties object) throws SVNException { String value = object.getStringValue(SVNProperty.EXTERNALS); if (value != null) { externals.put(target, value); } } });
private Date getDate(SVNProperties revisionProperties) { if (revisionProperties == null) { return null; } String dateString = revisionProperties.getStringValue(SVNRevisionProperty.DATE); if (dateString == null) { return null; } return SVNDate.parseDate(dateString); } }
private String getCharset(SVNProperties properties, DefaultSVNDiffGenerator generator) { if (properties == null) { return null; } String charset = properties.getStringValue(SVNProperty.CHARSET); return getCharset(charset, generator, true); }
private String getCharset(SVNProperties properties, ISvnDiffGenerator generator) { if (properties == null) { return null; } String charset = properties.getStringValue(SVNProperty.CHARSET); return getCharset(charset, generator, true); }
public String getNodeOrigin(String nodeID) throws SVNException { SVNProperties nodeOrigins = getNodeOriginsFromFile(nodeID); if (nodeOrigins != null) { return nodeOrigins.getStringValue(nodeID); } return null; }
/** * Gets the datestamp when the revision was committed. * * @return the moment in time when the revision was committed */ public Date getDate() { String date = myRevisionProperties.getStringValue(SVNRevisionProperty.DATE); return date == null ? null : SVNDate.parseDate(date); }
private String getCharset(SVNProperties properties, DefaultSVNDiffGenerator generator) { if (properties == null) { return null; } String charset = properties.getStringValue(SVNProperty.CHARSET); return getCharset(charset, generator, true); }
private void setBinary(SVNProperties props) { String mimeType = props.getStringValue(SVNProperty.MIME_TYPE); isBinary = Boolean.valueOf(SVNProperty.isBinaryMimeType(mimeType)); } });
public String getNodeOrigin(String nodeID) throws SVNException { SVNProperties nodeOrigins = getNodeOriginsFromFile(nodeID); if (nodeOrigins != null) { return nodeOrigins.getStringValue(nodeID); } return null; }
private boolean areFileContentsEqual(String path1, long rev1, String path2, long rev2, SVNProperties props2) throws SVNException { SVNProperties props1 = new SVNProperties(); props2 = props2 == null ? new SVNProperties() : props2; SVNRepository repos = getSourceRepository(); repos.getFile(path1, rev1, props1, null); repos.getFile(path2, rev2, props2, null); String crc1 = props1.getStringValue(SVNProperty.CHECKSUM); String crc2 = props2.getStringValue(SVNProperty.CHECKSUM); return crc1 != null && crc1.equals(crc2); }
private boolean areFileContentsEqual(String path1, long rev1, String path2, long rev2, SVNProperties props2) throws SVNException { SVNProperties props1 = new SVNProperties(); props2 = props2 == null ? new SVNProperties() : props2; SVNRepository repos = getSourceRepository(); repos.getFile(path1, rev1, props1, null); repos.getFile(path2, rev2, props2, null); String crc1 = props1.getStringValue(SVNProperty.CHECKSUM); String crc2 = props2.getStringValue(SVNProperty.CHECKSUM); return crc1 != null && crc1.equals(crc2); }
public FSTransactionRoot createTransactionRoot(FSTransactionInfo txn) throws SVNException { SVNProperties txnProps = getTransactionProperties(txn.getTxnId()); int flags = 0; if (txnProps.getStringValue(SVNProperty.TXN_CHECK_OUT_OF_DATENESS) != null) { flags |= FSTransactionRoot.SVN_FS_TXN_CHECK_OUT_OF_DATENESS; } if (txnProps.getStringValue(SVNProperty.TXN_CHECK_LOCKS) != null) { flags |= FSTransactionRoot.SVN_FS_TXN_CHECK_LOCKS; } return new FSTransactionRoot(this, txn.getTxnId(), txn.getBaseRevision(), flags); }
public static FSTransactionInfo beginTransactionForCommit(long baseRevision, SVNProperties revisionProperties, FSFS owner) throws SVNException { List caps = new ArrayList(); caps.add("mergeinfo"); String author = revisionProperties.getStringValue(SVNRevisionProperty.AUTHOR); FSHooks.runStartCommitHook(owner.getRepositoryRoot(), author, caps); FSTransactionInfo txn = FSTransactionRoot.beginTransaction(baseRevision, FSTransactionRoot.SVN_FS_TXN_CHECK_LOCKS, owner); owner.changeTransactionProperties(txn.getTxnId(), revisionProperties); return txn; }
private Date getRevisionTime(long revision) throws SVNException { SVNProperties revisionProperties = getRevisionProperties(revision); String timeString = revisionProperties.getStringValue(SVNRevisionProperty.DATE); if (timeString == null) { SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.FS_GENERAL, "Failed to find time on revision {0}", new Long(revision)); SVNErrorManager.error(err, SVNLogType.FSFS); } return SVNDate.parseDateString(timeString); }
@Override public ISVNEditor handleStartRevision(long revision, SVNProperties revisionProperties) throws SVNException { final CopyFromSVNEditor editor = new CopyFromSVNEditor(dstRepo.getCommitEditor(revisionProperties.getStringValue("svn:log"), null), "/", checkDelete); copyFroms.put(revision, editor); return editor; }