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


org.apache.turbine.services.TurbineBaseService
   org.apache.turbine.services.ui.TurbineUIService

TurbineUIService
public class TurbineUIService extends TurbineBaseService implements UIService(Code)
The UI service provides for shared access to User Interface (skin) files, as well as the ability for non-default skin files to inherit properties from a default skin. Use TurbineUI to access skin properties from your screen classes and action code. UITool is provided as a pull tool for accessing skin properties from your templates.
author:
   Jason van Zyl
author:
   James Coltman
author:
   Henning P. Schmiedehausen
author:
   Scott Eade
author:
   Thomas Vandahl
version:
   $Id$
See Also:   UIService
See Also:   UITool


Field Summary
final public static  StringSKIN_PROPERTY_DEFAULT
     Default skin name.


Method Summary
public  Stringget(String skinName, String key)
     Retrieve a skin property from the named skin.
public  Stringget(String key)
     Retrieve a skin property from the default skin for the webapp.
public  StringgetScript(String skinName, String filename, ServerData serverData)
     Retrieve the URL for a given script that is part of a skin.
public  StringgetScript(String skinName, String filename)
     Retrieve the URL for a given script that is part of a skin.
public  String[]getSkinNames()
     Provide access to the list of available skin names.
public  StringgetStylecss(String skinName, ServerData serverData)
     Retrieve the URL for the style sheet that is part of a skin.
public  StringgetStylecss(String skinName)
     Retrieve the URL for the style sheet that is part of a skin.
public  StringgetWebappSkinName()
     Get the name of the default skin name for the web application from the TurbineResources.properties file.
public  Stringimage(String skinName, String imageId, ServerData serverData)
     Retrieve the URL for an image that is part of a skin.
public  Stringimage(String skinName, String imageId)
     Retrieve the URL for an image that is part of a skin.
public  voidinit()
     Initializes the service.
public  voidrefresh()
     Refresh the service by clearing all skins.
public  voidrefresh(String skinName)
     Refresh a particular skin by clearing it.
public  voidshutdown()
     Returns to uninitialized state.

Field Detail
SKIN_PROPERTY_DEFAULT
final public static String SKIN_PROPERTY_DEFAULT(Code)
Default skin name. This name refers to a directory in the WEBAPP/resources/ui/skins directory. There is a file called skin.props which contains the name/value pairs to be made available via the skin.





Method Detail
get
public String get(String skinName, String key)(Code)
Retrieve a skin property from the named skin. If the property is not defined in the named skin the value for the default skin will be provided. If the named skin does not exist then the skin configured for the webapp will be used. If the webapp skin does not exist the default skin will be used. If the default skin does not exist then null will be returned.
Parameters:
  skinName - the name of the skin to retrieve the property from.
Parameters:
  key - the key to retrieve from the skin. the value of the property for the named skin (defaulting to the default skin), the webapp skin, the default skin or null,depending on whether or not the property or skins exist.



get
public String get(String key)(Code)
Retrieve a skin property from the default skin for the webapp. If the property is not defined in the webapp skin the value for the default skin will be provided. If the webapp skin does not exist the default skin will be used. If the default skin does not exist then null will be returned.
Parameters:
  key - the key to retrieve. the value of the property for the webapp skin (defaulting to the default skin), the default skin or null, depending on whether or not the property or skins exist.



getScript
public String getScript(String skinName, String filename, ServerData serverData)(Code)
Retrieve the URL for a given script that is part of a skin. The script is stored in the WEBAPP/resources/ui/skins/[SKIN] directory.

Use this if for some reason your server name, server scheme, or server port change on a per request basis. I'm not sure if this would happen in a load balanced situation. I think in most cases the style() method would probably be enough, but I'm not absolutely positive.
Parameters:
  skinName - the name of the skin to retrieve the image from.
Parameters:
  filename - the name of the script file.
Parameters:
  serverData - the serverData to use as the basis for the URL.




getScript
public String getScript(String skinName, String filename)(Code)
Retrieve the URL for a given script that is part of a skin. The script is stored in the WEBAPP/resources/ui/skins/[SKIN] directory.
Parameters:
  skinName - the name of the skin to retrieve the image from.
Parameters:
  filename - the name of the script file.



getSkinNames
public String[] getSkinNames()(Code)
Provide access to the list of available skin names. the available skin names.



getStylecss
public String getStylecss(String skinName, ServerData serverData)(Code)
Retrieve the URL for the style sheet that is part of a skin. The style is stored in the WEBAPP/resources/ui/skins/[SKIN] directory with the filename skin.css

Use this if for some reason your server name, server scheme, or server port change on a per request basis. I'm not sure if this would happen in a load balanced situation. I think in most cases the style() method would probably be enough, but I'm not absolutely positive.
Parameters:
  skinName - the name of the skin to retrieve the style sheet from.
Parameters:
  serverData - the serverData to use as the basis for the URL.




getStylecss
public String getStylecss(String skinName)(Code)
Retrieve the URL for the style sheet that is part of a skin. The style is stored in the WEBAPP/resources/ui/skins/[SKIN] directory with the filename skin.css
Parameters:
  skinName - the name of the skin to retrieve the style sheet from.



getWebappSkinName
public String getWebappSkinName()(Code)
Get the name of the default skin name for the web application from the TurbineResources.properties file. If the property is not present the name of the default skin will be returned. Note that the web application skin name may be something other than default, in which case its properties will default to the skin with the name "default". the name of the default skin for the web application.



image
public String image(String skinName, String imageId, ServerData serverData)(Code)
Retrieve the URL for an image that is part of a skin. The images are stored in the WEBAPP/resources/ui/skins/[SKIN]/images directory.

Use this if for some reason your server name, server scheme, or server port change on a per request basis. I'm not sure if this would happen in a load balanced situation. I think in most cases the image(String image) method would probably be enough, but I'm not absolutely positive.
Parameters:
  skinName - the name of the skin to retrieve the image from.
Parameters:
  imageId - the id of the image whose URL will be generated.
Parameters:
  serverData - the serverData to use as the basis for the URL.




image
public String image(String skinName, String imageId)(Code)
Retrieve the URL for an image that is part of a skin. The images are stored in the WEBAPP/resources/ui/skins/[SKIN]/images directory.
Parameters:
  skinName - the name of the skin to retrieve the image from.
Parameters:
  imageId - the id of the image whose URL will be generated.



init
public void init() throws InitializationException(Code)
Initializes the service.



refresh
public void refresh()(Code)
Refresh the service by clearing all skins.



refresh
public void refresh(String skinName)(Code)
Refresh a particular skin by clearing it.
Parameters:
  skinName - the name of the skin to clear.



shutdown
public void shutdown()(Code)
Returns to uninitialized state.



Methods inherited from org.apache.turbine.services.TurbineBaseService
public void init(Object data) throws InitializationException(Code)(Java Doc)
public void init(ServletConfig config) throws InitializationException(Code)(Java Doc)
public void init(RunData data) throws InitializationException(Code)(Java Doc)
public void init() throws InitializationException(Code)(Java Doc)
public void shutdown()(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.