Class Blackboard<T>
java.lang.Object
de.uka.ipd.sdq.workflow.blackboard.Blackboard<T>
- Type Parameters:
T- The type of the partitions of the blackboard
- All Implemented Interfaces:
IBlackboard<T>
- Direct Known Subclasses:
MDSDBlackboard
A blackboard is a storage space where workflow jobs can retrieve and store data from respectively
to. It implements the well known architecture pattern "Blackboard" of POSA I
The blackboard contains information pieces called partitions. Each partition contains data needed
for a specific type of job. For example, in a compiler, there would be a partition called symbol
table to store the detected variable declarations.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddPartition(String id, T partition) Add a specific partition to the blackboard.getPartition(String id) Get a specific partition from the blackboard identified by the id it was registered with.Get the set of partitions currently present on this blackboard.booleanhasPartition(String id) Query the blackboard for a named partition.voidRemove a named partition from the blackboard.
-
Constructor Details
-
Blackboard
public Blackboard()
-
-
Method Details
-
addPartition
Add a specific partition to the blackboard.- Specified by:
addPartitionin interfaceIBlackboard<T>- Parameters:
id- The identifier for the partition to add.partition- The partition itself.- See Also:
-
getPartition
Get a specific partition from the blackboard identified by the id it was registered with.- Specified by:
getPartitionin interfaceIBlackboard<T>- Parameters:
id- The id to get the partition for.- Returns:
- The requested partition or null if none matching found.
- See Also:
-
hasPartition
Description copied from interface:IBlackboardQuery the blackboard for a named partition.- Specified by:
hasPartitionin interfaceIBlackboard<T>- Parameters:
id- The ID of the named partition- Returns:
- true if the partition exists on the blackboard
-
removePartition
Description copied from interface:IBlackboardRemove a named partition from the blackboard.- Specified by:
removePartitionin interfaceIBlackboard<T>- Parameters:
id- ID of the partition to removeS
-
getPartitionIds
Description copied from interface:IBlackboardGet the set of partitions currently present on this blackboard.- Specified by:
getPartitionIdsin interfaceIBlackboard<T>- Returns:
- the set of partition ids.
-