Top Description Methods
org.glassfish.hk2.api

public @Interface Customizer

extends Annotation
Annotations
@Documented
@Retention:RUNTIME
@Target:TYPE
Static Imports
java.lang.annotation.ElementType.TYPE, .RetentionPolicy.RUNTIME

Gives the type (and optional name) of a customizer service to use when an unknown method on a bean interface is encountered. Customizers are found in the hk2 service registry

This annotation is for use with the hk2-xml configuration system

Author
jwells

Method Summary

Modifier and TypeMethod and Description
public boolean

Returns:

true if an unknown method called on a bean at runtime which does not have a mirrored method on the customizer should raise a RuntimeException
failWhenMethodNotFound
()

If true then if a bean method is not mirrored in the customizer a RuntimeException will be thrown.

public String[]

Returns:

the name of the customizer for this bean
name
()

The name of the customizer to lookup for this bean

public Class<?>[]

Returns:

the class of the customizer for this bean
value
()

The class of the customizer to lookup for this bean

Inherited from java.lang.annotation.Annotation:
annotationTypeequalshashCodetoString

Method Detail

failWhenMethodNotFoundback to summary
public boolean failWhenMethodNotFound()

If true then if a bean method is not mirrored in the customizer a RuntimeException will be thrown. Otherwise unknown methods are treated as a no-op. Setting this to false must be used with care as any method with a scalar return will throw a null pointer exception if no method can be found in the customizer methods since converting null to a scalar value does not work

Returns:boolean

true if an unknown method called on a bean at runtime which does not have a mirrored method on the customizer should raise a RuntimeException

nameback to summary
public String[] name()

The name of the customizer to lookup for this bean

Returns:String[]

the name of the customizer for this bean

valueback to summary
public Class<?>[] value()

The class of the customizer to lookup for this bean

Returns:Class<?>[]

the class of the customizer for this bean