---
title: "serviceClass(_:)"
framework: network
role: symbol
role_heading: Instance Method
path: "network/nwparametersprovider/serviceclass(_:)"
---

# serviceClass(_:)

Set the data service class to use for connections.

## Declaration

```swift
func serviceClass(_ serviceClass: NWParameters.ServiceClass) -> Self
```

## Parameters

- `serviceClass`: The service class to use.
