1 package org.wamblee.system;
3 import javax.sql.DataSource;
6 public class Environment extends AbstractComponent {
8 private static final ProvidedInterfaceDescriptor[] PROVIDED =
9 new ProvidedInterfaceDescriptor[] {
10 new DefaultProvidedInterfaceDescriptor("datasource", DataSource.class),
11 new DefaultProvidedInterfaceDescriptor("integer", Integer.class)
14 public Environment(ServiceRegistry aRegistry) {
15 super("environment", aRegistry, PROVIDED, new RequiredInterfaceDescriptor[0]);
19 protected void doStart(String aContext, Service[] aRequiredServices) {
20 addService(aContext, PROVIDED[0], new Integer(1));
21 addService(aContext, PROVIDED[1], new Integer(2));
25 protected void doStop() {