org.dbe.eve.net
Interface NetworkManager

All Known Implementing Classes:
NetworkManagerImpl

public interface NetworkManager

The Networkmanager handles the connections between the nodes of the Habitat Network, and cares about the migration and distribution of services.
Also, the Networkmanager acts as the "Gatekeeper" to the service pool. A service is only added to a habitat by using the Networkmanager's receive method.


Method Summary
 ConnectionPool getConnectionPool()
          Returns the connectionPool of this habitat
 void migrate(EvEService service, java.lang.String targetHabitatId)
          Method for targeted migration.
 void receive(EvEService service)
          This method is usually called by the HabitatService.
 void send(EvEService service)
          Triggers the random migration of the provided service to all connected habitats.
 

Method Detail

send

void send(EvEService service)
Triggers the random migration of the provided service to all connected habitats.

Parameters:
service - The service to migrate to connect habitats

receive

void receive(EvEService service)
This method is usually called by the HabitatService. Here, a "gatekeeper" function to "test" a service before it is added to the service pool can be envisioned.

Parameters:
service - The service to be added to the pool

migrate

void migrate(EvEService service,
             java.lang.String targetHabitatId)
Method for targeted migration. To be called from sub-components like the DIS, etc. The target habitat does not have to be known (see ConnectionPool). However, after a successful migration the target habitat is added to the ConnectionPool.

Parameters:
service - The Service to be migrated
targetHabitatId - The habitat where it goes to.

getConnectionPool

ConnectionPool getConnectionPool()
Returns the connectionPool of this habitat

Returns:
ConnectionPool