Creating a Click to Action receiver portletAdded by IBM on June 28, 2011 | Version 1 (Original)
|In developing a C2A application, develop a receiver portlet first.
In developing a C2A application, develop a receiver portlet first.
By developing a receiver portlet first, you can define the type of data or events you want to receive. This approach can simplify your design decisions when developing sender portlets. To develop a receiver portlet, perform the following operations in your model.
- Add a C2A Event Declaration builder to your model and use this builder to define a C2A event.
- Define the Event Name, Input Name, Input Type Name, Namespace and Caption inputs.
- Ensure that any sender portlets that wish to interact with this receiver portlet use the same value specified in the Input Type Name input.
- Ensure that the Input Type input you select matches that of the data that the portlet receives.
- Before you add an Event Handler builder to your model, develop the method or page that the Event Handler executes.
If you have the method or page available beforehand, you can select the event from the Action drop-down list in the Event Handler builder call editor, rather than typing it in manually.
- Add an Event Handler builder to the model.
The Event Handler builder performs an action when an event occurs. In this case, ensure that the Event Name input matches the Event Name input from your C2A Event Declaration builder to ensure that the C2A event triggers the action.
- Add a Portlet Adapter builder to the model.
This builder call provides your model with a portlet title so that the portlet can be added to a page in IBM® WebSphere® Portal server. Since C2A was designed to function in a WebSphere Portal environment, it is important to remember this simple, but important step.
How do I use Click-to-Action portlets?
Click-to-Action (C2A) is a feature of IBM WebSphere Portal that allows data to be transferred and shared among multiple WebSphere Application Server portlets via UI elements such as drop-down menus.
Parent topic: Developing portlets