- java.lang.Object
-
- org.xnio.ChannelListener.SimpleSetter<T>
-
- Type Parameters:
T
- the channel type
- All Implemented Interfaces:
ChannelListener.Setter<T>
- Enclosing interface:
- ChannelListener<T extends java.nio.channels.Channel>
public static class ChannelListener.SimpleSetter<T extends java.nio.channels.Channel> extends java.lang.Object implements ChannelListener.Setter<T>
A simple implementation ofChannelListener.Setter
.- Since:
- 3.0
-
-
Constructor Summary
Constructors Constructor Description SimpleSetter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ChannelListener<? super T>
get()
Get the channel listener set on this setter.void
set(ChannelListener<? super T> listener)
Set the listener, ornull
to ignore the associated event type.java.lang.String
toString()
-
-
-
Method Detail
-
set
public void set(ChannelListener<? super T> listener)
Set the listener, ornull
to ignore the associated event type.- Specified by:
set
in interfaceChannelListener.Setter<T extends java.nio.channels.Channel>
- Parameters:
listener
- the new listener
-
get
public ChannelListener<? super T> get()
Get the channel listener set on this setter.- Returns:
- the channel listener
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-