//AMIS Technology Blog » publish event

Posts tagged publish event

image.png

ADF: (re-)Introducing Contextual Events in several simple steps

0

Communication between taskflows and pages, beans and other components in ADF Faces applications is in many cases ideally implemented using contextual events. These events are published from a producer component – a page, taskflow or associated bean – and made available to all interested parties. Events are handed over by the ADF run time infrastructure to any registered consumer in the current scope. This includes any taskflow or enclosing page which has been configured as such. This publish/subscribe model helps achieve interaction and reuse in a decoupled way. I like the principle. I have applied it on several occasions. And today I needed it again in a WebCenter Portal application with custom ADF 11g components. And once again I could not remember exactly how to implement the contextual events, the publication and subscription. This article therefore is primarily for me – so I can quickly recall how to do this in similar subsequent situations. However, if it is useful to you too, that is even better!

The use case discussed in this article is as follows:

The section in the red rectangle is a taskflow that has been embedded as a region in the page. This taskflow has indicated More >

SIG Event

ADF 11g : Drag’n Drop and Contextual Events

0

While going through my list of requirements for our AMIS re-usable ADF taskflow library, I ran into the following requirement: publish a contextual event on a Drag and Drop action. If you know contextual events, you immediately notice that there is no way to publish a contextual event from a Drag and Drop action. There are two types of events: ADF Binding Type events or JSF Component Type Events such as actionEvents, valueChangeEvents or clickEvents (also called eventBindings). However none of those is directly related to Drag and Drop. With some knowledge of the ADF Framework you will be able to create contextual events anyway. This post describes how to publish contextual events when a Drag and Drop action occurs. (more…)

Go to Top