Weaver 3.1.0a1-D1

com.oldlight.weaver.apploader
Class WeaverDomApplicationBuilder

java.lang.Object
  extended bycom.oldlight.weaver.apploader.WeaverDomApplicationBuilder

public class WeaverDomApplicationBuilder
extends Object


Field Summary
private  WeaverApplication application
           
private static String ATTRIBUTE_APPLICATION_NAME
           
private static String ATTRIBUTE_AUTHOR_EMAIL
           
private static String ATTRIBUTE_AUTHOR_NAME
           
private static String ATTRIBUTE_CLASS
           
private static String ATTRIBUTE_DATE
           
private static String ATTRIBUTE_NAME
           
private static String ATTRIBUTE_SIGNATURE
           
private static String ATTRIBUTE_VENDOR_NAME
           
private static String ATTRIBUTE_VERSION
           
private  HashMap beanNamesToInstances
           
private static int ELEMENT_APPLICATION
           
private static int ELEMENT_DEFAULT
           
private static int ELEMENT_DESTROY
           
private static int ELEMENT_DISPATCH
           
private static int ELEMENT_FUNCTION
           
private static int ELEMENT_INFORMATION
           
private static int ELEMENT_INIT
           
private static int ELEMENT_LOAD_BEAN
           
private static int ELEMENT_LOAD_BEANS
           
private static int ELEMENT_LOAD_FUNCTIONS
           
private static int ELEMENT_MAIN
           
private static String ELEMENT_NAME_APPLICATION
           
private static String ELEMENT_NAME_BEAN
           
private static String ELEMENT_NAME_DEFAULT
           
private static String ELEMENT_NAME_DESTROY
           
private static String ELEMENT_NAME_DISPATCH
           
private static String ELEMENT_NAME_FUNCTION
           
private static String ELEMENT_NAME_INFORMATION
           
private static String ELEMENT_NAME_INIT
           
private static String ELEMENT_NAME_LOAD_BEANS
           
private static String ELEMENT_NAME_LOAD_FUNCTIONS
           
private static String ELEMENT_NAME_MAIN
           
private static String ELEMENT_NAME_SECURITY
           
private static String ELEMENT_NAME_SESSION
           
private static String ELEMENT_NAME_TIMED_OUT
           
private static String ELEMENT_NAME_WEAVER
           
private static int ELEMENT_SECURITY
           
private static int ELEMENT_SESSION
           
private static int ELEMENT_TIMED_OUT
           
private static int ELEMENT_WEAVER
           
private static HashMap elements
          A mapping between the string values in the Weaver configuration file and ELEMENT_* constants
private  Logger l
           
private  WeaverWADFileLocation locations
           
private  WeaverDomComponentBuilderRegistry registry
           
 
Constructor Summary
WeaverDomApplicationBuilder()
           
 
Method Summary
 WeaverApplication createApplication(Document document, WeaverWADFileLocation locations, WeaverDomComponentBuilderRegistry registry)
           
private  void doApplication(Node node)
           
private  void doInformation(Node node)
           
private  void doLoadBean(Node node)
           
private  void doLoadBeans(Node node)
           
private  void doLoadFunction(Node node)
           
private  void doLoadFunctions(Node node)
           
private  void doMain(Node node)
           
private  void doSection(WeaverWadSection section, Node node)
           
private  void doSession(Node node)
           
private  void doWeaver(Node node)
           
private  String getAttributeValueByName(String name, NamedNodeMap attributes)
           
 WeaverBean getBean(String name)
           
 WeaverDomComponentBuilder getBuilder(String name)
           
 WeaverFileLocation getLocation(Node node)
           
private  void parseWad(Node node)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ATTRIBUTE_APPLICATION_NAME

private static final String ATTRIBUTE_APPLICATION_NAME
See Also:
Constant Field Values

ATTRIBUTE_AUTHOR_EMAIL

private static final String ATTRIBUTE_AUTHOR_EMAIL
See Also:
Constant Field Values

ATTRIBUTE_AUTHOR_NAME

private static final String ATTRIBUTE_AUTHOR_NAME
See Also:
Constant Field Values

ATTRIBUTE_CLASS

private static final String ATTRIBUTE_CLASS
See Also:
Constant Field Values

ATTRIBUTE_DATE

private static final String ATTRIBUTE_DATE
See Also:
Constant Field Values

ATTRIBUTE_NAME

private static final String ATTRIBUTE_NAME
See Also:
Constant Field Values

ATTRIBUTE_VENDOR_NAME

private static final String ATTRIBUTE_VENDOR_NAME
See Also:
Constant Field Values

ATTRIBUTE_VERSION

private static final String ATTRIBUTE_VERSION
See Also:
Constant Field Values

ATTRIBUTE_SIGNATURE

private static final String ATTRIBUTE_SIGNATURE
See Also:
Constant Field Values

ELEMENT_WEAVER

private static final int ELEMENT_WEAVER
See Also:
Constant Field Values

ELEMENT_INFORMATION

private static final int ELEMENT_INFORMATION
See Also:
Constant Field Values

ELEMENT_LOAD_BEANS

private static final int ELEMENT_LOAD_BEANS
See Also:
Constant Field Values

ELEMENT_LOAD_BEAN

private static final int ELEMENT_LOAD_BEAN
See Also:
Constant Field Values

ELEMENT_APPLICATION

