|
SOAj Core v. 1.3 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectinfo.soaj.core.util.SjGeneralStore
public class SjGeneralStore
This utility class provides static methods for creating an instance of a plugin declared as active.
In addition, there are two distinct strategies for managing (launching) the
initialization of the SOAj Core Framework and activation of plugins. The
first option is to invoke one of the static activateSOAj()
methods contained in this class:
// Use the default descriptor document name.
SjGeneralStore.activateSOAj();
// Else, use the specified descriptor document name.
SjGeneralStore.activateSOAj("soaj-mypluginproject.xml");
The second option is to use the ServletContextListener and
declare similarly to the following web.xml document elements:
<listener>
<listener-class>info.soaj.core.listener.SjFrameworkActivationManager</listener-class>
</listener>
The decision to use the static method or the listener approach is guided by
the type of JVM being launched.
Java Applet - Static Method
Java Application - Static Method
JUnit-style Test - Static Method (Typically outside-the-container approach.)
Web Application - Servlet Context Listener
In either case, the activation methods take on a controller role for the six
phases of the plugin Activation Sequence.
Phase One - Retrieve Properties
Phase Two - Create Active
Phase Three - Initialize Active
Phase Four - Verify Active
Phase Five - Report Status
Phase Six - Log Context
Copyright (c) 2006 - 2009 by Global Technology Consulting Group, Inc. at gtcGroup.com .
| Field Summary | |
|---|---|
private static SjCacher |
cache
Reference to caching singleton. |
static java.lang.String |
CLASS_NAME
Class name. |
private static java.lang.String |
DELIMITER
Cosmetic delimiter string for logging. |
| Constructor Summary | |
|---|---|
private |
SjGeneralStore()
Private Constructor |
| Method Summary | ||
|---|---|---|
static boolean |
activateSOAj()
This synchronized method executes the phases of the SOAj core framework Activation Sequence using the default name for the descriptor document. |
|
static boolean |
activateSOAj(java.lang.String documentName)
This synchronized method executes the phases of the SOAj core framework Activation Sequence using a client supplied descriptor document name. |
|
static boolean |
containsActivePlugin(java.lang.String pluginKey)
This method determines whether an active plugin is declared and available for creation. |
|
static boolean |
containsInactivePlugin(java.lang.String pluginKey)
This method determines whether plugin key is declared inactive. |
|
static
|
createPlugin(java.lang.Class<PLUGIN> pluginAbstractClass,
java.lang.String pluginKey)
This method returns a plugin instance. |
|
static
|
createPlugin(java.lang.Class<PLUGIN> pluginAbstractClass,
java.lang.String pluginKey,
boolean suppressException)
This overloaded method returns a plugin instance. |
|
static SjAbstractPluginLogging |
createPluginForLogging()
This convenience method returns a logging plugin instance. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String CLASS_NAME
private static final SjCacher cache
private static final java.lang.String DELIMITER
| Constructor Detail |
|---|
private SjGeneralStore()
| Method Detail |
|---|
public static boolean containsActivePlugin(java.lang.String pluginKey)
pluginKey - The 'Key' defined in the descriptor document.
public static boolean containsInactivePlugin(java.lang.String pluginKey)
pluginKey - The 'Key' defined in the descriptor document.
public static <PLUGIN extends SjBasePlugin> PLUGIN createPlugin(java.lang.Class<PLUGIN> pluginAbstractClass,
java.lang.String pluginKey)
PLUGIN - Generic bounded type parameter.pluginAbstractClass - Typically the plugin's abstract super class.pluginKey - The 'Key' defined in the descriptor document.
public static <PLUGIN extends SjBasePlugin> PLUGIN createPlugin(java.lang.Class<PLUGIN> pluginAbstractClass,
java.lang.String pluginKey,
boolean suppressException)
null returned (as
specified by the client).
PLUGIN - pluginAbstractClass - Typically the plugin's abstract super class.pluginKey - The 'Key' defined in the descriptor document.suppressException - Indicates whether an exception is thrown if the plugin cannot
be created.
null.public static SjAbstractPluginLogging createPluginForLogging()
SjPluginLoggingSystemOut instance.
public static boolean activateSOAj()
throws SjCoreExceptionActivationSequence
boolean
indicates whether activation was completed successfully. THIS
METHOD IS EXPLICITLY INVOKED IF THE
SjFrameworkActivationManager CLASS IS *NOT* BEING USED AS A
LISTENER.
SjCoreExceptionActivationSequence
public static boolean activateSOAj(java.lang.String documentName)
throws SjCoreExceptionActivationSequence
boolean
indicates whether activation was completed successfully. THIS
METHOD IS EXPLICITLY INVOKED IF THE
SjFrameworkActivationManager CLASS IS *NOT* BEING USED AS A
LISTENER.
documentName - Descriptor document available on class path.
SjCoreExceptionActivationSequence
|
SOAj Core v. 1.3 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Copyright (c) 2006 - 2009 by Global Technology Consulting Group, Inc. at gtcGroup.com.
Use is authorized, provided the source is acknowledged by inclusion of this copyright notice.