---
title: AVCustomRoutingPartialIP
framework: avrouting
role: symbol
role_heading: Class
path: avrouting/avcustomroutingpartialip
---

# AVCustomRoutingPartialIP

An object that represents a full or partial IP address.

## Declaration

```swift
class AVCustomRoutingPartialIP
```

## Overview

Overview Use this type to define the IP address and subnet mask of known routes on a local network. Create an instance of this class and add it to a custom routing controller’s knownRouteIPs array like shown below: // Define the IP address. let anIPAddressInBytes:[UInt8] = [192, 168, 10, 5] let address = Data(bytes: anIPAddressInBytes, count: anIPAddressInBytes.count)

// Define the subnet mask. let aMaskInBytes:[UInt8] = [255, 255, 255, 255] let mask = Data(bytes: aMaskInBytes, count: aMaskInBytes.count)

// Create a new object to represent the address and mask. let partialIP = AVCustomRoutingPartialIP(address: address, mask: mask)

// Add the instance to the custom routing controller's known routes. routingController.knownRouteIPs.append(partialIP)

## Topics

### Creating an IP fragment

- [init(address:mask:)](avrouting/avcustomroutingpartialip/init(address:mask:).md)

### Inspecting the IP fragment

- [address](avrouting/avcustomroutingpartialip/address.md)
- [mask](avrouting/avcustomroutingpartialip/mask.md)

## Relationships

### Inherits From

- [NSObject](objectivec/nsobject-swift.class.md)

### Conforms To

- [CVarArg](swift/cvararg.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [CustomStringConvertible](swift/customstringconvertible.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### Configuring route addresses

- [knownRouteIPs](avrouting/avcustomroutingcontroller/knownrouteips.md)
