---
title: "sharedController(withID:xpcConnect:)"
framework: matter
role: symbol
role_heading: Type Method
path: "matter/mtrdevicecontroller/sharedcontroller(withid:xpcconnect:)-5yhq4"
---

# sharedController(withID:xpcConnect:)

## Declaration

```swift
class func sharedController(withID controllerID: (any NSCopying)?, xpcConnect xpcConnectBlock: @escaping MTRXPCConnectBlock) -> MTRDeviceController
```
