cast.architecture.ManagedComponent Class Reference

Inheritance diagram for cast.architecture.ManagedComponent:

cast.architecture.WorkingMemoryReaderComponent cast.interfaces._ManagedComponentOperations cast.architecture.WorkingMemoryWriterComponent cast.interfaces._WorkingMemoryReaderComponentOperations cast.interfaces._WorkingMemoryReaderComponentOperations cast.architecture.WorkingMemoryAttachedComponent cast.interfaces._WorkingMemoryAttachedComponentOperations cast.interfaces._WorkingMemoryAttachedComponentOperations cast.core.SubarchitectureComponent cast.interfaces._WorkingMemoryAttachedComponentOperations cast.interfaces._CASTComponentOperations cast.interfaces._CASTComponentOperations cast.core.CASTComponent cast.interfaces._CASTComponentOperations cast.interfaces._CASTComponentOperations cast.examples.PriorityTest cast.tests.DirectAccessReader cast.tests.DirectAccessWriter comedyarch.AssistantDirector comedyarch.AudienceMember comedyarch.Director comedyarch.FunnyMan

List of all members.

Classes

class  GMResponseHandler
class  TaskManagementResult

Public Member Functions

 ManagedComponent ()
void setTaskManager (TaskManagerPrx _tm, Current __current)
void taskDecision (String _id, TaskManagementDecision _decision, Current __current)
void stopInternal ()

Protected Member Functions

String newTaskID ()
void proposeInformationProcessingTask (String _taskID, String _taskName)
void retractInformationProcessingTask (String _taskID)
void taskAdopted (String _taskID)
void taskComplete (String _taskID, TaskOutcome _outcome)
void taskRejected (String _taskID)
void waitForNotifications ()

Protected Attributes

int m_taskCounter

Package Attributes

int m_notifications


Detailed Description

An abstract class to represent a component in a subarchitecture that can read and write to a working memory, and has its operations controlled by a task manager.

Author:
nah

Definition at line 45 of file ManagedComponent.java.


Constructor & Destructor Documentation

cast.architecture.ManagedComponent.ManagedComponent (  ) 

Definition at line 61 of file ManagedComponent.java.


Member Function Documentation

String cast.architecture.ManagedComponent.newTaskID (  )  [protected]

Generate a new unique task id.

Returns:
A unique task id.

Definition at line 156 of file ManagedComponent.java.

void cast.architecture.ManagedComponent.proposeInformationProcessingTask ( String  _taskID,
String  _taskName 
) [protected]

Propose the processing of a task.

Parameters:
_taskID The id used to refer to this task.
_taskName The name of the task.

Definition at line 171 of file ManagedComponent.java.

void cast.architecture.ManagedComponent.retractInformationProcessingTask ( String  _taskID  )  [protected]

Register a list of tasks that this component can perform.

Parameters:
_taskDesc An array of task descriptions.
Exceptions:
SubarchitectureProcessException if connection to goal manager is not set or on comms error. Retract the proposal of processing a task.
Parameters:
_taskID The id of the task.
Exceptions:
SubarchitectureProcessException if connection to goal manager is not set or on comms error.

Definition at line 214 of file ManagedComponent.java.

void cast.architecture.ManagedComponent.setTaskManager ( TaskManagerPrx  _tm,
Current  __current 
)

Definition at line 69 of file ManagedComponent.java.

void cast.architecture.ManagedComponent.stopInternal (  ) 

Stop this component. This overridden method also stops the encapsulated thread that forwards change information.

See also:
balt.core.processes.FrameworkComponent.stop()

Reimplemented from cast.architecture.WorkingMemoryReaderComponent.

Definition at line 319 of file ManagedComponent.java.

void cast.architecture.ManagedComponent.taskAdopted ( String  _taskID  )  [protected]

Receive a signal that an information processing task has been accepted.

Parameters:
_taskID 

Definition at line 225 of file ManagedComponent.java.

void cast.architecture.ManagedComponent.taskComplete ( String  _taskID,
TaskOutcome  _outcome 
) [protected]

Signal the outcome of goal processing to the sub-architecture goal manager.

Parameters:
_taskID The task id.
_outcome The task outcome.
Exceptions:
SubarchitectureProcessException if connection to goal manager is not set.`

Definition at line 240 of file ManagedComponent.java.

void cast.architecture.ManagedComponent.taskDecision ( String  _id,
TaskManagementDecision  _decision,
Current  __current 
)

Definition at line 300 of file ManagedComponent.java.

void cast.architecture.ManagedComponent.taskRejected ( String  _taskID  )  [protected]

Receive a signal that an information processing goal has been rejected.

Parameters:
_taskID 

Definition at line 257 of file ManagedComponent.java.

void cast.architecture.ManagedComponent.waitForNotifications (  )  [protected]

Put the process to sleep until a new task notification is received. This method will sleep until either the taskAdopted or taskRejected functions next exit, unless these methods have exited more times than this method has been called. In this case the method does not block, as the assumption is that the process has to process these outstanding notifications first. This latter behaviour was added to fixed bug #31.

Remarks:
Interface change: Used to take a single argument. This was removed to simplify behaviour.

Definition at line 275 of file ManagedComponent.java.


Member Data Documentation

Count of notifications that are outstanding in the "wait" cycle.

Definition at line 108 of file ManagedComponent.java.

Counter for generating task ids.

Definition at line 113 of file ManagedComponent.java.


The documentation for this class was generated from the following file:

Generated on Mon Jun 13 15:55:46 2011 for CAST Java by  doxygen 1.5.8