Java Doc for DefaultServiceWriter.java in  » J2EE » Expresso » com » jcorporate » expresso » kernel » management » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » J2EE » Expresso » com.jcorporate.expresso.kernel.management 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.jcorporate.expresso.kernel.ComponentBase
      com.jcorporate.expresso.kernel.management.DefaultServiceWriter

DefaultServiceWriter
public class DefaultServiceWriter extends ComponentBase implements ServiceWriter,ComponentLifecycle(Code)
Default Implementation of the class used to write the ExpressoServices configuration file to a file or stream. This class is an ExpressoComponent that receives various configuration items from the system.

This class also keeps keeps intact an instance of a DOM Writer. The particular implementation class for the DOMWriter depends on the contents of the Expresso Configuration file.


author:
   Michael Rimov
version:
   $Revision: 1.5 $ on $Date: 2004/11/17 20:48:17 $


Field Summary
 DOMWriterdomWriter
    
 StringdomWriterClass
    

Constructor Summary
public  DefaultServiceWriter()
    

Method Summary
protected  DocumentbuildDOMTree(ExpressoServicesConfig configRoot)
     Convert the ExpressoServicesConfig bean to a DOM document that's compatible with what is expected in the expresso-services.xml file.
Parameters:
  configRoot - the root of the configuration tree.
public  voidconfigure(Configuration newConfig)
     Configure the DefaultServiceWriter.
public  voiddestroy()
     Implementation of the Destroy() lifecycle event.
public  DOMWritergetDOMWriter()
     Retrieves the DOMWriter isntantiated class.
public  StringgetDomWriterClass()
    
public  voidinitialize()
    
protected  voidprocessComponent(ComponentConfig config, Element parent, Document dom)
     Recursively go through the Expresso-services.config and convert all the various components into the DOM tree.
protected  voidprocessComponentProperties(ComponentConfig config, Element parent, Document dom)
     Write the current component's configuration to the current DOM element.
public  voidreconfigure(Configuration newConfig)
     Reconfigure lifecycle event for this component.
public  voidsetDomWriterClass(String domWriterClass)
     Sets and loads the specified domWriter class.
public  voidwriteServicesFile(RootContainerInterface rootContainer, String location)
     Write the services file to a particular file location.
Parameters:
  rootContainer - The RootContainer interface that will contain baseinformation about the system state we are about to save.
Parameters:
  location - The location to save the services file.
public  voidwriteServicesFile(RootContainerInterface rootContainer, OutputStream os)
    

Field Detail
domWriter
DOMWriter domWriter(Code)



domWriterClass
String domWriterClass(Code)




Constructor Detail
DefaultServiceWriter
public DefaultServiceWriter()(Code)
Default Constructor




Method Detail
buildDOMTree
protected Document buildDOMTree(ExpressoServicesConfig configRoot) throws ExpressoRuntimeException(Code)
Convert the ExpressoServicesConfig bean to a DOM document that's compatible with what is expected in the expresso-services.xml file.
Parameters:
  configRoot - the root of the configuration tree. a DOM document representing the entire tree.
throws:
  ExpressoRuntimeException - if there is an error building the DOM tree



configure
public void configure(Configuration newConfig) throws ConfigurationException(Code)
Configure the DefaultServiceWriter. The chief configuration value is the domWriter class, which describes which implementation to use for writing out DOM documents.
Parameters:
  newConfig - the Configuration object to load items from.
throws:
  ConfigurationException - if the domWriterClass cannot be instantiated



destroy
public void destroy()(Code)
Implementation of the Destroy() lifecycle event. nulls out all member properties.



getDOMWriter
public DOMWriter getDOMWriter()(Code)
Retrieves the DOMWriter isntantiated class. May be null if the component was unable to load the specified system. an instantiated DOMWRiter for file writing.



getDomWriterClass
public String getDomWriterClass()(Code)
Retrieves the previously set classname of the Dom Writer java.lang.String



initialize
public void initialize()(Code)



processComponent
protected void processComponent(ComponentConfig config, Element parent, Document dom)(Code)
Recursively go through the Expresso-services.config and convert all the various components into the DOM tree.
Parameters:
  config - the current config bean in the tree
Parameters:
  parent - the Parent DOM Element to append items to
Parameters:
  dom - the DOM tree, used for building the various elements in the DOM tree.



processComponentProperties
protected void processComponentProperties(ComponentConfig config, Element parent, Document dom)(Code)
Write the current component's configuration to the current DOM element.
Parameters:
  config - the current config to glean the properties from
Parameters:
  parent - the parent element to append properties to as children.
Parameters:
  dom - the DOM tree to use for Element factores



reconfigure
public void reconfigure(Configuration newConfig) throws ConfigurationException(Code)
Reconfigure lifecycle event for this component. It attempts to load a new DOMWriter class, however, if unable to do so, it will rollback the configuration internally and throw a ConfigurationException.
Parameters:
  newConfig - the Configuration object to load items from.
throws:
  ConfigurationException - if the system is unable to load the new DOMWriterclass specified.



setDomWriterClass
public void setDomWriterClass(String domWriterClass) throws ExpressoRuntimeException(Code)
Sets and loads the specified domWriter class.
Parameters:
  domWriterClass - The classname of the DOMWriter to load



writeServicesFile
public void writeServicesFile(RootContainerInterface rootContainer, String location) throws ExpressoRuntimeException(Code)
Write the services file to a particular file location.
Parameters:
  rootContainer - The RootContainer interface that will contain baseinformation about the system state we are about to save.
Parameters:
  location - The location to save the services file. (File name should be includedin this parameter).
throws:
  ExpressoRuntimeException - upon error.



writeServicesFile
public void writeServicesFile(RootContainerInterface rootContainer, OutputStream os) throws ExpressoRuntimeException(Code)
Write the services file to a particular output stream
Parameters:
  rootContainer - The RootContainer interface that will contain baseinformation about the system state we are about to save.
Parameters:
  os - The output stream to save the services file to.
throws:
  ExpressoRuntimeException - upon error.



Methods inherited from com.jcorporate.expresso.kernel.ComponentBase
public synchronized ComponentMetadata getMetaData()(Code)(Java Doc)
public synchronized URL getMetadataLocation()(Code)(Java Doc)
public synchronized Containable getParent()(Code)(Java Doc)
public synchronized void setMetaData(ComponentMetadata metadata)(Code)(Java Doc)
public synchronized void setParent(Containable parent)(Code)(Java Doc)

Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.