You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
43 lines
1.3 KiB
43 lines
1.3 KiB
package seng302;
|
|
|
|
|
|
import javafx.application.Application;
|
|
import javafx.stage.Stage;
|
|
import org.xml.sax.SAXException;
|
|
import seng302.Mock.RegattaDataSource;
|
|
import seng302.Mock.RegattaXMLReader;
|
|
import seng302.Model.Event;
|
|
|
|
import javax.xml.parsers.ParserConfigurationException;
|
|
import java.io.IOException;
|
|
import java.io.OutputStream;
|
|
|
|
public class App extends Application {
|
|
|
|
/**
|
|
* Entry point for running the programme
|
|
*
|
|
* @param args for starting the programme
|
|
*/
|
|
public static void main(String[] args) {
|
|
launch(args);
|
|
}
|
|
|
|
@Override
|
|
public void start(Stage primaryStage) {
|
|
try {
|
|
OutputStream outputStream = System.out;//TEMP currently using System.out, but should replace this with tcp socket we are sending over.
|
|
RaceDataSource raceData = new RaceXMLReader("raceXML/bermuda_AC35.xml");
|
|
RegattaDataSource regattaData = new RegattaXMLReader("mockXML/regattaTest.xml");
|
|
Event raceEvent = new Event(raceData, regattaData, outputStream);
|
|
raceEvent.start();
|
|
} catch (IOException e) {
|
|
e.printStackTrace();
|
|
} catch (SAXException e) {
|
|
e.printStackTrace();
|
|
} catch (ParserConfigurationException e) {
|
|
e.printStackTrace();
|
|
}
|
|
}
|
|
}
|