title: Store array in a JTable column
body: <p>I would like to display the values of an array in a JTable column using a for loop.</p>
  
  <p>My code looks like this:</p>
  
  <pre><code>public class MigTable extends FormsTableModel implements XmlInterface {
  
      private Element srcDoc = null;
      private String string = null;
      private ArrayList&lt;Integer&gt;data =new ArrayList&lt;Integer&gt;(Arrays.asList(20,10,100));
  
      public MigTable(Element element, String string) {
          super(element,string);
  
      }
  
      @Override
      public Class&lt;?&gt; getColumnClass(int columnIndex) {
          switch (columnIndex){
              case 0: return  super.getColumnClass(0);
              case 1: return super.getColumnClass(1);
              case 2: return Integer.class;
              default: return Object.class;
          }
      }
  
      @Override
      public int getColumnCount() {
          return 3;
      }
  
      @Override
      public String getColumnName(int columnIndex) {
          switch(columnIndex){
              case 0: return super.getColumnName(0);
              case 1: return super.getColumnName(1);
              case 2: return "status";
          }
  
          return null;
      }
  
  
      @Override
      public Object getValueAt(int rowIndex, int columnIndex) {
              // Here I'm getting the values 
              if (columnIndex==2){
                  // I would like to do it here so that at column Index 2 has the datas
                  //from the array list 20 10 100
              }
          }
          return super.getValueAt(rowIndex, columnIndex);
      }
  
      @Override
      public boolean isCellEditable(int i, int i2) {
          // TODO Implement this method
          return false;
      }
  
      @Override
      public void setValueAt(Object aValue, int rowIndex, int columnIndex) {
          if (rowIndex &gt; getColumnName(columnIndex).length())
              throw new IllegalArgumentException ("" + rowIndex);
          super.setValueAt(aValue, rowIndex, columnIndex);
      }
  }
  </code></pre>
  
  <p>Thanks for your help</p>