---
title: hasDirectoryPath
framework: foundation
role: symbol
role_heading: Instance Property
path: foundation/url/hasdirectorypath
---

# hasDirectoryPath

A Boolean that is true if the URL path represents a directory.

## Declaration

```swift
var hasDirectoryPath: Bool { get }
```

## See Also

### Working with file URLs

- [isFileURL](foundation/url/isfileurl.md)
- [withUnsafeFileSystemRepresentation(_:)](foundation/url/withunsafefilesystemrepresentation(_:).md)
- [resolveSymlinksInPath()](foundation/url/resolvesymlinksinpath().md)
- [resolvingSymlinksInPath()](foundation/url/resolvingsymlinksinpath().md)
- [standardize()](foundation/url/standardize().md)
