Weitere ähnliche Inhalte
Ähnlich wie Single sourcing using Rich Ajax Platform (20)
Kürzlich hochgeladen (20)
Single sourcing using Rich Ajax Platform
- 1. Single Sourcing using Rich Ajax Platform
Ankur Sharma
PDE UI Contributor
ankur_sharma@in.ibm.com
© 2009 by International Business Machines; made available under the EPL v1.0
- 2. Agenda
o Rich Ajax Platform
o How it works?
o Single Sourcing
o How to develop for RAP?
o The Good, The Bad and The Ugly
© 2010 by International Business Machines; made available under the EPL v1.0
- 3. RCP RAP Plug-ins
http://www.flickr.com/photos/stringgle/298571748/
© 2010 by International Business Machines; made available under the EPL v1.0
- 4. Rich Ajax Platform
o brings RCP applications to browser
o is not a web-application development toolkit
o exposes sub-set of RCP API
o enables re-use
© 2010 by International Business Machines; made available under the EPL v1.0
- 5. How RAP works?
© 2010 by International Business Machines; made available under the EPL v1.0
- 6. How RAP works?
o RWT impersonates SWT
o uses qooxdoo Javascript library
for rendering UI in browser
o runs in a OSGi runtime (Equinox)
with servlet bridge
© 2010 by International Business Machines; made available under the EPL v1.0
- 7. Single Sourcing
o write once run everywhere
o develop desktop and web client simultaneously
from same code base
o maximize code and skill reuse
o can manage with few Javascript and web-
development skills and resources
© 2010 by International Business Machines; made available under the EPL v1.0
- 8. How to develop for RAP?
o Things you need to be careful about
– Target Platforms
– Dependencies
– Platform specific APIs
– Validation
– Resources
– Threads
– Jobs
...
© 2010 by International Business Machines; made available under the EPL v1.0
- 9. RAP Target Platform
o RAP can not co-exists with RCP
o has separate run-time thus needs different TP
o better use different workspaces
o develop principally for RAP TP
© 2010 by International Business Machines; made available under the EPL v1.0
- 10. Approach
o Dependencies
– Favor Require-Bundle. Better tooling support.
– Import-Packages suffer split package problems
o Missing API
– Build fragments
– Use compatibility plug-in
© 2010 by International Business Machines; made available under the EPL v1.0
- 11. RCP vs RAP
RCP App.
RAP App.
© 2010 by International Business Machines; made available under the EPL v1.0
- 12. Session
o Singletons are application scope
o Use SessionSingletonBase for session scope
o Use a façade
o Move instance creation to fragments
© 2010 by International Business Machines; made available under the EPL v1.0
- 13. © 2010 by International Business Machines; made available under the EPL v1.0
- 14. Good, Bad and Ugly
o Good
– Easy to port legacy RCP Applications to web
o Bad
– Internationalization and localization is tricky
o Ugly
– Need a bunch of Ant scripts, resource templates and
few jars to build a .war
© 2010 by International Business Machines; made available under the EPL v1.0
- 15. © 2010 by International Business Machines; made available under the EPL v1.0
- 16. © 2010 by International Business Machines; made available under the EPL v1.0
- 17. Sources
o http://www.eclipse.org/rap/introduction.php
o http://www.eclipse-banking.org/pdf/slides/Krause.pdf
o http://eclipsesource.com/en/info/rcp-rap-single-sourcing-
guideline
© 2010 by International Business Machines; made available under the EPL v1.0
- 18. Image Credits
o http://www.flickr.com/photos/stringgle/298571748/
© 2010 by International Business Machines; made available under the EPL v1.0