public abstract class BaseNativePropertyGetter extends Object implements EventPropertyGetterSPI
Constructor and Description |
---|
BaseNativePropertyGetter(EventBeanTypedEventFactory eventBeanTypedEventFactory,
BeanEventTypeFactory beanEventTypeFactory,
Class returnType,
Class genericType) |
Modifier and Type | Method and Description |
---|---|
CodegenExpression |
eventBeanFragmentCodegen(CodegenExpression beanExpression,
CodegenMethodScope codegenMethodScope,
CodegenClassScope codegenClassScope) |
abstract Class |
getBeanPropType() |
Object |
getFragment(EventBean eventBean)
|
static Object |
getFragmentDynamic(Object object,
EventBeanTypedEventFactory eventBeanTypedEventFactory,
BeanEventTypeFactory beanEventTypeFactory)
NOTE: Code-generation-invoked method, method name and parameter order matters
Returns the fragment for dynamic properties.
|
abstract Class |
getTargetType() |
static Object |
toFragmentArray(Object[] object,
BeanEventType fragmentEventType,
EventBeanTypedEventFactory eventBeanTypedEventFactory)
NOTE: Code-generation-invoked method, method name and parameter order matters
|
static Object |
toFragmentIterable(Object object,
BeanEventType fragmentEventType,
EventBeanTypedEventFactory eventBeanTypedEventFactory)
NOTE: Code-generation-invoked method, method name and parameter order matters
Returns the fragment for dynamic properties.
|
CodegenExpression |
underlyingFragmentCodegen(CodegenExpression underlyingExpression,
CodegenMethodScope codegenMethodScope,
CodegenClassScope codegenClassScope) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
eventBeanExistsCodegen, underlyingExistsCodegen, underlyingGetCodegen
isExistsProperty
get
eventBeanGetCodegen
public BaseNativePropertyGetter(EventBeanTypedEventFactory eventBeanTypedEventFactory, BeanEventTypeFactory beanEventTypeFactory, Class returnType, Class genericType)
public abstract Class getTargetType()
public abstract Class getBeanPropType()
public static Object toFragmentArray(Object[] object, BeanEventType fragmentEventType, EventBeanTypedEventFactory eventBeanTypedEventFactory)
object
- arrayfragmentEventType
- fragment typeeventBeanTypedEventFactory
- event adapterspublic static Object getFragmentDynamic(Object object, EventBeanTypedEventFactory eventBeanTypedEventFactory, BeanEventTypeFactory beanEventTypeFactory)
object
- to inspecteventBeanTypedEventFactory
- factory for event beans and event typesbeanEventTypeFactory
- bean factorypublic static Object toFragmentIterable(Object object, BeanEventType fragmentEventType, EventBeanTypedEventFactory eventBeanTypedEventFactory)
object
- to inspectfragmentEventType
- typeeventBeanTypedEventFactory
- factory for event beans and event typespublic Object getFragment(EventBean eventBean)
EventPropertyGetter
EventBean
or array of EventBean
for a property name or property expression.
For use with properties whose value is itself an event or whose value can be represented as an event by the underlying event representation.
The EventType
of the EventBean
instance(s) returned by this method can be determined by
EventType.getFragmentType(String)
. Use EventPropertyDescriptor
to
obtain a list of properties that return fragments from an event type.
Returns null if the property value is null or the property value cannot be represented as a fragment by the underlying representation.
getFragment
in interface EventPropertyGetter
eventBean
- is the event to get the fragment value of a propertypublic final CodegenExpression eventBeanFragmentCodegen(CodegenExpression beanExpression, CodegenMethodScope codegenMethodScope, CodegenClassScope codegenClassScope)
eventBeanFragmentCodegen
in interface EventPropertyGetterSPI
public final CodegenExpression underlyingFragmentCodegen(CodegenExpression underlyingExpression, CodegenMethodScope codegenMethodScope, CodegenClassScope codegenClassScope)
underlyingFragmentCodegen
in interface EventPropertyGetterSPI
Copyright © 2005–2018. All rights reserved.