コード例 #1
0
ファイル: JazzClient.java プロジェクト: joetopshot/rtc-plugin
  /**
   * **************************************************
   *
   * <p>private Map<String, JazzChangeSet> accept(Collection<String> changeSets) throws IOException,
   * InterruptedException {
   *
   * <p>**************************************************
   */
  private Map<String, JazzChangeSet> accept(Collection<String> changeSets)
      throws IOException, InterruptedException {
    // output to console.
    PrintStream output = listener.getLogger();
    output.println("  RTC SCM - Jazz Client: Accept...");
    String version =
        getVersion(); // TODO The version should be checked when configuring the Jazz Executable

    String[] streams = configuration.getStreamNames();
    Map<String, JazzChangeSet> returnObject = new LinkedHashMap<String, JazzChangeSet>();

    for (int i = 0; i < streams.length; i++) {
      configuration.setStreamIndex(i);
      AcceptCommand cmd =
          new AcceptCommand(configuration, changeSets, version, listener, jazzExecutable);
      Map<String, JazzChangeSet> acceptResults = execute(cmd);
      // for debugging
      /*
         output.println("DEBUG: results of calling accept...");
         for (String key : acceptResults.keySet()) {
      output.println("DEBUG: accept key = " + key + ": " + acceptResults.get(key).toStringDetails());
         }
         */

      returnObject.putAll(acceptResults);
    }

    return returnObject;
  }
コード例 #2
0
ファイル: JazzClient.java プロジェクト: joetopshot/rtc-plugin
  /**
   * **************************************************
   *
   * <p>private Map<String, JazzChangeSet> compare() throws IOException, InterruptedException {
   *
   * <p>**************************************************
   */
  private Map<String, JazzChangeSet> compare() throws IOException, InterruptedException {

    PrintStream output = listener.getLogger();
    output.println("  RTC SCM - Jazz Client: compare...");

    Map<String, JazzChangeSet> returnObject = new LinkedHashMap<String, JazzChangeSet>();
    String[] streams = configuration.getStreamNames();

    for (int i = 0; i < streams.length; i++) {
      configuration.setStreamIndex(i);
      CompareCommand cmd = new CompareCommand(configuration);
      returnObject.putAll(execute(cmd));
    }

    return returnObject;
  }