title: Printing all children into RecyclerView
body: <p>I am writing a simple program that stores the amount of formula drank each day.</p>
  
  <pre><code>private final String date = new SimpleDateFormat("dd-MM-yyyy", Locale.getDefault()).format(new Date());
  FirebaseAuth fAuth = FirebaseAuth.getInstance();
  private DatabaseReference feedRecordsDatabase = FirebaseDatabase.getInstance().getReference().child(fAuth.getCurrentUser().getUid()).child("feedRecords").child(date);
  </code></pre>
  
  <p>As you can see each time I save a record it will save will the date as the child of Feed Records</p>
  
  <p><a href="https://i.stack.imgur.com/teGOe.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/teGOe.png" alt="Firebase"></a></p>
  
  <p>Annoyingly I've only done one for today hence why there's only one date present</p>
  
  <p>I want to print out each date that appears into a RecyclerView</p>
  
  <p>(afterwards im going to make them clickable to go in and view the records) </p>
  
  <pre><code> databaseReference = FirebaseDatabase.getInstance().getReference().child(fAuth.getCurrentUser().getUid()).child("feedRecords");
  
  
      options = new FirebaseRecyclerOptions.Builder&lt;Records&gt;().setQuery(databaseReference,Records.class).build();
  
      adapter = new FirebaseRecyclerAdapter&lt;Records, RecordsViewHolder&gt;(options) {
          @Override
          protected void onBindViewHolder(@NonNull RecordsViewHolder holder, int position, @NonNull Records model) {
  
  
          }
  
          @NonNull
          @Override
          public RecordsViewHolder onCreateViewHolder(@NonNull ViewGroup viewGroup, int i) {
  
              View view = LayoutInflater.from(viewGroup.getContext()).inflate(R.layout.saved_records_view,viewGroup,false);
  
              return new RecordsViewHolder(view);
          }
      };
      GridLayoutManager gridLayoutManager = new GridLayoutManager(getApplicationContext(),1);
      recyclerView.setLayoutManager(gridLayoutManager);
      adapter.startListening();
      recyclerView.setAdapter(adapter);
  }
  </code></pre>
  
  <p>I am struggling to find a way to print all the children of feed records into my recyclerView, I believe the code I need is to go into onBindViewHolder</p>
  
  <p>For instance I would like the recyclerview to only populate with 04-02-2019 at the moment, but if I where to add more records in upcoming days it would populate with these days also</p>
  
  <p>I'm struggling to reference this child as it will change daily</p>
  
  <p>Any help is greatly appreciated, if I haven't explained clearly please let me know so I can clarify</p>
  
  <p>Records.java</p>
  
  <pre><code>package com.example.lewisthompson.childcareapplication;
  
  public class Records {
  public String timestamp;
  
  public Records(){
  
  }
  
  public Records(String timestamp) {
      this.timestamp = timestamp;
  }
  
  public String getTimestamp() {
      return timestamp;
  }
  
  public void setTimestamp(String timestamp) {
      this.timestamp = timestamp;
  }
  </code></pre>
  
  <p>}</p>
  
  <p>RecordsViewHolder.java</p>
  
  <pre><code>package com.example.lewisthompson.childcareapplication;
  
  import android.support.annotation.NonNull;
  import android.support.v7.widget.RecyclerView;
  import android.view.View;
  import android.widget.TextView;
  
  public class RecordsViewHolder extends RecyclerView.ViewHolder {
  TextView t1;
  
  public RecordsViewHolder(@NonNull View itemView) {
      super(itemView);
      t1 = itemView.findViewById(R.id.record_date);
  }
  }
  </code></pre>