edu.ou.kmi.buddyspace.plugins.maps
Class BSMapsPlugin

java.lang.Object
  |
  +--edu.ou.kmi.buddyspace.plugins.BSPlugin
        |
        +--edu.ou.kmi.buddyspace.plugins.maps.BSMapsPlugin
All Implemented Interfaces:
java.awt.event.ActionListener, java.util.EventListener, javax.swing.event.MenuListener

public class BSMapsPlugin
extends BSPlugin
implements java.awt.event.ActionListener, javax.swing.event.MenuListener

BSMapsPlugin is main class of maping plugin to BuddySpace. It provides methods for plugin loading and user interaction.


Field Summary
static java.lang.String mapPath
           
static java.lang.String PREF_NAME_MAP_PATH
           
static java.lang.String PREF_NAME_PUBSUB_JID
           
static java.lang.String PREF_NAME_PUBSUB_NODE
           
static JID pubsubJID
           
static java.lang.String pubsubNode
           
 
Fields inherited from class edu.ou.kmi.buddyspace.plugins.BSPlugin
core, mainFrame, name, tabbedPane
 
Constructor Summary
BSMapsPlugin(BSMainFrame mainFrame, javax.swing.JTabbedPane tabbedPane, BSCore core)
          Constructor
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent evt)
          Handles actions from GUI controls
protected  void addGUIControls()
          Adds plugin GUI controls
 void addOpenWindows(java.util.Vector openWindows, boolean connected)
          Add its open windows into the vector (for opening when starting next time).
protected  void connectBeans()
          Connects underlying beans
 void connected()
          Handles connection change to connected
 void disconnected()
          Handles connection change to disconnected
 void getPreferencesTab(java.util.Vector components, java.util.Vector names)
          Returns components and their names for display in preferences dialog
 void getSupportedNamespaces(java.util.Vector namespaces, java.util.Vector names)
          Adds supported namespaces and their names
protected  void initCore()
          Inits plugin core
protected  void initGUI()
          Inits plugin GUI
protected  void loadPreferences()
          Loads preferences
 void menuCanceled(javax.swing.event.MenuEvent menuEvent)
          Empty
 void menuDeselected(javax.swing.event.MenuEvent menuEvent)
          Empty
 void menuSelected(javax.swing.event.MenuEvent evt)
          Fills the map menu on its selection
 void openTheWindows(java.util.Vector openWindows, boolean connected)
          Opens windows specified in vector.
 boolean performAction(JID jid, java.lang.String namespace)
          Performs action within given namespace for given JID.
 boolean storePreferences()
          Stores preferences from preferences tab.
 void updateLAF()
          Updates LAF of all plug-ins
 
Methods inherited from class edu.ou.kmi.buddyspace.plugins.BSPlugin
isNewMessage, shutdownCorbaServer, startCorbaServer
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PREF_NAME_MAP_PATH

public static final java.lang.String PREF_NAME_MAP_PATH
See Also:
Constant Field Values

PREF_NAME_PUBSUB_JID

public static final java.lang.String PREF_NAME_PUBSUB_JID
See Also:
Constant Field Values

PREF_NAME_PUBSUB_NODE

public static final java.lang.String PREF_NAME_PUBSUB_NODE
See Also:
Constant Field Values

mapPath

public static java.lang.String mapPath

pubsubJID

public static JID pubsubJID

pubsubNode

public static java.lang.String pubsubNode
Constructor Detail

BSMapsPlugin

public BSMapsPlugin(BSMainFrame mainFrame,
                    javax.swing.JTabbedPane tabbedPane,
                    BSCore core)
Constructor

Method Detail

initCore

protected void initCore()
Inits plugin core

Specified by:
initCore in class BSPlugin

initGUI

protected void initGUI()
Inits plugin GUI

Specified by:
initGUI in class BSPlugin

loadPreferences

protected void loadPreferences()
Description copied from class: BSPlugin
Loads preferences

Specified by:
loadPreferences in class BSPlugin

addGUIControls

protected void addGUIControls()
Adds plugin GUI controls

Specified by:
addGUIControls in class BSPlugin

connectBeans

protected void connectBeans()
Connects underlying beans

Specified by:
connectBeans in class BSPlugin

connected

public void connected()
Handles connection change to connected

Overrides:
connected in class BSPlugin

disconnected

public void disconnected()
Handles connection change to disconnected

Specified by:
disconnected in class BSPlugin

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent evt)
Handles actions from GUI controls

Specified by:
actionPerformed in interface java.awt.event.ActionListener

menuSelected

public void menuSelected(javax.swing.event.MenuEvent evt)
Fills the map menu on its selection

Specified by:
menuSelected in interface javax.swing.event.MenuListener

menuCanceled

public void menuCanceled(javax.swing.event.MenuEvent menuEvent)
Empty

Specified by:
menuCanceled in interface javax.swing.event.MenuListener

menuDeselected

public void menuDeselected(javax.swing.event.MenuEvent menuEvent)
Empty

Specified by:
menuDeselected in interface javax.swing.event.MenuListener

getPreferencesTab

public void getPreferencesTab(java.util.Vector components,
                              java.util.Vector names)
Returns components and their names for display in preferences dialog

Specified by:
getPreferencesTab in class BSPlugin

storePreferences

public boolean storePreferences()
Stores preferences from preferences tab.

Specified by:
storePreferences in class BSPlugin

updateLAF

public void updateLAF()
Updates LAF of all plug-ins

Specified by:
updateLAF in class BSPlugin

performAction

public boolean performAction(JID jid,
                             java.lang.String namespace)
Performs action within given namespace for given JID. Returns if action was performed.

Overrides:
performAction in class BSPlugin

getSupportedNamespaces

public void getSupportedNamespaces(java.util.Vector namespaces,
                                   java.util.Vector names)
Adds supported namespaces and their names

Specified by:
getSupportedNamespaces in class BSPlugin

openTheWindows

public void openTheWindows(java.util.Vector openWindows,
                           boolean connected)
Opens windows specified in vector.

Overrides:
openTheWindows in class BSPlugin

addOpenWindows

public void addOpenWindows(java.util.Vector openWindows,
                           boolean connected)
Add its open windows into the vector (for opening when starting next time).

Overrides:
addOpenWindows in class BSPlugin