|  | ## Cheshire3 Object Model: Class RecordStore

Module baseObjects :: Class RecordStore

## Class RecordStore
source code

Object Tree:

               object --+
                        |
    configParser.C3Object --+
                            |
                  ObjectStore --+
                                |
                               RecordStore

Known Subclasses:
  recordStore.SimpleRecordStore

A persistent storage mechanism for Records. It allows such operations as create, update, fetch and delete. It also allows fast retrieval of important record metadata, for use with computing relevance ranking for example.
Instance Methods

create_record(self, session, record=None) Create a record and assign it a new identifier.
delete_record(self, session, id) Delete the record with the given identifier from storage.
fetch_record(self, session, id) Return the record with the given identifier.
fetch_recordChecksum(self, session, id) Return a checksum for the record, if one is available.
fetch_recordSize(self, session, id) Return the size of the record, according to its metadata.
replace_record(self, session, record) Permissions checking hook for store_record if the record does not already exist.
store_record(self, session, record) Store an existing record.
Inherited from `ObjectStore`: `create_object`, `delete_object`, `fetch_object`, `store_object` Inherited from `configParser.C3Object`: `__init__`, `auth_function`, `get_config`, `get_default`, `get_object`, `get_path`, `get_setting`, `log_function`, `unauth_function`, `unlog_function` Inherited from `configParser.C3Object` (private): `_getDomFromFile`, `_handleConfigNode`, `_parseIncludes`, `_recurseSubConfigs`, `_verifyDefault`, `_verifyOption`, `_verifySetting` Inherited from `object`: `__delattr__`, `__getattribute__`, `__hash__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__repr__`, `__setattr__`, `__str__`

Class Variables

Inherited from `configParser.C3Object`: `configStore`, `defaults`, `functionLogger`, `id`, `name`, `objectType`, `objects`, `parent`, `paths`, `permissionHandlers`, `settings`, `subConfigs`, `unresolvedObjects` Inherited from `configParser.C3Object` (private): `_includeConfigStores`, `_objectRefs` Inherited from `object`: `__class__`

Method Details

### create_record(self, session, record=None) | source code
Create a record and assign it a new identifier.

### delete_record(self, session, id) | source code
Delete the record with the given identifier from storage.

### fetch_record(self, session, id) | source code
Return the record with the given identifier.

### fetch_recordChecksum(self, session, id) | source code
Return a checksum for the record, if one is available.

### fetch_recordSize(self, session, id) | source code
Return the size of the record, according to its metadata.

### replace_record(self, session, record) | source code
Permissions checking hook for store_record if the record does not already exist.

### store_record(self, session, record) | source code
Store an existing record. It must already have an identifier assigned to it.