Class InetAddressEditor
java.lang.Object
java.beans.PropertyEditorSupport
org.apache.mina.integration.beans.AbstractPropertyEditor
org.apache.mina.integration.beans.InetAddressEditor
- All Implemented Interfaces:
PropertyEditor
A
PropertyEditor which converts a String into an
InetAddress.
This editor simply calls InetAddress.getByName(java.lang.String)
when converting from a String, and InetAddress.getHostAddress()
when converting to a String.- See Also:
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class AbstractPropertyEditor
getAsText, getValue, setAsText, setTrimText, setValueMethods inherited from class PropertyEditorSupport
addPropertyChangeListener, firePropertyChange, getCustomEditor, getJavaInitializationString, getSource, getTags, isPaintable, paintValue, removePropertyChangeListener, setSource, supportsCustomEditor
-
Constructor Details
-
InetAddressEditor
public InetAddressEditor()
-
-
Method Details
-
toText
Description copied from class:AbstractPropertyEditorReturns a String representation of the given value- Specified by:
toTextin classAbstractPropertyEditor- Parameters:
value- The value- Returns:
- A String representation of the value
-
toValue
Description copied from class:AbstractPropertyEditorReturns an instance from a String representation of an object- Specified by:
toValuein classAbstractPropertyEditor- Parameters:
text- The String representation to convert- Returns:
- A instance of an object
- Throws:
IllegalArgumentException
-
defaultText
- Overrides:
defaultTextin classAbstractPropertyEditor- Returns:
- The default text
-
defaultValue
- Overrides:
defaultValuein classAbstractPropertyEditor- Returns:
- The default value
-