Class UberspectPublicFields
java.lang.Object
org.apache.velocity.util.introspection.UberspectPublicFields
- All Implemented Interfaces:
Uberspect
,RuntimeServicesAware
Implementation of Uberspect to additionally provide access to public fields.
-
Field Summary
Modifier and TypeFieldDescriptionprotected Introspector
the default Velocity introspectorprotected org.slf4j.Logger
Our runtime logger. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetIterator
(Object obj, Info info) To support iteratives - #foreach()Returns a general method, corresponding to $foo.bar( $woogie )getPropertyGet
(Object obj, String identifier, Info i) Property gettergetPropertySet
(Object obj, String identifier, Object arg, Info i) Property settervoid
init()
init - generates the Introspector.void
Called automatically when event cartridge is initialized.
-
Field Details
-
log
protected org.slf4j.Logger logOur runtime logger. -
introspector
the default Velocity introspector
-
-
Constructor Details
-
UberspectPublicFields
public UberspectPublicFields()
-
-
Method Details
-
init
public void init()init - generates the Introspector. As the setup code makes sure that the log gets set before this is called, we can initialize the Introspector using the log object. -
getPropertyGet
Property getter- Specified by:
getPropertyGet
in interfaceUberspect
- Parameters:
obj
-identifier
-i
-- Returns:
- A Velocity Getter Method.
-
getPropertySet
Property setter- Specified by:
getPropertySet
in interfaceUberspect
- Parameters:
obj
-identifier
-arg
-i
-- Returns:
- A Velocity Setter method.
-
getIterator
Description copied from interface:Uberspect
To support iteratives - #foreach()- Specified by:
getIterator
in interfaceUberspect
- Parameters:
obj
-info
-- Returns:
- iterator
-
getMethod
Description copied from interface:Uberspect
Returns a general method, corresponding to $foo.bar( $woogie ) -
setRuntimeServices
Description copied from interface:RuntimeServicesAware
Called automatically when event cartridge is initialized.- Specified by:
setRuntimeServices
in interfaceRuntimeServicesAware
- Parameters:
rs
- RuntimeServices object assigned during initialization
-