<!--
{
  "availability" : [
    "macOS: 14.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Virtualization",
  "identifier" : "/documentation/Virtualization/VZNetworkBlockDeviceStorageDeviceAttachmentDelegate",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "Virtualization"
    ],
    "preciseIdentifier" : "c:objc(pl)VZNetworkBlockDeviceStorageDeviceAttachmentDelegate"
  },
  "title" : "VZNetworkBlockDeviceStorageDeviceAttachmentDelegate"
}
-->

# VZNetworkBlockDeviceStorageDeviceAttachmentDelegate

Methods you implement to respond to changes to a network block device attachment.

```
protocol VZNetworkBlockDeviceStorageDeviceAttachmentDelegate : NSObjectProtocol
```

## Topics

### Responding to connectivity changes

[`attachment(_:didEncounterError:)`](/documentation/Virtualization/VZNetworkBlockDeviceStorageDeviceAttachmentDelegate/attachment(_:didEncounterError:))

The method the attachment object calls when the NBD client encounters a nonrecoverable error.

[`attachmentWasConnected(_:)`](/documentation/Virtualization/VZNetworkBlockDeviceStorageDeviceAttachmentDelegate/attachmentWasConnected(_:))

The method the attachment object calls when the NBD client successfully connects or reconnects with the server.



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)