Package org.jboss.as.test.integration.osgi.xservice.bundle

Examples of org.jboss.as.test.integration.osgi.xservice.bundle.ConfiguredService


            config.update(configProps);

            // Register a {@link ManagedService}
            Dictionary<String, String> serviceProps = new Hashtable<String, String>();
            serviceProps.put(Constants.SERVICE_PID, ConfiguredService.SERVICE_PID);
            context.registerService(new String[] { ConfiguredService.class.getName(), ManagedService.class.getName() }, new ConfiguredService(), serviceProps);

            // Wait a little for the update event
            if (latch.await(5, TimeUnit.SECONDS) == false)
                throw new TimeoutException();

            // Verify service property
            sref = context.getServiceReference(ConfiguredService.class.getName());
            ConfiguredService service = (ConfiguredService) context.getService(sref);
            assertEquals("bar", service.getValue("foo"));
        }
        finally
        {
            config.delete();
        }
View Full Code Here

TOP

Related Classes of org.jboss.as.test.integration.osgi.xservice.bundle.ConfiguredService

Copyright © 2018 www.massapicom. 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.