All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class vnr.ide.Desktop

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----com.sun.java.swing.JComponent
                           |
                           +----com.sun.java.swing.JPanel
                                   |
                                   +----vnr.ide.Desktop

public class Desktop
extends JPanel
Desktop for VNRJ
1997-10-29 dlg Created
1997-11-17 dlg Changed to use a tree and card layout rather than tabs

Author:
dIon

Variable Index

 o cards
the panel that holds the many other panels that show views of the selected element in the tree
 o cardsLM
the layout manager used by cards
 o catView
category view - shown when a category is selected in the tree
 o classList
list of classes, alphabetically
 o currentDetailsView
currentProjectDetailsView - the currently selected details view of a project, or null
 o hierarchy
need to create its own view for this variable
 o noList
need to create its own view for this variable
 o pkgList
a view of the project: tree of projects, with classes as leaves
 o projView
project view - shown when a project is selected in the tree
 o scroller
a scroll pane to hold the tree
 o status
the status bar - used to communicate non-actionable messages to the user
 o userView
user view - shown when a user is selected in the tree

Constructor Index

 o Desktop(String, Server)
Desktop consists of a SplitPane with a tree and a cardlayout view window

Method Index

 o addClassToCurrentProject(NetRexxClass)
Add a new class to the currently selected project
 o addClassToCurrentProject(String)
Add a new class to the currently selected project
 o addProject(String)
Add a project to the currently selected category:
 o buildClass(NetRexxClass)
method to send a build to the server for the selected project of the tree using a NetRexxClass
 o buildClassForProject(NetRexxClass, Project)
method to send a build to the server for the given project
 o categorySelected(Category)
handle a click on a category - set the category for the view
 o classListSelected(Project)
handle a click on the class list item - set the project for the card being viewed
 o emptyStatus()
empty the status bar
 o getAddClassAction()
 o getBuildClassAction()
 o getController()
 o getCoordinator()
 o getDesktop(JComponent)
retrieve the desktop the class list is a child of
 o getEditClassAction()
 o getExitAction()
 o getModel()
 o getNewCategoryAction()
 o getNewProjectAction()
 o getOpenBuildResultsAction()
 o getRemoveClassAction()
 o getRemoveCurrentCategoryAction()
 o getRemoveCurrentProjectAction()
 o getRoot()
 o getSelectedCategory()
 o getSelectedCategoryNode()

Get selection path of the tree and get the 2nd element:
0 -> 1 -> 2 -> 3
root->category->project->View (category is 2nd)

 o getSelectedClass()
 o getSelectedProject()
 o getSplit()
 o getTheServer()
 o getTheUser()
 o getTree()
 o getUserModel()
get the current user for the desktop
 o packageListSelected(Project)
handle a click on the package list item - set the project for the view
 o projectSelected(Project)
handle a click on a project - set the project for the view
 o removeClassFromCurrentProject(NetRexxClass)
Removes a netRexxClass from the currently selected project ???
 o removeClassFromCurrentProject(String)
Removes a class from the currently selected project
 o removeCurrentCategory()
Remove the selected category from the tree

Updates the model directly

 o removeCurrentProject()
Remove the currently selected project from the selected category
 o setAddClassAction(AddClassToCurrentProject)
 o setBuildClassAction(BuildCurrentClass)
 o setController(DesktopController)
 o setCoordinator(WindowCoordinator)
 o setCurrentProjectCodeBase(String)
set the codeBase for the currently selected project
 o setEditClassAction(EditCurrentClass)
 o setExitAction(ExitApplication)
 o setModel(DefaultTreeModel)
 o setNewCategoryAction(NewCategory)
 o setNewProjectAction(NewProject)
 o setOpenBuildResultsAction(OpenBuildResults)
 o setRemoveClassAction(RemoveCurrentClass)
 o setRemoveCurrentCategoryAction(RemoveCurrentCategory)
 o setRemoveCurrentProjectAction(RemoveCurrentProject)
 o setRoot(DefaultMutableTreeNode)
 o setSplit(JSplitPane)
 o setTheServer(Server)
 o setTheUser(String)
 o setTree(JTree)
 o showDefault()
