Package org.apache.felix.ipojo

Examples of org.apache.felix.ipojo.ComponentInstance.reconfigure()


        instance.reconfigure(conf);

        assertThat(check.getProps().get("grade")).isEqualTo(1);

        conf.put("grade", "2");
        instance.reconfigure(conf);
        assertThat(check.getProps().get("grade")).isEqualTo(2);

        conf.put("grade", "3");
        instance.reconfigure(conf);
        assertThat(check.getProps().get("grade")).isNull();
View Full Code Here


        conf.put("grade", "2");
        instance.reconfigure(conf);
        assertThat(check.getProps().get("grade")).isEqualTo(2);

        conf.put("grade", "3");
        instance.reconfigure(conf);
        assertThat(check.getProps().get("grade")).isNull();
    }


    private ComponentInstance provider(int i) {
View Full Code Here

        assertEquals("Classes[0] -2", FooService.class.getName(), str2[0].getName());

        Properties props2 = new Properties();
        props2.put("cls", new String[]{FooService.class.getName(), CheckService.class.getName()});
        try {
            ci.reconfigure(props2);
        } catch (Exception e) {
            fail(e.getMessage());
        }

        // Check the service property
View Full Code Here

       
        if (instance == null) {
            return; // The instance does not exist.
        }
       
        instance.reconfigure(properties); // re-configure the component
    }

    public String getFactoryName() {
        return m_componentMetadata.getAttribute("name"); // Mandatory attribute.
    }
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.