cast.core.CASTWMPermissionMap Class Reference

List of all members.

Classes

class  PermissionsStruct

Public Member Functions

 CASTWMPermissionMap ()
void add (String _id)
void lock (String _id, String _component, WorkingMemoryPermissions _permission) throws InterruptedException
void unlock (String _id, String _component)
boolean tryLock (String _id, String _component, WorkingMemoryPermissions _permission) throws InterruptedException
boolean isLocked (String _id)
boolean isLockHolder (String _id, String _component)
boolean contains (String _id)
WorkingMemoryPermissions getPermissions (String _id)
void remove (String _id) throws InterruptedException
String getLockHolder (String _id)


Detailed Description

A class to manage the locking, unlocking and setting of permissions for working memory entries.

Author:
nah

Definition at line 16 of file CASTWMPermissionMap.java.


Constructor & Destructor Documentation

cast.core.CASTWMPermissionMap.CASTWMPermissionMap (  ) 

Definition at line 48 of file CASTWMPermissionMap.java.


Member Function Documentation

void cast.core.CASTWMPermissionMap.add ( String  _id  ) 

Add an entry to the map. The entry is unlocked by default.

Parameters:
_id 

Definition at line 71 of file CASTWMPermissionMap.java.

boolean cast.core.CASTWMPermissionMap.contains ( String  _id  ) 

Definition at line 268 of file CASTWMPermissionMap.java.

String cast.core.CASTWMPermissionMap.getLockHolder ( String  _id  ) 

Definition at line 357 of file CASTWMPermissionMap.java.

WorkingMemoryPermissions cast.core.CASTWMPermissionMap.getPermissions ( String  _id  ) 

Gets the permissions for the given entry.

Parameters:
_id 
Returns:

Definition at line 288 of file CASTWMPermissionMap.java.

boolean cast.core.CASTWMPermissionMap.isLocked ( String  _id  ) 

Checks whether the given entry is locked.

Parameters:
_id 
Returns:

Definition at line 239 of file CASTWMPermissionMap.java.

boolean cast.core.CASTWMPermissionMap.isLockHolder ( String  _id,
String  _component 
)

Checks whether the given entry is locked.

Parameters:
_id 
Returns:

Definition at line 257 of file CASTWMPermissionMap.java.

void cast.core.CASTWMPermissionMap.lock ( String  _id,
String  _component,
WorkingMemoryPermissions  _permission 
) throws InterruptedException

Acquires the lock for the entry given by the id. Blocks until the lock is available.

Parameters:
_id 
Exceptions:
InterruptedException 

Definition at line 86 of file CASTWMPermissionMap.java.

void cast.core.CASTWMPermissionMap.remove ( String  _id  )  throws InterruptedException

Definition at line 305 of file CASTWMPermissionMap.java.

boolean cast.core.CASTWMPermissionMap.tryLock ( String  _id,
String  _component,
WorkingMemoryPermissions  _permission 
) throws InterruptedException

Trys to acquire the lock for the entry given by the id. Only obtains one if one is available.

Parameters:
_id 
Exceptions:
InterruptedException 

Definition at line 188 of file CASTWMPermissionMap.java.

void cast.core.CASTWMPermissionMap.unlock ( String  _id,
String  _component 
)

Release the lock for the entry given by the id.

Parameters:
_id 

Definition at line 152 of file CASTWMPermissionMap.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