org.xwiki.component.event
Class AbstractComponentDescriptorEvent

java.lang.Object
  extended by org.xwiki.component.event.AbstractComponentDescriptorEvent
All Implemented Interfaces:
ComponentDescriptorEvent, Event
Direct Known Subclasses:
ComponentDescriptorAddedEvent, ComponentDescriptorRemovedEvent

public abstract class AbstractComponentDescriptorEvent
extends Object
implements ComponentDescriptorEvent

Base class for events about components descriptors.

Since:
2.6RC2
Version:
$Id$

Constructor Summary
AbstractComponentDescriptorEvent()
          Watches all roles (whenever a component is added it'll trigger this event).
AbstractComponentDescriptorEvent(Class<?> role)
           
AbstractComponentDescriptorEvent(Class<?> role, String roleHint)
           
 
Method Summary
 Class<?> getRole()
           
 String getRoleHint()
           
 boolean matches(Object otherEvent)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractComponentDescriptorEvent

public AbstractComponentDescriptorEvent()
Watches all roles (whenever a component is added it'll trigger this event).


AbstractComponentDescriptorEvent

public AbstractComponentDescriptorEvent(Class<?> role)
Parameters:
role - the component role to watch (all components matching this role will trigger this event)

AbstractComponentDescriptorEvent

public AbstractComponentDescriptorEvent(Class<?> role,
                                        String roleHint)
Parameters:
role - the component role to watch
roleHint - the component rolehint to watch
Method Detail

getRole

public Class<?> getRole()
Specified by:
getRole in interface ComponentDescriptorEvent
Returns:
the role of the component

getRoleHint

public String getRoleHint()
Specified by:
getRoleHint in interface ComponentDescriptorEvent
Returns:
the role hint of the component

matches

public boolean matches(Object otherEvent)
Specified by:
matches in interface Event


Copyright © 2004-2012 XWiki. All Rights Reserved.