summaryrefslogtreecommitdiff
path: root/src/main/kotlin/io/dico/parcels2/storage/Backing.kt
diff options
context:
space:
mode:
authorDico <dico.karssiens@gmail.com>2018-09-24 02:45:41 +0100
committerDico <dico.karssiens@gmail.com>2018-09-24 02:45:41 +0100
commit1a440767b3d8d7b267ecfeeb37f8c315bae9d112 (patch)
tree7250af6b41be34f41c2b5702922bb1d3948f15ce /src/main/kotlin/io/dico/parcels2/storage/Backing.kt
parente0bf8249bdf23386039d395ec55b2a011c2e09ac (diff)
Replace AddedData API with Privileges API, adding CAN_MANAGE and required changes
Diffstat (limited to 'src/main/kotlin/io/dico/parcels2/storage/Backing.kt')
-rw-r--r--src/main/kotlin/io/dico/parcels2/storage/Backing.kt12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/main/kotlin/io/dico/parcels2/storage/Backing.kt b/src/main/kotlin/io/dico/parcels2/storage/Backing.kt
index 6c91714..69c5b62 100644
--- a/src/main/kotlin/io/dico/parcels2/storage/Backing.kt
+++ b/src/main/kotlin/io/dico/parcels2/storage/Backing.kt
@@ -1,13 +1,13 @@
package io.dico.parcels2.storage
import io.dico.parcels2.*
-import kotlinx.coroutines.CoroutineDispatcher
import kotlinx.coroutines.Deferred
import kotlinx.coroutines.Job
import kotlinx.coroutines.channels.ReceiveChannel
import kotlinx.coroutines.channels.SendChannel
import org.joda.time.DateTime
import java.util.UUID
+import kotlin.coroutines.CoroutineContext
interface Backing {
@@ -15,7 +15,7 @@ interface Backing {
val isConnected: Boolean
- val dispatcher: CoroutineDispatcher
+ val coroutineContext: CoroutineContext
fun launchJob(job: Backing.() -> Unit): Job
@@ -56,9 +56,9 @@ interface Backing {
fun setParcelOwnerSignOutdated(parcel: ParcelId, outdated: Boolean)
- fun setLocalPlayerStatus(parcel: ParcelId, player: PlayerProfile, status: AddedStatus)
+ fun setLocalPrivilege(parcel: ParcelId, player: PlayerProfile, status: Privilege)
- fun setParcelOptionsInteractBitmask(parcel: ParcelId, bitmask: IntArray?)
+ fun setParcelOptionsInteractConfig(parcel: ParcelId, config: InteractableConfiguration)
/*
fun setParcelAllowsInteractInventory(parcel: ParcelId, value: Boolean)
@@ -67,7 +67,7 @@ interface Backing {
fun transmitAllGlobalAddedData(channel: SendChannel<AddedDataPair<PlayerProfile>>)
- fun readGlobalAddedData(owner: PlayerProfile): MutableAddedDataMap
+ fun readGlobalPrivileges(owner: PlayerProfile): MutablePrivilegeMap
- fun setGlobalPlayerStatus(owner: PlayerProfile, player: PlayerProfile, status: AddedStatus)
+ fun setGlobalPrivilege(owner: PlayerProfile, player: PlayerProfile, status: Privilege)
}