Class EventHandlerInfo

  • All Implemented Interfaces:
    ConfigurationElement, ConfigurationFile, java.lang.Cloneable

    public class EventHandlerInfo
    extends AbstractConfigurationElement
    This class represents the "eventHandler" node from the XML. Each event handler is identified by its type. Children : The events node which holds the list of all the events. Attributes: "type" - The event handler type "name" - The name of the event handler Key : "type" attribute.
    Since:
    MicroStrategy Web 9.0.0
    • Constructor Detail

      • EventHandlerInfo

        public EventHandlerInfo()
        Default constructor. Set the node name and register the child element
      • EventHandlerInfo

        public EventHandlerInfo​(int type)
        Constructor: Set the type field for the event handler
        Parameters:
        type - The event handler "type" for this object
      • EventHandlerInfo

        public EventHandlerInfo​(int type,
                                java.lang.String name)
        Constructor: Set the "type" and "name" field for this event handler
        Parameters:
        type - The event handler "type" for this object
        name - The event handler "name" for this object
    • Method Detail

      • getKeyAttribute

        protected java.lang.String getKeyAttribute()
        Description copied from class: AbstractConfigurationElement
        This method must return the attribute that uniquely identifies this element among its siblings; if no single attribute can be used, return null and override the getKey and setKey methods.
        Specified by:
        getKeyAttribute in class AbstractConfigurationElement
      • getType

        public int getType()
        Return the type field value
        Returns:
        The "type" associated with this event handler
      • setType

        public void setType​(int type)
        Set the type field value
        Parameters:
        type - The new value for the "type" attribute
      • getName

        public java.lang.String getName()
        Return the name field value
        Returns:
        The "name" associated with this event handler
      • setName

        public void setName​(java.lang.String name)
        Set the name field value
        Parameters:
        name - The new value for the "name" attribute
      • getEvent

        public EventInfo getEvent​(int eventID)
        Return the event with the given id from the events list
        Parameters:
        eventID - The id for the event to be returned
        Returns:
        The event with the given id
      • deleteEvent

        public void deleteEvent​(int id)
        Delete the event with the given id. This is a shortcut method to EventInfoList#deleteEvent()
        Parameters:
        id - The id of the event to be deleted
      • newEvent

        public EventInfo newEvent​(int id)
        Create a new event and add it to the events list. This is a shortcut method to EventInfoList#newEvent()
        Parameters:
        id - The id (key) for the new event to be created
        Returns:
        The new event created and added to the list with the given id
      • getEventsList

        public EventInfoList getEventsList()
        Return the list of events associated with this event handler
        Returns:
        The events list for this handler