Package org.intermine.web.struts
Class InitialiserPlugin
- java.lang.Object
-
- org.intermine.web.struts.InitialiserPlugin
-
- All Implemented Interfaces:
org.apache.struts.action.PlugIn
public class InitialiserPlugin extends java.lang.Object implements org.apache.struts.action.PlugIn
Initialiser for the InterMine web application. Anything that needs global initialisation goes here.- Author:
- Andrew Varley, Thomas Riley
-
-
Field Summary
Fields Modifier and Type Field Description static java.util.List<java.lang.String>
PUBLIC_TAG_LIST
The list of tags that mark something as public
-
Constructor Summary
Constructors Constructor Description InitialiserPlugin()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected static void
cleanTags(TagManager tagManager)
Remove class tags from the user profile that refer to classes that non longer existvoid
destroy()
Destroy method called at Servlet destroy.protected static java.util.Set<java.lang.String>
getChildren(ClassDescriptor cld)
Get the names of the type of this ClassDescriptor and all its descendantsprotected static void
getChildren(ClassDescriptor cld, java.util.Set<java.lang.String> children)
Add the names of the descendents of a ClassDescriptor to a Setvoid
init(org.apache.struts.action.ActionServlet servlet, org.apache.struts.config.ModuleConfig config)
Init method called at Servlet initialisation
-
-
-
Method Detail
-
init
public void init(org.apache.struts.action.ActionServlet servlet, org.apache.struts.config.ModuleConfig config) throws javax.servlet.ServletException
Init method called at Servlet initialisation- Specified by:
init
in interfaceorg.apache.struts.action.PlugIn
- Parameters:
servlet
- ActionServlet that is managing all the modules in this web applicationconfig
- ModuleConfig for the module with which this plug-in is associated- Throws:
javax.servlet.ServletException
- if thisPlugIn
cannot be successfully initialized
-
destroy
public void destroy()
Destroy method called at Servlet destroy. Close connection pools and the mail queue thread pool.- Specified by:
destroy
in interfaceorg.apache.struts.action.PlugIn
-
cleanTags
protected static void cleanTags(TagManager tagManager)
Remove class tags from the user profile that refer to classes that non longer exist- Parameters:
tagManager
- tag manager
-
getChildren
protected static java.util.Set<java.lang.String> getChildren(ClassDescriptor cld)
Get the names of the type of this ClassDescriptor and all its descendants- Parameters:
cld
- the ClassDescriptor- Returns:
- a Set of class names
-
getChildren
protected static void getChildren(ClassDescriptor cld, java.util.Set<java.lang.String> children)
Add the names of the descendents of a ClassDescriptor to a Set- Parameters:
cld
- the ClassDescriptorchildren
- the Set of child names
-
-