private static final int ELEMENT_APPLICATION
See Also:
Constant Field Values

ELEMENT_SESSION

private static final int ELEMENT_SESSION
See Also:
Constant Field Values

ELEMENT_DEFAULT

private static final int ELEMENT_DEFAULT
See Also:
Constant Field Values

ELEMENT_TIMED_OUT

private static final int ELEMENT_TIMED_OUT
See Also:
Constant Field Values

ELEMENT_INIT

private static final int ELEMENT_INIT
See Also:
Constant Field Values

ELEMENT_DESTROY

private static final int ELEMENT_DESTROY
See Also:
Constant Field Values

ELEMENT_MAIN

private static final int ELEMENT_MAIN
See Also:
Constant Field Values

ELEMENT_DISPATCH

private static final int ELEMENT_DISPATCH
See Also:
Constant Field Values

ELEMENT_LOAD_FUNCTIONS

private static final int ELEMENT_LOAD_FUNCTIONS
See Also:
Constant Field Values

ELEMENT_FUNCTION

private static final int ELEMENT_FUNCTION
See Also:
Constant Field Values

ELEMENT_SECURITY

private static final int ELEMENT_SECURITY
See Also:
Constant Field Values

ELEMENT_NAME_WEAVER

private static final String ELEMENT_NAME_WEAVER
See Also:
Constant Field Values

ELEMENT_NAME_INFORMATION

private static final String ELEMENT_NAME_INFORMATION
See Also:
Constant Field Values

ELEMENT_NAME_LOAD_BEANS

private static final String ELEMENT_NAME_LOAD_BEANS
See Also:
Constant Field Values

ELEMENT_NAME_BEAN

private static final String ELEMENT_NAME_BEAN
See Also:
Constant Field Values

ELEMENT_NAME_APPLICATION

private static final String ELEMENT_NAME_APPLICATION
See Also:
Constant Field Values

ELEMENT_NAME_SESSION

private static final String ELEMENT_NAME_SESSION
See Also:
Constant Field Values

ELEMENT_NAME_DEFAULT

private static final String ELEMENT_NAME_DEFAULT
See Also:
Constant Field Values

ELEMENT_NAME_TIMED_OUT

private static final String ELEMENT_NAME_TIMED_OUT
See Also:
Constant Field Values

ELEMENT_NAME_INIT

private static final String ELEMENT_NAME_INIT
See Also:
Constant Field Values

ELEMENT_NAME_DESTROY

private static final String ELEMENT_NAME_DESTROY
See Also:
Constant Field Values

ELEMENT_NAME_MAIN

private static final String ELEMENT_NAME_MAIN
See Also:
Constant Field Values

ELEMENT_NAME_DISPATCH

private static final String ELEMENT_NAME_DISPATCH
See Also:
Constant Field Values

ELEMENT_NAME_LOAD_FUNCTIONS

private static final String ELEMENT_NAME_LOAD_FUNCTIONS
See Also:
Constant Field Values

ELEMENT_NAME_FUNCTION

private static final String ELEMENT_NAME_FUNCTION
See Also:
Constant Field Values

ELEMENT_NAME_SECURITY

private static final String ELEMENT_NAME_SECURITY
See Also:
Constant Field Values

elements

private static HashMap elements
A mapping between the string values in the Weaver configuration file and ELEMENT_* constants


l

private Logger l

registry

private WeaverDomComponentBuilderRegistry registry

application

private WeaverApplication application

locations

private WeaverWADFileLocation locations

beanNamesToInstances

private HashMap beanNamesToInstances
Constructor Detail

WeaverDomApplicationBuilder

public WeaverDomApplicationBuilder()
Method Detail

createApplication

public WeaverApplication createApplication(Document document,
                                           WeaverWADFileLocation locations,
                                           WeaverDomComponentBuilderRegistry registry)
                                    throws WeaverParseException
Throws:
WeaverParseException

parseWad

private void parseWad(Node node)
               throws WeaverParseException
Throws:
WeaverParseException

doWeaver

private void doWeaver(Node node)
               throws WeaverParseException
Throws:
WeaverParseException

doApplication

private void doApplication(Node node)
                    throws WeaverParseException
Throws:
WeaverParseException

doSession

private void doSession(Node node)
                throws WeaverParseException
Throws:
WeaverParseException

doMain

private void doMain(Node node)
             throws WeaverParseException
Throws:
WeaverParseException

doSection

private void doSection(WeaverWadSection section,
                       Node node)
                throws WeaverParseException
Throws:
WeaverParseException

getLocation

public WeaverFileLocation getLocation(Node node)

getBuilder

public WeaverDomComponentBuilder getBuilder(String name)

doLoadFunctions

private void doLoadFunctions(Node node)
                      throws WeaverParseException
Throws:
WeaverParseException

doLoadFunction

private void doLoadFunction(Node node)
                     throws WeaverParseException
Throws:
WeaverParseException

doLoadBeans

private void doLoadBeans(Node node)
                  throws WeaverParseException
Throws:
WeaverParseException

doLoadBean

private void doLoadBean(Node node)
                 throws WeaverParseException
Throws:
WeaverParseException

getBean

public WeaverBean getBean(String name)

doInformation

private void doInformation(Node node)
                    throws WeaverParseException
Throws:
WeaverParseException

getAttributeValueByName

private String getAttributeValueByName(String name,
                                       NamedNodeMap attributes)

Copyright ©Paul Harvey