title: Getting values from RecyclerView EditText?
body: <p>I am struck in recyclerView,</p>
  
  <p><img src="https://i.stack.imgur.com/YpiIU.png" alt="image"></p>
  
  <p>Here the name and balance fields are coming from two different arrays.
  What I need is, here each row has an EditText field. I need to access each EditText on each row. And get values from it.. and a total is displayed on the Total textView. Is it possible? I tried a lot. I didn't get it.</p>
  
  <p>i am attaching my classes here.</p>
  
  <p><strong>MainActivity</strong></p>
  
  <pre><code>public class GroupCollectionFragment extends Fragment {
  String[] nameArray = {"Akhil","Mohan","Anoop","Syam","Athul","Anish","Anand","Prasad","Mani","Oommen"
          ,"Akhil","Mohan","Anoop","Syam","Athul","Anish","Anand","Prasad","Mani","Oommen"
          ,"Akhil","Mohan","Anoop","Syam","Athul","Anish","Anand","Prasad","Mani","Oommen"};
  String[] balanceArray={"2354","6578","2345","34654","2542","2354","6578","2345","34654","2542"
          ,"2354","6578","2345","34654","2542","2354","6578","2345","34654","2542"
          ,"2354","6578","2345","34654","2542","2354","6578","2345","34654","2542"};
  RecyclerView mRecyclerView;
  RecyclerView.Adapter mAdapter;
  LinearLayoutManager mLayoutManager;
  List&lt;DataHolder&gt; holderList=new ArrayList&lt;DataHolder&gt;();
  
  @Override
  public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
      View rootview=inflater.inflate(R.layout.group_collection_layout,container,false);
      mRecyclerView = (RecyclerView) rootview.findViewById(R.id.my_recycler_view);
      mRecyclerView.setHasFixedSize(true);
      mLayoutManager = new LinearLayoutManager(getContext());
      mRecyclerView.setLayoutManager(mLayoutManager);
      setItems();
      mAdapter = new Adapter(holderList);
      mRecyclerView.setAdapter(mAdapter);
      return rootview;
  }
  
  private void setItems() {
  
      for(int i=0;i&lt;nameArray.length;i++){
          DataHolder item=new DataHolder();
          item.setDname(nameArray[i]);
          item.setDbalance(balanceArray[i]);
          holderList.add(item);
      }
  }
  </code></pre>
  
  <p>}</p>
  
  <p><strong>DataHolder</strong></p>
  
  <pre><code>public class DataHolder {
  
  String dname,dbalance;
  public DataHolder(){
  }
  public String getDname(){
      return dname;
  }
  public void setDname(String name){
      this.dname=name;
  }
  public String getDbalance(){
      return dbalance;
  }
  public void setDbalance(String balance){
      this.dbalance=balance;
  }
  </code></pre>
  
  <p>}</p>
  
  <p><strong>Adapter</strong></p>
  
  <pre><code>public class Adapter extends RecyclerView.Adapter&lt;Adapter.ViewHolder&gt; {
  private List&lt;DataHolder&gt; mDataSet;
  
  public static class ViewHolder extends RecyclerView.ViewHolder{
      private TextView anameTxtView,abalanceTxtView;
      private EditText adepositEditText;
      public ViewHolder(View v){
          super(v);
          anameTxtView=(TextView)v.findViewById(R.id.nameTextView);
          abalanceTxtView=(TextView)v.findViewById(R.id.balanceTextView);
          adepositEditText=(EditText)v.findViewById(R.id.depositEditText);
      }
  }
  
  public Adapter(List&lt;DataHolder&gt; myData){
      mDataSet=myData;
  }
  
  @Override
  public ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
      View v=LayoutInflater.from(parent.getContext()).inflate(R.layout.row_main,parent,false);
      ViewHolder vh=new ViewHolder(v);
      return vh;
  }
  
  @Override
  public void onBindViewHolder(ViewHolder holder, int position) {
      holder.anameTxtView.setText(mDataSet.get(position).getDname());
      holder.abalanceTxtView.setText(mDataSet.get(position).getDbalance());
  
  
  }
  
  @Override
  public int getItemCount() {
      return mDataSet.size();
  }
  
  @Override
  public int getItemViewType(int position) {
      return position;
  }
  </code></pre>
  
  <p>}</p>