pub unsafe trait VZNetworkBlockDeviceStorageDeviceAttachmentDelegate: NSObjectProtocol {
// Provided methods
unsafe fn attachmentWasConnected(
&self,
attachment: &VZNetworkBlockDeviceStorageDeviceAttachment,
)
where Self: Sized + Message { ... }
unsafe fn attachment_didEncounterError(
&self,
attachment: &VZNetworkBlockDeviceStorageDeviceAttachment,
error: &NSError,
)
where Self: Sized + Message { ... }
}
VZNetworkBlockDeviceStorageDeviceAttachment
only.Expand description
A class conforming to VZNetworkBlockDeviceStorageDeviceAttachmentDelegate can provide methods for tracking the attachment’s state.
See also Apple’s documentation
Provided Methods§
Sourceunsafe fn attachmentWasConnected(
&self,
attachment: &VZNetworkBlockDeviceStorageDeviceAttachment,
)
Available on crate feature VZStorageDeviceAttachment
only.
unsafe fn attachmentWasConnected( &self, attachment: &VZNetworkBlockDeviceStorageDeviceAttachment, )
VZStorageDeviceAttachment
only.Invoked when the NBD client has successfully connected/reconnected with the server.
Parameter attachment
: The attachment object invoking the delegate method.
Connection with the server will take place when the virtual machine is first started, and reconnection attempts will take place when the connection times out or when the NBD client has encountered a recoverable error, such as an I/O error from the server. The method may be invoked multiple times during a virtual machine’s life cycle. Reconnections are transparent to the guest.
Sourceunsafe fn attachment_didEncounterError(
&self,
attachment: &VZNetworkBlockDeviceStorageDeviceAttachment,
error: &NSError,
)
Available on crate feature VZStorageDeviceAttachment
only.
unsafe fn attachment_didEncounterError( &self, attachment: &VZNetworkBlockDeviceStorageDeviceAttachment, error: &NSError, )
VZStorageDeviceAttachment
only.Invoked when the NBD client has encountered a non-recoverable error.
Parameter attachment
: The attachment object invoking the delegate method.
Parameter error
: The error.
The NBD client will be in a non-functional state after this method is invoked.