diff --git a/CHANGELOG.md b/CHANGELOG.md index 2097436a45b..abfa8a71a66 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ ## 0.5.26 +* `Repos`: + * `InMemory`: + * `MapCRUDRepo`s and `MapKeyValueRepo`s got `protected` methods and properties instead of private + ## 0.5.25 * `Versions`: diff --git a/repos/inmemory/src/commonMain/kotlin/dev/inmo/micro_utils/repos/MapCRUDRepo.kt b/repos/inmemory/src/commonMain/kotlin/dev/inmo/micro_utils/repos/MapCRUDRepo.kt index 34a77aea72a..1d605a4c77b 100644 --- a/repos/inmemory/src/commonMain/kotlin/dev/inmo/micro_utils/repos/MapCRUDRepo.kt +++ b/repos/inmemory/src/commonMain/kotlin/dev/inmo/micro_utils/repos/MapCRUDRepo.kt @@ -23,13 +23,13 @@ class ReadMapCRUDRepo( } abstract class WriteMapCRUDRepo( - private val map: MutableMap = mutableMapOf() + protected val map: MutableMap = mutableMapOf() ) : WriteStandardCRUDRepo { - private val _newObjectsFlow: MutableSharedFlow = MutableSharedFlow() + protected val _newObjectsFlow: MutableSharedFlow = MutableSharedFlow() override val newObjectsFlow: Flow = _newObjectsFlow.asSharedFlow() - private val _updatedObjectsFlow: MutableSharedFlow = MutableSharedFlow() + protected val _updatedObjectsFlow: MutableSharedFlow = MutableSharedFlow() override val updatedObjectsFlow: Flow = _updatedObjectsFlow.asSharedFlow() - private val _deletedObjectsIdsFlow: MutableSharedFlow = MutableSharedFlow() + protected val _deletedObjectsIdsFlow: MutableSharedFlow = MutableSharedFlow() override val deletedObjectsIdsFlow: Flow = _deletedObjectsIdsFlow.asSharedFlow() protected abstract suspend fun updateObject(newValue: InputValueType, id: IdType, old: ObjectType): ObjectType diff --git a/repos/inmemory/src/commonMain/kotlin/dev/inmo/micro_utils/repos/MapKeyValueRepo.kt b/repos/inmemory/src/commonMain/kotlin/dev/inmo/micro_utils/repos/MapKeyValueRepo.kt index 79c58e1c83d..3d929737a12 100644 --- a/repos/inmemory/src/commonMain/kotlin/dev/inmo/micro_utils/repos/MapKeyValueRepo.kt +++ b/repos/inmemory/src/commonMain/kotlin/dev/inmo/micro_utils/repos/MapKeyValueRepo.kt @@ -8,7 +8,7 @@ import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.MutableSharedFlow class ReadMapKeyValueRepo( - private val map: Map = emptyMap() + protected val map: Map = emptyMap() ) : ReadStandardKeyValueRepo { override suspend fun get(k: Key): Value? = map[k]