title: NumberPicker with arraylist
body: <p>I am trying to add a list of data within a numberpicker. I am using the library of: <a href="https://github.com/ShawnLin013/NumberPicker" rel="nofollow noreferrer">https://github.com/ShawnLin013/NumberPicker</a> for the numberpicker.</p>
  
  <p><strong>This is how it appears in my app:</strong></p>
  
  <p><img src="https://i.stack.imgur.com/kuE70.png" alt="Image NumberPicker"></p>
  
  <p><em>As you can see it appears with [ ] at its sides and separated by a comma, how can I eliminate that? I guess that's the problem.</em></p>
  
  <p>I'm getting the information from the FIREBASE database.</p>
  
  <p><strong>My code:</strong></p>
  
  <pre><code>IList = new ArrayList&lt;&gt;();
  DatabaseReference reference = FirebaseDatabase.getInstance().getReference("Information").child( uploads.getIdPost() )
          .child("CBS1");
  
  reference.addValueEventListener(new ValueEventListener() {
      @Override
      public void onDataChange(DataSnapshot dataSnapshot) {
          IList.clear();
          for (DataSnapshot snapshot : dataSnapshot.getChildren()){
              IList.add(snapshot.getKey());
  
              String[] data = {String.valueOf( IList )};
              numberPicker.setMinValue(data.length);
              numberPicker.setMaxValue(data.length);
              numberPicker.setDisplayedValues(data);
              numberPicker.setValue(data.length);
              numberPicker.setWrapSelectorWheel(false);
          }
      }
  </code></pre>