<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "macOS: -",
    "tvOS: -",
    "visionOS: -",
    "watchOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "CoreFoundation",
  "identifier" : "/documentation/CoreFoundation/CFNotificationCenterPostNotificationWithOptions(_:_:_:_:_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Core Foundation"
    ],
    "preciseIdentifier" : "c:@F@CFNotificationCenterPostNotificationWithOptions"
  },
  "title" : "CFNotificationCenterPostNotificationWithOptions(_:_:_:_:_:)"
}
-->

# CFNotificationCenterPostNotificationWithOptions(_:_:_:_:_:)

Posts a notification for an object using specified options.

```
func CFNotificationCenterPostNotificationWithOptions(_ center: CFNotificationCenter!, _ name: CFNotificationName!, _ object: UnsafeRawPointer!, _ userInfo: CFDictionary!, _ options: CFOptionFlags)
```

## Parameters

`center`

The notification center to post the notification.

`name`

The name of the notification to post. This value must not be `NULL`.

`object`

The object posting the notification. If `NULL`, the notification is sent only to observers that are observing all objects. In other words, only observers that registered for the notification with a `NULL` value for `object` will receive the notification.

    If you want to allow your clients to register for notifications using Cocoa APIs (see     <doc://com.apple.documentation/documentation/Foundation/NotificationCenter>    ), then     `object`     must be a Core Foundation or Cocoa object.

    For distributed notifications,     `object`     must be a CFString object.

    If     `center`     is a Darwin notification center, this value is ignored.

`userInfo`

A dictionary to pass to observers. You populate this dictionary with additional information describing the notification. For distributed notifications, the dictionary must contain only property list objects. Can be `NULL`.
If `center` is a Darwin notification center, this value is ignored.

`options`

Specifies if the notification should be posted immediately, or to all sessions. See [Notification Posting Options](/documentation/CoreFoundation/1569610-notification-posting-options) for possible values.

    If     `center`     is a Darwin notification center, this value is ignored.

## Discussion

---

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)