show default view - called to show the default for the right hand side of the view
 o showStatus(String)
Show a message on the status bar
 o userSelected(User)
handle someone clicking on the user

Variables

 o scroller
 protected JScrollPane scroller
a scroll pane to hold the tree

 o cards
 protected JPanel cards
the panel that holds the many other panels that show views of the selected element in the tree

 o cardsLM
 protected CardLayout cardsLM
the layout manager used by cards

 o pkgList
 protected PackageListView pkgList
a view of the project: tree of projects, with classes as leaves

 o hierarchy
 protected PackageListView hierarchy
need to create its own view for this variable

 o classList
 protected ClassListView classList
list of classes, alphabetically

 o noList
 protected CategoryView noList
need to create its own view for this variable

 o userView
 protected UserView userView
user view - shown when a user is selected in the tree

 o catView
 protected CategoryView catView
category view - shown when a category is selected in the tree

 o projView
 protected ProjectView projView
project view - shown when a project is selected in the tree

 o currentDetailsView
 protected ProjectDetailsView currentDetailsView
currentProjectDetailsView - the currently selected details view of a project, or null

 o status
 protected StatusBar status
the status bar - used to communicate non-actionable messages to the user

Constructors

 o Desktop
 public Desktop(String uid,
                Server srv)
Desktop consists of a SplitPane with a tree and a cardlayout view window

Methods

 o classListSelected
 public void classListSelected(Project p)
handle a click on the class list item - set the project for the card being viewed

 o packageListSelected
 public void packageListSelected(Project p)
handle a click on the package list item - set the project for the view

 o projectSelected
 public void projectSelected(Project p)
handle a click on a project - set the project for the view

 o categorySelected
 public void categorySelected(Category c)
handle a click on a category - set the category for the view

 o userSelected
 public void userSelected(User u)
handle someone clicking on the user

 o getSelectedClass
 public NetRexxClass getSelectedClass()
Returns:
the selected class from the current details view
See Also:
ProjectDetailsView
 o showDefault
 public void showDefault()
show default view - called to show the default for the right hand side of the view

 o removeCurrentCategory
 public boolean removeCurrentCategory()
Remove the selected category from the tree

Updates the model directly

Returns:
true or false - from removeCategory or false if nothing selected
 o getSelectedCategory
 public Category getSelectedCategory()
Returns:
the currently selected category from the tree, or null if one isn't selected
See Also:
Category
 o getSelectedProject
 public Project getSelectedProject()
Returns:
the currently selected project from the tree or null if one isn't selected
See Also:
Project
 o getSelectedCategoryNode
 public DefaultMutableTreeNode getSelectedCategoryNode()

Get selection path of the tree and get the 2nd element:
0 -> 1 -> 2 -> 3
root->category->project->View (category is 2nd)

Returns:
the currently selected category from the tree as a DefaultMutableTreeNode
 o addProject
 public boolean addProject(String name)
Add a project to the currently selected category:

Returns:
true/false - success indicator
 o removeCurrentProject
 public boolean removeCurrentProject()
Remove the currently selected project from the selected category

Returns:
success of removal as a boolean
 o setCurrentProjectCodeBase
 public void setCurrentProjectCodeBase(String codeBase)
set the codeBase for the currently selected project

 o addClassToCurrentProject
 public boolean addClassToCurrentProject(String className)
Add a new class to the currently selected project

Parameters:
className - - the fully qualified class, e.g. vnr.ide.Desktop
Returns:
success of removal as a boolean
 o addClassToCurrentProject
 public void addClassToCurrentProject(NetRexxClass nrxClass)
Add a new class to the currently selected project

Parameters:
nrxClass - - the NetRexxClass to be added
 o removeClassFromCurrentProject
 public boolean removeClassFromCurrentProject(String className)
Removes a class from the currently selected project

