public Map getCheckoutProperties()

in clearcase-server/src/jetbrains/buildServer/buildTriggers/vcs/clearcase/ClearCaseSupport.java [900:926]


  public Map<String, String> getCheckoutProperties(@NotNull final VcsRoot root) {
    final Map<String, String> result = new HashMap<String, String>(4);

    try {
      final ViewPath viewPath = getViewPath(root);

      result.put(CC_VIEW_PATH, viewPath.getClearCaseViewPath()); // normalized path
      result.put(RELATIVE_PATH, viewPath.getRelativePathWithinTheView()); // normalized path

      consumeBranches(root, new Consumer<Collection<String>>() {
        public void consume(@Nullable final Collection<String> branches) {
          if (branches == null) { // auto detecting
            result.put(BRANCH_PROVIDER, BRANCH_PROVIDER_AUTO);
          }
          else {
            result.put(BRANCH_PROVIDER, BRANCH_PROVIDER_CUSTOM);
            result.put(BRANCHES, StringUtil.join(new TreeSet<String>(branches), ",")); // join branches in nomalized order
          }
        }
      });
    }
    catch (final Exception e) {
      LOG.warnAndDebugDetails("Failed to get repository properties", e);
    }

    return result;
  }