Source code for CS410J: Advanced Java Programming (Summer 2014) projects
airline-gwt
This is a web application that allows a user to add an airline and add invidivual flights information. The page updates a list of stored flights for that airline. The user can search for flights via source and destination airport codes and flight numbers with the page updating a result table. The user can select any item on the result table and delete the flight from storage.
This project demonstrates how a rich Internet application is created using Java, and using tools like the Google Web Toolkit (GWT) API, which abstracts most of the JavaScript HTML in wrapper classes.
Adding an airline and a flight
Searching/filtering flights by flight number, source, and destination
HOW TO RUN
- Ensure that you have the Java JDK version 1.7 or higher installed on your machine
- Install Apache Maven on your system:
- Download the latest version of Maven at: http://maven.apache.org/download.cgi
- Unzip apache-maven3.x.y archive
- Add the location of the extracted archive folder to your environment path
- Ensure that the JAVA_HOME variable is pointing to actual JDK path (in Linux: /usr/libexec/java_home)
- in Linux, in your ~/.bash_profile file, add the following:
export JAVA_HOME=$(/usr/libexec/java_home)
export PATH=/usr/local/apache-maven-3.x.y/bin:$PATH
(after moving apache-maven folder to /usr/local/)- in the terminal, enter:
source ~/.bash_profile
to add - in the terminal, in the airline-gwt folder, type in:
mvn package
(Note: this will take a while) - in the terminal, type in:
mvn jetty:run-war
(Note: this will take a while, as Java code is converted to JavaScript and HTML) - Open a web browser and go to: http://localhost:8080/airline-gwt/airline/