Advertisement
Guest User

Untitled

a guest
Nov 23rd, 2014
153
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.77 KB | None | 0 0
  1. /** Main method
  2. *
  3. * @param args args[0] should be the name of the IManager class and args[1] the name of a file containing the list of players or teams, one per line
  4. *
  5. * @throws FileNotFoundException thrown if the list file isn't found
  6. */
  7. public static void main(String[] args) throws FileNotFoundException {
  8. if (args.length!=2) {
  9. System.out.println("Usage: CompetitionManager <IManager class name> <list file> ");
  10. System.exit(0);
  11. }
  12. IManager manager = IManagerFactory.getManager(args[0]);
  13. if (manager==null) {
  14. System.out.println("Can't find IManager class name: " + args[0]);
  15. System.exit(0);
  16. }
  17. ArrayList<String> competitors = readPlayers(args[1]);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement