Examples of SetterInjection


Examples of org.picocontainer.injectors.SetterInjection

    public static InjectionFactory adaptiveDI() {
        return new AdaptingInjection();
    }

    public static InjectionFactory SDI() {
        return new SetterInjection();
    }
View Full Code Here

Examples of org.picocontainer.injectors.SetterInjection

        MutablePicoContainer primordial = new PicoBuilder().withBehaviors(primordialCaching).build();
        primordial.addComponent(WebDriverProvider.class, driverProvider);

        // Groovy Steps - can be stateful per story.
        final Storing store = (Storing) new Storing().wrap(new CompositeInjection(new ConstructorInjection(),
                new SetterInjection("set", "setMetaClass")));
        ClassLoader currentClassLoader = this.getClass().getClassLoader();
        final DefaultClassLoadingPicoContainer pageObjects = new DefaultClassLoadingPicoContainer(currentClassLoader,
                store, primordial);
        pageObjects.change(Characteristics.USE_NAMES);
        // This loads all the Groovy page objects - can be stateful
View Full Code Here

Examples of org.picocontainer.injectors.SetterInjection

@SuppressWarnings("serial")
public class WebDriverConstructorAndSetterInjection extends CompositeInjection {
    public WebDriverConstructorAndSetterInjection() {
        super(new ConstructorInjection(),
                new SetterInjection() {
                    @Override
                    public <T> ComponentAdapter<T> createComponentAdapter(ComponentMonitor monitor, LifecycleStrategy lifecycleStrategy, Properties componentProperties, Object componentKey, Class<T> componentImplementation, Parameter... parameters) throws PicoCompositionException {
                        return new SetterInjector<T>(componentKey, componentImplementation, parameters, monitor, "set", "", false, true) {
                            @Override
                            protected boolean isInjectorMethod(Method method) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.