XNap Version 2

STRUCTURE

 The core packages build a framework for the plugins. The core must be
 compilable by itself but makes no sense without plugins. Abstract
 classes will be provided for standard file sharing tasks.

 xnap.cmdl	 (console)
 xnap.gui	 (frame, dialogs)
 xnap.io	 (repository)
 xnap.net	 (abstract communication classes, interfaces)
 xnap.plugin	 (plugin manager, interfaces)
 xnap.util	 (preferences, queues)
 xnap.util.event (status change notifications)

PLUGIN ARCHITECUTRE
 
 So far we have two types of plugins. Protocol plugins and viewer
 plugins. The default plugins will reside in xnap.plugin. Each plugin
 is required to implement IPlugin. Network plugins should implement
 INetworkPlugin and viewer plugins IViewerPlugin. Optionally
 protocol plugins can provide a gui and implement IGUIPlugin. 

 It is recommended that the package structure looks somewhat like the core:

 xnap.plugin.[protocol].Plugin    (core plugin stuff)
 xnap.plugin.[protocol].GUIPlugin (extends Plugin, additional gui stuff)
 xnap.plugin.[protocol].gui
 xnap.plugin.[protocol].net
 xnap.plugin.[protocol].util

PLUGIN INTERFACES

 Protocol plugins (INetworkPlugin) need to implement the following
 interfaces, abstract helper classes that provide a common
 implementation are noted in parenthesis:

 xnap.net.IBrowse       (AbstractSearch)
 xnap.net.IDownload     (AbstractDownload)
 xnap.net.ISearch       (AbstractSearch)
 xnap.net.ISearchResult (AbstractSearchResult)
 xnap.net.IUpload       (AbstractUpload)
 
 The following classes need to be used by the plugins:

 xnap.util.ISearchResultCollector
 xnap.util.SearchFilter

 GUI plugins are encouraged to use these classes:
 
 xnap.gui.AbstractPanel
 xnap.gui.StatusPanel

CONVENTIONS

 Most important only gui classes are allowed to access java.awt or
 javax packages. There must not be any compile time dependency of core
 or cmdl classes on packages that are not available to gcj.

 We will make use of the singleton concept whenever it makes life
 easier. Except for networking classes, the following singletons can
 be accessed from anywhere. Change notification will be provided
 through event listener support.

 xnap.io.Repository           (upload file repository)
 xnap.plugin.PluginManager
 xnap.plugin.GUIPluginManager
 xnap.util.DownloadQueue
 xnap.util.Preferences        (application wide prefs)
 xnap.util.UploadQueue

FILES

 Directory ~/.xnap/

  cmd_history    (GUI command history)
  error.log      (System.err is diverted to this file to catch
                  exceptions)
  history        (command line history)
  search_history
  shared         (binary repository containing upload files)
  resumes        (binary repository containing incomplete auto downloads)
 