public class BeanEventAdapter extends Object implements BeanEventTypeFactory
BeanEventType
instances based on Java class information and using configured
settings forConstructor and Description |
---|
BeanEventAdapter(ConcurrentHashMap<Class,BeanEventType> typesPerJavaBean,
EventAdapterService eventAdapterService,
EventTypeIdGenerator eventTypeIdGenerator)
Ctor.
|
Modifier and Type | Method and Description |
---|---|
BeanEventType |
createBeanType(String name,
Class clazz,
boolean isPreconfiguredStatic,
boolean isPreconfigured,
boolean isConfigured)
Creates a new EventType object for a java bean of the specified class if this is the first time
the class has been seen.
|
BeanEventType |
createBeanTypeDefaultName(Class clazz)
Creates a new EventType object for a java bean of the specified class if this is the first time
the class has been seen.
|
BeanEventType[] |
getCachedTypes() |
ConfigurationEventTypeLegacy |
getClassToLegacyConfigs(String className) |
Configuration.PropertyResolutionStyle |
getDefaultPropertyResolutionStyle()
Gets the default property resolution style for Java class properties.
|
void |
setClassToLegacyConfigs(Map<String,ConfigurationEventTypeLegacy> classToLegacyConfigs)
Set the additional mappings for legacy classes.
|
void |
setDefaultAccessorStyle(ConfigurationEventTypeLegacy.AccessorStyle defaultAccessorStyle)
Sets the default accessor style.
|
void |
setDefaultPropertyResolutionStyle(Configuration.PropertyResolutionStyle defaultPropertyResolutionStyle)
Sets the default property resolution style for Java class properties.
|
public BeanEventAdapter(ConcurrentHashMap<Class,BeanEventType> typesPerJavaBean, EventAdapterService eventAdapterService, EventTypeIdGenerator eventTypeIdGenerator)
typesPerJavaBean
- shareable collection that this adapter writes to
for caching bean types per classeventAdapterService
- factory for event beans and event typeseventTypeIdGenerator
- type id generatorpublic BeanEventType[] getCachedTypes()
getCachedTypes
in interface BeanEventTypeFactory
public void setDefaultAccessorStyle(ConfigurationEventTypeLegacy.AccessorStyle defaultAccessorStyle)
defaultAccessorStyle
- style to setpublic void setClassToLegacyConfigs(Map<String,ConfigurationEventTypeLegacy> classToLegacyConfigs)
classToLegacyConfigs
- legacy class informationpublic void setDefaultPropertyResolutionStyle(Configuration.PropertyResolutionStyle defaultPropertyResolutionStyle)
defaultPropertyResolutionStyle
- resolution stylepublic Configuration.PropertyResolutionStyle getDefaultPropertyResolutionStyle()
getDefaultPropertyResolutionStyle
in interface BeanEventTypeFactory
public final BeanEventType createBeanTypeDefaultName(Class clazz)
createBeanTypeDefaultName
in interface BeanEventTypeFactory
clazz
- is the class of the Java bean.public final BeanEventType createBeanType(String name, Class clazz, boolean isPreconfiguredStatic, boolean isPreconfigured, boolean isConfigured)
createBeanType
in interface BeanEventTypeFactory
clazz
- is the class of the Java bean.name
- is the nameisPreconfiguredStatic
- if from static engine configisPreconfigured
- if configured before useisConfigured
- if the class is a configuration value, false if discoveredpublic ConfigurationEventTypeLegacy getClassToLegacyConfigs(String className)