Skip to content
Snippets Groups Projects
Commit e994510f authored by Jakob Behrens's avatar Jakob Behrens
Browse files

Wrote documentation

parent 9d98c933
No related branches found
No related tags found
No related merge requests found
......@@ -10,7 +10,6 @@ import java.io.IOException;
import java.nio.file.Path;
//TODO: I have no idea what i am doing
/**
* Controller for the Bracket View GUI. Handles all user interaction with the GUI.
......@@ -67,9 +66,10 @@ public class BracketViewController extends TournamentController {
tableTennisApplication.changeScene("tournament-view.fxml");
}
//Input all players, place them in a list, play all the matches, loser gets deleted
//Do it again till you reach the winner
//Need to go but should be a relatively simple task, and switch all the places to labels or non editable textfields
/**
* Adds players with the names given in the textfields to a register handled in the BracketviewController
* Also clears the register before it adds as an extra security step
*/
public void onPressAdd() {
if(textFieldPlayer1.getText().isBlank() || textFieldPlayer2.getText().isBlank()) {
Alert alert = new Alert(Alert.AlertType.WARNING);
......@@ -108,6 +108,9 @@ public class BracketViewController extends TournamentController {
}
}
/**
* Loads from the NEWTOURNAMENT.csv file, proceeds to the first game
*/
public void onPressLoad() {
try
{
......@@ -125,6 +128,10 @@ public class BracketViewController extends TournamentController {
}
}
/**
* Proceeds to the match
* @throws IOException
*/
public void onPressPlay() throws IOException{
TableTennisApplication tableTennisApplication = new TableTennisApplication();
tableTennisApplication.changeScene("create-tournament-match.fxml");
......
......@@ -9,7 +9,6 @@ import java.io.IOException;
import java.nio.file.Path;
//TODO: I have no idea what i am doing
/**
* Controller for the Bracket View GUI. Handles all user interaction with the GUI.
......@@ -100,9 +99,10 @@ public class BracketViewController32 extends TournamentController {
tableTennisApplication.changeScene("tournament-view.fxml");
}
//Input all players, place them in a list, play all the matches, loser gets deleted
//Do it again till you reach the winner
//Need to go but should be a relatively simple task, and switch all the places to labels or non editable textfields
/**
* Adds players with the names given in the textfields to a register handled in the BracketviewController
* Also clears the register before it adds as an extra security step
*/
public void onPressAdd() {
if(textFieldPlayer1.getText().isBlank() || textFieldPlayer2.getText().isBlank()) {
Alert alert = new Alert(Alert.AlertType.WARNING);
......@@ -157,6 +157,9 @@ public class BracketViewController32 extends TournamentController {
}
}
/**
* Loads from the NEWTOURNAMENT.csv file, proceeds to the first game
*/
public void onPressLoad() {
try
{
......@@ -174,6 +177,10 @@ public class BracketViewController32 extends TournamentController {
}
}
/**
* Proceeds to the match
* @throws IOException
*/
public void onPressPlay() throws IOException{
TableTennisApplication tableTennisApplication = new TableTennisApplication();
tableTennisApplication.changeScene("create-tournament-match.fxml");
......
......@@ -9,7 +9,6 @@ import java.io.IOException;
import java.nio.file.Path;
//TODO: I have no idea what i am doing
/**
* Controller for the Bracket View GUI. Handles all user interaction with the GUI.
......@@ -41,9 +40,11 @@ public class BracketViewController4 extends TournamentController {
tableTennisApplication.changeScene("tournament-view.fxml");
}
//Input all players, place them in a list, play all the matches, loser gets deleted
//Do it again till you reach the winner
//Need to go but should be a relatively simple task, and switch all the places to labels or non editable textfields
/**
* Adds players with the names given in the textfields to a register handled in the BracketviewController
* Also clears the register before it adds as an extra security step
*/
public void onPressAdd() {
if(textFieldPlayer1.getText().isBlank() || textFieldPlayer2.getText().isBlank()) {
Alert alert = new Alert(Alert.AlertType.WARNING);
......@@ -71,6 +72,9 @@ public class BracketViewController4 extends TournamentController {
}
}
/**
* Loads from the NEWTOURNAMENT.csv file, proceeds to the first game
*/
public void onPressLoad() {
try
{
......@@ -88,6 +92,10 @@ public class BracketViewController4 extends TournamentController {
}
}
/**
* Proceeds to the match
* @throws IOException
*/
public void onPressPlay() throws IOException{
TableTennisApplication tableTennisApplication = new TableTennisApplication();
tableTennisApplication.changeScene("create-tournament-match.fxml");
......
......@@ -9,7 +9,6 @@ import java.io.IOException;
import java.nio.file.Path;
//TODO: I have no idea what i am doing
/**
* Controller for the Bracket View GUI. Handles all user interaction with the GUI.
......@@ -49,9 +48,10 @@ public class BracketViewController8 extends TournamentController {
tableTennisApplication.changeScene("tournament-view.fxml");
}
//Input all players, place them in a list, play all the matches, loser gets deleted
//Do it again till you reach the winner
//Need to go but should be a relatively simple task, and switch all the places to labels or non editable textfields
/**
* Adds players with the names given in the textfields to a register handled in the BracketviewController
* Also clears the register before it adds as an extra security step
*/
public void onPressAdd() {
if(textFieldPlayer1.getText().isBlank() || textFieldPlayer2.getText().isBlank()) {
Alert alert = new Alert(Alert.AlertType.WARNING);
......@@ -84,6 +84,9 @@ public class BracketViewController8 extends TournamentController {
}
}
/**
* Loads from the NEWTOURNAMENT.csv file, proceeds to the first game
*/
public void onPressLoad() {
try
{
......@@ -101,6 +104,10 @@ public class BracketViewController8 extends TournamentController {
}
}
/**
* Proceeds to the match
* @throws IOException
*/
public void onPressPlay() throws IOException{
TableTennisApplication tableTennisApplication = new TableTennisApplication();
tableTennisApplication.changeScene("create-tournament-match.fxml");
......
......@@ -39,7 +39,7 @@ public class CreateTournamentMatchController implements Initializable {
@Override
public void initialize(URL url, ResourceBundle resourceBundle) {
//Unga bunga what do
//We dont really needs this as of right now
}
......
......@@ -63,7 +63,6 @@ public class TournamentController {
* button to create a bracket after entering players
* @throws IOException
*/
public void onClickCreateBracket() throws IOException {
TableTennisApplication tableTennisApplication = new TableTennisApplication();
tableTennisApplication.changeScene("create_single_match_view.fxml");
......
......@@ -147,7 +147,7 @@ public class TournamentMatchController extends TournamentController implements I
}
/**
* TODO: Either fix this or delete it
* Savesthe match to a csv file for later use
* @throws IOException
*/
public void onPressSaveMatch() throws IOException{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment