// Path: src/main/java/org/jboss/elasticsearch/river/sysinfo/mgm/JRMgmBaseResponse.java
// public abstract class JRMgmBaseResponse<T extends NodeJRMgmBaseResponse> extends NodesOperationResponse<T> {
// 
//   public JRMgmBaseResponse() {
// 
//   }
// 
//   public JRMgmBaseResponse(ClusterName clusterName, T[] nodes) {
//     super(clusterName, nodes);
//   }
// 
//   @Override
//   public void readFrom(StreamInput in) throws IOException {
//     super.readFrom(in);
//     nodes = newNodeResponsesArray(in.readVInt());
//     for (int i = 0; i < nodes.length; i++) {
//       T node = newNodeResponse();
//       node.readFrom(in);
//       nodes[i] = node;
//     }
//   }
// 
//   protected abstract T[] newNodeResponsesArray(int len);
// 
//   protected abstract T newNodeResponse();
// 
//   @Override
//   public void writeTo(StreamOutput out) throws IOException {
//     super.writeTo(out);
//     out.writeVInt(nodes.length);
//     for (T node : nodes) {
//       node.writeTo(out);
//     }
//   }
// 
//   /**
//    * Get response from node where running Sysinfo river instance was found.
//    * 
//    * @return response from node with river or null if no river with given name was found in any node.
//    */
//   public T getSuccessNodeResponse() {
//     if (nodes == null || nodes.length == 0)
//       return null;
// 
//     for (T resp : nodes) {
//       if (resp.riverFound) {
//         return resp;
//       }
//     }
//     return null;
//   }
// 
// }


import org.jboss.elasticsearch.river.sysinfo.mgm.JRMgmBaseResponse;
import org.elasticsearch.cluster.ClusterName;
/*
 * JBoss, Home of Professional Open Source
 * Copyright 2012 Red Hat Inc. and/or its affiliates and other contributors
 * as indicated by the @authors tag. All rights reserved.
 */
package org.jboss.elasticsearch.river.sysinfo.mgm.riverslist;


/**
 * Response with list names of all Sysinfo Rivers running in ES cluster.
 * 
 * @author Vlastimil Elias (velias at redhat dot com)
 */
public class ListRiversResponse extends JRMgmBaseResponse<NodeListRiversResponse> {

  public ListRiversResponse() {

  }

  public ListRiversResponse(ClusterName clusterName, NodeListRiversResponse[] nodes) {
    super(clusterName, nodes);
  }

// Path: src/main/java/org/jboss/elasticsearch/river/sysinfo/mgm/JRMgmBaseResponse.java
// public abstract class JRMgmBaseResponse<T extends NodeJRMgmBaseResponse> extends NodesOperationResponse<T> {
// 
//   public JRMgmBaseResponse() {
// 
//   }
// 
//   public JRMgmBaseResponse(ClusterName clusterName, T[] nodes) {
//     super(clusterName, nodes);
//   }
// 
//   @Override
//   public void readFrom(StreamInput in) throws IOException {
//     super.readFrom(in);
//     nodes = newNodeResponsesArray(in.readVInt());
//     for (int i = 0; i < nodes.length; i++) {
//       T node = newNodeResponse();
//       node.readFrom(in);
//       nodes[i] = node;
//     }
//   }
// 
//   protected abstract T[] newNodeResponsesArray(int len);
// 
//   protected abstract T newNodeResponse();
// 
//   @Override
//   public void writeTo(StreamOutput out) throws IOException {
//     super.writeTo(out);
//     out.writeVInt(nodes.length);
//     for (T node : nodes) {
//       node.writeTo(out);
//     }
//   }
// 
//   /**
//    * Get response from node where running Sysinfo river instance was found.
//    * 
//    * @return response from node with river or null if no river with given name was found in any node.
//    */
//   public T getSuccessNodeResponse() {
//     if (nodes == null || nodes.length == 0)
//       return null;
// 
//     for (T resp : nodes) {
//       if (resp.riverFound) {
//         return resp;
//       }
//     }
//     return null;
//   }
// 
// }


// Path: src/main/java/org/jboss/elasticsearch/river/sysinfo/mgm/riverslist/ListRiversResponse.java
import org.jboss.elasticsearch.river.sysinfo.mgm.JRMgmBaseResponse;
import org.elasticsearch.cluster.ClusterName;

/*
 * JBoss, Home of Professional Open Source
 * Copyright 2012 Red Hat Inc. and/or its affiliates and other contributors
 * as indicated by the @authors tag. All rights reserved.
 */
package org.jboss.elasticsearch.river.sysinfo.mgm.riverslist;


/**
 * Response with list names of all Sysinfo Rivers running in ES cluster.
 * 
 * @author Vlastimil Elias (velias at redhat dot com)
 */
public class ListRiversResponse extends JRMgmBaseResponse<NodeListRiversResponse> {

  public ListRiversResponse() {

  }

  public ListRiversResponse(ClusterName clusterName, NodeListRiversResponse[] nodes) {
    super(clusterName, nodes);
  }

  @Override