---
title: NETrafficDirection
framework: networkextension
role: symbol
role_heading: Enumeration
path: networkextension/netrafficdirection
---

# NETrafficDirection

A type to represent the direction of network traffic.

## Declaration

```swift
enum NETrafficDirection
```

## Topics

### Directions

- [NETrafficDirection.inbound](networkextension/netrafficdirection/inbound.md)
- [NETrafficDirection.outbound](networkextension/netrafficdirection/outbound.md)
- [NETrafficDirection.any](networkextension/netrafficdirection/any.md)

### Initializers

- [init(rawValue:)](networkextension/netrafficdirection/init(rawvalue:).md)

## Relationships

### Conforms To

- [BitwiseCopyable](swift/bitwisecopyable.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [RawRepresentable](swift/rawrepresentable.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### Matching network traffic characteristics

- [matchRemoteEndpoint](networkextension/nenetworkrule/matchremoteendpoint.md)
- [matchRemotePrefix](networkextension/nenetworkrule/matchremoteprefix.md)
- [matchLocalNetwork](networkextension/nenetworkrule/matchlocalnetwork.md)
- [matchLocalPrefix](networkextension/nenetworkrule/matchlocalprefix.md)
- [matchProtocol](networkextension/nenetworkrule/matchprotocol.md)
- [NENetworkRule.Protocol](networkextension/nenetworkrule/protocol.md)
- [matchDirection](networkextension/nenetworkrule/matchdirection.md)
