---
title: VZDirectorySharingDevice
framework: virtualization
role: symbol
role_heading: Class
path: virtualization/vzdirectorysharingdevice
---

# VZDirectorySharingDevice

The base class that represents a directory sharing device in a VM.

## Declaration

```swift
class VZDirectorySharingDevice
```

## Overview

Overview Don’t instantiate VZDirectorySharingDevice directly; configure a directory sharing device first by using VZVirtualMachineConfiguration through a subclass of VZDirectorySharingDeviceConfiguration. When you create a VZVirtualMachine from the configuration, the directory sharing devices are available through the VZVirtualMachine.directorySharingDevices property. The real type of VZDirectorySharingDevice corresponds to the type used by the configuration. For example, a VZVirtioFileSystemDeviceConfiguration leads to a device of type VZVirtioFileSystemDevice.

## Relationships

### Inherits From

- [NSObject](objectivec/nsobject-swift.class.md)

### Inherited By

- [VZVirtioFileSystemDevice](virtualization/vzvirtiofilesystemdevice.md)

### Conforms To

- [CVarArg](swift/cvararg.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [CustomStringConvertible](swift/customstringconvertible.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)

## See Also

### Shared directory devices

- [VZVirtioFileSystemDevice](virtualization/vzvirtiofilesystemdevice.md)
