
Public Member Functions | |
| CASTWorkingMemory () | |
| WorkingMemoryEntry[] | getArrayByType (String _type, int _count) |
| Collection< WorkingMemoryEntry > | getByType (String _type, int _count) |
| Collection< WorkingMemoryEntry > | getByType (String _type) |
| String | toString () |
| boolean | add (String _id, WorkingMemoryEntry _data) |
| boolean | overwrite (String _id, WorkingMemoryEntry _data) |
| WorkingMemoryEntry | remove (String _id) |
| WorkingMemoryEntry | get (String _id) |
| ArrayList< String > | getIDsByType (String _type, int _count) |
| int | size () |
| boolean | contains (String _queryID) |
| boolean | hasContained (String _queryID) |
| int | getOverwriteCount (String _queryID) |
Definition at line 42 of file CASTWorkingMemory.java.
| cast.core.CASTWorkingMemory.CASTWorkingMemory | ( | ) |
Create a new working memory object.
Definition at line 56 of file CASTWorkingMemory.java.
| boolean cast.core.CASTWorkingMemory.add | ( | String | _id, | |
| WorkingMemoryEntry | _data | |||
| ) | [virtual] |
Adds item to working memory with given id. Does not overwrite data if id already exists.
| _id | The id of the entry. | |
| _type | The ontological type of the entry. | |
| _data | The data itself. |
Implements cast.core.CASTWorkingMemoryInterface.
Definition at line 173 of file CASTWorkingMemory.java.
| boolean cast.core.CASTWorkingMemory.contains | ( | String | _queryID | ) | [virtual] |
Whether the wm currently contains an entry with the given id.
| _queryID |
Implements cast.core.CASTWorkingMemoryInterface.
Definition at line 306 of file CASTWorkingMemory.java.
| WorkingMemoryEntry cast.core.CASTWorkingMemory.get | ( | String | _id | ) | [virtual] |
Get the item with the given id.
| _id | The specified item or null if it does not exist. |
Implements cast.core.CASTWorkingMemoryInterface.
Definition at line 234 of file CASTWorkingMemory.java.
| WorkingMemoryEntry [] cast.core.CASTWorkingMemory.getArrayByType | ( | String | _type, | |
| int | _count | |||
| ) |
Get an array of memory items with the given type.
| _type | The type to check. | |
| _count | The number of entries to return. If 0 all matching entries are returned. |
Definition at line 71 of file CASTWorkingMemory.java.
| Collection<WorkingMemoryEntry> cast.core.CASTWorkingMemory.getByType | ( | String | _type | ) | [virtual] |
Get all working memory entries with given type.
| _type | The type to check. |
Implements cast.core.CASTWorkingMemoryInterface.
Definition at line 114 of file CASTWorkingMemory.java.
| Collection<WorkingMemoryEntry> cast.core.CASTWorkingMemory.getByType | ( | String | _type, | |
| int | _count | |||
| ) | [virtual] |
Get a collection of memory items with the given ontological type.
| _type | The type to check. | |
| _count | The number of entries to return. If 0 all matching entries are returned. |
Implements cast.core.CASTWorkingMemoryInterface.
Definition at line 84 of file CASTWorkingMemory.java.
| ArrayList<String> cast.core.CASTWorkingMemory.getIDsByType | ( | String | _type, | |
| int | _count | |||
| ) | [virtual] |
Gets the n most recent ids of entries with the given type.
| _type | The type to check. | |
| _count | The number of ids to return. If 0 all matching items are return. |
Implements cast.core.CASTWorkingMemoryInterface.
Definition at line 244 of file CASTWorkingMemory.java.
| int cast.core.CASTWorkingMemory.getOverwriteCount | ( | String | _queryID | ) | [virtual] |
| _queryID |
Implements cast.core.CASTWorkingMemoryInterface.
Definition at line 328 of file CASTWorkingMemory.java.
| boolean cast.core.CASTWorkingMemory.hasContained | ( | String | _queryID | ) | [virtual] |
* Whether the wm has ever contained an entry with the given id.
| _queryID |
Implements cast.core.CASTWorkingMemoryInterface.
Definition at line 316 of file CASTWorkingMemory.java.
| boolean cast.core.CASTWorkingMemory.overwrite | ( | String | _id, | |
| WorkingMemoryEntry | _data | |||
| ) | [virtual] |
Overwrites item with given id. Does not do anything if id does not exist.
| _id | The id of the entry. | |
| _type | The ontological type of the entry. | |
| _data | The data itself. |
Implements cast.core.CASTWorkingMemoryInterface.
Definition at line 199 of file CASTWorkingMemory.java.
| WorkingMemoryEntry cast.core.CASTWorkingMemory.remove | ( | String | _id | ) | [virtual] |
Removes the item with the given id.
| _id | The id of the entry. |
Implements cast.core.CASTWorkingMemoryInterface.
Definition at line 216 of file CASTWorkingMemory.java.
| int cast.core.CASTWorkingMemory.size | ( | ) | [virtual] |
Get the current size of the working memory.
Implements cast.core.CASTWorkingMemoryInterface.
Definition at line 297 of file CASTWorkingMemory.java.
| String cast.core.CASTWorkingMemory.toString | ( | ) |
Returns a formatted representation of the object. If an ontology is set then the wm attempts to use this to format the contents of memory.
Definition at line 125 of file CASTWorkingMemory.java.
1.5.8