org.jasig.portal
Class PortalEvent

java.lang.Object
  extended by org.jasig.portal.PortalEvent

public class PortalEvent
extends java.lang.Object

Events which may be arguments to the IChannel receiveEvent() method.

Version:
$Revision: 1.9 $ $Date: 2005/01/04 18:28:33 $
Author:
Peter Kharchenko, andrew.petro@yale.edu

Field Summary
static PortalEvent ABOUT_BUTTON
          The layout-generated event that is sent to a channel when the user actuates its about control.
static int ABOUT_BUTTON_EVENT
           
static PortalEvent DETACH_BUTTON
          The layout-generated event that is sent to a channel when the user actuates its detach control.
static int DETACH_BUTTON_EVENT
           
static PortalEvent EDIT_BUTTON
          The layout-generated event that is sent to a channel when the user actuates its edit control.
static int EDIT_BUTTON_EVENT
           
private  java.lang.String eventName
          String representation of the event.
private  int eventNumber
          Integer representation of an event.
static PortalEvent HELP_BUTTON
          The layout-generated event that is sent to a channel when the user actuates its help control.
static int HELP_BUTTON_EVENT
           
static PortalEvent MAXIMIZE
          The layout-generated event that is sent to a channel when the user actuates its maximize control.
static int MAXIMIZE_EVENT
           
static PortalEvent MINIMIZE
          The layout-generated event that is sent to a channel when the user actuates its minimize control.
static int MINIMIZE_EVENT
           
static int SESSION_DONE
           
static PortalEvent SESSION_DONE_EVENT
          The framework-generated event that is broadcast to channels that were used for a user session which is now ending.
private  PortalEventSource source
          Source of the event -- curently either FRAMEWORK or LAYOUT.
static int UNSUBSCRIBE
           
static PortalEvent UNSUBSCRIBE_EVENT
          The framework-generated event that is sent to a channel when the user unsubscribes from that channel.
 
Constructor Summary
  PortalEvent(int ev)
          Deprecated. instead reference one of the static singleton events.
private PortalEvent(int eventNumber, java.lang.String eventName, PortalEventSource source)
          Construct a PortalEvent instance from parameters.
 
Method Summary
 boolean equals(java.lang.Object other)
          Two PortalEvents are equal if they have the same eventNumber.
 java.lang.String getEventName()
          Get a String representing this event.
 int getEventNumber()
          Get an integer representing this event.
 PortalEventSource getSource()
          Get the source type of this event.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

SESSION_DONE

public static final int SESSION_DONE
See Also:
Constant Field Values

UNSUBSCRIBE

public static final int UNSUBSCRIBE
See Also:
Constant Field Values

EDIT_BUTTON_EVENT

public static final int EDIT_BUTTON_EVENT
See Also:
Constant Field Values

HELP_BUTTON_EVENT

public static final int HELP_BUTTON_EVENT
See Also:
Constant Field Values

ABOUT_BUTTON_EVENT

public static final int ABOUT_BUTTON_EVENT
See Also:
Constant Field Values

DETACH_BUTTON_EVENT

public static final int DETACH_BUTTON_EVENT
See Also:
Constant Field Values

MINIMIZE_EVENT

public static final int MINIMIZE_EVENT
See Also:
Constant Field Values

MAXIMIZE_EVENT

public static final int MAXIMIZE_EVENT
See Also:
Constant Field Values

SESSION_DONE_EVENT

public static final PortalEvent SESSION_DONE_EVENT
The framework-generated event that is broadcast to channels that were used for a user session which is now ending. Typical usage is to trigger state cleanup in channels that are not user-session-scoped.


UNSUBSCRIBE_EVENT

public static final PortalEvent UNSUBSCRIBE_EVENT
The framework-generated event that is sent to a channel when the user unsubscribes from that channel.


EDIT_BUTTON

public static final PortalEvent EDIT_BUTTON
The layout-generated event that is sent to a channel when the user actuates its edit control.


HELP_BUTTON

public static final PortalEvent HELP_BUTTON
The layout-generated event that is sent to a channel when the user actuates its help control.


ABOUT_BUTTON

public static final PortalEvent ABOUT_BUTTON
The layout-generated event that is sent to a channel when the user actuates its about control.


DETACH_BUTTON

public static final PortalEvent DETACH_BUTTON
The layout-generated event that is sent to a channel when the user actuates its detach control.


MINIMIZE

public static final PortalEvent MINIMIZE
The layout-generated event that is sent to a channel when the user actuates its minimize control.


MAXIMIZE

public static final PortalEvent MAXIMIZE
The layout-generated event that is sent to a channel when the user actuates its maximize control.


eventNumber

private final int eventNumber
Integer representation of an event. Must be one of the static integers declared in this class.


eventName

private final java.lang.String eventName
String representation of the event.


source

private final PortalEventSource source
Source of the event -- curently either FRAMEWORK or LAYOUT.

Constructor Detail

PortalEvent

public PortalEvent(int ev)
Deprecated. instead reference one of the static singleton events.

Constructor which translates from one of the integers representing a PortalEvent to the actual PortalEvent class.

Parameters:
ev - integer representing the event

PortalEvent

private PortalEvent(int eventNumber,
                    java.lang.String eventName,
                    PortalEventSource source)
Construct a PortalEvent instance from parameters.

Parameters:
eventNumber - - integer representation of event type
eventName - - String name of event
source - - source type of event
Method Detail

getEventName

public java.lang.String getEventName()
Get a String representing this event.

Returns:
a String representing this event.

getEventNumber

public int getEventNumber()
Get an integer representing this event.

Returns:
an integer representing this event.

getSource

public PortalEventSource getSource()
Get the source type of this event.

Returns:
the source type of this event.

equals

public boolean equals(java.lang.Object other)
Two PortalEvents are equal if they have the same eventNumber.

Overrides:
equals in class java.lang.Object
Parameters:
other - - another object
Returns:
true if other is a PortalEvent with the same eventNumber, false otherwise

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object