[kairos] Rename kt-frp to Kairos
Flag: EXEMPT no code changed
Test: m kairos
Change-Id: I656f511ece24c5b03af340e156b98ed3d5213453
diff --git a/packages/SystemUI/frp/Android.bp b/packages/SystemUI/utils/kairos/Android.bp
similarity index 88%
rename from packages/SystemUI/frp/Android.bp
rename to packages/SystemUI/utils/kairos/Android.bp
index c3381db..1442591 100644
--- a/packages/SystemUI/frp/Android.bp
+++ b/packages/SystemUI/utils/kairos/Android.bp
@@ -20,9 +20,9 @@
}
java_library {
- name: "kt-frp",
+ name: "kairos",
host_supported: true,
- kotlincflags: ["-opt-in=com.android.systemui.experimental.frp.ExperimentalFrpApi"],
+ kotlincflags: ["-opt-in=com.android.systemui.kairos.ExperimentalFrpApi"],
srcs: ["src/**/*.kt"],
static_libs: [
"kotlin-stdlib",
@@ -31,7 +31,7 @@
}
java_test {
- name: "kt-frp-test",
+ name: "kairos-test",
optimize: {
enabled: false,
},
@@ -39,7 +39,7 @@
"test/**/*.kt",
],
static_libs: [
- "kt-frp",
+ "kairos",
"junit",
"kotlin-stdlib",
"kotlin-test",
diff --git a/packages/SystemUI/frp/OWNERS b/packages/SystemUI/utils/kairos/OWNERS
similarity index 100%
rename from packages/SystemUI/frp/OWNERS
rename to packages/SystemUI/utils/kairos/OWNERS
diff --git a/packages/SystemUI/frp/README.md b/packages/SystemUI/utils/kairos/README.md
similarity index 89%
rename from packages/SystemUI/frp/README.md
rename to packages/SystemUI/utils/kairos/README.md
index 9c5bdb0..85f622c 100644
--- a/packages/SystemUI/frp/README.md
+++ b/packages/SystemUI/utils/kairos/README.md
@@ -1,4 +1,4 @@
-# kt-frp
+# Kairos
A functional reactive programming (FRP) library for Kotlin.
@@ -13,12 +13,12 @@
### Details for nerds
-`kt-frp` implements an applicative / monadic flavor of FRP, using a push-pull
+`Kairos` implements an applicative / monadic flavor of FRP, using a push-pull
methodology to allow for efficient updates.
"Real" functional reactive programming should be specified with denotational
semantics ([wikipedia](https://en.wikipedia.org/wiki/Denotational_semantics)):
-you can view the semantics for `kt-frp` [here](docs/semantics.md).
+you can view the semantics for `Kairos` [here](docs/semantics.md).
## Usage
@@ -61,4 +61,4 @@
## Resources
-- [Cheatsheet for those coming from Kotlin Flow](docs/flow-to-frp-cheatsheet.md)
+- [Cheatsheet for those coming from Kotlin Flow](docs/flow-to-kairos-cheatsheet.md)
diff --git a/packages/SystemUI/frp/docs/flow-to-frp-cheatsheet.md b/packages/SystemUI/utils/kairos/docs/flow-to-kairos-cheatsheet.md
similarity index 90%
rename from packages/SystemUI/frp/docs/flow-to-frp-cheatsheet.md
rename to packages/SystemUI/utils/kairos/docs/flow-to-kairos-cheatsheet.md
index e20f3e6..9f7fd02 100644
--- a/packages/SystemUI/frp/docs/flow-to-frp-cheatsheet.md
+++ b/packages/SystemUI/utils/kairos/docs/flow-to-kairos-cheatsheet.md
@@ -1,27 +1,27 @@
-# From Flows to FRP
+# From Flows to Kairos
## Key differences
-* FRP evaluates all events (`TFlow` emissions + observers) in a transaction.
+* Kairos evaluates all events (`TFlow` emissions + observers) in a transaction.
-* FRP splits `Flow` APIs into two distinct types: `TFlow` and `TState`
+* Kairos splits `Flow` APIs into two distinct types: `TFlow` and `TState`
* `TFlow` is roughly equivalent to `SharedFlow` w/ a replay cache that
- exists for the duration of the current FRP transaction and shared with
+ exists for the duration of the current Kairos transaction and shared with
`SharingStarted.WhileSubscribed()`
* `TState` is roughly equivalent to `StateFlow` shared with
`SharingStarted.Eagerly`, but the current value can only be queried within
- a FRP transaction, and the value is only updated at the end of the
+ a Kairos transaction, and the value is only updated at the end of the
transaction
-* FRP further divides `Flow` APIs based on how they internally use state:
+* Kairos further divides `Flow` APIs based on how they internally use state:
* **FrpTransactionScope:** APIs that internally query some state need to be
- performed within an FRP transaction
+ performed within an Kairos transaction
* this scope is available from the other scopes, and from most lambdas
- passed to other FRP APIs
+ passed to other Kairos APIs
* **FrpStateScope:** APIs that internally accumulate state in reaction to
events need to be performed within an FRP State scope (akin to a
@@ -126,8 +126,8 @@
developers generally append `.onStart { emit(initialValue) }` to the `Flows`
that don't immediately emit.
-FRP avoids this gotcha by forcing usage of `TState` for `combine`, thus ensuring
-that there is always a current value to be combined for each input.
+Kairos avoids this gotcha by forcing usage of `TState` for `combine`, thus
+ensuring that there is always a current value to be combined for each input.
## collect { … }
@@ -158,8 +158,8 @@
#### Explanation
To keep all state-reads consistent, the current value of a TState can only be
-queried within an FRP transaction, modeled with `FrpTransactionScope`. Note that
-both `FrpStateScope` and `FrpBuildScope` extend `FrpTransactionScope`.
+queried within a Kairos transaction, modeled with `FrpTransactionScope`. Note
+that both `FrpStateScope` and `FrpBuildScope` extend `FrpTransactionScope`.
### I want to sample a TFlow
@@ -198,7 +198,7 @@
#### Explanation
-Under FRP's rules, a `TFlow` may only emit up to once per transaction. This
+Under Kairos's rules, a `TFlow` may only emit up to once per transaction. This
means that if we are merging two or more `TFlows` that are emitting at the same
time (within the same transaction), the resulting merged `TFlow` must emit a
single value. The lambda argument allows the developer to decide what to do in
diff --git a/packages/SystemUI/frp/docs/semantics.md b/packages/SystemUI/utils/kairos/docs/semantics.md
similarity index 96%
rename from packages/SystemUI/frp/docs/semantics.md
rename to packages/SystemUI/utils/kairos/docs/semantics.md
index b533190..d43bb44 100644
--- a/packages/SystemUI/frp/docs/semantics.md
+++ b/packages/SystemUI/utils/kairos/docs/semantics.md
@@ -1,11 +1,11 @@
# FRP Semantics
-`kt-frp`'s pure API is based off of the following denotational semantics
+`Kairos`'s pure API is based off of the following denotational semantics
([wikipedia](https://en.wikipedia.org/wiki/Denotational_semantics)).
-The semantics model `kt-frp` types as time-varying values; by making `Time` a
+The semantics model `Kairos` types as time-varying values; by making `Time` a
first-class value, we can define a referentially-transparent API that allows us
-to reason about the behavior of the pure FRP combinators. This is
+to reason about the behavior of the pure `Kairos` combinators. This is
implementation-agnostic; we can compare the behavior of any implementation with
expected behavior denoted by these semantics to identify bugs.
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/Combinators.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/Combinators.kt
similarity index 97%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/Combinators.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/Combinators.kt
index 298c071..8bf3a43 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/Combinators.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/Combinators.kt
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp
+package com.android.systemui.kairos
-import com.android.systemui.experimental.frp.util.These
-import com.android.systemui.experimental.frp.util.just
-import com.android.systemui.experimental.frp.util.none
+import com.android.systemui.kairos.util.These
+import com.android.systemui.kairos.util.just
+import com.android.systemui.kairos.util.none
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.channelFlow
import kotlinx.coroutines.flow.conflate
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpBuildScope.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpBuildScope.kt
similarity index 98%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpBuildScope.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpBuildScope.kt
index 6e4c9eb..4de6deb 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpBuildScope.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpBuildScope.kt
@@ -16,11 +16,11 @@
@file:OptIn(ExperimentalCoroutinesApi::class)
-package com.android.systemui.experimental.frp
+package com.android.systemui.kairos
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.just
-import com.android.systemui.experimental.frp.util.map
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.just
+import com.android.systemui.kairos.util.map
import kotlin.coroutines.CoroutineContext
import kotlin.coroutines.EmptyCoroutineContext
import kotlin.coroutines.RestrictsSuspension
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpEffectScope.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpEffectScope.kt
similarity index 97%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpEffectScope.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpEffectScope.kt
index a8ec98f..be2eb43 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpEffectScope.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpEffectScope.kt
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp
+package com.android.systemui.kairos
import kotlin.coroutines.RestrictsSuspension
import kotlinx.coroutines.CoroutineScope
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpNetwork.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpNetwork.kt
similarity index 94%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpNetwork.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpNetwork.kt
index acc76d9..b688eaf 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpNetwork.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpNetwork.kt
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp
+package com.android.systemui.kairos
-import com.android.systemui.experimental.frp.internal.BuildScopeImpl
-import com.android.systemui.experimental.frp.internal.Network
-import com.android.systemui.experimental.frp.internal.StateScopeImpl
-import com.android.systemui.experimental.frp.internal.util.awaitCancellationAndThen
-import com.android.systemui.experimental.frp.internal.util.childScope
+import com.android.systemui.kairos.internal.BuildScopeImpl
+import com.android.systemui.kairos.internal.Network
+import com.android.systemui.kairos.internal.StateScopeImpl
+import com.android.systemui.kairos.internal.util.awaitCancellationAndThen
+import com.android.systemui.kairos.internal.util.childScope
import kotlin.coroutines.CoroutineContext
import kotlin.coroutines.EmptyCoroutineContext
import kotlin.coroutines.coroutineContext
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpScope.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpScope.kt
similarity index 97%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpScope.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpScope.kt
index a5a7977..ad6b2c8 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpScope.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpScope.kt
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp
+package com.android.systemui.kairos
import kotlin.coroutines.RestrictsSuspension
import kotlin.coroutines.resume
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpStateScope.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpStateScope.kt
similarity index 97%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpStateScope.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpStateScope.kt
index 61336f4..c7ea680 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpStateScope.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpStateScope.kt
@@ -14,20 +14,20 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp
+package com.android.systemui.kairos
-import com.android.systemui.experimental.frp.combine as combinePure
-import com.android.systemui.experimental.frp.map as mapPure
-import com.android.systemui.experimental.frp.util.Just
-import com.android.systemui.experimental.frp.util.Left
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.Right
-import com.android.systemui.experimental.frp.util.WithPrev
-import com.android.systemui.experimental.frp.util.just
-import com.android.systemui.experimental.frp.util.map
-import com.android.systemui.experimental.frp.util.none
-import com.android.systemui.experimental.frp.util.partitionEithers
-import com.android.systemui.experimental.frp.util.zipWith
+import com.android.systemui.kairos.combine as combinePure
+import com.android.systemui.kairos.map as mapPure
+import com.android.systemui.kairos.util.Just
+import com.android.systemui.kairos.util.Left
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.Right
+import com.android.systemui.kairos.util.WithPrev
+import com.android.systemui.kairos.util.just
+import com.android.systemui.kairos.util.map
+import com.android.systemui.kairos.util.none
+import com.android.systemui.kairos.util.partitionEithers
+import com.android.systemui.kairos.util.zipWith
import kotlin.coroutines.RestrictsSuspension
typealias FrpStateful<R> = suspend FrpStateScope.() -> R
@@ -715,7 +715,7 @@
stateB: TState<B>,
transform: suspend FrpTransactionScope.(A, B) -> Z,
): TState<Z> =
- com.android.systemui.experimental.frp
+ com.android.systemui.kairos
.combine(stateA, stateB) { a, b -> transactionally { transform(a, b) } }
.sampleTransactionals()
@@ -733,7 +733,7 @@
stateD: TState<D>,
transform: suspend FrpTransactionScope.(A, B, C, D) -> Z,
): TState<Z> =
- com.android.systemui.experimental.frp
+ com.android.systemui.kairos
.combine(stateA, stateB, stateC, stateD) { a, b, c, d ->
transactionally { transform(a, b, c, d) }
}
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpTransactionScope.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpTransactionScope.kt
similarity index 97%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpTransactionScope.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpTransactionScope.kt
index b0b9dbc..a7ae1d9 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/FrpTransactionScope.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/FrpTransactionScope.kt
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp
+package com.android.systemui.kairos
import kotlin.coroutines.RestrictsSuspension
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/TFlow.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/TFlow.kt
similarity index 90%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/TFlow.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/TFlow.kt
index cca6c9a..7ba1aca 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/TFlow.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/TFlow.kt
@@ -14,36 +14,36 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp
+package com.android.systemui.kairos
-import com.android.systemui.experimental.frp.internal.DemuxImpl
-import com.android.systemui.experimental.frp.internal.Init
-import com.android.systemui.experimental.frp.internal.InitScope
-import com.android.systemui.experimental.frp.internal.InputNode
-import com.android.systemui.experimental.frp.internal.Network
-import com.android.systemui.experimental.frp.internal.NoScope
-import com.android.systemui.experimental.frp.internal.TFlowImpl
-import com.android.systemui.experimental.frp.internal.activated
-import com.android.systemui.experimental.frp.internal.cached
-import com.android.systemui.experimental.frp.internal.constInit
-import com.android.systemui.experimental.frp.internal.filterNode
-import com.android.systemui.experimental.frp.internal.init
-import com.android.systemui.experimental.frp.internal.map
-import com.android.systemui.experimental.frp.internal.mapImpl
-import com.android.systemui.experimental.frp.internal.mapMaybeNode
-import com.android.systemui.experimental.frp.internal.mergeNodes
-import com.android.systemui.experimental.frp.internal.mergeNodesLeft
-import com.android.systemui.experimental.frp.internal.neverImpl
-import com.android.systemui.experimental.frp.internal.switchDeferredImplSingle
-import com.android.systemui.experimental.frp.internal.switchPromptImpl
-import com.android.systemui.experimental.frp.internal.util.hashString
-import com.android.systemui.experimental.frp.util.Either
-import com.android.systemui.experimental.frp.util.Left
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.Right
-import com.android.systemui.experimental.frp.util.just
-import com.android.systemui.experimental.frp.util.map
-import com.android.systemui.experimental.frp.util.toMaybe
+import com.android.systemui.kairos.internal.DemuxImpl
+import com.android.systemui.kairos.internal.Init
+import com.android.systemui.kairos.internal.InitScope
+import com.android.systemui.kairos.internal.InputNode
+import com.android.systemui.kairos.internal.Network
+import com.android.systemui.kairos.internal.NoScope
+import com.android.systemui.kairos.internal.TFlowImpl
+import com.android.systemui.kairos.internal.activated
+import com.android.systemui.kairos.internal.cached
+import com.android.systemui.kairos.internal.constInit
+import com.android.systemui.kairos.internal.filterNode
+import com.android.systemui.kairos.internal.init
+import com.android.systemui.kairos.internal.map
+import com.android.systemui.kairos.internal.mapImpl
+import com.android.systemui.kairos.internal.mapMaybeNode
+import com.android.systemui.kairos.internal.mergeNodes
+import com.android.systemui.kairos.internal.mergeNodesLeft
+import com.android.systemui.kairos.internal.neverImpl
+import com.android.systemui.kairos.internal.switchDeferredImplSingle
+import com.android.systemui.kairos.internal.switchPromptImpl
+import com.android.systemui.kairos.internal.util.hashString
+import com.android.systemui.kairos.util.Either
+import com.android.systemui.kairos.util.Left
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.Right
+import com.android.systemui.kairos.util.just
+import com.android.systemui.kairos.util.map
+import com.android.systemui.kairos.util.toMaybe
import java.util.concurrent.atomic.AtomicReference
import kotlin.reflect.KProperty
import kotlinx.coroutines.CompletableDeferred
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/TState.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/TState.kt
similarity index 91%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/TState.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/TState.kt
index a5ec503..a4c6956 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/TState.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/TState.kt
@@ -14,29 +14,29 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp
+package com.android.systemui.kairos
-import com.android.systemui.experimental.frp.internal.DerivedMapCheap
-import com.android.systemui.experimental.frp.internal.Init
-import com.android.systemui.experimental.frp.internal.InitScope
-import com.android.systemui.experimental.frp.internal.Network
-import com.android.systemui.experimental.frp.internal.NoScope
-import com.android.systemui.experimental.frp.internal.Schedulable
-import com.android.systemui.experimental.frp.internal.TFlowImpl
-import com.android.systemui.experimental.frp.internal.TStateImpl
-import com.android.systemui.experimental.frp.internal.TStateSource
-import com.android.systemui.experimental.frp.internal.activated
-import com.android.systemui.experimental.frp.internal.cached
-import com.android.systemui.experimental.frp.internal.constInit
-import com.android.systemui.experimental.frp.internal.constS
-import com.android.systemui.experimental.frp.internal.filterNode
-import com.android.systemui.experimental.frp.internal.flatMap
-import com.android.systemui.experimental.frp.internal.init
-import com.android.systemui.experimental.frp.internal.map
-import com.android.systemui.experimental.frp.internal.mapCheap
-import com.android.systemui.experimental.frp.internal.mapImpl
-import com.android.systemui.experimental.frp.internal.util.hashString
-import com.android.systemui.experimental.frp.internal.zipStates
+import com.android.systemui.kairos.internal.DerivedMapCheap
+import com.android.systemui.kairos.internal.Init
+import com.android.systemui.kairos.internal.InitScope
+import com.android.systemui.kairos.internal.Network
+import com.android.systemui.kairos.internal.NoScope
+import com.android.systemui.kairos.internal.Schedulable
+import com.android.systemui.kairos.internal.TFlowImpl
+import com.android.systemui.kairos.internal.TStateImpl
+import com.android.systemui.kairos.internal.TStateSource
+import com.android.systemui.kairos.internal.activated
+import com.android.systemui.kairos.internal.cached
+import com.android.systemui.kairos.internal.constInit
+import com.android.systemui.kairos.internal.constS
+import com.android.systemui.kairos.internal.filterNode
+import com.android.systemui.kairos.internal.flatMap
+import com.android.systemui.kairos.internal.init
+import com.android.systemui.kairos.internal.map
+import com.android.systemui.kairos.internal.mapCheap
+import com.android.systemui.kairos.internal.mapImpl
+import com.android.systemui.kairos.internal.util.hashString
+import com.android.systemui.kairos.internal.zipStates
import kotlin.reflect.KProperty
import kotlinx.coroutines.CompletableDeferred
import kotlinx.coroutines.Deferred
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/Transactional.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/Transactional.kt
similarity index 85%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/Transactional.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/Transactional.kt
index 0e7b420..6b1c8c8 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/Transactional.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/Transactional.kt
@@ -14,14 +14,14 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp
+package com.android.systemui.kairos
-import com.android.systemui.experimental.frp.internal.InitScope
-import com.android.systemui.experimental.frp.internal.NoScope
-import com.android.systemui.experimental.frp.internal.TransactionalImpl
-import com.android.systemui.experimental.frp.internal.init
-import com.android.systemui.experimental.frp.internal.transactionalImpl
-import com.android.systemui.experimental.frp.internal.util.hashString
+import com.android.systemui.kairos.internal.InitScope
+import com.android.systemui.kairos.internal.NoScope
+import com.android.systemui.kairos.internal.TransactionalImpl
+import com.android.systemui.kairos.internal.init
+import com.android.systemui.kairos.internal.transactionalImpl
+import com.android.systemui.kairos.internal.util.hashString
import kotlinx.coroutines.CompletableDeferred
/**
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/debug/Debug.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/debug/Debug.kt
similarity index 83%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/debug/Debug.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/debug/Debug.kt
index 8062341..4f302a1 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/debug/Debug.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/debug/Debug.kt
@@ -14,25 +14,25 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.debug
+package com.android.systemui.kairos.debug
-import com.android.systemui.experimental.frp.MutableTState
-import com.android.systemui.experimental.frp.TState
-import com.android.systemui.experimental.frp.TStateInit
-import com.android.systemui.experimental.frp.TStateLoop
-import com.android.systemui.experimental.frp.internal.DerivedFlatten
-import com.android.systemui.experimental.frp.internal.DerivedMap
-import com.android.systemui.experimental.frp.internal.DerivedMapCheap
-import com.android.systemui.experimental.frp.internal.DerivedZipped
-import com.android.systemui.experimental.frp.internal.Init
-import com.android.systemui.experimental.frp.internal.TStateDerived
-import com.android.systemui.experimental.frp.internal.TStateImpl
-import com.android.systemui.experimental.frp.internal.TStateSource
-import com.android.systemui.experimental.frp.util.Just
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.None
-import com.android.systemui.experimental.frp.util.none
-import com.android.systemui.experimental.frp.util.orElseGet
+import com.android.systemui.kairos.MutableTState
+import com.android.systemui.kairos.TState
+import com.android.systemui.kairos.TStateInit
+import com.android.systemui.kairos.TStateLoop
+import com.android.systemui.kairos.internal.DerivedFlatten
+import com.android.systemui.kairos.internal.DerivedMap
+import com.android.systemui.kairos.internal.DerivedMapCheap
+import com.android.systemui.kairos.internal.DerivedZipped
+import com.android.systemui.kairos.internal.Init
+import com.android.systemui.kairos.internal.TStateDerived
+import com.android.systemui.kairos.internal.TStateImpl
+import com.android.systemui.kairos.internal.TStateSource
+import com.android.systemui.kairos.util.Just
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.None
+import com.android.systemui.kairos.util.none
+import com.android.systemui.kairos.util.orElseGet
// object IdGen {
// private val counter = AtomicLong()
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/BuildScopeImpl.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/BuildScopeImpl.kt
similarity index 89%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/BuildScopeImpl.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/BuildScopeImpl.kt
index 127abd8..90f1aea 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/BuildScopeImpl.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/BuildScopeImpl.kt
@@ -14,34 +14,34 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.CoalescingMutableTFlow
-import com.android.systemui.experimental.frp.FrpBuildScope
-import com.android.systemui.experimental.frp.FrpCoalescingProducerScope
-import com.android.systemui.experimental.frp.FrpDeferredValue
-import com.android.systemui.experimental.frp.FrpEffectScope
-import com.android.systemui.experimental.frp.FrpNetwork
-import com.android.systemui.experimental.frp.FrpProducerScope
-import com.android.systemui.experimental.frp.FrpSpec
-import com.android.systemui.experimental.frp.FrpStateScope
-import com.android.systemui.experimental.frp.FrpTransactionScope
-import com.android.systemui.experimental.frp.GroupedTFlow
-import com.android.systemui.experimental.frp.LocalFrpNetwork
-import com.android.systemui.experimental.frp.MutableTFlow
-import com.android.systemui.experimental.frp.TFlow
-import com.android.systemui.experimental.frp.TFlowInit
-import com.android.systemui.experimental.frp.groupByKey
-import com.android.systemui.experimental.frp.init
-import com.android.systemui.experimental.frp.internal.util.childScope
-import com.android.systemui.experimental.frp.internal.util.launchOnCancel
-import com.android.systemui.experimental.frp.internal.util.mapValuesParallel
-import com.android.systemui.experimental.frp.launchEffect
-import com.android.systemui.experimental.frp.util.Just
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.None
-import com.android.systemui.experimental.frp.util.just
-import com.android.systemui.experimental.frp.util.map
+import com.android.systemui.kairos.CoalescingMutableTFlow
+import com.android.systemui.kairos.FrpBuildScope
+import com.android.systemui.kairos.FrpCoalescingProducerScope
+import com.android.systemui.kairos.FrpDeferredValue
+import com.android.systemui.kairos.FrpEffectScope
+import com.android.systemui.kairos.FrpNetwork
+import com.android.systemui.kairos.FrpProducerScope
+import com.android.systemui.kairos.FrpSpec
+import com.android.systemui.kairos.FrpStateScope
+import com.android.systemui.kairos.FrpTransactionScope
+import com.android.systemui.kairos.GroupedTFlow
+import com.android.systemui.kairos.LocalFrpNetwork
+import com.android.systemui.kairos.MutableTFlow
+import com.android.systemui.kairos.TFlow
+import com.android.systemui.kairos.TFlowInit
+import com.android.systemui.kairos.groupByKey
+import com.android.systemui.kairos.init
+import com.android.systemui.kairos.internal.util.childScope
+import com.android.systemui.kairos.internal.util.launchOnCancel
+import com.android.systemui.kairos.internal.util.mapValuesParallel
+import com.android.systemui.kairos.launchEffect
+import com.android.systemui.kairos.util.Just
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.None
+import com.android.systemui.kairos.util.just
+import com.android.systemui.kairos.util.map
import java.util.concurrent.atomic.AtomicReference
import kotlin.coroutines.Continuation
import kotlin.coroutines.CoroutineContext
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/DeferScope.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/DeferScope.kt
similarity index 88%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/DeferScope.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/DeferScope.kt
index f72ba5f..f65307c 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/DeferScope.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/DeferScope.kt
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.internal.util.asyncImmediate
-import com.android.systemui.experimental.frp.internal.util.launchImmediate
+import com.android.systemui.kairos.internal.util.asyncImmediate
+import com.android.systemui.kairos.internal.util.launchImmediate
import kotlinx.coroutines.CoroutineName
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.CoroutineStart
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Demux.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Demux.kt
similarity index 96%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Demux.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Demux.kt
index 418220f..e7b9952 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Demux.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Demux.kt
@@ -16,13 +16,13 @@
@file:Suppress("NOTHING_TO_INLINE")
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.internal.util.hashString
-import com.android.systemui.experimental.frp.util.Just
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.flatMap
-import com.android.systemui.experimental.frp.util.getMaybe
+import com.android.systemui.kairos.internal.util.hashString
+import com.android.systemui.kairos.util.Just
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.flatMap
+import com.android.systemui.kairos.util.getMaybe
import java.util.concurrent.ConcurrentHashMap
import kotlinx.coroutines.CompletableDeferred
import kotlinx.coroutines.async
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/EvalScopeImpl.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/EvalScopeImpl.kt
similarity index 84%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/EvalScopeImpl.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/EvalScopeImpl.kt
index 38bc22f..815473f 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/EvalScopeImpl.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/EvalScopeImpl.kt
@@ -14,20 +14,20 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.FrpDeferredValue
-import com.android.systemui.experimental.frp.FrpTransactionScope
-import com.android.systemui.experimental.frp.TFlow
-import com.android.systemui.experimental.frp.TFlowInit
-import com.android.systemui.experimental.frp.TFlowLoop
-import com.android.systemui.experimental.frp.TState
-import com.android.systemui.experimental.frp.TStateInit
-import com.android.systemui.experimental.frp.Transactional
-import com.android.systemui.experimental.frp.emptyTFlow
-import com.android.systemui.experimental.frp.init
-import com.android.systemui.experimental.frp.mapCheap
-import com.android.systemui.experimental.frp.switch
+import com.android.systemui.kairos.FrpDeferredValue
+import com.android.systemui.kairos.FrpTransactionScope
+import com.android.systemui.kairos.TFlow
+import com.android.systemui.kairos.TFlowInit
+import com.android.systemui.kairos.TFlowLoop
+import com.android.systemui.kairos.TState
+import com.android.systemui.kairos.TStateInit
+import com.android.systemui.kairos.Transactional
+import com.android.systemui.kairos.emptyTFlow
+import com.android.systemui.kairos.init
+import com.android.systemui.kairos.mapCheap
+import com.android.systemui.kairos.switch
import kotlin.coroutines.Continuation
import kotlin.coroutines.CoroutineContext
import kotlin.coroutines.EmptyCoroutineContext
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/FilterNode.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/FilterNode.kt
similarity index 83%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/FilterNode.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/FilterNode.kt
index 4f2a769..bc06a36 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/FilterNode.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/FilterNode.kt
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.util.Just
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.just
-import com.android.systemui.experimental.frp.util.none
+import com.android.systemui.kairos.util.Just
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.just
+import com.android.systemui.kairos.util.none
internal inline fun <A, B> mapMaybeNode(
crossinline getPulse: suspend EvalScope.() -> TFlowImpl<A>,
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Graph.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Graph.kt
similarity index 99%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Graph.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Graph.kt
index 9425870..3aec319 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Graph.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Graph.kt
@@ -14,9 +14,9 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.internal.util.Bag
+import com.android.systemui.kairos.internal.util.Bag
import java.util.TreeMap
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.launch
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Init.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Init.kt
similarity index 89%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Init.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Init.kt
index efb7a09..57db9a4 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Init.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Init.kt
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.just
-import com.android.systemui.experimental.frp.util.none
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.just
+import com.android.systemui.kairos.util.none
import java.util.concurrent.atomic.AtomicBoolean
import kotlinx.coroutines.CompletableDeferred
import kotlinx.coroutines.ExperimentalCoroutinesApi
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Inputs.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Inputs.kt
similarity index 94%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Inputs.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Inputs.kt
index 85c87fe..8efaf79 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Inputs.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Inputs.kt
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.internal.util.Key
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.just
+import com.android.systemui.kairos.internal.util.Key
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.just
import java.util.concurrent.atomic.AtomicBoolean
import kotlinx.coroutines.coroutineScope
import kotlinx.coroutines.sync.Mutex
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/InternalScopes.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/InternalScopes.kt
similarity index 81%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/InternalScopes.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/InternalScopes.kt
index b6cd906..af864e6 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/InternalScopes.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/InternalScopes.kt
@@ -14,15 +14,15 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.FrpBuildScope
-import com.android.systemui.experimental.frp.FrpStateScope
-import com.android.systemui.experimental.frp.FrpTransactionScope
-import com.android.systemui.experimental.frp.TFlow
-import com.android.systemui.experimental.frp.internal.util.HeteroMap
-import com.android.systemui.experimental.frp.internal.util.Key
-import com.android.systemui.experimental.frp.util.Maybe
+import com.android.systemui.kairos.FrpBuildScope
+import com.android.systemui.kairos.FrpStateScope
+import com.android.systemui.kairos.FrpTransactionScope
+import com.android.systemui.kairos.TFlow
+import com.android.systemui.kairos.internal.util.HeteroMap
+import com.android.systemui.kairos.internal.util.Key
+import com.android.systemui.kairos.util.Maybe
internal interface InitScope {
val networkId: Any
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Mux.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Mux.kt
similarity index 97%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Mux.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Mux.kt
index e616d62..f7ff15f 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Mux.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Mux.kt
@@ -16,11 +16,11 @@
@file:Suppress("NOTHING_TO_INLINE")
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.internal.util.ConcurrentNullableHashMap
-import com.android.systemui.experimental.frp.internal.util.hashString
-import com.android.systemui.experimental.frp.util.Just
+import com.android.systemui.kairos.internal.util.ConcurrentNullableHashMap
+import com.android.systemui.kairos.internal.util.hashString
+import com.android.systemui.kairos.util.Just
import java.util.concurrent.ConcurrentHashMap
import kotlinx.coroutines.coroutineScope
import kotlinx.coroutines.sync.Mutex
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/MuxDeferred.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/MuxDeferred.kt
similarity index 93%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/MuxDeferred.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/MuxDeferred.kt
index 6d43285..08bee85 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/MuxDeferred.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/MuxDeferred.kt
@@ -14,28 +14,28 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.internal.util.Key
-import com.android.systemui.experimental.frp.internal.util.associateByIndexTo
-import com.android.systemui.experimental.frp.internal.util.hashString
-import com.android.systemui.experimental.frp.internal.util.mapParallel
-import com.android.systemui.experimental.frp.internal.util.mapValuesNotNullParallelTo
-import com.android.systemui.experimental.frp.util.Just
-import com.android.systemui.experimental.frp.util.Left
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.None
-import com.android.systemui.experimental.frp.util.Right
-import com.android.systemui.experimental.frp.util.These
-import com.android.systemui.experimental.frp.util.flatMap
-import com.android.systemui.experimental.frp.util.getMaybe
-import com.android.systemui.experimental.frp.util.just
-import com.android.systemui.experimental.frp.util.maybeThat
-import com.android.systemui.experimental.frp.util.maybeThis
-import com.android.systemui.experimental.frp.util.merge
-import com.android.systemui.experimental.frp.util.orElseGet
-import com.android.systemui.experimental.frp.util.partitionEithers
-import com.android.systemui.experimental.frp.util.these
+import com.android.systemui.kairos.internal.util.Key
+import com.android.systemui.kairos.internal.util.associateByIndexTo
+import com.android.systemui.kairos.internal.util.hashString
+import com.android.systemui.kairos.internal.util.mapParallel
+import com.android.systemui.kairos.internal.util.mapValuesNotNullParallelTo
+import com.android.systemui.kairos.util.Just
+import com.android.systemui.kairos.util.Left
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.None
+import com.android.systemui.kairos.util.Right
+import com.android.systemui.kairos.util.These
+import com.android.systemui.kairos.util.flatMap
+import com.android.systemui.kairos.util.getMaybe
+import com.android.systemui.kairos.util.just
+import com.android.systemui.kairos.util.maybeThat
+import com.android.systemui.kairos.util.maybeThis
+import com.android.systemui.kairos.util.merge
+import com.android.systemui.kairos.util.orElseGet
+import com.android.systemui.kairos.util.partitionEithers
+import com.android.systemui.kairos.util.these
import java.util.TreeMap
import kotlinx.coroutines.coroutineScope
import kotlinx.coroutines.launch
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/MuxPrompt.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/MuxPrompt.kt
similarity index 95%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/MuxPrompt.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/MuxPrompt.kt
index ea0c150..cdfafa9 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/MuxPrompt.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/MuxPrompt.kt
@@ -14,20 +14,20 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.internal.util.Key
-import com.android.systemui.experimental.frp.internal.util.launchImmediate
-import com.android.systemui.experimental.frp.internal.util.mapParallel
-import com.android.systemui.experimental.frp.internal.util.mapValuesNotNullParallelTo
-import com.android.systemui.experimental.frp.util.Just
-import com.android.systemui.experimental.frp.util.Left
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.None
-import com.android.systemui.experimental.frp.util.Right
-import com.android.systemui.experimental.frp.util.filterJust
-import com.android.systemui.experimental.frp.util.map
-import com.android.systemui.experimental.frp.util.partitionEithers
+import com.android.systemui.kairos.internal.util.Key
+import com.android.systemui.kairos.internal.util.launchImmediate
+import com.android.systemui.kairos.internal.util.mapParallel
+import com.android.systemui.kairos.internal.util.mapValuesNotNullParallelTo
+import com.android.systemui.kairos.util.Just
+import com.android.systemui.kairos.util.Left
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.None
+import com.android.systemui.kairos.util.Right
+import com.android.systemui.kairos.util.filterJust
+import com.android.systemui.kairos.util.map
+import com.android.systemui.kairos.util.partitionEithers
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.async
import kotlinx.coroutines.awaitAll
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Network.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Network.kt
similarity index 95%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Network.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Network.kt
index b5ffe75..f0df89d 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Network.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Network.kt
@@ -14,14 +14,14 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.TState
-import com.android.systemui.experimental.frp.internal.util.HeteroMap
-import com.android.systemui.experimental.frp.util.Just
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.just
-import com.android.systemui.experimental.frp.util.none
+import com.android.systemui.kairos.TState
+import com.android.systemui.kairos.internal.util.HeteroMap
+import com.android.systemui.kairos.util.Just
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.just
+import com.android.systemui.kairos.util.none
import java.util.concurrent.ConcurrentHashMap
import java.util.concurrent.ConcurrentLinkedDeque
import java.util.concurrent.ConcurrentLinkedQueue
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/NoScope.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/NoScope.kt
similarity index 93%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/NoScope.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/NoScope.kt
index 6375918..fbd9689 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/NoScope.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/NoScope.kt
@@ -14,9 +14,9 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.FrpScope
+import com.android.systemui.kairos.FrpScope
import kotlin.coroutines.Continuation
import kotlin.coroutines.CoroutineContext
import kotlin.coroutines.EmptyCoroutineContext
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/NodeTypes.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/NodeTypes.kt
similarity index 95%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/NodeTypes.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/NodeTypes.kt
index e7f76a0..0002407 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/NodeTypes.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/NodeTypes.kt
@@ -14,9 +14,9 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.util.Maybe
+import com.android.systemui.kairos.util.Maybe
/*
Dmux
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Output.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Output.kt
similarity index 94%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Output.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Output.kt
index e60dcca..a3af2d3 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Output.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Output.kt
@@ -14,9 +14,9 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.util.Just
+import com.android.systemui.kairos.util.Just
import kotlin.coroutines.CoroutineContext
import kotlin.coroutines.EmptyCoroutineContext
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/PullNodes.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/PullNodes.kt
similarity index 91%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/PullNodes.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/PullNodes.kt
index b4656e0..dac98e0 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/PullNodes.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/PullNodes.kt
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.internal.util.Key
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.map
+import com.android.systemui.kairos.internal.util.Key
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.map
import kotlinx.coroutines.CoroutineStart
import kotlinx.coroutines.Deferred
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Scheduler.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Scheduler.kt
similarity index 98%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Scheduler.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Scheduler.kt
index 4fef865..872fb7a 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/Scheduler.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/Scheduler.kt
@@ -16,7 +16,7 @@
@file:OptIn(ExperimentalCoroutinesApi::class)
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
import java.util.concurrent.ConcurrentHashMap
import java.util.concurrent.PriorityBlockingQueue
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/StateScopeImpl.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/StateScopeImpl.kt
similarity index 89%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/StateScopeImpl.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/StateScopeImpl.kt
index c1d1076..baf4101 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/StateScopeImpl.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/StateScopeImpl.kt
@@ -14,27 +14,27 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.FrpDeferredValue
-import com.android.systemui.experimental.frp.FrpStateScope
-import com.android.systemui.experimental.frp.FrpStateful
-import com.android.systemui.experimental.frp.FrpTransactionScope
-import com.android.systemui.experimental.frp.GroupedTFlow
-import com.android.systemui.experimental.frp.TFlow
-import com.android.systemui.experimental.frp.TFlowInit
-import com.android.systemui.experimental.frp.TFlowLoop
-import com.android.systemui.experimental.frp.TState
-import com.android.systemui.experimental.frp.TStateInit
-import com.android.systemui.experimental.frp.emptyTFlow
-import com.android.systemui.experimental.frp.groupByKey
-import com.android.systemui.experimental.frp.init
-import com.android.systemui.experimental.frp.internal.util.mapValuesParallel
-import com.android.systemui.experimental.frp.mapCheap
-import com.android.systemui.experimental.frp.merge
-import com.android.systemui.experimental.frp.switch
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.map
+import com.android.systemui.kairos.FrpDeferredValue
+import com.android.systemui.kairos.FrpStateScope
+import com.android.systemui.kairos.FrpStateful
+import com.android.systemui.kairos.FrpTransactionScope
+import com.android.systemui.kairos.GroupedTFlow
+import com.android.systemui.kairos.TFlow
+import com.android.systemui.kairos.TFlowInit
+import com.android.systemui.kairos.TFlowLoop
+import com.android.systemui.kairos.TState
+import com.android.systemui.kairos.TStateInit
+import com.android.systemui.kairos.emptyTFlow
+import com.android.systemui.kairos.groupByKey
+import com.android.systemui.kairos.init
+import com.android.systemui.kairos.internal.util.mapValuesParallel
+import com.android.systemui.kairos.mapCheap
+import com.android.systemui.kairos.merge
+import com.android.systemui.kairos.switch
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.map
import kotlin.coroutines.Continuation
import kotlin.coroutines.CoroutineContext
import kotlin.coroutines.EmptyCoroutineContext
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/TFlowImpl.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/TFlowImpl.kt
similarity index 94%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/TFlowImpl.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/TFlowImpl.kt
index 7997864..b904b48 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/TFlowImpl.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/TFlowImpl.kt
@@ -14,9 +14,9 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.util.Maybe
+import com.android.systemui.kairos.util.Maybe
/* Initialized TFlow */
internal fun interface TFlowImpl<out A> {
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/TStateImpl.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/TStateImpl.kt
similarity index 95%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/TStateImpl.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/TStateImpl.kt
index d8b6dac..5cec05c 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/TStateImpl.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/TStateImpl.kt
@@ -14,16 +14,16 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.internal.util.Key
-import com.android.systemui.experimental.frp.internal.util.associateByIndex
-import com.android.systemui.experimental.frp.internal.util.hashString
-import com.android.systemui.experimental.frp.internal.util.mapValuesParallel
-import com.android.systemui.experimental.frp.util.Just
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.just
-import com.android.systemui.experimental.frp.util.none
+import com.android.systemui.kairos.internal.util.Key
+import com.android.systemui.kairos.internal.util.associateByIndex
+import com.android.systemui.kairos.internal.util.hashString
+import com.android.systemui.kairos.internal.util.mapValuesParallel
+import com.android.systemui.kairos.util.Just
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.just
+import com.android.systemui.kairos.util.none
import java.util.concurrent.atomic.AtomicLong
import kotlinx.coroutines.CompletableDeferred
import kotlinx.coroutines.CoroutineStart
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/TransactionalImpl.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/TransactionalImpl.kt
similarity index 89%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/TransactionalImpl.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/TransactionalImpl.kt
index c3f80a1..8647bdd 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/TransactionalImpl.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/TransactionalImpl.kt
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal
+package com.android.systemui.kairos.internal
-import com.android.systemui.experimental.frp.internal.util.Key
-import com.android.systemui.experimental.frp.internal.util.hashString
+import com.android.systemui.kairos.internal.util.Key
+import com.android.systemui.kairos.internal.util.hashString
import kotlinx.coroutines.CoroutineStart
import kotlinx.coroutines.Deferred
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/Bag.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/Bag.kt
similarity index 96%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/Bag.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/Bag.kt
index cc5538e..4718519 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/Bag.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/Bag.kt
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal.util
+package com.android.systemui.kairos.internal.util
internal class Bag<T> private constructor(private val intMap: MutableMap<T, Int>) :
Set<T> by intMap.keys {
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/ConcurrentNullableHashMap.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/ConcurrentNullableHashMap.kt
similarity index 95%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/ConcurrentNullableHashMap.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/ConcurrentNullableHashMap.kt
index 449aa19..6c8ae7c 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/ConcurrentNullableHashMap.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/ConcurrentNullableHashMap.kt
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal.util
+package com.android.systemui.kairos.internal.util
import java.util.concurrent.ConcurrentHashMap
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/HeteroMap.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/HeteroMap.kt
similarity index 86%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/HeteroMap.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/HeteroMap.kt
index 14a567c..5cee2dd 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/HeteroMap.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/HeteroMap.kt
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal.util
+package com.android.systemui.kairos.internal.util
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.None
-import com.android.systemui.experimental.frp.util.just
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.None
+import com.android.systemui.kairos.util.just
import java.util.concurrent.ConcurrentHashMap
internal interface Key<A>
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/MapUtils.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/MapUtils.kt
similarity index 97%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/MapUtils.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/MapUtils.kt
index 6f19a76..ebf9a66 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/MapUtils.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/MapUtils.kt
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.internal.util
+package com.android.systemui.kairos.internal.util
import kotlinx.coroutines.CoroutineStart
import kotlinx.coroutines.async
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/Util.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/Util.kt
similarity index 97%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/Util.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/Util.kt
index 0a47429..6bb7f9f 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/internal/util/Util.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/internal/util/Util.kt
@@ -16,7 +16,7 @@
@file:OptIn(ExperimentalCoroutinesApi::class)
-package com.android.systemui.experimental.frp.internal.util
+package com.android.systemui.kairos.internal.util
import kotlin.coroutines.CoroutineContext
import kotlin.coroutines.EmptyCoroutineContext
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/util/Either.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/util/Either.kt
similarity index 98%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/util/Either.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/util/Either.kt
index dca8364..ad9f7d7 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/util/Either.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/util/Either.kt
@@ -16,7 +16,7 @@
@file:Suppress("NOTHING_TO_INLINE")
-package com.android.systemui.experimental.frp.util
+package com.android.systemui.kairos.util
/**
* Contains a value of two possibilities: `Left<A>` or `Right<B>`
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/util/Maybe.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/util/Maybe.kt
similarity index 99%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/util/Maybe.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/util/Maybe.kt
index 59c680e..c3cae38 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/util/Maybe.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/util/Maybe.kt
@@ -16,7 +16,7 @@
@file:Suppress("NOTHING_TO_INLINE", "SuspendCoroutine")
-package com.android.systemui.experimental.frp.util
+package com.android.systemui.kairos.util
import kotlin.coroutines.Continuation
import kotlin.coroutines.CoroutineContext
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/util/These.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/util/These.kt
similarity index 98%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/util/These.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/util/These.kt
index 5404c07..aa95e0d 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/util/These.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/util/These.kt
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.util
+package com.android.systemui.kairos.util
/** Contains at least one of two potential values. */
sealed class These<A, B> {
diff --git a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/util/WithPrev.kt b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/util/WithPrev.kt
similarity index 93%
rename from packages/SystemUI/frp/src/com/android/systemui/experimental/frp/util/WithPrev.kt
rename to packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/util/WithPrev.kt
index e52a6e1..5cfaa3e 100644
--- a/packages/SystemUI/frp/src/com/android/systemui/experimental/frp/util/WithPrev.kt
+++ b/packages/SystemUI/utils/kairos/src/com/android/systemui/kairos/util/WithPrev.kt
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.android.systemui.experimental.frp.util
+package com.android.systemui.kairos.util
/** Holds a [newValue] emitted from a `TFlow`, along with the [previousValue] emitted value. */
data class WithPrev<out S, out T : S>(val previousValue: S, val newValue: T)
diff --git a/packages/SystemUI/frp/test/com/android/systemui/experimental/frp/FrpTests.kt b/packages/SystemUI/utils/kairos/test/com/android/systemui/kairos/KairosTests.kt
similarity index 98%
rename from packages/SystemUI/frp/test/com/android/systemui/experimental/frp/FrpTests.kt
rename to packages/SystemUI/utils/kairos/test/com/android/systemui/kairos/KairosTests.kt
index a58f499..165230b 100644
--- a/packages/SystemUI/frp/test/com/android/systemui/experimental/frp/FrpTests.kt
+++ b/packages/SystemUI/utils/kairos/test/com/android/systemui/kairos/KairosTests.kt
@@ -16,17 +16,17 @@
@file:OptIn(ExperimentalCoroutinesApi::class, ExperimentalFrpApi::class)
-package com.android.systemui.experimental.frp
+package com.android.systemui.kairos
-import com.android.systemui.experimental.frp.util.Either
-import com.android.systemui.experimental.frp.util.Left
-import com.android.systemui.experimental.frp.util.Maybe
-import com.android.systemui.experimental.frp.util.None
-import com.android.systemui.experimental.frp.util.Right
-import com.android.systemui.experimental.frp.util.just
-import com.android.systemui.experimental.frp.util.map
-import com.android.systemui.experimental.frp.util.maybe
-import com.android.systemui.experimental.frp.util.none
+import com.android.systemui.kairos.util.Either
+import com.android.systemui.kairos.util.Left
+import com.android.systemui.kairos.util.Maybe
+import com.android.systemui.kairos.util.None
+import com.android.systemui.kairos.util.Right
+import com.android.systemui.kairos.util.just
+import com.android.systemui.kairos.util.map
+import com.android.systemui.kairos.util.maybe
+import com.android.systemui.kairos.util.none
import kotlin.time.Duration
import kotlin.time.Duration.Companion.seconds
import kotlin.time.DurationUnit
@@ -55,7 +55,7 @@
import org.junit.Assert.assertTrue
import org.junit.Test
-class FrpTests {
+class KairosTests {
@Test
fun basic() = runFrpTest { network ->