Skip to content

Commit 52f0dba

Browse files
committed
Mark :core and :paging as experimental
Signed-off-by: mramotar <mramotar@dropbox.com>
1 parent c3950a1 commit 52f0dba

File tree

22 files changed

+30
-18
lines changed

22 files changed

+30
-18
lines changed
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package org.mobilenativefoundation.store.store5
1+
package org.mobilenativefoundation.store.core5
22

33
/**
44
* Marks declarations that are still **experimental** in store API.

core/src/commonMain/kotlin/org/mobilenativefoundation/store/core5/InsertionStrategy.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
package org.mobilenativefoundation.store.core5
22

3+
@ExperimentalStoreApi
34
enum class InsertionStrategy {
45
APPEND,
56
PREPEND,

core/src/commonMain/kotlin/org/mobilenativefoundation/store/core5/KeyProvider.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
package org.mobilenativefoundation.store.core5
22

3+
@ExperimentalStoreApi
34
interface KeyProvider<Id : Any, Single : StoreData.Single<Id>> {
45
fun fromCollection(key: StoreKey.Collection<Id>, value: Single): StoreKey.Single<Id>
56
fun fromSingle(key: StoreKey.Single<Id>, value: Single): StoreKey.Collection<Id>

core/src/commonMain/kotlin/org/mobilenativefoundation/store/core5/StoreData.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ package org.mobilenativefoundation.store.core5
55
* Every item that implements the [StoreData] interface must have a means of identification.
66
* This is useful in scenarios when data can be represented as singles or collections.
77
*/
8-
8+
@ExperimentalStoreApi
99
interface StoreData<out Id : Any> {
1010

1111
/**

core/src/commonMain/kotlin/org/mobilenativefoundation/store/core5/StoreKey.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ package org.mobilenativefoundation.store.core5
66
* Provides mechanisms for ID-based fetch, page-based fetch, and cursor-based fetch.
77
* Includes options for sorting and filtering.
88
*/
9+
@ExperimentalStoreApi
910
interface StoreKey<out Id : Any> {
1011

1112
/**

paging/src/commonMain/kotlin/org/mobilenativefoundation/store/paging5/LaunchPagingStore.kt

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ import kotlinx.coroutines.flow.asStateFlow
1010
import kotlinx.coroutines.flow.drop
1111
import kotlinx.coroutines.flow.first
1212
import kotlinx.coroutines.launch
13+
import org.mobilenativefoundation.store.core5.ExperimentalStoreApi
1314
import org.mobilenativefoundation.store.core5.StoreData
1415
import org.mobilenativefoundation.store.core5.StoreKey
15-
import org.mobilenativefoundation.store.store5.ExperimentalStoreApi
1616
import org.mobilenativefoundation.store.store5.MutableStore
1717
import org.mobilenativefoundation.store.store5.Store
1818
import org.mobilenativefoundation.store.store5.StoreReadRequest
@@ -27,6 +27,7 @@ private class StopProcessingException : Exception()
2727
* @param stream A lambda that invokes [Store.stream].
2828
* @return A read-only [StateFlow] reflecting the state of the Store.
2929
*/
30+
@ExperimentalStoreApi
3031
private fun <Id : Any, Key : StoreKey<Id>, Output : StoreData<Id>> launchPagingStore(
3132
scope: CoroutineScope,
3233
keys: Flow<Key>,
@@ -73,6 +74,7 @@ private fun <Id : Any, Key : StoreKey<Id>, Output : StoreData<Id>> launchPagingS
7374
* Initializes and returns a [StateFlow] that reflects the state of the [Store], updating by a flow of provided keys.
7475
* @see [launchPagingStore].
7576
*/
77+
@ExperimentalStoreApi
7678
fun <Id : Any, Key : StoreKey<Id>, Output : StoreData<Id>> Store<Key, Output>.launchPagingStore(
7779
scope: CoroutineScope,
7880
keys: Flow<Key>,
@@ -86,7 +88,7 @@ fun <Id : Any, Key : StoreKey<Id>, Output : StoreData<Id>> Store<Key, Output>.la
8688
* Initializes and returns a [StateFlow] that reflects the state of the [Store], updating by a flow of provided keys.
8789
* @see [launchPagingStore].
8890
*/
89-
@OptIn(ExperimentalStoreApi::class)
91+
@ExperimentalStoreApi
9092
fun <Id : Any, Key : StoreKey<Id>, Output : StoreData<Id>> MutableStore<Key, Output>.launchPagingStore(
9193
scope: CoroutineScope,
9294
keys: Flow<Key>,
@@ -96,6 +98,7 @@ fun <Id : Any, Key : StoreKey<Id>, Output : StoreData<Id>> MutableStore<Key, Out
9698
}
9799
}
98100

101+
@ExperimentalStoreApi
99102
private fun <Id : Any, Key : StoreKey.Collection<Id>, Output : StoreData<Id>> joinData(
100103
key: Key,
101104
prevResponse: StoreReadResponse<Output>,

paging/src/commonTest/kotlin/org/mobilenativefoundation/store/paging5/LaunchPagingStoreTests.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import org.mobilenativefoundation.store.paging5.util.PostDatabase
1515
import org.mobilenativefoundation.store.paging5.util.PostKey
1616
import org.mobilenativefoundation.store.paging5.util.PostPutRequestResult
1717
import org.mobilenativefoundation.store.paging5.util.PostStoreFactory
18-
import org.mobilenativefoundation.store.store5.ExperimentalStoreApi
18+
import org.mobilenativefoundation.store.core5.ExperimentalStoreApi
1919
import org.mobilenativefoundation.store.store5.MutableStore
2020
import org.mobilenativefoundation.store.store5.StoreReadRequest
2121
import org.mobilenativefoundation.store.store5.StoreReadResponse

paging/src/commonTest/kotlin/org/mobilenativefoundation/store/paging5/util/PostStoreFactory.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import org.mobilenativefoundation.store.cache5.StoreMultiCache
88
import org.mobilenativefoundation.store.core5.KeyProvider
99
import org.mobilenativefoundation.store.core5.StoreKey
1010
import org.mobilenativefoundation.store.store5.Converter
11-
import org.mobilenativefoundation.store.store5.ExperimentalStoreApi
11+
import org.mobilenativefoundation.store.core5.ExperimentalStoreApi
1212
import org.mobilenativefoundation.store.store5.Fetcher
1313
import org.mobilenativefoundation.store.store5.MutableStore
1414
import org.mobilenativefoundation.store.store5.SourceOfTruth

rx2/src/main/kotlin/org/mobilenativefoundation/store/rx2/RxStore.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import io.reactivex.Flowable
66
import kotlinx.coroutines.rx2.asFlowable
77
import kotlinx.coroutines.rx2.rxCompletable
88
import kotlinx.coroutines.rx2.rxSingle
9-
import org.mobilenativefoundation.store.store5.ExperimentalStoreApi
9+
import org.mobilenativefoundation.store.core5.ExperimentalStoreApi
1010
import org.mobilenativefoundation.store.store5.Store
1111
import org.mobilenativefoundation.store.store5.StoreBuilder
1212
import org.mobilenativefoundation.store.store5.StoreReadRequest

rx2/src/test/kotlin/org/mobilenativefoundation/store/rx2/test/RxSingleStoreExtensionsTest.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import org.mobilenativefoundation.store.rx2.getSingle
1414
import org.mobilenativefoundation.store.rx2.ofMaybe
1515
import org.mobilenativefoundation.store.rx2.ofResultSingle
1616
import org.mobilenativefoundation.store.rx2.withScheduler
17-
import org.mobilenativefoundation.store.store5.ExperimentalStoreApi
17+
import org.mobilenativefoundation.store.core5.ExperimentalStoreApi
1818
import org.mobilenativefoundation.store.store5.Fetcher
1919
import org.mobilenativefoundation.store.store5.FetcherResult
2020
import org.mobilenativefoundation.store.store5.SourceOfTruth

0 commit comments

Comments
 (0)