API Notes: OpenDirectory and CFOpenDirectory frameworks
An introduction to PyObjC describes the general method for translating Objective-C calls into Python calls, including the handling of pass-by-reference arguments and buffers.
This document describes where the PyObjC bindings for this framework are different from the general rule, such as mentioning APIs that are not supported or where the interface is different than expected.
Both the OpenDirectory framework and the embedded CFOpenDirectory framework are fully wrapped and can be used as described in the generic PyObjC documentation.
The callback function is stored by the framework, the callable can therefore not be
a generic callable, but must be a callable that is annotated using the
@objc.callbackFor("CFOpenDirectory.ODQuerySetCallback") def query_callback(query, value, context, error, info): pass
userInfo argument needs to be an integer.
This function is not supported because PyObjC doesn’t interface with dispatch queues yet.