Class MailServer

java.lang.Object
net.messagevortex.AbstractDaemon
net.messagevortex.transport.MailServer
All Implemented Interfaces:
RunningDaemon, Transport, TransportSender

public class MailServer extends AbstractDaemon implements Transport
  • Constructor Details

    • MailServer

      public MailServer(String section) throws IOException

      Creates a mail server according to the parameters specified.

      Parameters:
      section - the name of the config section
      Throws:
      IOException - if creation of the mail server fails
  • Method Details

    • sendMessage

      public void sendMessage(String address, InputStream os) throws IOException
      Description copied from interface: TransportSender

      sends a message on the transport layer.

      This method is called by the blender layer to send a message.

      Specified by:
      sendMessage in interface TransportSender
      Parameters:
      address - the string representation of the target address on the transport layer
      os - the outputstream providing the message
      Throws:
      IOException - if transport layer was unable to satisfy the request
    • shutdownDaemon

      public void shutdownDaemon()
      Description copied from interface: RunningDaemon

      Shuts this class down.

      This frees all resources and ends all threads for an application or layer shutdown. It is not possible to call start() after running shutdown().

      Specified by:
      shutdownDaemon in interface RunningDaemon
      Overrides:
      shutdownDaemon in class AbstractDaemon