當前位置: 首頁>>代碼示例>>Java>>正文


Java SVNURL.equals方法代碼示例

本文整理匯總了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);
}
 
開發者ID:jskierbi,項目名稱:intellij-ce-playground,代碼行數:23,代碼來源:SvnUpdateEnvironment.java

示例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);
  }
}
 
開發者ID:jskierbi,項目名稱:intellij-ce-playground,代碼行數:10,代碼來源:UpdateEventHandler.java

示例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));
  }
}
 
開發者ID:jskierbi,項目名稱:intellij-ce-playground,代碼行數:14,代碼來源:BranchConfigurationDialog.java

示例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;
}
 
開發者ID:jskierbi,項目名稱:intellij-ce-playground,代碼行數:16,代碼來源:SvnRootsDetector.java

示例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()));
}
 
開發者ID:jskierbi,項目名稱:intellij-ce-playground,代碼行數:7,代碼來源:UpdateEventHandler.java


注:本文中的org.tmatesoft.svn.core.SVNURL.equals方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。