jadex.bridge.service.component.IInternalRequiredServicesFeature Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jadex-platform-bridge Show documentation
Show all versions of jadex-platform-bridge Show documentation
Jadex bridge is a base package for kernels and platforms, i.e., it is used by both and provides commonly used interfaces and classes for active components and their management.
package jadex.bridge.service.component;
import java.util.Collection;
import jadex.bridge.service.RequiredServiceInfo;
import jadex.bridge.service.search.ServiceQuery;
import jadex.commons.future.IFuture;
import jadex.commons.future.ISubscriptionIntermediateFuture;
import jadex.commons.future.ITerminableIntermediateFuture;
/**
* Interface for internal service access methods.
*/
public interface IInternalRequiredServicesFeature
{
/**
* Get the required service info for a name.
* @param name The required service name.
*/
// Hack!!! used by multi invoker?
public RequiredServiceInfo getServiceInfo(String name);
/**
* Get a service raw (i.e. w/o required proxy).
*/
// Hack???
public T getRawService(Class type);
/**
* Get a service raw (i.e. w/o required proxy).
*/
// Hack???
public Collection getRawServices(Class type);
/**
* Search for matching services and provide first result.
* @param query The search query.
* @param info Used for required service proxy configuration -> null for no proxy.
* @return Future providing the corresponding service or ServiceNotFoundException when not found.
*/
public IFuture resolveService(ServiceQuery query, RequiredServiceInfo info);
/**
* Search for matching services and provide first result.
* Synchronous method only for locally available services.
* @param query The search query.
* @param info Used for required service proxy configuration -> null for no proxy.
* @return Future providing the corresponding service or ServiceNotFoundException when not found.
*/
public T resolveLocalService(ServiceQuery query, RequiredServiceInfo info);
/**
* Search for all matching services.
* @param query The search query.
* @param info Used for required service proxy configuration -> null for no proxy.
* @return Future providing the corresponding services or ServiceNotFoundException when not found.
*/
public ITerminableIntermediateFuture resolveServices(ServiceQuery query, RequiredServiceInfo info);
/**
* Search for all matching services.
* Synchronous method only for locally available services.
* @param query The search query.
* @param info Used for required service proxy configuration -> null for no proxy.
* @return Future providing the corresponding services or ServiceNotFoundException when not found.
*/
public Collection resolveLocalServices(ServiceQuery query, RequiredServiceInfo info);
/**
* Query for all matching services.
* @param query The search query.
* @param info Used for required service proxy configuration -> null for no proxy.
* @return Future providing the corresponding services.
*/
public ISubscriptionIntermediateFuture resolveQuery(ServiceQuery query, RequiredServiceInfo info);
//-------- all declared services (e.g. JCC component details) --------
/**
* Get the required services.
* @return The required services.
*/
public RequiredServiceInfo[] getServiceInfos();
}