1 10 11 package org.picocontainer.defaults; 12 13 import org.picocontainer.ComponentAdapter; 14 import org.picocontainer.Parameter; 15 import org.picocontainer.PicoIntrospectionException; 16 17 import java.io.Serializable ; 18 19 20 27 public class SetterInjectionComponentAdapterFactory implements ComponentAdapterFactory, Serializable { 28 private final boolean allowNonPublicClasses; 29 30 public SetterInjectionComponentAdapterFactory(boolean allowNonPublicClasses) { 31 this.allowNonPublicClasses = allowNonPublicClasses; 32 } 33 34 public SetterInjectionComponentAdapterFactory() { 35 this(false); 36 } 37 38 55 public ComponentAdapter createComponentAdapter(Object componentKey, Class componentImplementation, Parameter[] parameters) 56 throws PicoIntrospectionException, AssignabilityRegistrationException, NotConcreteRegistrationException { 57 return new SetterInjectionComponentAdapter(componentKey, componentImplementation, parameters, allowNonPublicClasses); 58 } 59 } 60 | Popular Tags |