public abstract class PropertyEditorFinder extends Object
| Modifier and Type | Field and Description |
|---|---|
protected static String |
EDITOR |
protected static String |
EDITOR_ARRAY |
| Constructor and Description |
|---|
PropertyEditorFinder() |
| Modifier and Type | Method and Description |
|---|---|
abstract PropertyEditor |
find(Class<?> type)
Returns PropertyEditor which capable of converting String into instances of
type parameter. |
abstract String[] |
getEditorSearchPackages() |
static PropertyEditorFinder |
getInstance() |
static PropertyEditorFinder |
getInstance(ClassLoader classLoader)
Returns instance of property finder.
|
abstract void |
register(Class<?> type,
Class<? extends PropertyEditor> editor)
If supported, this method register editor class for specific type.
|
abstract void |
setEditorSearchPackages(String[] packages)
If supported this sets search packages.
|
protected static final String EDITOR
protected static final String EDITOR_ARRAY
public abstract PropertyEditor find(Class<?> type)
type parameter.type - - class object representing type of property beeing converted from String to object instance.public abstract void register(Class<?> type, Class<? extends PropertyEditor> editor)
find(Class) method.type - - class object representing type of property, ie. int[].class, InetAddress.classeditor - - editor class which is capable of converting type, to and from String.public abstract void setEditorSearchPackages(String[] packages)
packages - - set of packages, ie. {"com.sun.beans","custom.editors"}public abstract String[] getEditorSearchPackages()
public static PropertyEditorFinder getInstance(ClassLoader classLoader)
ServiceLoader service.
If no service is found, this method, this method will return null.public static PropertyEditorFinder getInstance()
Copyright © 2015 JBoss by Red Hat. All rights reserved.