title: change column names after refreshing JTable java
body: <p>I dont know why column names are named "A","B","C" ... after refreshing JTable.</p>
  
  <p>I created a class to refresh JTable.</p>
  
  <pre><code>public class TableModelClass extends AbstractTableModel
  {
      Object[][] data;
      Object[] title;
  
  public TableModelClass(Object[][] dat, Object[] tit)
  {
      data = dat;
      title = tit;    
  }
  
  @Override
  public int getColumnCount()
  {
      if(title != null)
          return title.length;
      return 0;
  }
  
  @Override
  public int getRowCount()
  {
      if(data != null)
          return data.length;
      return 0;
  }
  
  @Override
  public Object getValueAt(int rowIndex, int columnIndex)
  {
      return data[rowIndex][columnIndex];
  }
  </code></pre>
  
  <p>}</p>
  
  <p>I set JTables values default in my class:</p>
  
  <pre><code>Object[] titlesDefault = { "tit1", "tit12","tit3"};
  Object[][] dataDefault = {{ "1", "2","3"},
              {"1", "2","3"}};
  
  
         _jTable = new JTable(dataDefault, titlesDefault);    
  
  _bAddTable.addActionListener(new ActionListener()
      {           
          @Override
          public void actionPerformed(ActionEvent arg0)
          {
                  try
                  {
                  Object[] titles2 = { "1", "2","3", "1", "2","3"};
                  Object[][] data = {{ "1", "2","3"},
                                     { "1", "2","3"},
                         {"1", "2","3"}};
                  data.setModel(new TableModelClass(data, titles2));
                  } 
                  catch (ClassNotFoundException)
                  {
  
                      e1.printStackTrace();
                  }               
  
           };
          });
  </code></pre>
  
  <p>And after this I receive letters in column names. Why?</p>