title: Load arrayList data into JTable
body: <p>I'm trying to set items from a method called <code>FootballClub</code> and so far it's fine.
  but then I created an arrayList from it and I somehow can't find a way to store this information into a JTable.
  The problem is that i cant find a way to set a fixed number of rows</p>
  
  <p>Here is my code:</p>
  
  <p>Class StartLeague:</p>
  
  <pre><code>import javax.swing.*;
  import javax.swing.table.*;
  import java.awt.*;
  
  public class startLeague implements LeagueManager{
  
  //setting the frame and other components to appear
  
  public startLeague(){
      JButton createTeam = new JButton("Create Team");
      JButton deleteTeam = new JButton("Delete Team");
  
      JFrame frame = new JFrame("Premier League System");
      JPanel panel = new JPanel();
      frame.setSize(1280, 800);
      frame.setVisible(true);
      frame.add(panel);
      frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
      String col[] = {"Pos","Team","P", "W", "L", "D", "MP", "GF", "GA", "GD"};
  
      panel.setLayout(new GridLayout(20, 20));
      panel.add(createTeam);
      panel.add(deleteTeam);
      panel.add(new JLabel(""));
      //JLabels to fill the space
      }
      }
  </code></pre>
  
  <p>FootBall Club Class:</p>
  
  <pre><code>import java.util.ArrayList;
  
  
  
   public class FootballClub extends SportsClub{
  
  
  
  
  
     FootballClub(int position, String name, int points, int wins, int defeats, int draws, int totalMatches, int goalF, int goalA, int goalD){
     this.position = position;
     this.name = name;
     this.points = points;
     this.wins = wins;
     this.defeats = defeats;
     this.draws = draws;
     this.totalMatches = totalMatches;
     this.goalF = goalF;
     this.goalA = goalA;
     this.goalD = goalD;
  
     }
  </code></pre>
  
  <p>The SportsClub Class(abstract):</p>
  
  <pre><code>abstract class SportsClub {
  int position;
  String name;
  int points;
  int wins;
  int defeats;
  int draws;
  int totalMatches;
  int goalF;
  int goalA;
  int goalD;
  
  }
  </code></pre>
  
  <p>And finally, LeagueManager, which is an interface:</p>
  
  <pre><code>import java.util.ArrayList;
  
  
  public interface LeagueManager {
  ArrayList&lt;FootballClub&gt; originalLeagueTable = new ArrayList&lt;FootballClub&gt;();
  FootballClub arsenal = new FootballClub(1, "Arsenal", 35, 11, 2, 2, 15, 30, 11, 19);
  FootballClub liverpool = new FootballClub(2, "Liverpool", 30, 9, 3, 3, 15, 34, 18, 16);
  FootballClub chelsea = new FootballClub(3, "Chelsea", 30, 9, 2, 2, 15, 30, 11, 19);
  FootballClub mCity = new FootballClub(4, "Man City", 29, 9, 2, 4, 15, 41, 15, 26);
  FootballClub everton = new FootballClub(5, "Everton", 28, 7, 1, 7, 15, 23, 14, 9);
  FootballClub tot = new FootballClub(6, "Tottenham", 27, 8, 4, 3, 15, 15, 16, -1);
  FootballClub newcastle = new FootballClub(7, "Newcastle", 26, 8, 5, 2, 15, 20, 21, -1);
  FootballClub south = new FootballClub(8, "Southampton", 23, 6, 4, 5, 15, 19, 14, 5);
  
  }
  </code></pre>
  
  <p>Can somebody please help me?
  I've trying and trying for days.
  Thank you.</p>