clean structure
This commit is contained in:
18
DEV/DEV3.1/TP_JDBC/Exercise1/Main.java
Normal file
18
DEV/DEV3.1/TP_JDBC/Exercise1/Main.java
Normal file
@@ -0,0 +1,18 @@
|
||||
public class Main {
|
||||
|
||||
public static void main(String[] args) {
|
||||
Database database = new Database();
|
||||
|
||||
Votes votesForItaly = database.getVotesFromCompetitor("Pays-Bas");
|
||||
|
||||
System.out.println("Vote " + votesForItaly.getCompetitorName() + " :");
|
||||
for(Vote vote : votesForItaly.getVoters()) {
|
||||
System.out.println(vote.getVoterName() + " " + vote.getPoints());
|
||||
}
|
||||
|
||||
System.out.println("-------------------");
|
||||
System.out.println("Total " + votesForItaly.getTotalPoints());
|
||||
|
||||
database.close();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user