<!--
{
  "availability" : [
    "iOS: 27.0.0 -",
    "iPadOS: 27.0.0 -",
    "macCatalyst: 27.0.0 -",
    "macOS: 27.0.0 -",
    "tvOS: 27.0.0 -",
    "visionOS: 27.0.0 -",
    "watchOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "System",
  "identifier" : "/documentation/System/FileDescriptor/PipeOptions",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "System"
    ],
    "preciseIdentifier" : "s:6System14FileDescriptorV11PipeOptionsV"
  },
  "title" : "FileDescriptor.PipeOptions"
}
-->

# FileDescriptor.PipeOptions

Options that specify behavior for a newly-created pipe.

```
@frozen struct PipeOptions
```

## Topics

### Initializers

[`init(rawValue: CInt)`](/documentation/System/FileDescriptor/PipeOptions/init(rawValue:))

Create a strongly-typed options value from raw C options.

### Instance Properties

[`var rawValue: CInt`](/documentation/System/FileDescriptor/PipeOptions/rawValue)

The raw C options.

### Type Properties

[`static var closeOnExec: FileDescriptor.PipeOptions`](/documentation/System/FileDescriptor/PipeOptions/closeOnExec)

Indicates that executing a program closes the file.

[`static var closeOnFork: FileDescriptor.PipeOptions`](/documentation/System/FileDescriptor/PipeOptions/closeOnFork)

Indicates that forking a program closes the file.

[`static var nonBlocking: FileDescriptor.PipeOptions`](/documentation/System/FileDescriptor/PipeOptions/nonBlocking)

Indicates that all subsequent input and output operations
on the pipe’s file descriptors will be nonblocking.

## Relationships

### Conforms To

[`RawRepresentable`](/documentation/Swift/RawRepresentable)

[`BitwiseCopyable`](/documentation/Swift/BitwiseCopyable)

[`Encodable`](/documentation/Swift/Encodable)

[`Hashable`](/documentation/Swift/Hashable)

[`Copyable`](/documentation/Swift/Copyable)

[`SetAlgebra`](/documentation/Swift/SetAlgebra)

[`Decodable`](/documentation/Swift/Decodable)

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

[`Equatable`](/documentation/Swift/Equatable)

[`Sendable`](/documentation/Swift/Sendable)

[`ExpressibleByArrayLiteral`](/documentation/Swift/ExpressibleByArrayLiteral)

[`OptionSet`](/documentation/Swift/OptionSet)

---

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)