Parameters:
className - - the fully qualified class, e.g. vnr.ide.Desktop
Returns:
success of removal as a boolean
 o removeClassFromCurrentProject
 public void removeClassFromCurrentProject(NetRexxClass nrxClass)
Removes a netRexxClass from the currently selected project ???

Parameters:
className - - the fully qualified class, e.g. vnr.ide.Desktop
Returns:
success of removal as a boolean
See Also:
NetRexxClass
 o getUserModel
 public User getUserModel()
get the current user for the desktop

 o buildClass
 public void buildClass(NetRexxClass nrxClass)
method to send a build to the server for the selected project of the tree using a NetRexxClass

See Also:
NetRexxClass
 o buildClassForProject
 public void buildClassForProject(NetRexxClass nrxClass,
                                  Project proj)
method to send a build to the server for the given project

Parameters:
nrxClass - - the class to build
proj - - the project the class is being built for
See Also:
NetRexxClass, Project
 o getDesktop
 public static Desktop getDesktop(JComponent c)
retrieve the desktop the class list is a child of

 o showStatus
 public void showStatus(String msg)
Show a message on the status bar

Parameters:
msg - The text to show on the statusBar
 o emptyStatus
 public void emptyStatus()
empty the status bar

 o getTheServer
 public Server getTheServer()
 o setTheServer
 public void setTheServer(Server $1)
 o getTheUser
 public String getTheUser()
 o setTheUser
 public void setTheUser(String $2)
 o getRoot
 public DefaultMutableTreeNode getRoot()
 o setRoot
 public void setRoot(DefaultMutableTreeNode $3)
 o getTree
 public JTree getTree()
 o setTree
 public void setTree(JTree $4)
 o getCoordinator
 public WindowCoordinator getCoordinator()
 o setCoordinator
 public void setCoordinator(WindowCoordinator $5)
 o getNewCategoryAction
 public NewCategory getNewCategoryAction()
 o setNewCategoryAction
 public void setNewCategoryAction(NewCategory $6)
 o getNewProjectAction
 public NewProject getNewProjectAction()
 o setNewProjectAction
 public void setNewProjectAction(NewProject $7)
 o getOpenBuildResultsAction
 public OpenBuildResults getOpenBuildResultsAction()
 o setOpenBuildResultsAction
 public void setOpenBuildResultsAction(OpenBuildResults $8)
 o getExitAction
 public ExitApplication getExitAction()
 o setExitAction
 public void setExitAction(ExitApplication $9)
 o getRemoveCurrentCategoryAction
 public RemoveCurrentCategory getRemoveCurrentCategoryAction()
 o setRemoveCurrentCategoryAction
 public void setRemoveCurrentCategoryAction(RemoveCurrentCategory $10)
 o getRemoveCurrentProjectAction
 public RemoveCurrentProject getRemoveCurrentProjectAction()
 o setRemoveCurrentProjectAction
 public void setRemoveCurrentProjectAction(RemoveCurrentProject $11)
 o getAddClassAction
 public AddClassToCurrentProject getAddClassAction()
 o setAddClassAction
 public void setAddClassAction(AddClassToCurrentProject $12)
 o getRemoveClassAction
 public RemoveCurrentClass getRemoveClassAction()
 o setRemoveClassAction
 public void setRemoveClassAction(RemoveCurrentClass $13)
 o getEditClassAction
 public EditCurrentClass getEditClassAction()
 o setEditClassAction
 public void setEditClassAction(EditCurrentClass $14)
 o getBuildClassAction
 public BuildCurrentClass getBuildClassAction()
 o setBuildClassAction
 public void setBuildClassAction(BuildCurrentClass $15)
 o getModel
 public DefaultTreeModel getModel()
 o setModel
 public void setModel(DefaultTreeModel $16)
 o getController
 public DesktopController getController()
 o setController
 public void setController(DesktopController $17)
 o getSplit
 public JSplitPane getSplit()
 o setSplit
 public void setSplit(JSplitPane $18)

All Packages  Class Hierarchy  This Package  Previous  Next  Index