pyobjc-framework-BackgroundAssets 12.2.2__tar.gz → 13.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/Lib/BackgroundAssets/_metadata.py +126 -7
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/Lib/pyobjc_framework_BackgroundAssets.egg-info/PKG-INFO +5 -5
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/Lib/pyobjc_framework_BackgroundAssets.egg-info/SOURCES.txt +3 -2
- pyobjc_framework_backgroundassets-13.0/Lib/pyobjc_framework_BackgroundAssets.egg-info/pyobjc-build-info.txt +3 -0
- pyobjc_framework_backgroundassets-13.0/Lib/pyobjc_framework_BackgroundAssets.egg-info/requires.txt +2 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/Modules/_BackgroundAssets.m +10 -2
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/Modules/_BackgroundAssets_protocols.m +6 -6
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/Modules/pyobjc-api.h +18 -4
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/Modules/pyobjc-compat.h +0 -18
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PKG-INFO +5 -5
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/test_baassetpackmanager.py +63 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/test_baassetpackstatus.py +1 -1
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/test_badownload.py +4 -2
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/test_badownloaderextension.py +2 -2
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/test_badownloadmanager.py +1 -1
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/test_baerror.py +1 -2
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/test_bamanagedassetpackdownloaddelegate.py +3 -1
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/test_bamanageddownloaderextension.py +1 -1
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/test_bamanagederror.py +8 -1
- pyobjc_framework_backgroundassets-13.0/PyObjCTest/test_batypes.py +11 -0
- pyobjc_framework_backgroundassets-13.0/metadata/BackgroundAssets.fwinfo +23 -0
- pyobjc_framework_backgroundassets-12.2.2/metadata/raw/arm64-26.5.fwinfo → pyobjc_framework_backgroundassets-13.0/metadata/raw/arm64-27.fwinfo +669 -60
- pyobjc_framework_backgroundassets-12.2.2/metadata/raw/x86_64-26.5.fwinfo → pyobjc_framework_backgroundassets-13.0/metadata/raw/x86_64-27.fwinfo +669 -60
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/pyobjc_setup.py +7 -7
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/setup.py +1 -1
- pyobjc_framework_backgroundassets-12.2.2/Lib/pyobjc_framework_BackgroundAssets.egg-info/pyobjc-build-info.txt +0 -3
- pyobjc_framework_backgroundassets-12.2.2/Lib/pyobjc_framework_BackgroundAssets.egg-info/requires.txt +0 -2
- pyobjc_framework_backgroundassets-12.2.2/metadata/BackgroundAssets.fwinfo +0 -49
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/Lib/BackgroundAssets/__init__.py +0 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/Lib/pyobjc_framework_BackgroundAssets.egg-info/dependency_links.txt +0 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/Lib/pyobjc_framework_BackgroundAssets.egg-info/not-zip-safe +0 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/Lib/pyobjc_framework_BackgroundAssets.egg-info/top_level.txt +0 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/License.txt +0 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/MANIFEST.in +0 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/__init__.py +0 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/test_baassetpackmanifest.py +0 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/test_backgroundassets.py +0 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PyObjCTest/test_baurldownload.py +0 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/metadata/metadata.ini +0 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/pyproject.toml +0 -0
- {pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/setup.cfg +0 -0
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
# This file is generated by objective.metadata
|
|
2
2
|
#
|
|
3
|
-
# Last update: Sun May 24 11:42:56 2026
|
|
4
|
-
#
|
|
5
3
|
# flake8: noqa
|
|
6
4
|
|
|
7
5
|
import objc, sys
|
|
@@ -30,15 +28,16 @@ else:
|
|
|
30
28
|
|
|
31
29
|
|
|
32
30
|
misc = {}
|
|
33
|
-
constants = """$BAAssetPackIdentifierErrorKey$BADownloaderPriorityDefault@q$BADownloaderPriorityMax@q$BADownloaderPriorityMin@q$BAErrorDomain$BAManagedErrorDomain$"""
|
|
34
|
-
enums = """$BAAssetPackStatusDownloadAvailable@1$BAAssetPackStatusDownloaded@64$BAAssetPackStatusDownloading@32$BAAssetPackStatusObsolete@16$BAAssetPackStatusOutOfDate@8$BAAssetPackStatusUpToDate@4$BAAssetPackStatusUpdateAvailable@2$BAContentRequestInstall@1$BAContentRequestPeriodic@3$BAContentRequestUpdate@2$BADownloadStateCreated@0$BADownloadStateDownloading@2$BADownloadStateFailed@-1$BADownloadStateFinished@3$BADownloadStateWaiting@1$BAErrorCodeCallFromExtensionNotAllowed@50$BAErrorCodeCallFromInactiveProcessNotAllowed@51$BAErrorCodeCallerConnectionInvalid@56$BAErrorCodeCallerConnectionNotAccepted@55$BAErrorCodeDownloadAlreadyFailed@103$BAErrorCodeDownloadAlreadyScheduled@100$BAErrorCodeDownloadBackgroundActivityProhibited@111$BAErrorCodeDownloadDoesNotExist@113$BAErrorCodeDownloadEssentialDownloadNotPermitted@109$BAErrorCodeDownloadFailedToStart@102$BAErrorCodeDownloadInvalid@0$BAErrorCodeDownloadNotScheduled@101$BAErrorCodeDownloadWouldExceedAllowance@112$BAErrorCodeSessionDownloadAllowanceExceeded@204$BAErrorCodeSessionDownloadDisallowedByAllowance@203$BAErrorCodeSessionDownloadDisallowedByDomain@202$BAErrorCodeSessionDownloadNotPermittedBeforeAppLaunch@206$BAManagedErrorCodeAssetPackNotFound@0$BAManagedErrorCodeFileNotFound@1$"""
|
|
31
|
+
constants = """$BAAssetPackIdentifierErrorKey$BADownloaderPriorityDefault@q$BADownloaderPriorityMax@q$BADownloaderPriorityMin@q$BAErrorDomain$BAFailuresErrorKey$BAManagedErrorDomain$BASuccessesErrorKey$"""
|
|
32
|
+
enums = """$BAAssetPackStatusDownloadAvailable@1$BAAssetPackStatusDownloaded@64$BAAssetPackStatusDownloading@32$BAAssetPackStatusObsolete@16$BAAssetPackStatusOutOfDate@8$BAAssetPackStatusUpToDate@4$BAAssetPackStatusUpdateAvailable@2$BAContentRequestInstall@1$BAContentRequestLanguageChange@4$BAContentRequestPeriodic@3$BAContentRequestUpdate@2$BADownloadStateCreated@0$BADownloadStateDownloading@2$BADownloadStateFailed@-1$BADownloadStateFinished@3$BADownloadStateWaiting@1$BAErrorCodeCallFromExtensionNotAllowed@50$BAErrorCodeCallFromInactiveProcessNotAllowed@51$BAErrorCodeCallerConnectionInvalid@56$BAErrorCodeCallerConnectionNotAccepted@55$BAErrorCodeDownloadAlreadyFailed@103$BAErrorCodeDownloadAlreadyScheduled@100$BAErrorCodeDownloadBackgroundActivityProhibited@111$BAErrorCodeDownloadDoesNotExist@113$BAErrorCodeDownloadEssentialDownloadNotPermitted@109$BAErrorCodeDownloadFailedToStart@102$BAErrorCodeDownloadInvalid@0$BAErrorCodeDownloadNotScheduled@101$BAErrorCodeDownloadWouldExceedAllowance@112$BAErrorCodeSessionDownloadAllowanceExceeded@204$BAErrorCodeSessionDownloadDisallowedByAllowance@203$BAErrorCodeSessionDownloadDisallowedByDomain@202$BAErrorCodeSessionDownloadNotPermittedBeforeAppLaunch@206$BAManagedErrorCodeAssetPackNotFound@0$BAManagedErrorCodeFileNotFound@1$BAManagedErrorCodeLocalAvailabilityFailure@2$BASizeCalculationMethodAllocated@1$BASizeCalculationMethodLogical@0$"""
|
|
35
33
|
misc.update(
|
|
36
34
|
{
|
|
37
|
-
"
|
|
38
|
-
"BAErrorCode": NewType("BAErrorCode", int),
|
|
35
|
+
"BADownloadState": NewType("BADownloadState", int),
|
|
39
36
|
"BAManagedErrorCode": NewType("BAManagedErrorCode", int),
|
|
37
|
+
"BAErrorCode": NewType("BAErrorCode", int),
|
|
40
38
|
"BAContentRequest": NewType("BAContentRequest", int),
|
|
41
|
-
"
|
|
39
|
+
"BAAssetPackStatus": NewType("BAAssetPackStatus", int),
|
|
40
|
+
"BASizeCalculationMethod": NewType("BASizeCalculationMethod", int),
|
|
42
41
|
}
|
|
43
42
|
)
|
|
44
43
|
misc.update(
|
|
@@ -51,6 +50,11 @@ misc.update({})
|
|
|
51
50
|
r = objc.registerMetaDataForSelector
|
|
52
51
|
objc._updatingMetadata(True)
|
|
53
52
|
try:
|
|
53
|
+
r(
|
|
54
|
+
b"BAAssetPackManager",
|
|
55
|
+
b"URLForPath:asLocalizedForLanguage:error:",
|
|
56
|
+
{"arguments": {4: {"type_modifier": b"o"}}},
|
|
57
|
+
)
|
|
54
58
|
r(
|
|
55
59
|
b"BAAssetPackManager",
|
|
56
60
|
b"URLForPath:error:",
|
|
@@ -80,6 +84,11 @@ try:
|
|
|
80
84
|
}
|
|
81
85
|
},
|
|
82
86
|
)
|
|
87
|
+
r(
|
|
88
|
+
b"BAAssetPackManager",
|
|
89
|
+
b"contentsAtPath:asLocalizedForLanguage:options:error:",
|
|
90
|
+
{"arguments": {5: {"type_modifier": b"o"}}},
|
|
91
|
+
)
|
|
83
92
|
r(
|
|
84
93
|
b"BAAssetPackManager",
|
|
85
94
|
b"contentsAtPath:searchingInAssetPackWithIdentifier:options:error:",
|
|
@@ -114,6 +123,40 @@ try:
|
|
|
114
123
|
}
|
|
115
124
|
},
|
|
116
125
|
)
|
|
126
|
+
r(
|
|
127
|
+
b"BAAssetPackManager",
|
|
128
|
+
b"ensureLocalAvailabilityOfAssetPacks:completionHandler:",
|
|
129
|
+
{
|
|
130
|
+
"arguments": {
|
|
131
|
+
3: {
|
|
132
|
+
"callable": {
|
|
133
|
+
"retval": {"type": b"v"},
|
|
134
|
+
"arguments": {0: {"type": b"^v"}, 1: {"type": b"@"}},
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
},
|
|
139
|
+
)
|
|
140
|
+
r(
|
|
141
|
+
b"BAAssetPackManager",
|
|
142
|
+
b"ensureLocalAvailabilityOfAssetPacks:requireLatestVersions:completionHandler:",
|
|
143
|
+
{
|
|
144
|
+
"arguments": {
|
|
145
|
+
3: {"type": b"Z"},
|
|
146
|
+
4: {
|
|
147
|
+
"callable": {
|
|
148
|
+
"retval": {"type": b"v"},
|
|
149
|
+
"arguments": {0: {"type": b"^v"}, 1: {"type": b"@"}},
|
|
150
|
+
}
|
|
151
|
+
},
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
)
|
|
155
|
+
r(
|
|
156
|
+
b"BAAssetPackManager",
|
|
157
|
+
b"fileDescriptorForPath:asLocalizedForLanguage:error:",
|
|
158
|
+
{"arguments": {4: {"type_modifier": b"o"}}},
|
|
159
|
+
)
|
|
117
160
|
r(
|
|
118
161
|
b"BAAssetPackManager",
|
|
119
162
|
b"fileDescriptorForPath:searchingInAssetPackWithIdentifier:error:",
|
|
@@ -155,6 +198,24 @@ try:
|
|
|
155
198
|
}
|
|
156
199
|
},
|
|
157
200
|
)
|
|
201
|
+
r(
|
|
202
|
+
b"BAAssetPackManager",
|
|
203
|
+
b"getLocalSizeOfAssetPackWithIdentifier:calculationMethod:completionHandler:",
|
|
204
|
+
{
|
|
205
|
+
"arguments": {
|
|
206
|
+
4: {
|
|
207
|
+
"callable": {
|
|
208
|
+
"retval": {"type": b"v"},
|
|
209
|
+
"arguments": {
|
|
210
|
+
0: {"type": b"^v"},
|
|
211
|
+
1: {"type": b"q"},
|
|
212
|
+
2: {"type": b"@"},
|
|
213
|
+
},
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
},
|
|
218
|
+
)
|
|
158
219
|
r(
|
|
159
220
|
b"BAAssetPackManager",
|
|
160
221
|
b"getLocalStatusOfAssetPackWithIdentifier:completionHandler:",
|
|
@@ -169,6 +230,38 @@ try:
|
|
|
169
230
|
}
|
|
170
231
|
},
|
|
171
232
|
)
|
|
233
|
+
r(
|
|
234
|
+
b"BAAssetPackManager",
|
|
235
|
+
b"getLocallyAvailableLanguagesWithCompletionHandler:",
|
|
236
|
+
{
|
|
237
|
+
"arguments": {
|
|
238
|
+
2: {
|
|
239
|
+
"callable": {
|
|
240
|
+
"retval": {"type": b"v"},
|
|
241
|
+
"arguments": {0: {"type": b"^v"}, 1: {"type": b"@"}},
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
},
|
|
246
|
+
)
|
|
247
|
+
r(
|
|
248
|
+
b"BAAssetPackManager",
|
|
249
|
+
b"getManifestWithCompletionHandler:",
|
|
250
|
+
{
|
|
251
|
+
"arguments": {
|
|
252
|
+
2: {
|
|
253
|
+
"callable": {
|
|
254
|
+
"retval": {"type": b"v"},
|
|
255
|
+
"arguments": {
|
|
256
|
+
0: {"type": b"^v"},
|
|
257
|
+
1: {"type": b"@"},
|
|
258
|
+
2: {"type": b"@"},
|
|
259
|
+
},
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
},
|
|
264
|
+
)
|
|
172
265
|
r(
|
|
173
266
|
b"BAAssetPackManager",
|
|
174
267
|
b"getStatusOfAssetPackWithIdentifier:completionHandler:",
|
|
@@ -205,6 +298,25 @@ try:
|
|
|
205
298
|
}
|
|
206
299
|
},
|
|
207
300
|
)
|
|
301
|
+
r(
|
|
302
|
+
b"BAAssetPackManager",
|
|
303
|
+
b"localVersionOfAssetPackWithIdentifier:error:",
|
|
304
|
+
{"arguments": {3: {"type_modifier": b"o"}}},
|
|
305
|
+
)
|
|
306
|
+
r(
|
|
307
|
+
b"BAAssetPackManager",
|
|
308
|
+
b"reconcilePreferredLanguagesWithCompletionHandler:",
|
|
309
|
+
{
|
|
310
|
+
"arguments": {
|
|
311
|
+
2: {
|
|
312
|
+
"callable": {
|
|
313
|
+
"retval": {"type": b"v"},
|
|
314
|
+
"arguments": {0: {"type": b"^v"}, 1: {"type": b"@"}},
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
}
|
|
318
|
+
},
|
|
319
|
+
)
|
|
208
320
|
r(
|
|
209
321
|
b"BAAssetPackManager",
|
|
210
322
|
b"removeAssetPackWithIdentifier:completionHandler:",
|
|
@@ -229,6 +341,7 @@ try:
|
|
|
229
341
|
b"initWithContentsOfURL:applicationGroupIdentifier:error:",
|
|
230
342
|
{"arguments": {4: {"type_modifier": b"o"}}},
|
|
231
343
|
)
|
|
344
|
+
r(b"BADownload", b"copyAsNonEssential", {"retval": {"already_retained": True}})
|
|
232
345
|
r(b"BADownload", b"isEssential", {"retval": {"type": b"Z"}})
|
|
233
346
|
r(
|
|
234
347
|
b"BADownloadManager",
|
|
@@ -502,5 +615,11 @@ objc.registerNewKeywordsFromSelector(
|
|
|
502
615
|
"BAURLDownload", b"initWithIdentifier:request:fileSize:applicationGroupIdentifier:"
|
|
503
616
|
)
|
|
504
617
|
expressions = {}
|
|
618
|
+
formal_protocols = {
|
|
619
|
+
"BADownloadManagerDelegate": "BADownloadManagerDelegate",
|
|
620
|
+
"BADownloaderExtension": "BADownloaderExtension",
|
|
621
|
+
"BAManagedAssetPackDownloadDelegate": "BAManagedAssetPackDownloadDelegate",
|
|
622
|
+
"BAManagedDownloaderExtension": "BAManagedDownloaderExtension",
|
|
623
|
+
}
|
|
505
624
|
|
|
506
625
|
# END OF FILE
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pyobjc-framework-BackgroundAssets
|
|
3
|
-
Version:
|
|
3
|
+
Version: 13.0
|
|
4
4
|
Summary: Wrappers for the framework BackgroundAssets on macOS
|
|
5
5
|
Home-page: https://github.com/ronaldoussoren/pyobjc
|
|
6
6
|
Author: Ronald Oussoren
|
|
@@ -17,21 +17,21 @@ Classifier: Operating System :: MacOS :: MacOS X
|
|
|
17
17
|
Classifier: Programming Language :: Python
|
|
18
18
|
Classifier: Programming Language :: Python :: 3
|
|
19
19
|
Classifier: Programming Language :: Python :: 3 :: Only
|
|
20
|
-
Classifier: Programming Language :: Python :: 3.10
|
|
21
20
|
Classifier: Programming Language :: Python :: 3.11
|
|
22
21
|
Classifier: Programming Language :: Python :: 3.12
|
|
23
22
|
Classifier: Programming Language :: Python :: 3.13
|
|
24
23
|
Classifier: Programming Language :: Python :: 3.14
|
|
25
24
|
Classifier: Programming Language :: Python :: 3.15
|
|
25
|
+
Classifier: Programming Language :: Python :: 3.16
|
|
26
26
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
27
27
|
Classifier: Programming Language :: Python :: Free Threading :: 3 - Stable
|
|
28
28
|
Classifier: Programming Language :: Objective C
|
|
29
29
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
30
30
|
Classifier: Topic :: Software Development :: User Interfaces
|
|
31
|
-
Requires-Python: >=3.
|
|
31
|
+
Requires-Python: >=3.11
|
|
32
32
|
Description-Content-Type: text/x-rst; charset=UTF-8
|
|
33
|
-
Requires-Dist: pyobjc-core>=
|
|
34
|
-
Requires-Dist: pyobjc-framework-Cocoa>=
|
|
33
|
+
Requires-Dist: pyobjc-core>=13.0
|
|
34
|
+
Requires-Dist: pyobjc-framework-Cocoa>=13.0
|
|
35
35
|
Dynamic: author
|
|
36
36
|
Dynamic: author-email
|
|
37
37
|
Dynamic: classifier
|
|
@@ -28,8 +28,9 @@ PyObjCTest/test_baerror.py
|
|
|
28
28
|
PyObjCTest/test_bamanagedassetpackdownloaddelegate.py
|
|
29
29
|
PyObjCTest/test_bamanageddownloaderextension.py
|
|
30
30
|
PyObjCTest/test_bamanagederror.py
|
|
31
|
+
PyObjCTest/test_batypes.py
|
|
31
32
|
PyObjCTest/test_baurldownload.py
|
|
32
33
|
metadata/BackgroundAssets.fwinfo
|
|
33
34
|
metadata/metadata.ini
|
|
34
|
-
metadata/raw/arm64-
|
|
35
|
-
metadata/raw/x86_64-
|
|
35
|
+
metadata/raw/arm64-27.fwinfo
|
|
36
|
+
metadata/raw/x86_64-27.fwinfo
|
|
@@ -2,6 +2,10 @@
|
|
|
2
2
|
#include "Python.h"
|
|
3
3
|
#include "pyobjc-api.h"
|
|
4
4
|
|
|
5
|
+
#ifdef USE_STATIC_ANALYZER
|
|
6
|
+
#include "../../pyobjc-core/Modules/objc/python-api-used.h"
|
|
7
|
+
#endif
|
|
8
|
+
|
|
5
9
|
#import <BackgroundAssets/BackgroundAssets.h>
|
|
6
10
|
#import <Foundation/Foundation.h>
|
|
7
11
|
|
|
@@ -10,6 +14,8 @@
|
|
|
10
14
|
*/
|
|
11
15
|
#include "_BackgroundAssets_protocols.m"
|
|
12
16
|
|
|
17
|
+
NS_ASSUME_NONNULL_BEGIN
|
|
18
|
+
|
|
13
19
|
static PyMethodDef mod_methods[] = {
|
|
14
20
|
{0, 0, 0, 0} /* sentinel */
|
|
15
21
|
};
|
|
@@ -55,10 +61,12 @@ static struct PyModuleDef mod_module = {
|
|
|
55
61
|
.m_free = NULL,
|
|
56
62
|
};
|
|
57
63
|
|
|
58
|
-
PyObject* PyInit__BackgroundAssets(void);
|
|
64
|
+
PyObject* _Nullable PyInit__BackgroundAssets(void);
|
|
59
65
|
|
|
60
|
-
PyObject* __attribute__((__visibility__("default")))
|
|
66
|
+
PyObject* _Nullable __attribute__((__visibility__("default")))
|
|
61
67
|
PyInit__BackgroundAssets(void)
|
|
62
68
|
{
|
|
63
69
|
return PyModuleDef_Init(&mod_module);
|
|
64
70
|
}
|
|
71
|
+
|
|
72
|
+
NS_ASSUME_NONNULL_END
|
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
*/
|
|
6
|
-
|
|
1
|
+
// LCOV_EXCL_START
|
|
2
|
+
// This function is only present to ensure protocols are
|
|
3
|
+
// available at runtime.
|
|
4
|
+
NS_ASSUME_NONNULL_BEGIN
|
|
7
5
|
static void __attribute__((__used__))
|
|
8
6
|
use_protocols(void)
|
|
9
7
|
{
|
|
@@ -19,3 +17,5 @@ use_protocols(void)
|
|
|
19
17
|
Py_XDECREF(p);
|
|
20
18
|
#endif
|
|
21
19
|
}
|
|
20
|
+
NS_ASSUME_NONNULL_END
|
|
21
|
+
// LCOV_EXCL_STOP
|
|
@@ -60,6 +60,11 @@ typedef int(RegisterMethodMappingFunctionType)(
|
|
|
60
60
|
PyObject* _Nonnull const* _Nonnull, size_t),
|
|
61
61
|
IMP _Nullable (*_Nonnull)(PyObject* _Nonnull, PyObject* _Nonnull));
|
|
62
62
|
|
|
63
|
+
#ifndef PyObjC_FUNCTION_CALL_H
|
|
64
|
+
typedef PyObject* _Nullable (*PyObjC_FunctionCallFunc)(
|
|
65
|
+
PyObject* meth, PyObject* _Nonnull const* _Nonnull args, size_t nargs);
|
|
66
|
+
#endif
|
|
67
|
+
|
|
63
68
|
struct pyobjc_api {
|
|
64
69
|
int api_version; /* API version */
|
|
65
70
|
size_t struct_len; /* Length of this struct */
|
|
@@ -117,6 +122,9 @@ struct pyobjc_api {
|
|
|
117
122
|
|
|
118
123
|
PyObject* _Nullable (*_Nonnull createopaquepointertype)(const char*, const char*,
|
|
119
124
|
const char*);
|
|
125
|
+
int (*_Nonnull register_functioncaller)(void*, PyObjC_FunctionCallFunc);
|
|
126
|
+
PyObject* _Nullable (*_Nonnull create_registered_struct)(
|
|
127
|
+
const char*, Py_ssize_t, const char* _Nonnull* _Nullable, Py_ssize_t*);
|
|
120
128
|
};
|
|
121
129
|
|
|
122
130
|
#ifndef PYOBJC_BUILD
|
|
@@ -159,6 +167,8 @@ static struct pyobjc_api* PyObjC_API;
|
|
|
159
167
|
#define PyObjC_CheckArgCount (PyObjC_API->checkargcount)
|
|
160
168
|
#define PyObjC_CheckNoKwnames (PyObjC_API->checknokwnames)
|
|
161
169
|
#define PyObjCCreateOpaquePointerType (PyObjC_API->createopaquepointertype)
|
|
170
|
+
#define PyObjCRegister_FunctionCaller (PyObjC_API->register_functioncaller)
|
|
171
|
+
#define PyObjC_CreateRegisteredStruct (PyObjC_API->create_registered_struct)
|
|
162
172
|
|
|
163
173
|
typedef void (*PyObjC_Function_Pointer)(void);
|
|
164
174
|
typedef struct PyObjC_function_map {
|
|
@@ -178,21 +188,25 @@ static inline int
|
|
|
178
188
|
PyObjC_ImportAPI(PyObject* calling_module)
|
|
179
189
|
{
|
|
180
190
|
PyObjC_API = (struct pyobjc_api*)PyCapsule_Import("objc." PYOBJC_API_NAME, 0);
|
|
181
|
-
if (PyObjC_API == NULL) {
|
|
182
|
-
return -1;
|
|
191
|
+
if (PyObjC_API == NULL) { // LCOV_BR_EXCL_LINE
|
|
192
|
+
return -1; // LCOV_EXCL_LINE
|
|
183
193
|
}
|
|
184
|
-
if (PyObjC_API->api_version != PYOBJC_API_VERSION) {
|
|
194
|
+
if (PyObjC_API->api_version != PYOBJC_API_VERSION) { // LCOV_BR_EXCL_LINE
|
|
195
|
+
// LCOV_EXCL_START
|
|
185
196
|
PyErr_Format(PyExc_RuntimeError,
|
|
186
197
|
"Wrong version of PyObjC C API (got %d, expected %d)",
|
|
187
198
|
(int)PyObjC_API->api_version, (int)PYOBJC_API_VERSION);
|
|
188
199
|
return -1;
|
|
200
|
+
// LCOV_EXCL_STOP
|
|
189
201
|
}
|
|
190
202
|
|
|
191
|
-
if (PyObjC_API->struct_len < PyObjC_EXPECTED_STRUCT_SIZE) {
|
|
203
|
+
if (PyObjC_API->struct_len < PyObjC_EXPECTED_STRUCT_SIZE) { // LCOV_EXCL_LINE
|
|
204
|
+
// LCOV_EXCL_START
|
|
192
205
|
PyErr_Format(PyExc_RuntimeError,
|
|
193
206
|
"Wrong struct-size of PyObjC C API (got %d, expected %d)",
|
|
194
207
|
(int)PyObjC_API->struct_len, (int)sizeof(struct pyobjc_api));
|
|
195
208
|
return -1;
|
|
209
|
+
// LCOV_EXCL_STOP
|
|
196
210
|
}
|
|
197
211
|
|
|
198
212
|
/* Current pyobjc implementation doesn't allow deregistering
|
|
@@ -167,24 +167,6 @@ _PyObjCTuple_GetItem(PyObject* tuple, Py_ssize_t idx)
|
|
|
167
167
|
PyGILState_Release(_GILState); \
|
|
168
168
|
} while (0)
|
|
169
169
|
|
|
170
|
-
#if PY_VERSION_HEX < 0x030a0000
|
|
171
|
-
|
|
172
|
-
static inline PyObject*
|
|
173
|
-
Py_NewRef(PyObject* o)
|
|
174
|
-
{
|
|
175
|
-
Py_INCREF(o);
|
|
176
|
-
return o;
|
|
177
|
-
}
|
|
178
|
-
|
|
179
|
-
static inline PyObject*
|
|
180
|
-
Py_XNewRef(PyObject* o)
|
|
181
|
-
{
|
|
182
|
-
Py_XINCREF(o);
|
|
183
|
-
return o;
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
#endif /* PY_VERSION_HEX < 0x030a0000 */
|
|
187
|
-
|
|
188
170
|
#if PY_VERSION_HEX < 0x030d0000
|
|
189
171
|
#define Py_BEGIN_CRITICAL_SECTION(value) \
|
|
190
172
|
{ \
|
{pyobjc_framework_backgroundassets-12.2.2 → pyobjc_framework_backgroundassets-13.0}/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pyobjc-framework-BackgroundAssets
|
|
3
|
-
Version:
|
|
3
|
+
Version: 13.0
|
|
4
4
|
Summary: Wrappers for the framework BackgroundAssets on macOS
|
|
5
5
|
Home-page: https://github.com/ronaldoussoren/pyobjc
|
|
6
6
|
Author: Ronald Oussoren
|
|
@@ -17,21 +17,21 @@ Classifier: Operating System :: MacOS :: MacOS X
|
|
|
17
17
|
Classifier: Programming Language :: Python
|
|
18
18
|
Classifier: Programming Language :: Python :: 3
|
|
19
19
|
Classifier: Programming Language :: Python :: 3 :: Only
|
|
20
|
-
Classifier: Programming Language :: Python :: 3.10
|
|
21
20
|
Classifier: Programming Language :: Python :: 3.11
|
|
22
21
|
Classifier: Programming Language :: Python :: 3.12
|
|
23
22
|
Classifier: Programming Language :: Python :: 3.13
|
|
24
23
|
Classifier: Programming Language :: Python :: 3.14
|
|
25
24
|
Classifier: Programming Language :: Python :: 3.15
|
|
25
|
+
Classifier: Programming Language :: Python :: 3.16
|
|
26
26
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
27
27
|
Classifier: Programming Language :: Python :: Free Threading :: 3 - Stable
|
|
28
28
|
Classifier: Programming Language :: Objective C
|
|
29
29
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
30
30
|
Classifier: Topic :: Software Development :: User Interfaces
|
|
31
|
-
Requires-Python: >=3.
|
|
31
|
+
Requires-Python: >=3.11
|
|
32
32
|
Description-Content-Type: text/x-rst; charset=UTF-8
|
|
33
|
-
Requires-Dist: pyobjc-core>=
|
|
34
|
-
Requires-Dist: pyobjc-framework-Cocoa>=
|
|
33
|
+
Requires-Dist: pyobjc-core>=13.0
|
|
34
|
+
Requires-Dist: pyobjc-framework-Cocoa>=13.0
|
|
35
35
|
Dynamic: author
|
|
36
36
|
Dynamic: author-email
|
|
37
37
|
Dynamic: classifier
|
|
@@ -65,3 +65,66 @@ class TestBAAssetPackManager(TestCase):
|
|
|
65
65
|
2,
|
|
66
66
|
b"v@",
|
|
67
67
|
)
|
|
68
|
+
|
|
69
|
+
@min_os_level("27.0")
|
|
70
|
+
def test_methods27_0(self):
|
|
71
|
+
self.assertArgIsBlock(
|
|
72
|
+
BackgroundAssets.BAAssetPackManager.getManifestWithCompletionHandler_,
|
|
73
|
+
0,
|
|
74
|
+
b"v@@",
|
|
75
|
+
)
|
|
76
|
+
self.assertArgIsBlock(
|
|
77
|
+
BackgroundAssets.BAAssetPackManager.getLocallyAvailableLanguagesWithCompletionHandler_,
|
|
78
|
+
0,
|
|
79
|
+
b"v@",
|
|
80
|
+
)
|
|
81
|
+
self.assertArgIsBlock(
|
|
82
|
+
BackgroundAssets.BAAssetPackManager.reconcilePreferredLanguagesWithCompletionHandler_,
|
|
83
|
+
0,
|
|
84
|
+
b"v@",
|
|
85
|
+
)
|
|
86
|
+
self.assertArgIsBlock(
|
|
87
|
+
BackgroundAssets.BAAssetPackManager.ensureLocalAvailabilityOfAssetPacks_completionHandler_,
|
|
88
|
+
1,
|
|
89
|
+
b"v@",
|
|
90
|
+
)
|
|
91
|
+
|
|
92
|
+
self.assertArgIsBOOL(
|
|
93
|
+
BackgroundAssets.BAAssetPackManager.ensureLocalAvailabilityOfAssetPacks_requireLatestVersions_completionHandler_,
|
|
94
|
+
1,
|
|
95
|
+
)
|
|
96
|
+
self.assertArgIsBlock(
|
|
97
|
+
BackgroundAssets.BAAssetPackManager.ensureLocalAvailabilityOfAssetPacks_requireLatestVersions_completionHandler_,
|
|
98
|
+
2,
|
|
99
|
+
b"v@",
|
|
100
|
+
)
|
|
101
|
+
|
|
102
|
+
self.assertArgIsOut(
|
|
103
|
+
BackgroundAssets.BAAssetPackManager.contentsAtPath_asLocalizedForLanguage_options_error_,
|
|
104
|
+
3,
|
|
105
|
+
)
|
|
106
|
+
self.assertArgIsOut(
|
|
107
|
+
BackgroundAssets.BAAssetPackManager.fileDescriptorForPath_asLocalizedForLanguage_error_,
|
|
108
|
+
2,
|
|
109
|
+
)
|
|
110
|
+
self.assertArgIsOut(
|
|
111
|
+
BackgroundAssets.BAAssetPackManager.URLForPath_error_,
|
|
112
|
+
1,
|
|
113
|
+
)
|
|
114
|
+
self.assertArgIsOut(
|
|
115
|
+
BackgroundAssets.BAAssetPackManager.URLForPath_asLocalizedForLanguage_error_,
|
|
116
|
+
2,
|
|
117
|
+
)
|
|
118
|
+
|
|
119
|
+
@min_os_level("27.2")
|
|
120
|
+
def test_methods27_2(self):
|
|
121
|
+
self.assertArgIsOut(
|
|
122
|
+
BackgroundAssets.BAAssetPackManager.localVersionOfAssetPackWithIdentifier_error_,
|
|
123
|
+
1,
|
|
124
|
+
)
|
|
125
|
+
|
|
126
|
+
self.assertArgIsBlock(
|
|
127
|
+
BackgroundAssets.BAAssetPackManager.getLocalSizeOfAssetPackWithIdentifier_calculationMethod_completionHandler_,
|
|
128
|
+
2,
|
|
129
|
+
b"vq@",
|
|
130
|
+
)
|
|
@@ -3,7 +3,7 @@ import BackgroundAssets
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
class TestBAAssetPackStatus(TestCase):
|
|
6
|
-
def
|
|
6
|
+
def test_enums(self):
|
|
7
7
|
self.assertIsEnumType(BackgroundAssets.BAAssetPackStatus)
|
|
8
8
|
self.assertEqual(BackgroundAssets.BAAssetPackStatusDownloadAvailable, 1 << 0)
|
|
9
9
|
self.assertEqual(BackgroundAssets.BAAssetPackStatusUpdateAvailable, 1 << 1)
|
|
@@ -3,7 +3,7 @@ import BackgroundAssets
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
class TestBADownload(TestCase):
|
|
6
|
-
def
|
|
6
|
+
def test_enums(self):
|
|
7
7
|
self.assertIsEnumType(BackgroundAssets.BADownloadState)
|
|
8
8
|
self.assertEqual(BackgroundAssets.BADownloadStateFailed, -1)
|
|
9
9
|
self.assertEqual(BackgroundAssets.BADownloadStateCreated, 0)
|
|
@@ -11,9 +11,10 @@ class TestBADownload(TestCase):
|
|
|
11
11
|
self.assertEqual(BackgroundAssets.BADownloadStateDownloading, 2)
|
|
12
12
|
self.assertEqual(BackgroundAssets.BADownloadStateFinished, 3)
|
|
13
13
|
|
|
14
|
+
self.assertIsEnumType(BackgroundAssets.BADownloaderPriority)
|
|
15
|
+
|
|
14
16
|
@min_os_level("13.0")
|
|
15
17
|
def test_constants13_0(self):
|
|
16
|
-
self.assertIsEnumType(BackgroundAssets.BADownloaderPriority)
|
|
17
18
|
self.assertIsInstance(BackgroundAssets.BADownloaderPriorityMin, int)
|
|
18
19
|
self.assertIsInstance(BackgroundAssets.BADownloaderPriorityDefault, int)
|
|
19
20
|
self.assertIsInstance(BackgroundAssets.BADownloaderPriorityMax, int)
|
|
@@ -21,3 +22,4 @@ class TestBADownload(TestCase):
|
|
|
21
22
|
@min_os_level("13.3")
|
|
22
23
|
def test_methods13_3(self):
|
|
23
24
|
self.assertResultIsBOOL(BackgroundAssets.BADownload.isEssential)
|
|
25
|
+
self.assertResultIsRetained(BackgroundAssets.BADownload.copyAsNonEssential)
|
|
@@ -9,14 +9,14 @@ class TestBADownloaderExtensionHelper(BackgroundAssets.NSObject):
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
class TestBADownloaderExtension(TestCase):
|
|
12
|
-
def
|
|
12
|
+
def test_enums(self):
|
|
13
13
|
self.assertIsEnumType(BackgroundAssets.BAContentRequest)
|
|
14
14
|
self.assertEqual(BackgroundAssets.BAContentRequestInstall, 1)
|
|
15
15
|
self.assertEqual(BackgroundAssets.BAContentRequestUpdate, 2)
|
|
16
16
|
self.assertEqual(BackgroundAssets.BAContentRequestPeriodic, 3)
|
|
17
17
|
|
|
18
18
|
def test_protocols(self):
|
|
19
|
-
self.assertProtocolExists("BADownloaderExtension")
|
|
19
|
+
self.assertProtocolExists("BADownloaderExtension", BackgroundAssets)
|
|
20
20
|
|
|
21
21
|
def test_protocol_methods(self):
|
|
22
22
|
self.assertArgIsBlock(
|
|
@@ -15,7 +15,7 @@ class TestBADownloaderHelper(BackgroundAssets.NSObject):
|
|
|
15
15
|
|
|
16
16
|
class TestBADownloadManager(TestCase):
|
|
17
17
|
def test_protocols(self):
|
|
18
|
-
self.assertProtocolExists("BADownloadManagerDelegate")
|
|
18
|
+
self.assertProtocolExists("BADownloadManagerDelegate", BackgroundAssets)
|
|
19
19
|
|
|
20
20
|
def test_protocol_methods(self):
|
|
21
21
|
self.assertArgHasType(
|
|
@@ -3,9 +3,8 @@ import BackgroundAssets
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
class TestBAError(TestCase):
|
|
6
|
-
def
|
|
6
|
+
def test_enums(self):
|
|
7
7
|
self.assertIsEnumType(BackgroundAssets.BAErrorCode)
|
|
8
|
-
|
|
9
8
|
self.assertEqual(BackgroundAssets.BAErrorCodeDownloadInvalid, 0)
|
|
10
9
|
self.assertEqual(BackgroundAssets.BAErrorCodeCallFromExtensionNotAllowed, 50)
|
|
11
10
|
self.assertEqual(
|
|
@@ -5,4 +5,6 @@ import BackgroundAssets # noqa: F401
|
|
|
5
5
|
class TestBAManagedAssetPackDownloadDelegate(TestCase):
|
|
6
6
|
@min_sdk_level("26.0")
|
|
7
7
|
def test_protocols(self):
|
|
8
|
-
self.assertProtocolExists(
|
|
8
|
+
self.assertProtocolExists(
|
|
9
|
+
"BAManagedAssetPackDownloadDelegate", BackgroundAssets
|
|
10
|
+
)
|
|
@@ -10,7 +10,7 @@ class TestBAManagedDownloaderExtensionHelper(BackgroundAssets.NSObject):
|
|
|
10
10
|
class TestBAManagedDownloaderExtension(TestCase):
|
|
11
11
|
@min_sdk_level("26.0")
|
|
12
12
|
def test_protocols(self):
|
|
13
|
-
self.assertProtocolExists("BAManagedDownloaderExtension")
|
|
13
|
+
self.assertProtocolExists("BAManagedDownloaderExtension", BackgroundAssets)
|
|
14
14
|
|
|
15
15
|
def test_protocol_methods(self):
|
|
16
16
|
self.assertResultIsBOOL(
|
|
@@ -3,11 +3,18 @@ import BackgroundAssets
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
class TestBAManagedError(TestCase):
|
|
6
|
-
def
|
|
6
|
+
def test_enums(self):
|
|
7
7
|
self.assertIsEnumType(BackgroundAssets.BAManagedErrorCode)
|
|
8
8
|
self.assertEqual(BackgroundAssets.BAManagedErrorCodeAssetPackNotFound, 0)
|
|
9
9
|
self.assertEqual(BackgroundAssets.BAManagedErrorCodeFileNotFound, 1)
|
|
10
|
+
self.assertEqual(BackgroundAssets.BAManagedErrorCodeLocalAvailabilityFailure, 2)
|
|
10
11
|
|
|
11
12
|
@min_os_level("26.0")
|
|
12
13
|
def test_constants26_0(self):
|
|
13
14
|
self.assertIsInstance(BackgroundAssets.BAManagedErrorDomain, str)
|
|
15
|
+
self.assertIsInstance(BackgroundAssets.BAAssetPackIdentifierErrorKey, str)
|
|
16
|
+
|
|
17
|
+
@min_os_level("27.0")
|
|
18
|
+
def test_constants27_0(self):
|
|
19
|
+
self.assertIsInstance(BackgroundAssets.BASuccessesErrorKey, str)
|
|
20
|
+
self.assertIsInstance(BackgroundAssets.BAFailuresErrorKey, str)
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
from PyObjCTools.TestSupport import TestCase
|
|
2
|
+
import BackgroundAssets
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
class TestBATypes(TestCase):
|
|
6
|
+
def test_enums(self):
|
|
7
|
+
self.assertIsEnumType(BackgroundAssets.BAContentRequest)
|
|
8
|
+
self.assertEqual(BackgroundAssets.BAContentRequestInstall, 1)
|
|
9
|
+
self.assertEqual(BackgroundAssets.BAContentRequestUpdate, 2)
|
|
10
|
+
self.assertEqual(BackgroundAssets.BAContentRequestPeriodic, 3)
|
|
11
|
+
self.assertEqual(BackgroundAssets.BAContentRequestLanguageChange, 4)
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
// objective.metadata exceptions file, see its document
|
|
2
|
+
// for information on how to update this file.
|
|
3
|
+
{
|
|
4
|
+
"definitions": {
|
|
5
|
+
"typed_enum": {
|
|
6
|
+
"BADownloadState": { "type": "q" },
|
|
7
|
+
"BADownloaderPriority": { "type": "q" }
|
|
8
|
+
},
|
|
9
|
+
"classes": {
|
|
10
|
+
"BADownloadManager": {
|
|
11
|
+
"methods": [
|
|
12
|
+
{
|
|
13
|
+
"args": {
|
|
14
|
+
"0": { "type_modifier": "o" }
|
|
15
|
+
},
|
|
16
|
+
"class_method": false,
|
|
17
|
+
"selector": "etchCurrentDownloads:"
|
|
18
|
+
}
|
|
19
|
+
]
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|