Class SJServerActionAdapter

All Implemented Interfaces:
SJServerAction, SJServerPlugin

public abstract class SJServerActionAdapter
extends java.lang.Object
implements SJServerAction

Title: $FileName:$

$VerNum: 4$
$AuthorName: Rob MacGrogan$

$Description: For convenience, this adapter is provided. It implements the SJServerAction interface.$
$KeyWordsOff: $

Field Summary
private  java.util.Map params
private workDirectory
Constructor Summary
Method Summary
abstract  void actionPerformed(org.sourcejammer.project.view.SJRequest request, org.sourcejammer.project.view.SJResponse response, ArchiveContext arch)
protected  java.lang.String getParameter(java.lang.String name)
          Returns the requested parameter as a String. getWorkDirectory()
          Returns a pointer to the work directory for this plugin.
 void initPlugin(java.util.Map params)
          Warning! If you override this method, be sure to call super.initPlugin().
 void setWorkDirectory( workDirectory)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail


private java.util.Map params


private workDirectory
Constructor Detail


public SJServerActionAdapter()
Method Detail


public final void setWorkDirectory( workDirectory)
Specified by:
setWorkDirectory in interface SJServerPlugin


public getWorkDirectory()
Returns a pointer to the work directory for this plugin. The directory will only be used by this plugin. A new directory will be created for each Archive this plugin is added to. No files in this directory will be added, removed, or modified by SourceJammer or any other plugins.

Please use common sense in dealing with this directory. Do not store files here unless you really need them. Delete files when you are finished with them.

For temp files, you are probably better off using SourceJammer's TempDirectoryManager (in org.sourcejammer.util in the lib package). SJ periodically wipes the temp directory clean so you don't have to worry about that.

Specified by:
getWorkDirectory in interface SJServerPlugin


protected java.lang.String getParameter(java.lang.String name)
Returns the requested parameter as a String.


public abstract void actionPerformed(org.sourcejammer.project.view.SJRequest request,
                                     org.sourcejammer.project.view.SJResponse response,
                                     ArchiveContext arch)
Specified by:
actionPerformed in interface SJServerAction
See Also:
SJServerAction.actionPerformed(SJRequest, SJResponse, ArchiveContext)


public void initPlugin(java.util.Map params)
                throws MissingParamException
Warning! If you override this method, be sure to call super.initPlugin().

Specified by:
initPlugin in interface SJServerPlugin

Copyright 2003 Soucejammer project.