title: gwt asyncCallback with ArrayList<SomeClass> fails when retrieving data
body: <p>I am trying to make a sample code for my further work. I am using gwt vanillia and new to gwt. My purpose is to populate some textboxes and a grid. for populating textboxes from database, no problem with rpc call. But I could'nt populate datagrid via using RPC call. I used <a href="http://altair.cs.oswego.edu/~tenberge/tenbergen.org/misc/DB-Access-in-GWT-The-Missing-Tutorial.pdf" rel="nofollow">Bastian Tenbergen's tutorial</a>
  for populating some textboxes. But when i tried to populate the grid with asyncronious callback using ArrayList, code failed. I know ArrayList is also serializable but I can't solve the issue. 
  Any advice is appreciated. 
  Here is some code for my questin.
  In server package: SqlDbConnection.java </p>
  
  <pre><code>    public ArrayList&lt;hastaGrid&gt; callGrid(String something){
      ArrayList&lt;hastaGrid&gt; list = new ArrayList&lt;hastaGrid&gt;();
      hastagrid hastaGrid = null;     
      try {
          Statement st = conn.createStatement();
          ResultSet result = st.executeQuery("select name from TEST where name = '"+ something +"'");
  
          while(result.next()) {
              hastagrid = new hastaGrid(result.getString(1), result.getString(2),result.getNString(2),result.getString(3));
              list.add(hastaGrid);
              System.out.println("result: " +hastagrid.getLogin().toString()+" " + hastagrid.getPassword() +" "+ hastagrid.getName() +" " + hastagrid.getSurname());
          }
          result.close();
          st.close();                 
      } catch (Exception e) {
          e.printStackTrace();
      }       
      return list;
  }
  </code></pre>
  
  <p>In client package: hastaGrid.java //the class also have getter and setter methods.</p>
  
  <pre><code>public class hastaGrid implements IsSerializable {
  
  private String name;
  private String surname;
  private String login;
  private String password;
  
  public hastaGrid(String name,String surname, String login, String password){
      this.setName(name);
      this.setSurname(surname);
      this.setLogin(login);
      this.setPassword(password);
  }}
  </code></pre>
  
  <p>In client package: DBConnection.java</p>
  
  <pre><code>public interface DBConnection extends RemoteService {   
  public ArrayList&lt;hastaGrid&gt; callGrid(String name);  }
  </code></pre>
  
  <p>In client package: DBConnectionAsync.java</p>
  
  <pre><code>public interface DBConnectionAsync {    
  public void callGrid(String name, AsyncCallback&lt;ArrayList&lt;hastaGrid&gt;&gt; callback);   }
  </code></pre>
  
  <p>In client package: userDetail.java</p>
  
  <p>onModuleLoad() {
          AsyncCallback> callback = new AuthenticationHandler1();
          rpc.gridGetir("John",callback);
  }</p>
  
  <pre><code>private class AuthenticationHandler&lt;T&gt; implements AsyncCallback&lt;ArrayList&lt;hastaGrid&gt;&gt;  {
      public void onFailure(Throwable ex) {
      RootPanel.get().add(new HTML("RPC call failed"));
      }
      public void onSuccess(ArrayList&lt;hastaGrid&gt; result) {        
      result.get(0).getName(); } } // I just want to reach some result here when debugging.
  </code></pre>
  
  <p>I read lots of pages on web but can't find a specific solution. I could be wrong. Thanks for responses.</p>