Module Frame1

Class Frame1

Description

This class builds a visual user interface, takes input from the user and processes the Vector of Edges to build the tree.

Functions

public Frame1()

This is the constructor for this class. It just calls jbInit() to build the GUI.

private void jbInit()

This function builds the GUI and sets up all the user interaction events.

Output: All of the GUI is built and shown.

void Load(ActionEvent e)

This function is called when the user chooses to load a file.

Input: The ActionEvent for choosing Load in the menybar.

Output: Produces the collection of WebPages and Edges. Also presents the user with the information for one Webpage in the system.

void see_Info(ActionEvent e)

This function is called when the user wants to see information about a specific page by browsing a list.

Input: The ActionEvent for choosing Webpages in the menybar.

Output: Hides the panel displaying the tree and showing the panel with the Webpage information.

void Show_tree(ActionEvent e)

This function is called when the user wants to see the tree of the site.

Input: The ActionEvent for choosing Visualize in the menybar.

Output: A picture of the site in tree form.

void Quit(ActionEvent e)

This function is called when the user wants to quit.

Input: The ActionEvent for choosing Quit in the menybar.

Output: Program is ended and shuts down.

void list1_itemStateChanged(ItemEvent e)

This function is called when the user chooses to select another Webpage to see info about.

Input: The ItemEvent for selecting another item in the list over all the Webpages.

Output: Shows info about the choosen Webpage and computes some additional info.

 

class MyPanel extends Panel

Description

This is the class the is used to display and build the tree of the site.

Functions

public MyPanel()

This is the constructer for this class.

public void display ()

This function is called to paint the tree.

public void paint (Graphics g )

This function called when a paint command is called to (re)paint the tree.