All Downloads are FREE. Search and download functionalities are using the official Maven repository.

jadex.bridge.component.IExternalSubcomponentsFeature Maven / Gradle / Ivy

Go to download

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.

There is a newer version: 4.0.267
Show newest version
package jadex.bridge.component;

import java.util.Map;

import jadex.bridge.IComponentIdentifier;
import jadex.bridge.IExternalAccess;
import jadex.bridge.ISearchConstraints;
import jadex.bridge.service.types.cms.CMSStatusEvent;
import jadex.bridge.service.types.cms.CreationInfo;
import jadex.bridge.service.types.cms.IComponentDescription;
import jadex.commons.Tuple2;
import jadex.commons.future.IFuture;
import jadex.commons.future.IIntermediateFuture;
import jadex.commons.future.ISubscriptionIntermediateFuture;

/**
 *  External perspective of the subcomponents feature.
 */
public interface IExternalSubcomponentsFeature extends IExternalComponentFeature
{
	/**
	 *  Get the model name of a component type.
	 *  @param ctype The component type.
	 *  @return The model name of this component type.
	 */
	public IFuture getFileName(String ctype);
	
//	/**
//	 *  Get the local type name of this component as defined in the parent.
//	 *  @return The type of this component type.
//	 */
//	public String getLocalType();
	
	/**
	 *  Get the local type name of this component as defined in the parent.
	 *  @return The type of this component type.
	 */
	public IFuture getLocalTypeAsync();
	
	/**
	 *  Starts a new POJO-component.
	 *  
	 *  @param pojocomponent The pojo object used as component.
	 *  @return The id of the component and the results after the component has been killed.
	 */
	public IFuture addComponent(Object pojocomponent);
	
	/**
	 *  Starts a new component.
	 *  
	 *  @param infos Start information.
	 *  @return The acces to the component.
	 */
	public IFuture createComponent(CreationInfo info);
	
	/**
	 *  Starts a new component while continuously receiving status events (create, result updates, termination).
	 *  
	 *  @param infos Start information.
	 *  @return Status events.
	 */
	public ISubscriptionIntermediateFuture createComponentWithEvents(CreationInfo info);
	
	/**
	 *  Starts a set of new components, in order of dependencies.
	 *  
	 *  @param infos Start information.
	 *  @return The id of the component and the results after the component has been killed.
	 */
	public IIntermediateFuture createComponents(CreationInfo... infos);
	
	/**
	 *  Stops a set of components, in order of dependencies.
	 *  
	 *  @param infos Start information.
	 *  @return The id of the component and the results after the component has been killed.
	 */
	public IIntermediateFuture>> killComponents(IComponentIdentifier... cids);
	
	/**
	 * Search for subcomponents matching the given description.
	 * @return An array of matching component descriptions.
	 */
	public IFuture searchComponents(IComponentDescription adesc, ISearchConstraints con);
	
	/**
	 *  Get the children (if any) component identifiers.
	 *  @param type The local child type.
	 *  @param parent The parent (null for this).
	 *  @return The children component identifiers.
	 */
	public IFuture getChildren(String type, IComponentIdentifier parent);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy