Your SlideShare is downloading. ×
0
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
CAF & Portlet Development Notes
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

CAF & Portlet Development Notes

1,826

Published on

0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
1,826
On Slideshare
0
From Embeds
0
Number of Embeds
3
Actions
Shares
0
Downloads
19
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. CAF & Portlet Development Notes 11-14.04.2011
  • 2. CAF and Portlets
    • Composite Application Framework
    • needs only Servlet container (can run on Tomcat)
    • Portlets
    • need the portlets container (my Webmethods)
    • before work need to deploy the caf war files to the server
  • 3. Portlets
    • Views:
    • VIEW, EDIT, HELP, custom
    • exist on the portlets page
    • are not URL-addressable
    • SSO !
  • 4. Development
    • Solution View in the Designer
    • Canvas for visual editing
    • Palette for elements
    • Outline to manage layers better
    •  
    • Change control type: good for adjusting the fields to your needs, but is not used much actually
  • 5. Web Service Connector
    • Consumer of the Web Service
    • Draging the connector to the canvas creates the form with data, can not be undoable (only delete from Outline and create again, but what happens with generated classes is unclear, they will remain same or can be regenerated but partially deleted or so...)
  • 6. Managed Beans
    • ... are behind each view (simple JSF approach)
    • in total there are:
    • View
      • Page Bean
        • Application Bean
        • AppNav Bean
      • WebServiceConnector Bean
    •  
    • Portlet:
      •   View
        • Page Bean
          • Porlet Bean
            • Application Bean
        • Web Service Connector Bean
    •  
  • 7. Beans
    • Business logic can be implemented as "Data Flow" (new term) which consists of actions and assignments of variables (cool, just as in WS DIAMOND) 
    • or by java implementation
    • "Data Flow" the expression language, but GUI of Designer allows to degign it easily without any need to write it on your own.
    • Reference allow to share same bean for many views.
  • 8. Validators and Converters
    • Same as in the JSF, nothing new actually, maybe some cool generators over GUI
  • 9. Client-side scripts
    • allow to use the Java Script on client side
    • are bind to ids of components ("defaultForm:...")
    • can be used to trigger the AJAX on Portlets (as only I did in the examples later)
    • "raise on change" event is used commonly to start such actions
  • 10. AJAX
    • many components incl. tables, tabs and trees are ajax-enabled
    • the Refresh() is used commonly in invocations
  • 11. Internationalisation
    • nothing new
    • same editing of application_en.properties files by hands
    • only great feature is the "CAF tools --> Externalize Strings from all views", it extracts all strings, gives them id and creates application*.property files.
    • Sometimes it extracts too much and can not distiguish between labels and ids, so it can require cleaning by hands.
  • 12. Navigation in Web Application
    • 3 main ways:
      • Basic Linking (over the url and link in <a> tag)
      • JSF navigation with faces-config.xml rules depending on the outcomes of some of the fuctions
        • there is pretty cool editor of the faces-config.xml file in Designer
      • Application navigation
        • using App Nav Bean
        • and app-nav.xml config file 
        • is used mostly for menu navigations
  • 13. Portlets
      • Other application type
      • can be deloyed only to MWS
      • have many views
      • each view is actually CAF
  • 14. MWS Portal Administration
      • 2 Admins with different views:
        • SysAdmin (manage porlets, portlet pages, aliases etc.)
        • Administrator (actually only for MWS itself)
      • Manage users and groups of users and roles(can be maped to LDAP)
  • 15. Portal Page
      • Has many portlets
      • Portlets can be draged and dropped on the canvas very easily
      •   strict column organisation
  • 16. Portlet pages
      • Alias is a short name for portet (can be used for wiring and liniing portlets on the portlet page)
  • 17. Wiring portlets
    • Goes over the Workspace Context.
    •  
    • Each Context Property can be used as a storage for common data !
    •  
    • The Source Portlet calls update Context and the target portlet has a reference to the context property.
  • 18. Linking portlets
      • URL link with property as parameter
  • 19. Wiring portlets
    • ONLY on the same portlets page !!!
    • is done over the commonly shared Properties of the Context
    • also globally accessible is the user profile, its properties (e.g. postal code) can be binded on (wired with) the properties of the portlet
  • 20. Events
    • not very interesting, as usuall define, subscribe etc.
    • there are several wizzards to difine everything which is needed for the event handling
  • 21. Pratics
    • In praxis was interesting to create the AJAX driven portlet page when only 2 out of 3 portlets are refreshed.
    • Otherwise in common case the whole portlets page is reloaded which can cause too many useless calls to DB or what ever is behind.
    • The AJAX-bases reload of only needed Portlets is something not standard and requires not only ajax-bases CAF components but also some client-side java scripting (with this &quot;defaultForm:...&quot; etc. hard coded references).

×