1 package org.wamblee.system;
4 * A sub system represents a part of a system that required a
5 * number of services and provides a number of services.
7 public interface SubSystem {
10 * Gets the name of the subsystem.
11 * @return Subsystem name.
16 * Gets a description of the provided interfaces.
17 * @return Provided interfaces.
19 ServiceDescriptor[] getProvidedServices();
22 * Gets a description of the required interfaces.
23 * @return Required interfaces.
25 ServiceDescriptor[] getRequiredServices();
29 * Initialises the subsytem by starting all the services that
30 * it described as provided.
31 * @param aContext Unique name for the subsystem.
32 * @param aRequiredServices Running services from other
33 * subsystems that are required by this subsystem.
34 * @return Services that are running in the subsystem.
36 Service[] initialize(String aContext, Service[] aRequiredServices);
39 * Gets the list of running services in the subsystem.
41 * This method may only be called after the
42 * {@link #initialize(String, Service[])} has been called.
45 Service[] getRunningServices();