DESCRIPTION
- ::pop3d::new ?serverName?
-
This command creates a new server object with an associated global Tcl
command whose name is serverName.
The command serverName may be used to invoke various operations
on the server. It has the following general form:
- serverName option ?arg arg ...?
-
Option and the args determine the exact behavior of the
command.
A pop3 server can be started on any port the caller has permission for
from the operating system. The default port will be 110, which is the
port defined by the standard (RFC 1939).
After creating, configuring and starting a the server object will
listen for and accept connections on that port and handle them
according to the POP3 protocol.
Note: The server provided by this module will handle only the
basic protocol by itself. For the higher levels of user authentication
and handling of the actual mailbox contents callbacks will be invoked.
The following commands are possible for server objects:
- serverName up
-
After this call the server will listen for connections on its configured port.
- serverName down
-
After this call the server will stop listening for connections. This
does not affect existing connections.
- serverName destroy ?mode?
-
Destroys the server object. Currently open connections are handled
depending on the chosen mode.
The provided modes are:
- kill
-
Destroys the server immediately, and forcefully closes all currently
open connections. This is the default mode.
- defer
-
Stops the server from accepting new connections and will actually
destroy it only after the last of the currently open connections for
the server is closed.
- serverName configure
-
Returns a list containing all options and their current values in a
format suitable for use by the command array set. The options
themselves are described in section OPTIONS.
- serverName configure -option
-
Returns the current value of the specified option. This is an alias
for the method cget. The options themselves are described in
section OPTIONS.
- serverName configure -option value...
-
Sets the specified option to the provided value. The options
themselves are described in section OPTIONS.
- serverName cget -option
-
Returns the current value of the specified option. The options
themselves are described in section OPTIONS.
- serverName conn list
-
Returns a list containing the ids of all connections currently open.
- serverName conn state id
-
Returns a list suitable for [array set] containing the
state of the connection referenced by id.