The Voltron GUI API With a short description

  • Slides: 11
Download presentation
The Voltron. GUI API With a short description of Voltron. Controller

The Voltron. GUI API With a short description of Voltron. Controller

Overview of the GUI API n We have three main categories of interface –

Overview of the GUI API n We have three main categories of interface – Classes implemented by the UI for use by the controller or model – Classes containing data the UI will need or representing data objects in the world – Adapters that allow the UI to notify the model when the user performs an action

Internal Class API n IView – Represents the GUI as a whole. – Should

Internal Class API n IView – Represents the GUI as a whole. – Should be notified whenever a node is directly connected or disconnected, and updated the status of jobs – Implemented by Main. Form. cs, the main GUI class, but could be moved out into a separate class if the code gets too large

Login/Authentication API n Get. Login class – Allows the controller to request login information

Login/Authentication API n Get. Login class – Allows the controller to request login information from the view n Login. Info class – Contains two string fields for the username and password – Essentially a structure so Get. Login can return a pair of strings

Data Representation API n IComputer – Represents a single computer on the grid –

Data Representation API n IComputer – Represents a single computer on the grid – Has methods for getting resource info, location, and name n ILocation – Contained by a given IComputer – Represents a location of the computer in the world

Adapters API n INetwork. Adapter – Allows the computer to interact with the grid

Adapters API n INetwork. Adapter – Allows the computer to interact with the grid as a network – Currently allows view to walk network n IConnection. Adapter – Manages the view’s notion of connections – Currently allows the view to make or break direct connections to remote hosts

Adapters API (2) n IFile. System. Adapter – Encapsulates the notion of getting files

Adapters API (2) n IFile. System. Adapter – Encapsulates the notion of getting files from or giving files to any provider – Can get, delete, and put files into the abstract file system by a string filename n IFlat. File. System. Adapter – Adds the ability to list all of the files in the file system, since it lacks hierarchy

UML Diagram of the GUI Main. Form IView Login. Dialog IFlat. File. Sytstem. Adapter

UML Diagram of the GUI Main. Form IView Login. Dialog IFlat. File. Sytstem. Adapter IConnection. Adapter IComputer Get. Login INetwork. Adapter ILocation Login. Info

Story – Running a Process The user would like to run one of the

Story – Running a Process The user would like to run one of the processes that is shown graphically in the view of the file system. The user single-clicks on the file they want to run, and then drags it onto the view of the grid (the blob). The file is then run by the grid, and its status is shown on the process panel, which tells the user which computer this process is being run on, and its status (running/done).

Story – Direct Connection A user would like to directly connect to one of

Story – Direct Connection A user would like to directly connect to one of the computers in the grid. To do this, the user right-clicks on one of the entries on the processes panel. They then select on the rightclick menu to directly connect to the computer that process was run on in the grid. If a direct connection has not already been established with this computer, a connection is established, and the computer that was connected to is displayed in the directly connected panel.

Controller Overview n Basic idea – implement classes the subprojects need and pass around

Controller Overview n Basic idea – implement classes the subprojects need and pass around information between model and view – Contains implementations of UI adapters n Encapsulate startup code for running the entire program