public class SingleArgumentMethodEventListener extends Object implements TypedEventListener
Constructor and Description |
---|
SingleArgumentMethodEventListener(Object target,
Method method) |
Modifier and Type | Method and Description |
---|---|
boolean |
accepts(Object event)
Returns
true if the listener instance can process the specified event object, false otherwise. |
Class |
getEventType() |
Method |
getMethod() |
protected Class |
getMethodArgumentType(Method method) |
Object |
getTarget() |
void |
onEvent(Object event)
Handles the specified event.
|
public SingleArgumentMethodEventListener(Object target, Method method)
public boolean accepts(Object event)
EventListener
true
if the listener instance can process the specified event object, false
otherwise.accepts
in interface EventListener
event
- the event object to testtrue
if the listener instance can process the specified event object, false
otherwise.public Class getEventType()
getEventType
in interface TypedEventListener
public void onEvent(Object event)
EventListener
onEvent
in interface EventListener
event
- the event to handle.protected Class getMethodArgumentType(Method method)
Copyright © 2004–2020 The Apache Software Foundation. All rights reserved.