---
title: directoryAttributes
framework: foundation
role: symbol
role_heading: Instance Property
path: foundation/filemanager/directoryenumerator/directoryattributes
---

# directoryAttributes

A dictionary with the attributes of the directory at which enumeration started.

## Declaration

```swift
var directoryAttributes: [FileAttributeKey : Any]? { get }
```

## Discussion

Discussion See the description of the fileAttributes(atPath:traverseLink:) method of FileManager for details on obtaining the attributes from the dictionary.

## See Also

### Related Documentation

- [createDirectory(atPath:attributes:)](foundation/filemanager/createdirectory(atpath:attributes:).md)

### Getting File and Directory Attributes

- [fileAttributes](foundation/filemanager/directoryenumerator/fileattributes.md)
- [level](foundation/filemanager/directoryenumerator/level.md)
