org.apache.ftpserver.impl
Class DefaultFtpServer

java.lang.Object
  extended by org.apache.ftpserver.impl.DefaultFtpServer
All Implemented Interfaces:
FtpServer

public class DefaultFtpServer
extends java.lang.Object
implements FtpServer

Internal class, do not use directly. This is the starting point of all the servers. It invokes a new listener thread. Server implementation is used to create the server socket and handle client connection.

Version:
$Rev: 729984 $, $Date: 2008-12-29 20:44:16 +0100 (Mon, 29 Dec 2008) $
Author:
The Apache MINA Project (dev@mina.apache.org)

Constructor Summary
DefaultFtpServer(FtpServerContext serverContext)
          Internal constructor, do not use directly.
 
Method Summary
 CommandFactory getCommandFactory()
          Retrieve the command factory used with this server
 ConnectionConfig getConnectionConfig()
          Retrieve the connection configuration this server
 FileSystemFactory getFileSystem()
          Retrieve the file system used with this server
 java.util.Map<java.lang.String,Ftplet> getFtplets()
          Get all Ftplets registered at this server
 Listener getListener(java.lang.String name)
          Get a specific listener identified by its name
 java.util.Map<java.lang.String,Listener> getListeners()
          Get all listeners available one this server
 MessageResource getMessageResource()
          Retrieve the message resource used with this server
 FtpServerContext getServerContext()
          Get the root server context.
 UserManager getUserManager()
          Retrieve the user manager used with this server
 boolean isStopped()
          Get the server status.
 boolean isSuspended()
          Is the server suspended
 void resume()
          Resume the server handler
 void start()
          Start the server.
 void stop()
          Stop the server.
 void suspend()
          Suspend further requests
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultFtpServer

public DefaultFtpServer(FtpServerContext serverContext)
Internal constructor, do not use directly. Use FtpServerFactory instead

Method Detail

start

public void start()
           throws FtpException
Start the server. Open a new listener thread.

Specified by:
start in interface FtpServer
Throws:
FtpException

stop

public void stop()
Stop the server. Stop the listener thread.

Specified by:
stop in interface FtpServer

isStopped

public boolean isStopped()
Get the server status.

Specified by:
isStopped in interface FtpServer
Returns:
true if the server is stopped

suspend

public void suspend()
Suspend further requests

Specified by:
suspend in interface FtpServer

resume

public void resume()
Resume the server handler

Specified by:
resume in interface FtpServer

isSuspended

public boolean isSuspended()
Is the server suspended

Specified by:
isSuspended in interface FtpServer
Returns:
true if the server is suspended

getServerContext

public FtpServerContext getServerContext()
Get the root server context.


getListeners

public java.util.Map<java.lang.String,Listener> getListeners()
Get all listeners available one this server

Returns:
The current listeners

getListener

public Listener getListener(java.lang.String name)
Get a specific listener identified by its name

Parameters:
name - The name of the listener
Returns:
The Listener matching the provided name

getFtplets

public java.util.Map<java.lang.String,Ftplet> getFtplets()
Get all Ftplets registered at this server

Returns:
All Ftplets

getUserManager

public UserManager getUserManager()
Retrieve the user manager used with this server

Returns:
The user manager

getFileSystem

public FileSystemFactory getFileSystem()
Retrieve the file system used with this server

Returns:
The FileSystemFactory

getCommandFactory

public CommandFactory getCommandFactory()
Retrieve the command factory used with this server

Returns:
The CommandFactory

getMessageResource

public MessageResource getMessageResource()
Retrieve the message resource used with this server

Returns:
The MessageResource

getConnectionConfig

public ConnectionConfig getConnectionConfig()
Retrieve the connection configuration this server

Returns:
The MessageResource


Copyright © 2003-2011 Apache Software Foundation. All Rights Reserved.