import javax.sql.DataSource;
public class Application extends AbstractComponent {
- private static final RequiredInterfaceDescriptor[] REQUIRED =
- new RequiredInterfaceDescriptor[] {
+ private static RequiredInterface[] required() {
+ return
+ new RequiredInterface[] {
new DefaultRequiredInterfaceDescriptor("datasource", DataSource.class),
new DefaultRequiredInterfaceDescriptor("integer", Integer.class)
};
+ }
- public Application(ServiceRegistry aRegistry) {
- super("application", aRegistry, new ProvidedInterfaceDescriptor[0], REQUIRED);
+ public Application() {
+ super("application", new ProvidedInterface[0], required());
}
@Override
- protected void doStart(String aContext, Service[] aRequiredServices) {
+ protected void doStart(String aContext) {
// Empty, no services provided externally.
}