Class SQLiteBufferStorage
java.lang.Object
uk.ac.manchester.spinnaker.storage.sqlite.SQLiteBufferStorage
- All Implemented Interfaces:
- BufferManagerStorage,- DatabaseAPI,- ProxyAwareStorage
How to actually talk to an SQLite database.
- Author:
- Donal Fellows
- 
Nested Class SummaryNested classes/interfaces inherited from interface uk.ac.manchester.spinnaker.storage.BufferManagerStorageBufferManagerStorage.Region
- 
Constructor SummaryConstructorsConstructorDescriptionSQLiteBufferStorage(BufferManagerDatabaseEngine connectionProvider) Create an instance.
- 
Method SummaryModifier and TypeMethodDescriptionvoidaddRecordingContents(BufferManagerStorage.Region region, byte[] contents) Extract some bytes to the database.byte[]Retrieves some bytes from the database.Get a list of all cores that have data stored in the database.Get the proxy information from the database.Get a list of all regions for a particular core that have data stored in the database.voidprotected static voidsetArguments(PreparedStatement statement, Object... args) Set the arguments to a prepared statement.Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface uk.ac.manchester.spinnaker.storage.BufferManagerStorageaddRecordingContents, deleteRegionContents, storeDSEContents, storeRegionContentsMethods inherited from interface uk.ac.manchester.spinnaker.storage.ProxyAwareStoragegetProxyInformation
- 
Constructor Details- 
SQLiteBufferStorageCreate an instance.- Parameters:
- connectionProvider- The connection provider that will be asked for how to talk SQL to the database.
 
 
- 
- 
Method Details- 
insertMockExtraction- Specified by:
- insertMockExtractionin interface- BufferManagerStorage
- Throws:
- StorageException
 
- 
addRecordingContentspublic void addRecordingContents(BufferManagerStorage.Region region, byte[] contents) throws StorageException Description copied from interface:BufferManagerStorageExtract some bytes to the database. The bytes represent the contents of a recording region of a particular SpiNNaker core.- Specified by:
- addRecordingContentsin interface- BufferManagerStorage
- Parameters:
- region- The recording region doing the recording.
- contents- The bytes to append.
- Throws:
- StorageException- If anything goes wrong.
 
- 
getContentsDescription copied from interface:BufferManagerStorageRetrieves some bytes from the database. The bytes represent the contents of a recording region of a particular SpiNNaker core.- Specified by:
- getContentsin interface- BufferManagerStorage
- Parameters:
- region- The (DSE) region descriptor.
- Returns:
- The region contents.
- Throws:
- StorageException- If anything goes wrong.
 
- 
getCoresWithStorageDescription copied from interface:BufferManagerStorageGet a list of all cores that have data stored in the database. Warning: this is a potentially expensive operation!- Specified by:
- getCoresWithStoragein interface- BufferManagerStorage
- Returns:
- A list of cores for which something is stored.
- Throws:
- StorageException- If anything goes wrong.
 
- 
getRegionsWithStorageDescription copied from interface:BufferManagerStorageGet a list of all regions for a particular core that have data stored in the database.- Specified by:
- getRegionsWithStoragein interface- BufferManagerStorage
- Parameters:
- core- The core that has the memory regions.
- Returns:
- A list of region IDs for which something is stored.
- Throws:
- StorageException- If anything goes wrong.
 
- 
getProxyInformationDescription copied from interface:ProxyAwareStorageGet the proxy information from the database.- Specified by:
- getProxyInformationin interface- ProxyAwareStorage
- Returns:
- The proxy information, or nullif none defined. When there is no proxy, only direct connections to SpiNNaker are possible.
- Throws:
- StorageException- If anything goes wrong.
 
- 
setArgumentsSet the arguments to a prepared statement. Convenience method.
 
-