<!--
{
  "availability" : [
    "macOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "IOBluetooth",
  "identifier" : "/documentation/IOBluetooth/OBEXSession/setEventSelector(_:target:refCon:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "IOBluetooth"
    ],
    "preciseIdentifier" : "c:objc(cs)OBEXSession(im)setEventSelector:target:refCon:"
  },
  "title" : "setEventSelector(_:target:refCon:)"
}
-->

# setEventSelector(_:target:refCon:)

Allow you to set a selector to be called when events occur on the OBEX session.

```
func setEventSelector(_ inEventSelector: Selector!, target inEventSelectorTarget: Any!, refCon inUserRefCon: UnsafeMutableRawPointer!)
```

## Parameters

`inEventSelector`

Selector to call on the target.

`inEventSelectorTarget`

Target to be called with the selector.

`inUserRefCon`

User’s refCon that will get passed when their event callback is invoked.

## Discussion

Really not needed to be used, since the event selector will get set when an OBEX command is sent out.

---

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)