DefaultApplicationDataHolder

Default, purely in-memory ApplicationDataHolder implementation — two mutable maps, one flat and one keyed by segment id, with no persistence and no locking beyond Kotlin's own MutableMap semantics. This is the implementation MosaicModules.applicationModule binds by default; there is no built-in alternative.

Constructors

Link copied to clipboard
constructor()

Functions

Link copied to clipboard
open override fun addPlainData(data: Any?, dataId: String)

Writes data under dataId in the flat (non-segmented) store, overwriting any existing value. The mechanism behind UpdateData targeting applicationPlainData().

Link copied to clipboard
open override fun addSegmentedData(data: Any?, segmentId: String, dataId: String)

Writes data under dataId within the namespace segmentId, overwriting any existing value — creating the segment if it doesn't exist yet. The mechanism behind UpdateData targeting applicationSegmentedData(segmentId).

Link copied to clipboard
open override fun getAllPlainData(): Map<String, Any?>

Every flat entry currently stored, keyed by data id. The mechanism behind GetData's fullAccessMode() over applicationPlainData().

Link copied to clipboard
open override fun getAllSegmentedData(segmentId: String): Map<String, Any?>?

Every entry currently stored within segmentId, keyed by data id. The mechanism behind GetData's fullAccessMode() over applicationSegmentedData(segmentId).

Link copied to clipboard
open override fun getPlainData(dataId: String): Any?

Reads the flat entry stored under dataId.

Link copied to clipboard
open override fun getSegmentedData(dataId: String, segmentId: String): Any?

Reads the entry stored under dataId within segmentId.

Link copied to clipboard
open override fun removePlainData(dataId: String)

Removes the flat entry stored under dataId, if any. The mechanism behind RemoveData targeting applicationPlainData().

Link copied to clipboard
open override fun removeSegmentedData(segmentId: String, dataId: String)

Removes the entry stored under dataId within segmentId, if any. The mechanism behind RemoveData targeting applicationSegmentedData(segmentId).

Link copied to clipboard
open override fun wipePlainData()

Clears every flat entry. The mechanism behind RemoveData's fullAccessMode() over applicationPlainData().

Link copied to clipboard
open override fun wipeSegmentedData()

Clears every segment entirely — every namespace, not just one.

open override fun wipeSegmentedData(segmentId: String)

Clears every entry within segmentId, leaving other segments untouched.