mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-03 06:55:41 +00:00
Document the nuances in UserId and SessionId types. (#1616)
This commit is contained in:
+3
@@ -16,4 +16,7 @@
|
|||||||
|
|
||||||
package io.element.android.libraries.matrix.api.core
|
package io.element.android.libraries.matrix.api.core
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The [UserId] of the currently logged in user.
|
||||||
|
*/
|
||||||
typealias SessionId = UserId
|
typealias SessionId = UserId
|
||||||
|
|||||||
+5
@@ -19,6 +19,11 @@ package io.element.android.libraries.matrix.api.core
|
|||||||
import io.element.android.libraries.matrix.api.BuildConfig
|
import io.element.android.libraries.matrix.api.BuildConfig
|
||||||
import java.io.Serializable
|
import java.io.Serializable
|
||||||
|
|
||||||
|
/**
|
||||||
|
* A [String] holding a valid Matrix user ID.
|
||||||
|
*
|
||||||
|
* https://spec.matrix.org/v1.8/appendices/#user-identifiers
|
||||||
|
*/
|
||||||
@JvmInline
|
@JvmInline
|
||||||
value class UserId(val value: String) : Serializable {
|
value class UserId(val value: String) : Serializable {
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user