com.r3corda.node.utilities / JDBCHashMap

JDBCHashMap

class JDBCHashMap<K : Any, V : Any> : AbstractJDBCHashMap<K, V, BlobMapTable>

A convenient JDBC table backed hash map with iteration order based on insertion order. See AbstractJDBCHashMap for further implementation details.

In this subclass, keys and values are represented by Blobs of Kryo serialized forms of the key and value objects. If you can extend AbstractJDBCHashMap and implement less Kryo dependent key and/or value mappings then that is likely preferrable.





Types

BlobMapTable class BlobMapTable : JDBCHashedTable

Constructors

<init> JDBCHashMap(tableName: String, loadOnInit: Boolean = false)

A convenient JDBC table backed hash map with iteration order based on insertion order. See AbstractJDBCHashMap for further implementation details.

Inherited Properties

entries open val entries: MutableSet<MutableEntry<K, V>>
keys open val keys: MutableSet<K>
loadOnInit val loadOnInit: Boolean
size open val size: Int
table val table: T
values open val values: MutableCollection<V>

Functions

addKeyToInsert fun addKeyToInsert(insert: <ERROR CLASS>, entry: Entry<K, V>, finalizables: MutableList<() -> Unit>): Unit

Implementation should marshall the key to the insert statement.

addValueToInsert fun addValueToInsert(insert: <ERROR CLASS>, entry: Entry<K, V>, finalizables: MutableList<() -> Unit>): Unit

Implementation should marshall the value to the insert statement.

keyFromRow fun keyFromRow(row: <ERROR CLASS>): K

Implementation should return the key object marshalled from the database table row.

valueFromRow fun valueFromRow(row: <ERROR CLASS>): V

Implementation should return the value object marshalled from the database table row.

Inherited Functions

clear open fun clear(): Unit
isEmpty open fun isEmpty(): Boolean