remote: refactor (WIP) (#3222)

* remote: refactor (WIP)

* refactor discoverRemoteCtrls

* refactor processRemoteCommand, storeRemoteFile

* refactor fetchRemoteFile

* refactor startRemoteHost, receiving files

* refactor relayCommand
This commit is contained in:
Evgeny Poberezkin
2023-10-15 14:17:36 +01:00
committed by GitHub
parent 41b86e07f1
commit fc1bba8817
9 changed files with 274 additions and 254 deletions
@@ -4521,7 +4521,6 @@ sealed class RemoteHostError {
@Serializable
sealed class RemoteCtrlError {
val string: String get() = when (this) {
is Missing -> "missing"
is Inactive -> "inactive"
is Busy -> "busy"
is Timeout -> "timeout"
@@ -4531,7 +4530,6 @@ sealed class RemoteCtrlError {
is CertificateUntrusted -> "certificateUntrusted"
is BadFingerprint -> "badFingerprint"
}
@Serializable @SerialName("missing") class Missing(val remoteCtrlId: Long): RemoteCtrlError()
@Serializable @SerialName("inactive") object Inactive: RemoteCtrlError()
@Serializable @SerialName("busy") object Busy: RemoteCtrlError()
@Serializable @SerialName("timeout") object Timeout: RemoteCtrlError()