KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > coldcore > coloradoftp > core > Core


1 package com.coldcore.coloradoftp.core;
2
3 /**
4  * The core itself.
5  *
6  * Core is responsible for starting/stopping FTP server and all its parts.
7  * There is nothing else the core can do because starting from version 1.2
8  * all components run in separate threads and therefore execute on their own.
9  *
10  * Core has a special status names POISONED. This status means that the server is going to shut
11  * down and is waiting for all control and data connections to finish and disconnect. All connection
12  * pools and control connection acceptors must take core status into consideration.
13  *
14  * When poisoned and there are no connections left to serve, the server will not neccessarily stop.
15  * This is up to the implementation of the core.
16  *
17  *
18  * ColoradoFTP - The Open Source FTP Server (http://cftp.coldcore.com)
19  */

20 public interface Core {
21
22   /** Start server */
23   public void start();
24
25
26   /** Stop server */
27   public void stop();
28
29
30   /** Poison server (no more connections allowed and existing will be killed when all data is transferred) */
31   public void poison();
32
33
34   /** Get server status
35    * @return Server status
36    */

37   public CoreStatus getStatus();
38 }
39
Popular Tags