mirror of
https://github.com/leonboe1/QuickDrop.git
synced 2026-11-19 12:56:06 +00:00
Refactoring
This commit is contained in:
1 parent
149c375230
commit
c7b47eba6f
7 files changed
+41
-41
No files matched your search
@@ -12,23 +12,23 @@ import SwiftECC
|
||||
|
||||
|
||||
protocol InboundNearbyConnectionDelegate {
|
||||
func obtainUserConsent(for transfer: TransferMetadata, from device: RemoteDeviceInfo, connection: InboundNearbyConnection)
|
||||
func inboundConnection(connection: InboundNearbyConnection, transferProgress: Double)
|
||||
func obtainUserConsent(transfer: TransferMetadata, device: RemoteDeviceInfo, connection: InboundNearbyConnection)
|
||||
func updatedTransferProgress(connection: InboundNearbyConnection, progress: Double)
|
||||
func connectionWasTerminated(connection: InboundNearbyConnection, error: Error?)
|
||||
}
|
||||
|
||||
|
||||
protocol OutboundNearbyConnectionDelegate {
|
||||
func outboundConnectionWasEstablished(connection: OutboundNearbyConnection)
|
||||
func outboundConnection(connection: OutboundNearbyConnection, transferProgress: Double)
|
||||
func outboundConnectionTransferAccepted(connection: OutboundNearbyConnection)
|
||||
func outboundConnection(connection: OutboundNearbyConnection, failedWithError: Error)
|
||||
func outboundConnectionTransferFinished(connection: OutboundNearbyConnection)
|
||||
func connectionWasEstablished(connection: OutboundNearbyConnection)
|
||||
func updatedTransferProgress(connection: OutboundNearbyConnection, progress: Double)
|
||||
func transferAccepted(connection: OutboundNearbyConnection)
|
||||
func failedWithError(connection: OutboundNearbyConnection, error: Error)
|
||||
func transferFinished(connection: OutboundNearbyConnection)
|
||||
}
|
||||
|
||||
|
||||
public protocol InboundAppDelegate: AnyObject {
|
||||
func obtainUserConsent(for transfer: TransferMetadata, from device: RemoteDeviceInfo)
|
||||
func obtainUserConsent(transfer: TransferMetadata, device: RemoteDeviceInfo)
|
||||
func connectionWasTerminated(from device: RemoteDeviceInfo, wasPlainTextTransfer: Bool, error: Error?)
|
||||
func transferProgress(progress: Double)
|
||||
}
|
||||
@@ -39,7 +39,7 @@ public protocol OutboundAppDelegate: AnyObject {
|
||||
func removeDevice(id: String)
|
||||
func startTransferWithQrCode(device: RemoteDeviceInfo)
|
||||
func connectionWasEstablished(pinCode: String)
|
||||
func connectionFailed(with error: Error)
|
||||
func connectionFailed(error: Error)
|
||||
func transferAccepted()
|
||||
func transferProgress(progress: Double)
|
||||
func transferFinished()
|
||||
|
||||
Reference in new issue
Block a user