---
title: hasSpaceAvailable
framework: foundation
role: symbol
role_heading: Instance Property
path: foundation/outputstream/hasspaceavailable
---

# hasSpaceAvailable

A boolean value that indicates whether the receiver can be written to.

## Declaration

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

## Discussion

Discussion true if the receiver can be written to or if a write must be attempted in order to determine if space is available, false otherwise.

## See Also

### Using Streams

- [write(_:maxLength:)](foundation/outputstream/write(_:maxlength:).md)
