Skip to content

Project Architecture

Eric Leung edited this page Aug 30, 2019 · 9 revisions

UML

The Software Architecture for this application was based on Object Oriented Principles, as we are using Java. The main goal was to decrease coupling and increase cohesion. Moreover, other goals of the Software Architecture were to have encapsulation, information hiding, and a good level of abstraction.

In order to accomplish this, we ensured that we would sole assign one main job per class in order to decouple the tasks that were done. Additionally, by using interfaces and abstract classes we ensured that the main contract of the architecture could not be broken and easily swapped out in the future. This was also done thinking about possible future implementations that could be quicker.

The basic classes are as follows:

  • IO Class: Deals with the reading and the writing of the files
  • Graph Class: Keeps the representation of the input graph and is used later to create the representation of the output graph during the visualization phase
  • Algorithm Abstract Class: This class is essential as it describes the contract that all algorithm classes must have. The algorithms that currently inherit from this abstract class are Sequential, IDAStarBase, and IDAStarParallel.
  • Visualization Project structure with MVC pattern support: This includes the controller, view (FXML) + the model from algorithm's classes. Controller involves instantiating and using JavaFX components from the FXML view created from Scenebuilder.
  • Visualization Project Manager/Helper classes: These classes are essential for the controller to operate using the model classes and given observer results. Will contain managers for larger components including the graph, gantt chart and table visualizations. Managers would usually involve instantiating the view initially during the start of the application + constant updates received by the observer interfaces for an update from the algorithm.
  • Observer Interface Classes: For integrating constant and end updates between the algorithm for scheduling and the visualization stats + graph components
  • Exception Classes: Dealing with external exceptions for inputs and outputs (i.e. input dot file had two of the same edges)

Thought was put into deciding design patterns to utilize. For example, the builder design pattern was used to instantiate the algorithm. This allows different algorithm types to be easily instantiated based on the input conditions.

UML Diagram:

UML

IntelliJ Non dependencies final UML implementation:

UMLIntelliJ

Build Tools

Used Maven for predictable compiles and external project dependency management.
This allows the auto code checker to run on Github by compiling via the rules defined on pom.xml.
Maven also provides clean jar packaging for each milestone release.

Additional Libraries

  1. JUnit - To implement unit test cases.
  2. OpenJFX - Provides additional graphics tools in addition to JavaFX to allow for more control over the creation of the GUI.
  3. Pyjama - Will be utilised to implement parallelization for the future milestone where our algorithm optimizes the use of all cores.
  4. JGraphT - Library for encapsulating the input data as a graph which allows us to perform graph related method calls on the data.
  5. Graphstream - Will be used to display the current dot input file graph, and will additionally show extra information on the tasks processor assignment and its start time of running in the schedule.
  6. JavaFX 8 - Will be the standard library for using important Java GUI components in extension to Java Swing components. It will offer charts, labels, dropboxes and FXML, CSS support flexibility.
  7. JFoenix 8 - Is an extension to JavaFX 8 and will offer extra components that are easier to shape and form according to our project's liking (styling and additional components are helpful within this library).

Clone this wiki locally