TelnetD at SF

net.wimpi.telnetd.shell
Class ShellManager

java.lang.Object
  extended bynet.wimpi.telnetd.shell.ShellManager

public class ShellManager
extends java.lang.Object

This class implements a Manager Singleton that takes care for all shells to be offered.

The resources can be defined via properties that contain following information:

The definition of any shell is simply represented by a fully qualified class name, of a class that implements the shell interface. Please read the documentation of this interface carefully.
The properties are passed on creation through the factory method, which is called by the net.wimpi.telnetd.TelnetD class.

Version:
2.0 (13/03/2005)
Author:
Dieter Wimberger
See Also:
Shell

Method Summary
static ShellManager createShellManager(java.util.Properties settings)
          Factory method for creating the Singleton instance of this class.
static ShellManager getReference()
          Accessor method for the Singleton instance of this class.
 Shell getShell(java.lang.String key)
          Accessor method for shells that have been set up.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getShell

public Shell getShell(java.lang.String key)
Accessor method for shells that have been set up.
Note that it uses a factory method that any shell should provide via a specific class operation.

Parameters:
key - String that represents a shell name.
Returns:
Shell instance that has been obtained from the factory method.

createShellManager

public static ShellManager createShellManager(java.util.Properties settings)
                                       throws BootException
Factory method for creating the Singleton instance of this class.
Note that this factory method is called by the net.wimpi.telnetd.TelnetD class.

Parameters:
settings - Properties defining the shells as described in the class documentation.
Returns:
ShellManager Singleton instance.
Throws:
BootException

getReference

public static ShellManager getReference()
Accessor method for the Singleton instance of this class.
Note that it returns null if the instance was not properly created beforehand.

Returns:
ShellManager Singleton instance reference.

TelnetD at SF

Copyright © 2000-2005 Dieter Wimberger.