sun java studio creator
TRANSCRIPT
Sun Java Studio Creator
Ken PaulsenStaff EngineerSun Microsystems, Incorporated(Slides by: Craig R. McClanahan)
2 | Seattle Java Users Group â Jan 18, 2005
Agenda
â Backgroundâ Developer characteristicsâ Corporate developersâ Sun Java Studio Creator
â Application Modelâ Overview â Basic componentsâ Under the covers â Additional componentsâ Using data in applicationsâ Page navigation
3 | Seattle Java Users Group â Jan 18, 2005
Agenda
â Other Featuresâ Component Library Importâ Creator Design Time APIs
â Summary
4 | Seattle Java Users Group â Jan 18, 2005
Agenda
â Backgroundâ Developer characteristicsâ Corporate developersâ Sun Java Studio Creator
â Application Modelâ Overview â Basic componentsâ Under the covers â Additional componentsâ Using data in applicationsâ Page navigation and value bindings
5 | Seattle Java Users Group â Jan 18, 2005
The Appeal of Java
â Java has traditionally appealed to technology-savvy developersâ Object orientationâ Type safetyâ Sophisticated, powerful APIs
â But it has often been perceived as âtoo hard to useâ by a significant audience
6 | Seattle Java Users Group â Jan 18, 2005
Corporate Developers
â May not be your typical developersâ May be domain expertsâ Might use VB, 4GLs, or scripting languages
â The applications they create:â Are typically consumers of data and servicesâ Provide rich UI to what may be a complex
underlying system
7 | Seattle Java Users Group â Jan 18, 2005
Corporate Developers
â The bar with most Java IDEs is just too highâ Geared toward techologists / enterprise
developersâ Value = flexibility and richness
â Corporate developers have different requirementsâ Value = simplicity and understandability
â Prefer a complete solution
8 | Seattle Java Users Group â Jan 18, 2005
Tools for Corporate Developers
â More âup frontâ codingâ Design UI, modify attributes, plug in data,
services, and logicâ Heavy re-use and component drag and drop
â Simplified codingâ Does not mean âno codeââ Results should be understandable, obviousâ âTruth in codeââ Cause and effect should be evident
Different development styles
9 | Seattle Java Users Group â Jan 18, 2005
Tools for Corporate Developers
â Platform âpowerââ Must be available, but not required to be
productiveâ Understanding complexity should not be
required
â Resulting applicationsâ Should be standards basedâ Minimal or no required runtime
Different requirements
10 | Seattle Java Users Group â Jan 18, 2005
Sun Java Studio Creator
â Solid IDE platform â NetBeansâ Infrastructure for building a complete
development environmentâ Powerful âstandard IDE fareâ features
â Built with and for Java standardsâ Integrated with SJSAS Platform Editionâ Features standard Java APIsâ Runtime applications are portable
A Tool For The Corporate Developer
11 | Seattle Java Users Group â Jan 18, 2005
DEMO
A Quick Orientation
12 | Seattle Java Users Group â Jan 18, 2005
Agenda
â Backgroundâ Developer characteristicsâ Corporate developersâ Sun Java Studio Creator
â Application Modelâ Overview â Basic componentsâ Under the covers â Additional componentsâ Using data in applicationsâ Page navigation and value bindings
13 | Seattle Java Users Group â Jan 18, 2005
The Application Model
â Applications consist of the following primary elements:â A set of web pages (and Java source)â Configuration (metadata) informationâ Additional logic, services, and runtime codeâ Extra resources as necessary (for example):
â Imagesâ Localizing bundles
High Level View
14 | Seattle Java Users Group â Jan 18, 2005
The Application Model
High Level View
15 | Seattle Java Users Group â Jan 18, 2005
The Application Model
â Each logical page consists of:â JSP Page
â JSF componentsâ Additional markup
â Corresponding Page Beanâ Component instancesâ Event handlersâ Page propertiesâ Methods
Page Level View
16 | Seattle Java Users Group â Jan 18, 2005
DEMO
JSP Pages and Page Beans
17 | Seattle Java Users Group â Jan 18, 2005
The Application Model
â Prebuilt JavaBeans:â PageBean â Per-request properties,
components, event handlersâ SessionBean â Per-user properties required
across requests or pagesâ ApplicationBean â Application wide properties
(such as cached contents for drop down lists)
Under The Covers â Additional Elements
18 | Seattle Java Users Group â Jan 18, 2005
The Application Model
â PageBean Additional Contents:â Event handlers (actions, value changes)â Convertersâ Validators
â Data Source Components:â JDBC Rowsetsâ Web Servicesâ Enterprise JavaBeans
Under The Covers â Additional Elements
19 | Seattle Java Users Group â Jan 18, 2005
Using Data In Applications
â JDBC Rowsets are components:â Non-visual, so represented in the âtrayââ Have properties that can be customizedâ Properties persisted in constructor of the
containing page bean
â Visual binding of rowsets to UI components
â Visual editing of SELECT queries
JDBC Rowsets
20 | Seattle Java Users Group â Jan 18, 2005
DEMO
Binding Rowsets To UI Components #1
21 | Seattle Java Users Group â Jan 18, 2005
Rich Design Time Experience
â As we have seen in the demos so far, Creator provides rich design time facilitiesâ WSYWIG rendering of componentsâ Configuration of components on dropâ Visual binding to properties or servicesâ Context sensitive operations
â Let's see more of this in action
22 | Seattle Java Users Group â Jan 18, 2005
DEMO
Binding Rowsets To UI Components #2
23 | Seattle Java Users Group â Jan 18, 2005
Using Data In Applications
â SOAP-Based Web Services are:â Defined by WSDL resource, which is ...â Located via a URL or a local file
â When you drop a web service onto a page in your application:â Creator generates client stubsâ Adds appropriate libraries to your applicationâ Provides Java API to access web service from
event handlers
Web Services
24 | Seattle Java Users Group â Jan 18, 2005
DEMO
Accessing Web Services (requires net access to deploy)
25 | Seattle Java Users Group â Jan 18, 2005
Using Data In Applications
â You may access stateless session beans that are available on your application server
â When you drop an EJB onto your pageâ Creator builds a client that encapsulates the
EJB lookup and callâ Adds appropriate libraries to your applicationâ Provides Java API to access EJBs from event
handlers
Enterprise JavaBeans (Preview Feature)
26 | Seattle Java Users Group â Jan 18, 2005
DEMO
Accessing Enterprise JavaBeans (Preview Feature)
27 | Seattle Java Users Group â Jan 18, 2005
Page Navigation
â JavaServer Faces supports two approaches to navigation:â Static â Predetermined path to second pageâ Dynamic â Calculate where to go next
â Navigation is based on:â Current page being submittedâ Which submit button was pressedâ Logical âoutcomeâ (or static value) returned
Easy Configuration for Multiple Page Applications
28 | Seattle Java Users Group â Jan 18, 2005
Value Binding Expressions
â JavaServer Faces uses value binding expressions to connect components to underlying model dataâ #{customer.address.city}
â Based on expression language from JSTL 1.0 and JSP 2.0
â Extended to support dynamic bean creation via managed beans facility
Connecting components to data
29 | Seattle Java Users Group â Jan 18, 2005
Method Binding Expressions
â Specialized expressions bind components to event handlersâ #{Page1.submit_action}â public void submit_action() { ... }
â Allows all the event handlers for a page to be combined in one class
â Can be used for actions, validators, and value change listeners
Connecting components to event handlers
30 | Seattle Java Users Group â Jan 18, 2005
DEMO
Using Page Navigation, Value Bindings, and Method Bindings
31 | Seattle Java Users Group â Jan 18, 2005
Agenda
â Other Featuresâ Component Library Importâ Creator Design Time APIs
â Summary
32 | Seattle Java Users Group â Jan 18, 2005
Component Library Import
â Creator supports a mechanism to import third party libraries of JavaServer Faces components
â âComponent Importâ archive contains:â Runtime classes (to include in a webapp)â Design time classes (to be used by Creator)â Metadata (to register components with JSF)
Going Beyond The Standard Components
33 | Seattle Java Users Group â Jan 18, 2005
Component Library Import
â At import time,â Each library gets its own palette sectionâ BeanInfo classes generated (if necessary)
â At design time,â Using third party components is the same drag-
and-drop process as for standard componentsâ Required runtime libraries added to webapp
â At run time,â JSF seamlessly manages all of the components
Going Beyond The Standard Components
34 | Seattle Java Users Group â Jan 18, 2005
Creator Design Time APIs
â Creator supports a rich design time experience for standard components:â Event handlers for drop and link actionsâ Persists configuration in JSP and/or Java codeâ Custom property editors and customizersâ Custom context menu items
â Internally, provided via âCreator Design Time APIs
Support for Third Party Components (Preview Feature)
35 | Seattle Java Users Group â Jan 18, 2005
Creator Design Time APIs
â We are publishing these APIs (as a Preview Feature) for use by third party component developers
â User's Guide for these APIs available on the Creator web site
Support for Third Party Components (Preview Feature)
36 | Seattle Java Users Group â Jan 18, 2005
DEMO
Component Import and Design Time APIs (Preview Feature)
37 | Seattle Java Users Group â Jan 18, 2005
Agenda
â Other Featuresâ Component Library Importâ Creator Design Time APIs
â Summary
38 | Seattle Java Users Group â Jan 18, 2005
Sun Java Studio Creator
â Rich design time user experienceâ Drag-and-drop visual programmingâ Persists all decisions in code:â JSP pagesâ Java sourcesâ Configuration files
â Simple, intuitive application model
A Tool For The Corporate Developer
39 | Seattle Java Users Group â Jan 18, 2005
Sun Java Studio Creator
â Available as part of the first year of a Sun Developer Network subscriptionâ Rich supporting web site contentâ Active user forum and support channelsâ Attractive price ($99/year list)â http://developer.sun.com/jscreator/
â Also available at Amazon with âJava Studio Creator Field Guideâ
A Tool For The Corporate Developer
Sun Java Studio Creator
Ken Paulsen ([email protected])Staff EngineerSun Microsystems, Incorporated(Slides by: Craig R. McClanahan)