Java Doc for TemplateScreen.java in  » Web-Framework » TURBINE » org » apache » turbine » modules » screens » 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 » Web Framework » TURBINE » org.apache.turbine.modules.screens 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.apache.turbine.modules.Screen
   org.apache.turbine.modules.screens.TemplateScreen

All known Subclasses:   org.apache.turbine.modules.screens.BaseJspScreen,  org.apache.turbine.modules.screens.VelocityScreen,
TemplateScreen
abstract public class TemplateScreen extends Screen (Code)
Template Screen. Base Template Screens should extend this class and override the buildTemplate() method. Users of the particular service can then override the doBuildTemplate() for any specific pre-processing. You can also override the doBuild() method in order to add extra functionality to your system, but you need to make sure to at least duplicate the existing functionality in order for things to work. Look at the code for the doBuild() method to get an idea of what is going on there (it is quite simple really).
author:
   Dave Bryson
author:
   Henning P. Schmiedehausen
version:
   $Id: TemplateScreen.java 534527 2007-05-02 16:10:59Z tv $


Field Summary
protected  Loglog
    


Method Summary
abstract public  ConcreteElementbuildTemplate(RunData data)
     This method should be implemented by Base template classes.
protected  ConcreteElementdoBuild(RunData data)
     This method is called by the Screenloader to construct the Screen.
Parameters:
  data - Turbine information.
abstract protected  voiddoBuildTemplate(RunData data)
     This method should be overidden by subclasses that wish to add specific business logic.
protected  voiddoPostBuildTemplate(RunData data)
    
public  voiddoRedirect(RunData data, String screen, String template)
     You can call this within a Screen to cause an internal redirect to happen.
public  voiddoRedirect(RunData data, String template)
     You can call this within a Screen to cause an internal redirect to happen.
public static  voidsetTemplate(RunData data, String template)
     This method is used when you want to short circuit a Screen and change the template that will be executed next.

Field Detail
log
protected Log log(Code)
Logging





Method Detail
buildTemplate
abstract public ConcreteElement buildTemplate(RunData data) throws Exception(Code)
This method should be implemented by Base template classes. It should contain the specific template service code to generate the template.
Parameters:
  data - Turbine information. A ConcreteElement.
exception:
  Exception - A generic exception.



doBuild
protected ConcreteElement doBuild(RunData data) throws Exception(Code)
This method is called by the Screenloader to construct the Screen.
Parameters:
  data - Turbine information. A ConcreteElement.
exception:
  Exception - A generic exception.



doBuildTemplate
abstract protected void doBuildTemplate(RunData data) throws Exception(Code)
This method should be overidden by subclasses that wish to add specific business logic.
Parameters:
  data - Turbine information.
exception:
  Exception - A generic exception.



doPostBuildTemplate
protected void doPostBuildTemplate(RunData data)(Code)
This method can be overridden to write code that executes when the template has been built (called from a finally clause, so executes regardless of whether an exception is thrown or not)



doRedirect
public void doRedirect(RunData data, String screen, String template) throws Exception(Code)
You can call this within a Screen to cause an internal redirect to happen. It essentially allows you to stop execution in one Screen and instantly execute another Screen. Don't worry, this does not do a HTTP redirect and also if you have anything added in the Context, it will get carried over.

This class is useful if you have a Screen that submits to another Screen and you want it to do error validation before executing the other Screen. If there is an error, you can doRedirect() back to the original Screen.
Parameters:
  data - Turbine information.
Parameters:
  screen - Name of screen to redirect to.
Parameters:
  template - Name of template.
exception:
  Exception - A generic exception.




doRedirect
public void doRedirect(RunData data, String template) throws Exception(Code)
You can call this within a Screen to cause an internal redirect to happen. It essentially allows you to stop execution in one Screen and instantly execute another Screen. Don't worry, this does not do a HTTP redirect and also if you have anything added in the Context, it will get carried over.

This class is useful if you have a Screen that submits to another Screen and you want it to do error validation before executing the other Screen. If there is an error, you can doRedirect() back to the original Screen.
Parameters:
  data - Turbine information.
Parameters:
  template - Name of template.
exception:
  Exception - A generic exception.




setTemplate
public static void setTemplate(RunData data, String template)(Code)
This method is used when you want to short circuit a Screen and change the template that will be executed next. Note that the current context will be applied to the next template that is executed. If you want to have the context executed for the next screen, to be the same one as the next screen, then you should use the TemplateScreen.doRedirect() method.
Parameters:
  data - Turbine information.
Parameters:
  template - The name of the next template.



Methods inherited from org.apache.turbine.modules.Screen
protected ConcreteElement build(RunData data) throws Exception(Code)(Java Doc)
abstract protected ConcreteElement doBuild(RunData data) throws Exception(Code)(Java Doc)
public String getLayout(RunData data)(Code)(Java Doc)
public static String prepareText(String s)(Code)(Java Doc)
public static String prepareTextMinimum(String s)(Code)(Java Doc)
public void setLayout(RunData data, String layout)(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.