本文整理匯總了Java中org.tmatesoft.svn.core.SVNURL.equals方法的典型用法代碼示例。如果您正苦於以下問題:Java SVNURL.equals方法的具體用法?Java SVNURL.equals怎麽用?Java SVNURL.equals使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類org.tmatesoft.svn.core.SVNURL
的用法示例。
在下文中一共展示了SVNURL.equals方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: checkAncestry
import org.tmatesoft.svn.core.SVNURL; //導入方法依賴的package包/類
private boolean checkAncestry(final File sourceFile, final SVNURL targetUrl, final SVNRevision targetRevision) throws SvnBindException {
final Info sourceSvnInfo = myVcs.getInfo(sourceFile);
final Info targetSvnInfo = myVcs.getInfo(targetUrl, targetRevision);
if (sourceSvnInfo == null || targetSvnInfo == null) {
// cannot check
return true;
}
final SVNURL copyFromTarget = targetSvnInfo.getCopyFromURL();
final SVNURL copyFromSource = sourceSvnInfo.getCopyFromURL();
if ((copyFromSource != null) || (copyFromTarget != null)) {
if (sourceSvnInfo.getURL().equals(copyFromTarget) || targetUrl.equals(copyFromSource)) {
return true;
}
}
final int result = Messages.showYesNoDialog(myVcs.getProject(), SvnBundle.message("switch.target.not.copy.current"),
SvnBundle.message("switch.target.problem.title"), Messages.getWarningIcon());
return (Messages.YES == result);
}
示例2: possiblySwitched
import org.tmatesoft.svn.core.SVNURL; //導入方法依賴的package包/類
private void possiblySwitched(ProgressEvent event) {
final File file = event.getFile();
if (file == null) return;
final SVNURL wasUrl = myUrlToCheckForSwitch.get(file);
if (wasUrl != null && ! wasUrl.equals(event.getURL())) {
myUrlToCheckForSwitch.remove(file);
addFileToGroup(FileGroup.SWITCHED_ID, event);
}
}
示例3: textChanged
import org.tmatesoft.svn.core.SVNURL; //導入方法依賴的package包/類
protected void textChanged(final DocumentEvent e) {
SVNURL url = parseUrl(myTrunkLocationTextField.getText());
if (url != null) {
boolean isAncestor = SVNURLUtil.isAncestor(myRootUrl, url);
boolean areNotSame = isAncestor && !url.equals(myRootUrl);
if (areNotSame) {
myConfiguration.setTrunkUrl(url.toDecodedString());
}
myErrorPrompt.setText(areNotSame ? "" : SvnBundle.message("configure.branches.error.wrong.url", myRootUrl));
}
}
示例4: ask
import org.tmatesoft.svn.core.SVNURL; //導入方法依賴的package包/類
public SVNURL ask(final SVNURL url, VirtualFile file) {
for (SVNURL root : myRoots) {
if (root.equals(SVNURLUtil.getCommonURLAncestor(root, url))) {
return root;
}
}
// TODO: Seems that RepositoryRoots class should be removed. And necessary repository root should be determined explicitly
// TODO: using info command.
final SVNURL newUrl = SvnUtil.getRepositoryRoot(myVcs, new File(file.getPath()));
if (newUrl != null) {
myRoots.add(newUrl);
return newUrl;
}
return null;
}
示例5: itemSwitched
import org.tmatesoft.svn.core.SVNURL; //導入方法依賴的package包/類
private boolean itemSwitched(final ProgressEvent event) {
final File file = event.getFile();
final SvnFileUrlMapping urlMapping = myVCS.getSvnFileUrlMapping();
final SVNURL currentUrl = urlMapping.getUrlForFile(file);
return (currentUrl != null) && (! currentUrl.equals(event.getURL()));
}