Skip to content

Commit

Permalink
Issue #381: Initial work for IOBluetooth bindings
Browse files Browse the repository at this point in the history
At this point incomplete and untested: scan of the headers
with ignores for two problematic structs.

Missing are:
- tests
- metadata overrides for input/output parameters
- documentation update, pyobjc/setup.py update
  • Loading branch information
ronaldoussoren committed Jan 11, 2023
1 parent 31bfc60 commit 6d99d4a
Show file tree
Hide file tree
Showing 11 changed files with 30,224 additions and 0 deletions.
30 changes: 30 additions & 0 deletions pyobjc-framework-IOBluetooth/Lib/IOBluetooth/__init__.py
@@ -0,0 +1,30 @@
"""
Python mapping for the IOBluetooth framework.
This module does not contain docstrings for the wrapped code, check Apple's
documentation for details on how to use these functions and classes.
"""

import sys

import Cocoa
import objc
from . import _metadata
from . import _IOBluetooth

sys.modules["IOBluetooth"] = mod = objc.ObjCLazyModule(
"IOBluetooth",
"com.apple.IOBluetooth",
objc.pathForFramework("/System/Library/Frameworks/IOBluetooth.framework"),
_metadata.__dict__,
None,
{
"__doc__": __doc__,
"objc": objc,
"__path__": __path__,
"__loader__": globals().get("__loader__", None),
},
(_IOBluetooth, Cocoa),
)

del sys.modules["IOBluetooth._metadata"]
2,071 changes: 2,071 additions & 0 deletions pyobjc-framework-IOBluetooth/Lib/IOBluetooth/_metadata.py

Large diffs are not rendered by default.

10 changes: 10 additions & 0 deletions pyobjc-framework-IOBluetooth/License.txt
@@ -0,0 +1,10 @@
(This is the MIT license, note that libffi-src is a separate product with its own license)

Copyright 2002, 2003 - Bill Bumgarner, Ronald Oussoren, Steve Majewski, Lele Gaifax, et.al.
Copyright 2003-2022 - Ronald Oussoren

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
14 changes: 14 additions & 0 deletions pyobjc-framework-IOBluetooth/MANIFEST.in
@@ -0,0 +1,14 @@
include *.txt MANIFEST.in *.py
graft Doc
graft Examples
graft Lib
graft Modules
graft source-deps
graft PyObjCTest
graft metadata
global-exclude .DS_Store
global-exclude *.pyc
global-exclude *.pyo
global-exclude *.so
prune Lib/*/*.dSYM
prune PyObjCTest/*.dSYM
1 change: 1 addition & 0 deletions pyobjc-framework-IOBluetooth/PyObjCTest/__init__.py
@@ -0,0 +1 @@
""" Test suite """

0 comments on commit 6d99d4a

Please sign in to comment.