org.objectweb.dream.control.activity
Interface ActiveComponentAttributeController

All Superinterfaces:
AttributeController

public interface ActiveComponentAttributeController
extends AttributeController

This attribute controller can be used by active components that need registering one or more tasks. It must be used by components using the ThreadPerTaskTaskManagerControllerMixin activity manager. It allows defining whether tasks have to be executed by a thread pool or only by a thread. Moreover, in cases the thread pool has been chosen, it allows setting the initial number of threads, as well as the max capacity of the pool.

See Also:
ThreadPoolController

Method Summary
 int getInitialCapacity()
          Returns the maximum capacity of the pool.
 int getInitialNumberOfThreads()
          Returns the initial number of threads in the pool.
 boolean getUsePool()
          Indicates whether a pool of threads is used for each task of the component.
 void setInitialCapacity(int i)
          Sets the initial capacity of the pool.
 void setInitialNumberOfThreads(int i)
          Sets the initial number of threads in the pool.
 void setUsePool(boolean usePool)
          Determines whether a pool of threads should be used for each task of the component.
 

Method Detail

setUsePool

public void setUsePool(boolean usePool)
Determines whether a pool of threads should be used for each task of the component.

Parameters:
usePool - the value to set.

getUsePool

public boolean getUsePool()
Indicates whether a pool of threads is used for each task of the component.

Returns:
true if task is executed by a pool of thread.

setInitialCapacity

public void setInitialCapacity(int i)
Sets the initial capacity of the pool.

Parameters:
i - the initial capacity of the pool.

getInitialCapacity

public int getInitialCapacity()
Returns the maximum capacity of the pool.

Returns:
the maximum capacity of the pool.

setInitialNumberOfThreads

public void setInitialNumberOfThreads(int i)
Sets the initial number of threads in the pool.

Parameters:
i - the initial number of threads in the pool.

getInitialNumberOfThreads

public int getInitialNumberOfThreads()
Returns the initial number of threads in the pool.

Returns:
the initial number of threads in the pool.


Copyright © 2003, 2004 - INRIA Rhone-Alpes - All Rights Reserved.