@Nullable
 public FilePath getFilePath(final SvnVcs vcs) {
   if (!myHadChanged) return null;
   final SvnFileUrlMapping svnFileUrlMapping = vcs.getSvnFileUrlMapping();
   final String absolutePath = SVNPathUtil.append(myRepositoryRoot, myCurrentPath);
   final String localPath = svnFileUrlMapping.getLocalPath(absolutePath);
   if (localPath == null) {
     LOG.info("Cannot find local path for url: " + absolutePath);
     return null;
   }
   return new FilePathImpl(new File(localPath), false);
 }
예제 #2
0
  /**
   * Returns real working copies roots - if there is <Project Root> -> Subversion setting, and there
   * is one working copy, will return one root
   */
  public List<WCInfo> getAllWcInfos() {
    final SvnFileUrlMapping urlMapping = getSvnFileUrlMapping();

    final List<RootUrlInfo> infoList = urlMapping.getAllWcInfos();
    final List<WCInfo> infos = new ArrayList<WCInfo>();
    for (RootUrlInfo info : infoList) {
      final File file = info.getIoFile();
      infos.add(
          new WCInfo(
              file.getAbsolutePath(),
              info.getAbsoluteUrlAsUrl(),
              info.getFormat(),
              info.getRepositoryUrl(),
              SvnUtil.isWorkingCopyRoot(file),
              info.getType(),
              SvnUtil.getDepth(this, file)));
    }
    return infos;
  }