Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jboss.portal.portlet.controller.event
Class AbstractEventControllerContext

    java.lang.Object
      org.jboss.portal.portlet.controller.event.AbstractEventControllerContext

All Implemented Interfaces:
  EventControllerContext

    public class AbstractEventControllerContext

extends java.lang.Object
implements EventControllerContext

An implementation of the event controller context that do no ops.

Version:
  $Revision: 630 $
Author:
  Julien Viet

Field Summary

Fields inherited from interface org.jboss.portal.portlet.controller.event.EventControllerContext
`CONSUMED_EVENT_FLOODED, EVENT_CONSUMER_INFO_NOT_AVAILABLE, EVENT_CONSUMER_NOT_AVAILABLE, EVENT_PRODUCER_INFO_NOT_AVAILABLE, EVENT_PRODUCER_NOT_AVAILABLE, PORTLET_DOES_NOT_CONSUME_EVENT, PRODUCED_EVENT_FLOODED`

Constructor Summary
`AbstractEventControllerContext()`

Method Summary
`void` | `eventConsumed(EventPhaseContext context, PortletWindowEvent consumedEvent, PortletInvocationResponse consumerResponse)` Context call back when an event is consumed by a portlet.
`void` | `eventDiscarded(EventPhaseContext context, PortletWindowEvent discardedEvent, int cause)` Context call back when an event is discarded by the controller for a specific reason.
`void` | `eventFailed(EventPhaseContext context, PortletWindowEvent consumedEvent, java.lang.Throwable throwable)` Context call back when an event failed to be delivered because the invoker threw an exception.
`void` | `eventProduced(EventPhaseContext context, PortletWindowEvent producedEvent, PortletWindowEvent sourceEvent)` Context call back when an event is produced.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### AbstractEventControllerContext

    public AbstractEventControllerContext()

Method Detail

### eventProduced

    public void eventProduced(EventPhaseContext context,
                              PortletWindowEvent producedEvent,
                              PortletWindowEvent sourceEvent)

  Description copied from interface: `EventControllerContext`

  Context call back when an event is produced. The session argument gives to the context the capability to queue events in response of the produced event or to interrupt the session. It has also access to the full history of distributed events in order to provide advanced implementation of event cycle detection.

  During the invocation of this method, any runtime exception thrown will signal a failure and the produced event will be discarded although the event distribution will continue.

  During the invocation of this method, any error thrown will be propagated to the portlet controller invoker.

  Specified by:
    `eventProduced` in interface `EventControllerContext`
  Parameters:
    `context` - the session
    `producedEvent` - the produced event
    `sourceEvent` - the source event

### eventConsumed

    public void eventConsumed(EventPhaseContext context,
                              PortletWindowEvent consumedEvent,
                              PortletInvocationResponse consumerResponse)

  Description copied from interface: `EventControllerContext`

  Context call back when an event is consumed by a portlet. The session argument only provides querying capabilities and it is not possible to queue event or interrupt the session.

  During the invocation of this method, any runtime exception thrown will be ignored by the controller.

  During the invocation of this method, any error thrown will be propagated to the portlet controller invoker.

  Specified by:
    `eventConsumed` in interface `EventControllerContext`
  Parameters:
    `context` - the session
    `consumedEvent` - the consumed event
    `consumerResponse` - the consumer response

### eventFailed

    public void eventFailed(EventPhaseContext context,
                            PortletWindowEvent consumedEvent,
                            java.lang.Throwable throwable)

  Description copied from interface: `EventControllerContext`

  Context call back when an event failed to be delivered because the invoker threw an exception. The session argument only provides querying capabilities and it is not possible to queue event or interrupt the session.

  During the invocation of this method, any runtime exception thrown will be ignored by the controller.

  During the invocation of this method, any error thrown will be propagated to the portlet controller invoker.

  Specified by:
    `eventFailed` in interface `EventControllerContext`
  Parameters:
    `context` - the session
    `consumedEvent` - the failed event
    `throwable` - the throwable

### eventDiscarded

    public void eventDiscarded(EventPhaseContext context,
                               PortletWindowEvent discardedEvent,
                               int cause)

  Description copied from interface: `EventControllerContext`

  Context call back when an event is discarded by the controller for a specific reason. The session argument only provides querying capabilities and it is not possible to queue event or interrupt the session.

  The cause value is an integer among the constants

  - `EventControllerContext.CONSUMED_EVENT_FLOODED`
  - `EventControllerContext.EVENT_CONSUMER_INFO_NOT_AVAILABLE`
  - `EventControllerContext.EVENT_CONSUMER_NOT_AVAILABLE`
  - `EventControllerContext.EVENT_PRODUCER_INFO_NOT_AVAILABLE`
  - `EventControllerContext.EVENT_PRODUCER_NOT_AVAILABLE`
  - `EventControllerContext.PORTLET_DOES_NOT_CONSUME_EVENT`
  - `EventControllerContext.PRODUCED_EVENT_FLOODED`

  During the invocation of this method, any runtime exception thrown will be ignored by the controller.

  During the invocation of this method, any error thrown will be propagated to the portlet controller invoker.

  Specified by:
    `eventDiscarded` in interface `EventControllerContext`
  Parameters:
    `context` - the session
    `discardedEvent` - the discarded event
    `cause` - the cause

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2008. All Rights Reserved.