|
XNIO version 1.2.0.GA | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.jboss.xnio.channels.PlainChannelOption<T>
public class PlainChannelOption<T>
A plain channel option implementation. Use to easily define channel options.
| Constructor Summary | |
|---|---|
PlainChannelOption(String name,
Class<T> type)
Basic constructor. |
|
| Method Summary | ||
|---|---|---|
static
|
createOption(String name,
Class<T> type)
Convenience factory method. |
|
boolean |
equals(Object o)
Check equality with another object. |
|
String |
getName()
Get the option name. |
|
Class<T> |
getType()
Get option type. |
|
int |
hashCode()
Calculate the hashCode. |
|
String |
toString()
Get a simple string representation of this option. |
|
T |
valueOf(String string)
Get the value of the given string as the value type of this channel option, if possible. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public PlainChannelOption(String name,
Class<T> type)
name - the option name; must not be nulltype - the option type; must not be null| Method Detail |
|---|
public static <T> ChannelOption<T> createOption(String name,
Class<T> type)
name - the option nametype - the value type
public boolean equals(Object o)
equals in interface ChannelOption<T>equals in class Objecto - the other object
true if the the other object is equal to this onepublic int hashCode()
ChannelOption.hashCode().
hashCode in interface ChannelOption<T>hashCode in class Objectpublic String getName()
getName in interface ChannelOption<T>public Class<T> getType()
getType in interface ChannelOption<T>public String toString()
toString in interface ChannelOption<T>toString in class Object
public T valueOf(String string)
throws IllegalArgumentException
valueOf in interface ChannelOption<T>string - the string representation of the value
IllegalArgumentException - if the value is not valid for this option
|
XNIO version 1.2.0.GA | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||