|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjfun.yan.DefaultPropertiesInjector
public class DefaultPropertiesInjector
The default PropertiesInjector implementation that uses java.beans introspection mechanism and injects properties by property names.
| Constructor Summary | |
|---|---|
DefaultPropertiesInjector(BeanType btype,
java.util.Set props)
Create an instance of DefaultPropertiesInjector using a BeanType object. |
|
| Method Summary | |
|---|---|
void |
injectProperties(java.lang.Object obj,
Dependency dep)
Pull property values and inject to the object. |
static PropertiesInjector |
instance(java.lang.Class type)
Create an instance of PropertiesInjector. |
static PropertiesInjector |
instance(java.lang.Class type,
java.util.Set props)
Create an instance of PropertiesInjector. |
java.lang.String |
toString()
|
void |
verifyProperties(java.lang.Class type,
Dependency dep)
Verify that all required properties are resolveable. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultPropertiesInjector(BeanType btype,
java.util.Set props)
btype - the BeanType object.props - the property names. Note, the constructor does not validate the property names.| Method Detail |
|---|
public static PropertiesInjector instance(java.lang.Class type)
throws java.beans.IntrospectionException
type - the bean class.
java.beans.IntrospectionException
public static PropertiesInjector instance(java.lang.Class type,
java.util.Set props)
throws java.beans.IntrospectionException
type - the bean class. null if unknown.props - the set of properties to set. null indicates all.
java.beans.IntrospectionException
public void injectProperties(java.lang.Object obj,
Dependency dep)
PropertiesInjector
injectProperties in interface PropertiesInjectorobj - the object to inject properties to.dep - the dependency to pull property values form.
public void verifyProperties(java.lang.Class type,
Dependency dep)
PropertiesInjector
verifyProperties in interface PropertiesInjectortype - the type that has the properties.dep - the dependency to resolve properties.public java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||