Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.mrbook.mrpostman
Class MrPostman  view MrPostman download MrPostman.java

java.lang.Object
  extended byorg.mrbook.mrpostman.MrPostman

public class MrPostman
extends java.lang.Object


Field Summary
static java.lang.String CVSID
           
static int DEFAULT_HELP_PORT
           
static int DEFAULT_PORT
           
static boolean DEFAULT_START_LOG
           
private  org.mrbook.mrpostman.gui.MrPostmanGui gui
           
private  int helpPort
           
private static org.mrbook.mrpostman.help.HelpServer hs
           
private static java.util.logging.Logger logger
           
private static MrPostman maininstance
           
private  java.util.Vector modulesVector
           
private  org.mrbook.mrpostman.pop.PopServer pops
           
private  boolean serverRunning
           
 java.util.prefs.Preferences userprefs
           
 
Constructor Summary
(package private) MrPostman()
           
 
Method Summary
 void exit()
           
 java.lang.String getHelpBaseUrl()
          Return the base URL for the help system.
 java.util.HashMap getLoadedModuleInfo()
          Return a list of ModuleInfo objects for all our loaded modules.
static MrPostman getMainInstance()
           
 WebMailSession getModuleHandlerForExtension(java.lang.String extension)
           
 java.util.Vector getModuleNamesVector()
           
 java.lang.String getModuleOptionValueForDisplay(java.lang.String moduleId, java.lang.String optionId)
          Return the current value for a module option This is retrieved from our preferences (if found) or the default value for that option This is used by the GUI to get current option values for display.
 java.lang.String getProperty(java.lang.String propname, java.lang.String defaut)
           
 boolean getPropertyBool(java.lang.String propname, boolean b)
           
 int getPropertyInt(java.lang.String propname, int i)
           
private  void initialiseModuleOptions(WebMailSession module)
          Set any user defined module specific option values for this module
private  void initModules()
           
private  void initPrefs()
           
static void main(java.lang.String[] args)
           
 void showGui()
           
 void startHelpServer()
           
private  void testAndAddModule(java.lang.String className)
           
 void updateModuleOption(java.lang.String optionId, java.lang.String value)
          Update our option value in our Prefs for the specified optionId.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CVSID

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

logger

private static java.util.logging.Logger logger

DEFAULT_PORT

public static int DEFAULT_PORT

DEFAULT_HELP_PORT

public static int DEFAULT_HELP_PORT

DEFAULT_START_LOG

public static boolean DEFAULT_START_LOG

maininstance

private static MrPostman maininstance

hs

private static org.mrbook.mrpostman.help.HelpServer hs

userprefs

public java.util.prefs.Preferences userprefs

serverRunning

private boolean serverRunning

pops

private org.mrbook.mrpostman.pop.PopServer pops

gui

private org.mrbook.mrpostman.gui.MrPostmanGui gui

modulesVector

private java.util.Vector modulesVector

helpPort

private int helpPort
Constructor Detail

MrPostman

MrPostman()
Method Detail

initPrefs

private void initPrefs()

testAndAddModule

private void testAndAddModule(java.lang.String className)

initModules

private void initModules()

getProperty

public java.lang.String getProperty(java.lang.String propname,
                                    java.lang.String defaut)

getPropertyInt

public int getPropertyInt(java.lang.String propname,
                          int i)

getPropertyBool

public boolean getPropertyBool(java.lang.String propname,
                               boolean b)

getMainInstance

public static MrPostman getMainInstance()

startHelpServer

public void startHelpServer()
                     throws java.io.IOException

getHelpBaseUrl

public java.lang.String getHelpBaseUrl()
Return the base URL for the help system. This will be the root of the doc tree. Requesting this URL will produce the /index.html document.


showGui

public void showGui()

exit

public void exit()

getModuleNamesVector

public java.util.Vector getModuleNamesVector()

getModuleHandlerForExtension

public WebMailSession getModuleHandlerForExtension(java.lang.String extension)

getLoadedModuleInfo

public java.util.HashMap getLoadedModuleInfo()
Return a list of ModuleInfo objects for all our loaded modules. This is required for the GUI to initialise the module info panels. This map is keyed on moduleId.


initialiseModuleOptions

private void initialiseModuleOptions(WebMailSession module)
Set any user defined module specific option values for this module


getModuleOptionValueForDisplay

public java.lang.String getModuleOptionValueForDisplay(java.lang.String moduleId,
                                                       java.lang.String optionId)
Return the current value for a module option This is retrieved from our preferences (if found) or the default value for that option This is used by the GUI to get current option values for display. This is NOT used by the WebMailSession objects.


updateModuleOption

public void updateModuleOption(java.lang.String optionId,
                               java.lang.String value)
Update our option value in our Prefs for the specified optionId. Used by MrPostmanGui after the 'Apply' button is pressed.


main

public static void main(java.lang.String[] args)