org.openejb.webadmin.ejbgen
Class EJBGenBean

java.lang.Object
  extended by org.openejb.webadmin.WebAdminBean
      extended by org.openejb.webadmin.ejbgen.EJBGenBean
All Implemented Interfaces:
java.io.Serializable, javax.ejb.EnterpriseBean, javax.ejb.SessionBean, HttpBean

public class EJBGenBean
extends WebAdminBean

Page for user to input needed data to build EJB Skeleton.

Author:
Jeremy Whitlock
See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.openejb.webadmin.WebAdminBean
ejbContext, footer, HTML_TITLE, request, response, section, sections, SUBSTITUTE
 
Constructor Summary
EJBGenBean()
           
 
Method Summary
 void ejbCreate()
          Called after a new instance of EJBGenBean is created
 java.lang.String getBeanDir()
          This method is used to get the path to where the EJB Template's source is stored locally on the computer.
 java.lang.String getBeanURL()
          This method is used to get the proper URL to the files for local access only.
 void postProcess(HttpRequest request, HttpResponse response)
          called after all content is written to the browser
 void preProcess(HttpRequest request, HttpResponse response)
          called before any content is written to the browser
 void showBeanFiles(java.io.PrintWriter body)
          This is the response after a good EJB Template generation
 void writeBody(java.io.PrintWriter body)
          writes the main body content to the broswer.
 void writeHtmlTitle(java.io.PrintWriter body)
          Write the TITLE of the HTML document.
 void writePageTitle(java.io.PrintWriter body)
          Write the title of the page.
 void writeSubMenuItems(java.io.PrintWriter body)
          Write the sub items for this bean in the left navigation bar of the page.
 
Methods inherited from class org.openejb.webadmin.WebAdminBean
ejbActivate, ejbPassivate, ejbRemove, formatSubMenuItem, getFooter, getTemplate, initNavSections, onMessage, printRow, printRow, setSessionContext, writeFooter, writeLeftNavBar, writeTemplate, writeTopNavBar
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EJBGenBean

public EJBGenBean()
Method Detail

ejbCreate

public void ejbCreate()
Called after a new instance of EJBGenBean is created

Overrides:
ejbCreate in class WebAdminBean

postProcess

public void postProcess(HttpRequest request,
                        HttpResponse response)
                 throws java.io.IOException
called after all content is written to the browser

Specified by:
postProcess in class WebAdminBean
Parameters:
request - the http request
response - the http response
Throws:
java.io.IOException - if an exception is thrown

preProcess

public void preProcess(HttpRequest request,
                       HttpResponse response)
                throws java.io.IOException
called before any content is written to the browser

Specified by:
preProcess in class WebAdminBean
Parameters:
request - the http request
response - the http response
Throws:
java.io.IOException - if an exception is thrown

writeBody

public void writeBody(java.io.PrintWriter body)
               throws java.io.IOException
writes the main body content to the broswer. This content is inside a <p> block.

Specified by:
writeBody in class WebAdminBean
Parameters:
body - the output to write to
Throws:
java.io.IOException - if an exception is thrown

writeHtmlTitle

public void writeHtmlTitle(java.io.PrintWriter body)
                    throws java.io.IOException
Write the TITLE of the HTML document. This is the part that goes into the <head><title> </title></head> tags

Specified by:
writeHtmlTitle in class WebAdminBean
Parameters:
body - the output to write to
Throws:
java.io.IOException - of an exception is thrown

writePageTitle

public void writePageTitle(java.io.PrintWriter body)
                    throws java.io.IOException
Write the title of the page. This is displayed right above the main block of content.

Specified by:
writePageTitle in class WebAdminBean
Parameters:
body - the output to write to
Throws:
java.io.IOException - if an exception is thrown

writeSubMenuItems

public void writeSubMenuItems(java.io.PrintWriter body)
                       throws java.io.IOException
Write the sub items for this bean in the left navigation bar of the page. This should look somthing like the one below: <tr> <td valign="top" align="left"> <a href="system?show=deployments"><span class="subMenuOff">    Deployments </span> </a></td> </tr> Alternately, the bean can use the method formatSubMenuItem(..) which will create HTML like the one above

Parameters:
body - the output to write to
Throws:
java.io.IOException - if an exception is thrown

getBeanDir

public java.lang.String getBeanDir()
This method is used to get the path to where the EJB Template's source is stored locally on the computer.

Returns:
Returns the full path to the local directory

getBeanURL

public java.lang.String getBeanURL()
This method is used to get the proper URL to the files for local access only.

Returns:
Returns the proper URL appendage to be added to the URL for proper file access

showBeanFiles

public void showBeanFiles(java.io.PrintWriter body)
This is the response after a good EJB Template generation

Parameters:
body - PrinterWriter is passed from the writeBody() method


Copyright © 1999-2011 OpenEJB. All Rights Reserved.