From 2bc4cc997fce31bd0bd3f0e124020fed7bac62ee Mon Sep 17 00:00:00 2001 From: Brian Quinlan Date: Wed, 15 Jan 2025 15:11:01 -0800 Subject: [PATCH] Fix incorrect response processing (#1448) --- pkgs/cupertino_http/CHANGELOG.md | 6 +- .../native_cupertino_bindings.m | 868 +- .../lib/src/native_cupertino_bindings.dart | 12825 ++++++++++++---- pkgs/cupertino_http/pubspec.yaml | 4 +- 4 files changed, 10631 insertions(+), 3072 deletions(-) diff --git a/pkgs/cupertino_http/CHANGELOG.md b/pkgs/cupertino_http/CHANGELOG.md index 0878800a33..eab2fcb974 100644 --- a/pkgs/cupertino_http/CHANGELOG.md +++ b/pkgs/cupertino_http/CHANGELOG.md @@ -1,6 +1,10 @@ ## 2.0.2-wip -* Upgrade to `package:objective_c` 4.0. +* Upgrade to `package:objective_c` 4.1. +* Upgrade to `package:ffigen` 16.1. +* Fixes a bug where responses were not processed correctly: + * [#1413](https://github.com/dart-lang/http/issues/1413) + * [#1446](https://github.com/dart-lang/http/issues/1446) ## 2.0.1 diff --git a/pkgs/cupertino_http/darwin/cupertino_http/Sources/cupertino_http/native_cupertino_bindings.m b/pkgs/cupertino_http/darwin/cupertino_http/Sources/cupertino_http/native_cupertino_bindings.m index 3bc6c93307..811037901c 100644 --- a/pkgs/cupertino_http/darwin/cupertino_http/Sources/cupertino_http/native_cupertino_bindings.m +++ b/pkgs/cupertino_http/darwin/cupertino_http/Sources/cupertino_http/native_cupertino_bindings.m @@ -1,4 +1,5 @@ #include +#import #import #import #import @@ -16,10 +17,10 @@ #error "This file must be compiled with ARC enabled" #endif -id objc_retain(id); id objc_retainBlock(id); typedef void (^_ListenerTrampoline)(); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline _NativeCupertinoHttp_wrapListenerBlock_1pl9qdv(_ListenerTrampoline block) NS_RETURNS_RETAINED { return ^void() { objc_retainBlock(block); @@ -27,31 +28,111 @@ _ListenerTrampoline _NativeCupertinoHttp_wrapListenerBlock_1pl9qdv(_ListenerTram }; } +typedef void (^_BlockingTrampoline)(void * waiter); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline _NativeCupertinoHttp_wrapBlockingBlock_1pl9qdv( + _BlockingTrampoline block, _BlockingTrampoline listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void() { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline1)(id arg0); -_ListenerTrampoline1 _NativeCupertinoHttp_wrapListenerBlock_1jdvcbf(_ListenerTrampoline1 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline1 _NativeCupertinoHttp_wrapListenerBlock_xtuoz7(_ListenerTrampoline1 block) NS_RETURNS_RETAINED { return ^void(id arg0) { objc_retainBlock(block); - block(objc_retain(arg0)); + block((__bridge id)(__bridge_retained void*)(arg0)); + }; +} + +typedef void (^_BlockingTrampoline1)(void * waiter, id arg0); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline1 _NativeCupertinoHttp_wrapBlockingBlock_xtuoz7( + _BlockingTrampoline1 block, _BlockingTrampoline1 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(id arg0) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, (__bridge id)(__bridge_retained void*)(arg0)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, (__bridge id)(__bridge_retained void*)(arg0)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline2)(void * arg0, id arg1); -_ListenerTrampoline2 _NativeCupertinoHttp_wrapListenerBlock_wjovn7(_ListenerTrampoline2 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline2 _NativeCupertinoHttp_wrapListenerBlock_18v1jvf(_ListenerTrampoline2 block) NS_RETURNS_RETAINED { return ^void(void * arg0, id arg1) { objc_retainBlock(block); - block(arg0, objc_retain(arg1)); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1)); + }; +} + +typedef void (^_BlockingTrampoline2)(void * waiter, void * arg0, id arg1); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline2 _NativeCupertinoHttp_wrapBlockingBlock_18v1jvf( + _BlockingTrampoline2 block, _BlockingTrampoline2 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(void * arg0, id arg1) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline3)(id arg0, id arg1, BOOL * arg2); -_ListenerTrampoline3 _NativeCupertinoHttp_wrapListenerBlock_1krhfwz(_ListenerTrampoline3 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline3 _NativeCupertinoHttp_wrapListenerBlock_1o83rbn(_ListenerTrampoline3 block) NS_RETURNS_RETAINED { return ^void(id arg0, id arg1, BOOL * arg2) { objc_retainBlock(block); - block(objc_retain(arg0), objc_retain(arg1), arg2); + block((__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1), arg2); + }; +} + +typedef void (^_BlockingTrampoline3)(void * waiter, id arg0, id arg1, BOOL * arg2); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline3 _NativeCupertinoHttp_wrapBlockingBlock_1o83rbn( + _BlockingTrampoline3 block, _BlockingTrampoline3 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(id arg0, id arg1, BOOL * arg2) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, (__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1), arg2); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, (__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1), arg2); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline4)(struct __CFRunLoopObserver * arg0, CFRunLoopActivity arg1); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline4 _NativeCupertinoHttp_wrapListenerBlock_tg5tbv(_ListenerTrampoline4 block) NS_RETURNS_RETAINED { return ^void(struct __CFRunLoopObserver * arg0, CFRunLoopActivity arg1) { objc_retainBlock(block); @@ -59,7 +140,27 @@ _ListenerTrampoline4 _NativeCupertinoHttp_wrapListenerBlock_tg5tbv(_ListenerTram }; } +typedef void (^_BlockingTrampoline4)(void * waiter, struct __CFRunLoopObserver * arg0, CFRunLoopActivity arg1); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline4 _NativeCupertinoHttp_wrapBlockingBlock_tg5tbv( + _BlockingTrampoline4 block, _BlockingTrampoline4 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(struct __CFRunLoopObserver * arg0, CFRunLoopActivity arg1) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, arg1); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, arg1); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline5)(struct __CFRunLoopTimer * arg0); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline5 _NativeCupertinoHttp_wrapListenerBlock_1dqvvol(_ListenerTrampoline5 block) NS_RETURNS_RETAINED { return ^void(struct __CFRunLoopTimer * arg0) { objc_retainBlock(block); @@ -67,7 +168,27 @@ _ListenerTrampoline5 _NativeCupertinoHttp_wrapListenerBlock_1dqvvol(_ListenerTra }; } +typedef void (^_BlockingTrampoline5)(void * waiter, struct __CFRunLoopTimer * arg0); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline5 _NativeCupertinoHttp_wrapBlockingBlock_1dqvvol( + _BlockingTrampoline5 block, _BlockingTrampoline5 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(struct __CFRunLoopTimer * arg0) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline6)(size_t arg0); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline6 _NativeCupertinoHttp_wrapListenerBlock_6enxqz(_ListenerTrampoline6 block) NS_RETURNS_RETAINED { return ^void(size_t arg0) { objc_retainBlock(block); @@ -75,15 +196,55 @@ _ListenerTrampoline6 _NativeCupertinoHttp_wrapListenerBlock_6enxqz(_ListenerTram }; } +typedef void (^_BlockingTrampoline6)(void * waiter, size_t arg0); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline6 _NativeCupertinoHttp_wrapBlockingBlock_6enxqz( + _BlockingTrampoline6 block, _BlockingTrampoline6 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(size_t arg0) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline7)(id arg0, int arg1); -_ListenerTrampoline7 _NativeCupertinoHttp_wrapListenerBlock_qxvyq2(_ListenerTrampoline7 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline7 _NativeCupertinoHttp_wrapListenerBlock_18kzm6a(_ListenerTrampoline7 block) NS_RETURNS_RETAINED { return ^void(id arg0, int arg1) { objc_retainBlock(block); - block(objc_retain(arg0), arg1); + block((__bridge id)(__bridge_retained void*)(arg0), arg1); + }; +} + +typedef void (^_BlockingTrampoline7)(void * waiter, id arg0, int arg1); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline7 _NativeCupertinoHttp_wrapBlockingBlock_18kzm6a( + _BlockingTrampoline7 block, _BlockingTrampoline7 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(id arg0, int arg1) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, (__bridge id)(__bridge_retained void*)(arg0), arg1); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, (__bridge id)(__bridge_retained void*)(arg0), arg1); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline8)(int arg0); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline8 _NativeCupertinoHttp_wrapListenerBlock_9o8504(_ListenerTrampoline8 block) NS_RETURNS_RETAINED { return ^void(int arg0) { objc_retainBlock(block); @@ -91,15 +252,55 @@ _ListenerTrampoline8 _NativeCupertinoHttp_wrapListenerBlock_9o8504(_ListenerTram }; } +typedef void (^_BlockingTrampoline8)(void * waiter, int arg0); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline8 _NativeCupertinoHttp_wrapBlockingBlock_9o8504( + _BlockingTrampoline8 block, _BlockingTrampoline8 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(int arg0) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline9)(BOOL arg0, id arg1, int arg2); -_ListenerTrampoline9 _NativeCupertinoHttp_wrapListenerBlock_12a4qua(_ListenerTrampoline9 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline9 _NativeCupertinoHttp_wrapListenerBlock_og5b6y(_ListenerTrampoline9 block) NS_RETURNS_RETAINED { return ^void(BOOL arg0, id arg1, int arg2) { objc_retainBlock(block); - block(arg0, objc_retain(arg1), arg2); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1), arg2); + }; +} + +typedef void (^_BlockingTrampoline9)(void * waiter, BOOL arg0, id arg1, int arg2); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline9 _NativeCupertinoHttp_wrapBlockingBlock_og5b6y( + _BlockingTrampoline9 block, _BlockingTrampoline9 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(BOOL arg0, id arg1, int arg2) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1), arg2); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1), arg2); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline10)(struct __SecTrust * arg0, SecTrustResultType arg1); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline10 _NativeCupertinoHttp_wrapListenerBlock_gwxhxt(_ListenerTrampoline10 block) NS_RETURNS_RETAINED { return ^void(struct __SecTrust * arg0, SecTrustResultType arg1) { objc_retainBlock(block); @@ -107,7 +308,27 @@ _ListenerTrampoline10 _NativeCupertinoHttp_wrapListenerBlock_gwxhxt(_ListenerTra }; } +typedef void (^_BlockingTrampoline10)(void * waiter, struct __SecTrust * arg0, SecTrustResultType arg1); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline10 _NativeCupertinoHttp_wrapBlockingBlock_gwxhxt( + _BlockingTrampoline10 block, _BlockingTrampoline10 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(struct __SecTrust * arg0, SecTrustResultType arg1) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, arg1); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, arg1); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline11)(struct __SecTrust * arg0, BOOL arg1, struct __CFError * arg2); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline11 _NativeCupertinoHttp_wrapListenerBlock_k73ff5(_ListenerTrampoline11 block) NS_RETURNS_RETAINED { return ^void(struct __SecTrust * arg0, BOOL arg1, struct __CFError * arg2) { objc_retainBlock(block); @@ -115,7 +336,27 @@ _ListenerTrampoline11 _NativeCupertinoHttp_wrapListenerBlock_k73ff5(_ListenerTra }; } +typedef void (^_BlockingTrampoline11)(void * waiter, struct __SecTrust * arg0, BOOL arg1, struct __CFError * arg2); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline11 _NativeCupertinoHttp_wrapBlockingBlock_k73ff5( + _BlockingTrampoline11 block, _BlockingTrampoline11 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(struct __SecTrust * arg0, BOOL arg1, struct __CFError * arg2) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, arg1, arg2); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, arg1, arg2); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline12)(uint16_t arg0); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline12 _NativeCupertinoHttp_wrapListenerBlock_15f11yh(_ListenerTrampoline12 block) NS_RETURNS_RETAINED { return ^void(uint16_t arg0) { objc_retainBlock(block); @@ -123,31 +364,111 @@ _ListenerTrampoline12 _NativeCupertinoHttp_wrapListenerBlock_15f11yh(_ListenerTr }; } +typedef void (^_BlockingTrampoline12)(void * waiter, uint16_t arg0); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline12 _NativeCupertinoHttp_wrapBlockingBlock_15f11yh( + _BlockingTrampoline12 block, _BlockingTrampoline12 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(uint16_t arg0) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline13)(id arg0, id arg1); -_ListenerTrampoline13 _NativeCupertinoHttp_wrapListenerBlock_wjvic9(_ListenerTrampoline13 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline13 _NativeCupertinoHttp_wrapListenerBlock_pfv6jd(_ListenerTrampoline13 block) NS_RETURNS_RETAINED { return ^void(id arg0, id arg1) { objc_retainBlock(block); - block(objc_retain(arg0), objc_retain(arg1)); + block((__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1)); + }; +} + +typedef void (^_BlockingTrampoline13)(void * waiter, id arg0, id arg1); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline13 _NativeCupertinoHttp_wrapBlockingBlock_pfv6jd( + _BlockingTrampoline13 block, _BlockingTrampoline13 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(id arg0, id arg1) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, (__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, (__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline14)(id arg0, id arg1, id arg2); -_ListenerTrampoline14 _NativeCupertinoHttp_wrapListenerBlock_91c9gi(_ListenerTrampoline14 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline14 _NativeCupertinoHttp_wrapListenerBlock_18qun1e(_ListenerTrampoline14 block) NS_RETURNS_RETAINED { return ^void(id arg0, id arg1, id arg2) { objc_retainBlock(block); - block(objc_retain(arg0), objc_retain(arg1), objc_retainBlock(arg2)); + block((__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1), objc_retainBlock(arg2)); + }; +} + +typedef void (^_BlockingTrampoline14)(void * waiter, id arg0, id arg1, id arg2); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline14 _NativeCupertinoHttp_wrapBlockingBlock_18qun1e( + _BlockingTrampoline14 block, _BlockingTrampoline14 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(id arg0, id arg1, id arg2) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, (__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1), objc_retainBlock(arg2)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, (__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1), objc_retainBlock(arg2)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline15)(id arg0, id arg1); -_ListenerTrampoline15 _NativeCupertinoHttp_wrapListenerBlock_14pxqbs(_ListenerTrampoline15 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline15 _NativeCupertinoHttp_wrapListenerBlock_o762yo(_ListenerTrampoline15 block) NS_RETURNS_RETAINED { return ^void(id arg0, id arg1) { objc_retainBlock(block); - block(objc_retain(arg0), objc_retainBlock(arg1)); + block((__bridge id)(__bridge_retained void*)(arg0), objc_retainBlock(arg1)); + }; +} + +typedef void (^_BlockingTrampoline15)(void * waiter, id arg0, id arg1); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline15 _NativeCupertinoHttp_wrapBlockingBlock_o762yo( + _BlockingTrampoline15 block, _BlockingTrampoline15 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(id arg0, id arg1) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, (__bridge id)(__bridge_retained void*)(arg0), objc_retainBlock(arg1)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, (__bridge id)(__bridge_retained void*)(arg0), objc_retainBlock(arg1)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline16)(BOOL arg0); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline16 _NativeCupertinoHttp_wrapListenerBlock_1s56lr9(_ListenerTrampoline16 block) NS_RETURNS_RETAINED { return ^void(BOOL arg0) { objc_retainBlock(block); @@ -155,15 +476,55 @@ _ListenerTrampoline16 _NativeCupertinoHttp_wrapListenerBlock_1s56lr9(_ListenerTr }; } +typedef void (^_BlockingTrampoline16)(void * waiter, BOOL arg0); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline16 _NativeCupertinoHttp_wrapBlockingBlock_1s56lr9( + _BlockingTrampoline16 block, _BlockingTrampoline16 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(BOOL arg0) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline17)(id arg0, id arg1, id arg2); -_ListenerTrampoline17 _NativeCupertinoHttp_wrapListenerBlock_1hcfngn(_ListenerTrampoline17 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline17 _NativeCupertinoHttp_wrapListenerBlock_r8gdi7(_ListenerTrampoline17 block) NS_RETURNS_RETAINED { return ^void(id arg0, id arg1, id arg2) { objc_retainBlock(block); - block(objc_retain(arg0), objc_retain(arg1), objc_retain(arg2)); + block((__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2)); + }; +} + +typedef void (^_BlockingTrampoline17)(void * waiter, id arg0, id arg1, id arg2); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline17 _NativeCupertinoHttp_wrapBlockingBlock_r8gdi7( + _BlockingTrampoline17 block, _BlockingTrampoline17 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(id arg0, id arg1, id arg2) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, (__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, (__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline18)(NSURLSessionResponseDisposition arg0); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline18 _NativeCupertinoHttp_wrapListenerBlock_16sve1d(_ListenerTrampoline18 block) NS_RETURNS_RETAINED { return ^void(NSURLSessionResponseDisposition arg0) { objc_retainBlock(block); @@ -171,133 +532,453 @@ _ListenerTrampoline18 _NativeCupertinoHttp_wrapListenerBlock_16sve1d(_ListenerTr }; } +typedef void (^_BlockingTrampoline18)(void * waiter, NSURLSessionResponseDisposition arg0); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline18 _NativeCupertinoHttp_wrapBlockingBlock_16sve1d( + _BlockingTrampoline18 block, _BlockingTrampoline18 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(NSURLSessionResponseDisposition arg0) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline19)(void * arg0, id arg1, id arg2, id arg3, id arg4); -_ListenerTrampoline19 _NativeCupertinoHttp_wrapListenerBlock_1f43wec(_ListenerTrampoline19 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline19 _NativeCupertinoHttp_wrapListenerBlock_xx612k(_ListenerTrampoline19 block) NS_RETURNS_RETAINED { return ^void(void * arg0, id arg1, id arg2, id arg3, id arg4) { objc_retainBlock(block); - block(arg0, objc_retain(arg1), objc_retain(arg2), objc_retain(arg3), objc_retainBlock(arg4)); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), (__bridge id)(__bridge_retained void*)(arg3), objc_retainBlock(arg4)); + }; +} + +typedef void (^_BlockingTrampoline19)(void * waiter, void * arg0, id arg1, id arg2, id arg3, id arg4); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline19 _NativeCupertinoHttp_wrapBlockingBlock_xx612k( + _BlockingTrampoline19 block, _BlockingTrampoline19 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(void * arg0, id arg1, id arg2, id arg3, id arg4) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), (__bridge id)(__bridge_retained void*)(arg3), objc_retainBlock(arg4)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), (__bridge id)(__bridge_retained void*)(arg3), objc_retainBlock(arg4)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline20)(void * arg0, id arg1, id arg2, id arg3); -_ListenerTrampoline20 _NativeCupertinoHttp_wrapListenerBlock_1r3kn8f(_ListenerTrampoline20 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline20 _NativeCupertinoHttp_wrapListenerBlock_1tz5yf(_ListenerTrampoline20 block) NS_RETURNS_RETAINED { return ^void(void * arg0, id arg1, id arg2, id arg3) { objc_retainBlock(block); - block(arg0, objc_retain(arg1), objc_retain(arg2), objc_retain(arg3)); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), (__bridge id)(__bridge_retained void*)(arg3)); + }; +} + +typedef void (^_BlockingTrampoline20)(void * waiter, void * arg0, id arg1, id arg2, id arg3); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline20 _NativeCupertinoHttp_wrapBlockingBlock_1tz5yf( + _BlockingTrampoline20 block, _BlockingTrampoline20 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(void * arg0, id arg1, id arg2, id arg3) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), (__bridge id)(__bridge_retained void*)(arg3)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), (__bridge id)(__bridge_retained void*)(arg3)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline21)(void * arg0, id arg1, id arg2); -_ListenerTrampoline21 _NativeCupertinoHttp_wrapListenerBlock_ao4xm9(_ListenerTrampoline21 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline21 _NativeCupertinoHttp_wrapListenerBlock_fjrv01(_ListenerTrampoline21 block) NS_RETURNS_RETAINED { return ^void(void * arg0, id arg1, id arg2) { objc_retainBlock(block); - block(arg0, objc_retain(arg1), objc_retain(arg2)); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2)); + }; +} + +typedef void (^_BlockingTrampoline21)(void * waiter, void * arg0, id arg1, id arg2); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline21 _NativeCupertinoHttp_wrapBlockingBlock_fjrv01( + _BlockingTrampoline21 block, _BlockingTrampoline21 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(void * arg0, id arg1, id arg2) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline22)(NSURLSessionDelayedRequestDisposition arg0, id arg1); -_ListenerTrampoline22 _NativeCupertinoHttp_wrapListenerBlock_mn1xu3(_ListenerTrampoline22 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline22 _NativeCupertinoHttp_wrapListenerBlock_1otpo83(_ListenerTrampoline22 block) NS_RETURNS_RETAINED { return ^void(NSURLSessionDelayedRequestDisposition arg0, id arg1) { objc_retainBlock(block); - block(arg0, objc_retain(arg1)); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1)); + }; +} + +typedef void (^_BlockingTrampoline22)(void * waiter, NSURLSessionDelayedRequestDisposition arg0, id arg1); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline22 _NativeCupertinoHttp_wrapBlockingBlock_1otpo83( + _BlockingTrampoline22 block, _BlockingTrampoline22 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(NSURLSessionDelayedRequestDisposition arg0, id arg1) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline23)(void * arg0, id arg1, id arg2, id arg3, id arg4, id arg5); -_ListenerTrampoline23 _NativeCupertinoHttp_wrapListenerBlock_13vswqm(_ListenerTrampoline23 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline23 _NativeCupertinoHttp_wrapListenerBlock_l2g8ke(_ListenerTrampoline23 block) NS_RETURNS_RETAINED { return ^void(void * arg0, id arg1, id arg2, id arg3, id arg4, id arg5) { objc_retainBlock(block); - block(arg0, objc_retain(arg1), objc_retain(arg2), objc_retain(arg3), objc_retain(arg4), objc_retainBlock(arg5)); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), (__bridge id)(__bridge_retained void*)(arg3), (__bridge id)(__bridge_retained void*)(arg4), objc_retainBlock(arg5)); + }; +} + +typedef void (^_BlockingTrampoline23)(void * waiter, void * arg0, id arg1, id arg2, id arg3, id arg4, id arg5); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline23 _NativeCupertinoHttp_wrapBlockingBlock_l2g8ke( + _BlockingTrampoline23 block, _BlockingTrampoline23 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(void * arg0, id arg1, id arg2, id arg3, id arg4, id arg5) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), (__bridge id)(__bridge_retained void*)(arg3), (__bridge id)(__bridge_retained void*)(arg4), objc_retainBlock(arg5)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), (__bridge id)(__bridge_retained void*)(arg3), (__bridge id)(__bridge_retained void*)(arg4), objc_retainBlock(arg5)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline24)(NSURLSessionAuthChallengeDisposition arg0, id arg1); -_ListenerTrampoline24 _NativeCupertinoHttp_wrapListenerBlock_37btrl(_ListenerTrampoline24 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline24 _NativeCupertinoHttp_wrapListenerBlock_n8yd09(_ListenerTrampoline24 block) NS_RETURNS_RETAINED { return ^void(NSURLSessionAuthChallengeDisposition arg0, id arg1) { objc_retainBlock(block); - block(arg0, objc_retain(arg1)); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1)); + }; +} + +typedef void (^_BlockingTrampoline24)(void * waiter, NSURLSessionAuthChallengeDisposition arg0, id arg1); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline24 _NativeCupertinoHttp_wrapBlockingBlock_n8yd09( + _BlockingTrampoline24 block, _BlockingTrampoline24 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(NSURLSessionAuthChallengeDisposition arg0, id arg1) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline25)(void * arg0, id arg1, id arg2, id arg3); -_ListenerTrampoline25 _NativeCupertinoHttp_wrapListenerBlock_12nszru(_ListenerTrampoline25 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline25 _NativeCupertinoHttp_wrapListenerBlock_bklti2(_ListenerTrampoline25 block) NS_RETURNS_RETAINED { return ^void(void * arg0, id arg1, id arg2, id arg3) { objc_retainBlock(block); - block(arg0, objc_retain(arg1), objc_retain(arg2), objc_retainBlock(arg3)); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), objc_retainBlock(arg3)); + }; +} + +typedef void (^_BlockingTrampoline25)(void * waiter, void * arg0, id arg1, id arg2, id arg3); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline25 _NativeCupertinoHttp_wrapBlockingBlock_bklti2( + _BlockingTrampoline25 block, _BlockingTrampoline25 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(void * arg0, id arg1, id arg2, id arg3) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), objc_retainBlock(arg3)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), objc_retainBlock(arg3)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline26)(void * arg0, id arg1, id arg2, int64_t arg3, id arg4); -_ListenerTrampoline26 _NativeCupertinoHttp_wrapListenerBlock_qm01og(_ListenerTrampoline26 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline26 _NativeCupertinoHttp_wrapListenerBlock_jyim80(_ListenerTrampoline26 block) NS_RETURNS_RETAINED { return ^void(void * arg0, id arg1, id arg2, int64_t arg3, id arg4) { objc_retainBlock(block); - block(arg0, objc_retain(arg1), objc_retain(arg2), arg3, objc_retainBlock(arg4)); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), arg3, objc_retainBlock(arg4)); + }; +} + +typedef void (^_BlockingTrampoline26)(void * waiter, void * arg0, id arg1, id arg2, int64_t arg3, id arg4); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline26 _NativeCupertinoHttp_wrapBlockingBlock_jyim80( + _BlockingTrampoline26 block, _BlockingTrampoline26 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(void * arg0, id arg1, id arg2, int64_t arg3, id arg4) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), arg3, objc_retainBlock(arg4)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), arg3, objc_retainBlock(arg4)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline27)(void * arg0, id arg1, id arg2, int64_t arg3, int64_t arg4, int64_t arg5); -_ListenerTrampoline27 _NativeCupertinoHttp_wrapListenerBlock_1uuez7b(_ListenerTrampoline27 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline27 _NativeCupertinoHttp_wrapListenerBlock_h68abb(_ListenerTrampoline27 block) NS_RETURNS_RETAINED { return ^void(void * arg0, id arg1, id arg2, int64_t arg3, int64_t arg4, int64_t arg5) { objc_retainBlock(block); - block(arg0, objc_retain(arg1), objc_retain(arg2), arg3, arg4, arg5); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), arg3, arg4, arg5); }; } -Protocol* _NativeCupertinoHttp_NSURLSessionDataDelegate() { return @protocol(NSURLSessionDataDelegate); } +typedef void (^_BlockingTrampoline27)(void * waiter, void * arg0, id arg1, id arg2, int64_t arg3, int64_t arg4, int64_t arg5); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline27 _NativeCupertinoHttp_wrapBlockingBlock_h68abb( + _BlockingTrampoline27 block, _BlockingTrampoline27 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(void * arg0, id arg1, id arg2, int64_t arg3, int64_t arg4, int64_t arg5) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), arg3, arg4, arg5); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), arg3, arg4, arg5); + awaitWaiter(waiter); + } + }; +} + +Protocol* _NativeCupertinoHttp_NSURLSessionDataDelegate(void) { return @protocol(NSURLSessionDataDelegate); } typedef void (^_ListenerTrampoline28)(void * arg0, id arg1, id arg2, int64_t arg3, int64_t arg4); -_ListenerTrampoline28 _NativeCupertinoHttp_wrapListenerBlock_9qxjkl(_ListenerTrampoline28 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline28 _NativeCupertinoHttp_wrapListenerBlock_ly2579(_ListenerTrampoline28 block) NS_RETURNS_RETAINED { return ^void(void * arg0, id arg1, id arg2, int64_t arg3, int64_t arg4) { objc_retainBlock(block); - block(arg0, objc_retain(arg1), objc_retain(arg2), arg3, arg4); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), arg3, arg4); + }; +} + +typedef void (^_BlockingTrampoline28)(void * waiter, void * arg0, id arg1, id arg2, int64_t arg3, int64_t arg4); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline28 _NativeCupertinoHttp_wrapBlockingBlock_ly2579( + _BlockingTrampoline28 block, _BlockingTrampoline28 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(void * arg0, id arg1, id arg2, int64_t arg3, int64_t arg4) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), arg3, arg4); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), arg3, arg4); + awaitWaiter(waiter); + } }; } -Protocol* _NativeCupertinoHttp_NSURLSessionDownloadDelegate() { return @protocol(NSURLSessionDownloadDelegate); } +Protocol* _NativeCupertinoHttp_NSURLSessionDownloadDelegate(void) { return @protocol(NSURLSessionDownloadDelegate); } typedef void (^_ListenerTrampoline29)(void * arg0, id arg1, id arg2, NSURLSessionWebSocketCloseCode arg3, id arg4); -_ListenerTrampoline29 _NativeCupertinoHttp_wrapListenerBlock_3lo3bb(_ListenerTrampoline29 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline29 _NativeCupertinoHttp_wrapListenerBlock_1lx650f(_ListenerTrampoline29 block) NS_RETURNS_RETAINED { return ^void(void * arg0, id arg1, id arg2, NSURLSessionWebSocketCloseCode arg3, id arg4) { objc_retainBlock(block); - block(arg0, objc_retain(arg1), objc_retain(arg2), arg3, objc_retain(arg4)); + block(arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), arg3, (__bridge id)(__bridge_retained void*)(arg4)); + }; +} + +typedef void (^_BlockingTrampoline29)(void * waiter, void * arg0, id arg1, id arg2, NSURLSessionWebSocketCloseCode arg3, id arg4); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline29 _NativeCupertinoHttp_wrapBlockingBlock_1lx650f( + _BlockingTrampoline29 block, _BlockingTrampoline29 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(void * arg0, id arg1, id arg2, NSURLSessionWebSocketCloseCode arg3, id arg4) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), arg3, (__bridge id)(__bridge_retained void*)(arg4)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), arg3, (__bridge id)(__bridge_retained void*)(arg4)); + awaitWaiter(waiter); + } }; } -Protocol* _NativeCupertinoHttp_NSURLSessionWebSocketDelegate() { return @protocol(NSURLSessionWebSocketDelegate); } +Protocol* _NativeCupertinoHttp_NSURLSessionWebSocketDelegate(void) { return @protocol(NSURLSessionWebSocketDelegate); } typedef void (^_ListenerTrampoline30)(id arg0, unsigned long arg1, BOOL * arg2); -_ListenerTrampoline30 _NativeCupertinoHttp_wrapListenerBlock_16ko9u(_ListenerTrampoline30 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline30 _NativeCupertinoHttp_wrapListenerBlock_1p9ui4q(_ListenerTrampoline30 block) NS_RETURNS_RETAINED { return ^void(id arg0, unsigned long arg1, BOOL * arg2) { objc_retainBlock(block); - block(objc_retain(arg0), arg1, arg2); + block((__bridge id)(__bridge_retained void*)(arg0), arg1, arg2); + }; +} + +typedef void (^_BlockingTrampoline30)(void * waiter, id arg0, unsigned long arg1, BOOL * arg2); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline30 _NativeCupertinoHttp_wrapBlockingBlock_1p9ui4q( + _BlockingTrampoline30 block, _BlockingTrampoline30 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(id arg0, unsigned long arg1, BOOL * arg2) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, (__bridge id)(__bridge_retained void*)(arg0), arg1, arg2); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, (__bridge id)(__bridge_retained void*)(arg0), arg1, arg2); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline31)(id arg0, id arg1, id arg2); -_ListenerTrampoline31 _NativeCupertinoHttp_wrapListenerBlock_1j2nt86(_ListenerTrampoline31 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline31 _NativeCupertinoHttp_wrapListenerBlock_1b3bb6a(_ListenerTrampoline31 block) NS_RETURNS_RETAINED { return ^void(id arg0, id arg1, id arg2) { objc_retainBlock(block); - block(objc_retainBlock(arg0), objc_retain(arg1), objc_retain(arg2)); + block(objc_retainBlock(arg0), (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2)); + }; +} + +typedef void (^_BlockingTrampoline31)(void * waiter, id arg0, id arg1, id arg2); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline31 _NativeCupertinoHttp_wrapBlockingBlock_1b3bb6a( + _BlockingTrampoline31 block, _BlockingTrampoline31 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(id arg0, id arg1, id arg2) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, objc_retainBlock(arg0), (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, objc_retainBlock(arg0), (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2)); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline32)(id arg0, struct _NSRange arg1, struct _NSRange arg2, BOOL * arg3); -_ListenerTrampoline32 _NativeCupertinoHttp_wrapListenerBlock_8wbg7l(_ListenerTrampoline32 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline32 _NativeCupertinoHttp_wrapListenerBlock_lmc3p5(_ListenerTrampoline32 block) NS_RETURNS_RETAINED { return ^void(id arg0, struct _NSRange arg1, struct _NSRange arg2, BOOL * arg3) { objc_retainBlock(block); - block(objc_retain(arg0), arg1, arg2, arg3); + block((__bridge id)(__bridge_retained void*)(arg0), arg1, arg2, arg3); + }; +} + +typedef void (^_BlockingTrampoline32)(void * waiter, id arg0, struct _NSRange arg1, struct _NSRange arg2, BOOL * arg3); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline32 _NativeCupertinoHttp_wrapBlockingBlock_lmc3p5( + _BlockingTrampoline32 block, _BlockingTrampoline32 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(id arg0, struct _NSRange arg1, struct _NSRange arg2, BOOL * arg3) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, (__bridge id)(__bridge_retained void*)(arg0), arg1, arg2, arg3); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, (__bridge id)(__bridge_retained void*)(arg0), arg1, arg2, arg3); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline33)(id arg0, BOOL * arg1); -_ListenerTrampoline33 _NativeCupertinoHttp_wrapListenerBlock_148br51(_ListenerTrampoline33 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline33 _NativeCupertinoHttp_wrapListenerBlock_t8l8el(_ListenerTrampoline33 block) NS_RETURNS_RETAINED { return ^void(id arg0, BOOL * arg1) { objc_retainBlock(block); - block(objc_retain(arg0), arg1); + block((__bridge id)(__bridge_retained void*)(arg0), arg1); + }; +} + +typedef void (^_BlockingTrampoline33)(void * waiter, id arg0, BOOL * arg1); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline33 _NativeCupertinoHttp_wrapBlockingBlock_t8l8el( + _BlockingTrampoline33 block, _BlockingTrampoline33 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(id arg0, BOOL * arg1) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, (__bridge id)(__bridge_retained void*)(arg0), arg1); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, (__bridge id)(__bridge_retained void*)(arg0), arg1); + awaitWaiter(waiter); + } }; } typedef void (^_ListenerTrampoline34)(unsigned short * arg0, unsigned long arg1); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline34 _NativeCupertinoHttp_wrapListenerBlock_vhbh5h(_ListenerTrampoline34 block) NS_RETURNS_RETAINED { return ^void(unsigned short * arg0, unsigned long arg1) { objc_retainBlock(block); @@ -305,7 +986,27 @@ _ListenerTrampoline34 _NativeCupertinoHttp_wrapListenerBlock_vhbh5h(_ListenerTra }; } +typedef void (^_BlockingTrampoline34)(void * waiter, unsigned short * arg0, unsigned long arg1); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline34 _NativeCupertinoHttp_wrapBlockingBlock_vhbh5h( + _BlockingTrampoline34 block, _BlockingTrampoline34 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(unsigned short * arg0, unsigned long arg1) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, arg1); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, arg1); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline35)(void * arg0, unsigned long arg1); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline35 _NativeCupertinoHttp_wrapListenerBlock_zuf90e(_ListenerTrampoline35 block) NS_RETURNS_RETAINED { return ^void(void * arg0, unsigned long arg1) { objc_retainBlock(block); @@ -313,7 +1014,27 @@ _ListenerTrampoline35 _NativeCupertinoHttp_wrapListenerBlock_zuf90e(_ListenerTra }; } +typedef void (^_BlockingTrampoline35)(void * waiter, void * arg0, unsigned long arg1); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline35 _NativeCupertinoHttp_wrapBlockingBlock_zuf90e( + _BlockingTrampoline35 block, _BlockingTrampoline35 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(void * arg0, unsigned long arg1) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0, arg1); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0, arg1); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline36)(void * arg0); +__attribute__((visibility("default"))) __attribute__((used)) _ListenerTrampoline36 _NativeCupertinoHttp_wrapListenerBlock_ovsamd(_ListenerTrampoline36 block) NS_RETURNS_RETAINED { return ^void(void * arg0) { objc_retainBlock(block); @@ -321,10 +1042,49 @@ _ListenerTrampoline36 _NativeCupertinoHttp_wrapListenerBlock_ovsamd(_ListenerTra }; } +typedef void (^_BlockingTrampoline36)(void * waiter, void * arg0); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline36 _NativeCupertinoHttp_wrapBlockingBlock_ovsamd( + _BlockingTrampoline36 block, _BlockingTrampoline36 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(void * arg0) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, arg0); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, arg0); + awaitWaiter(waiter); + } + }; +} + typedef void (^_ListenerTrampoline37)(id arg0, id arg1, id arg2, id arg3); -_ListenerTrampoline37 _NativeCupertinoHttp_wrapListenerBlock_4ya7yd(_ListenerTrampoline37 block) NS_RETURNS_RETAINED { +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline37 _NativeCupertinoHttp_wrapListenerBlock_mlcr8l(_ListenerTrampoline37 block) NS_RETURNS_RETAINED { return ^void(id arg0, id arg1, id arg2, id arg3) { objc_retainBlock(block); - block(objc_retain(arg0), objc_retain(arg1), objc_retain(arg2), objc_retain(arg3)); + block((__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), (__bridge id)(__bridge_retained void*)(arg3)); + }; +} + +typedef void (^_BlockingTrampoline37)(void * waiter, id arg0, id arg1, id arg2, id arg3); +__attribute__((visibility("default"))) __attribute__((used)) +_ListenerTrampoline37 _NativeCupertinoHttp_wrapBlockingBlock_mlcr8l( + _BlockingTrampoline37 block, _BlockingTrampoline37 listenerBlock, + void* (*newWaiter)(), void (*awaitWaiter)(void*)) NS_RETURNS_RETAINED { + NSThread *targetThread = [NSThread currentThread]; + return ^void(id arg0, id arg1, id arg2, id arg3) { + if ([NSThread currentThread] == targetThread) { + objc_retainBlock(block); + block(nil, (__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), (__bridge id)(__bridge_retained void*)(arg3)); + } else { + void* waiter = newWaiter(); + objc_retainBlock(listenerBlock); + listenerBlock(waiter, (__bridge id)(__bridge_retained void*)(arg0), (__bridge id)(__bridge_retained void*)(arg1), (__bridge id)(__bridge_retained void*)(arg2), (__bridge id)(__bridge_retained void*)(arg3)); + awaitWaiter(waiter); + } }; } diff --git a/pkgs/cupertino_http/lib/src/native_cupertino_bindings.dart b/pkgs/cupertino_http/lib/src/native_cupertino_bindings.dart index 9cc83b62e0..cc01adeb41 100644 --- a/pkgs/cupertino_http/lib/src/native_cupertino_bindings.dart +++ b/pkgs/cupertino_http/lib/src/native_cupertino_bindings.dart @@ -618,10 +618,10 @@ class NativeCupertinoHttp { .asFunction Function(ffi.Pointer, int)>(); ffi.Pointer valloc( - int arg0, + int __size, ) { return _valloc( - arg0, + __size, ); } @@ -701,6 +701,22 @@ class NativeCupertinoHttp { late final _atexit = _atexitPtr.asFunction< int Function(ffi.Pointer>)>(); + int at_quick_exit( + ffi.Pointer> arg0, + ) { + return _at_quick_exit( + arg0, + ); + } + + late final _at_quick_exitPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer>)>>( + 'at_quick_exit'); + late final _at_quick_exit = _at_quick_exitPtr.asFunction< + int Function(ffi.Pointer>)>(); + double atof( ffi.Pointer arg0, ) { @@ -980,6 +996,18 @@ class NativeCupertinoHttp { ffi.Int Function( ffi.Pointer, ffi.Pointer)>>)>(); + void quick_exit( + int arg0, + ) { + return _quick_exit( + arg0, + ); + } + + late final _quick_exitPtr = + _lookup>('quick_exit'); + late final _quick_exit = _quick_exitPtr.asFunction(); + int rand() { return _rand(); } @@ -3092,6 +3120,99 @@ class NativeCupertinoHttp { CFAllocatorRef Function( CFAllocatorRef, ffi.Pointer)>(); + ffi.Pointer CFAllocatorAllocateTyped( + CFAllocatorRef allocator, + int size, + int descriptor, + int hint, + ) { + return _CFAllocatorAllocateTyped( + allocator, + size, + descriptor, + hint, + ); + } + + late final _CFAllocatorAllocateTypedPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(CFAllocatorRef, CFIndex, + CFAllocatorTypeID, CFOptionFlags)>>('CFAllocatorAllocateTyped'); + late final _CFAllocatorAllocateTyped = + _CFAllocatorAllocateTypedPtr.asFunction< + ffi.Pointer Function(CFAllocatorRef, int, int, int)>(); + + ffi.Pointer CFAllocatorReallocateTyped( + CFAllocatorRef allocator, + ffi.Pointer ptr, + int newsize, + int descriptor, + int hint, + ) { + return _CFAllocatorReallocateTyped( + allocator, + ptr, + newsize, + descriptor, + hint, + ); + } + + late final _CFAllocatorReallocateTypedPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + CFAllocatorRef, + ffi.Pointer, + CFIndex, + CFAllocatorTypeID, + CFOptionFlags)>>('CFAllocatorReallocateTyped'); + late final _CFAllocatorReallocateTyped = + _CFAllocatorReallocateTypedPtr.asFunction< + ffi.Pointer Function( + CFAllocatorRef, ffi.Pointer, int, int, int)>(); + + ffi.Pointer CFAllocatorAllocateBytes( + CFAllocatorRef allocator, + int size, + int hint, + ) { + return _CFAllocatorAllocateBytes( + allocator, + size, + hint, + ); + } + + late final _CFAllocatorAllocateBytesPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(CFAllocatorRef, CFIndex, + CFOptionFlags)>>('CFAllocatorAllocateBytes'); + late final _CFAllocatorAllocateBytes = _CFAllocatorAllocateBytesPtr + .asFunction Function(CFAllocatorRef, int, int)>(); + + ffi.Pointer CFAllocatorReallocateBytes( + CFAllocatorRef allocator, + ffi.Pointer ptr, + int newsize, + int hint, + ) { + return _CFAllocatorReallocateBytes( + allocator, + ptr, + newsize, + hint, + ); + } + + late final _CFAllocatorReallocateBytesPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(CFAllocatorRef, ffi.Pointer, + CFIndex, CFOptionFlags)>>('CFAllocatorReallocateBytes'); + late final _CFAllocatorReallocateBytes = + _CFAllocatorReallocateBytesPtr.asFunction< + ffi.Pointer Function( + CFAllocatorRef, ffi.Pointer, int, int)>(); + ffi.Pointer CFAllocatorAllocate( CFAllocatorRef allocator, int size, @@ -7138,6 +7259,20 @@ class NativeCupertinoHttp { int Function( int, ffi.Pointer, int, ffi.Pointer, int)>(); + int printf( + ffi.Pointer arg0, + ) { + return _printf( + arg0, + ); + } + + late final _printfPtr = + _lookup)>>( + 'printf'); + late final _printf = + _printfPtr.asFunction)>(); + late final ffi.Pointer> ___stdinp = _lookup>('__stdinp'); @@ -7513,20 +7648,6 @@ class NativeCupertinoHttp { late final _perror = _perrorPtr.asFunction)>(); - int printf( - ffi.Pointer arg0, - ) { - return _printf( - arg0, - ); - } - - late final _printfPtr = - _lookup)>>( - 'printf'); - late final _printf = - _printfPtr.asFunction)>(); - int putc( int arg0, ffi.Pointer arg1, @@ -16733,6 +16854,13 @@ class NativeCupertinoHttp { CFNumberFormatterKey get kCFNumberFormatterMaxSignificantDigits => _kCFNumberFormatterMaxSignificantDigits.value; + late final ffi.Pointer + _kCFNumberFormatterMinGroupingDigits = + _lookup('kCFNumberFormatterMinGroupingDigits'); + + CFNumberFormatterKey get kCFNumberFormatterMinGroupingDigits => + _kCFNumberFormatterMinGroupingDigits.value; + int CFNumberFormatterGetDecimalInfoForCurrencyCode( CFStringRef currencyCode, ffi.Pointer defaultFractionDigits, @@ -30083,6 +30211,32 @@ class NativeCupertinoHttp { late final _CFAttributedStringEndEditing = _CFAttributedStringEndEditingPtr .asFunction(); + bool CFAttributedStringGetBidiLevelsAndResolvedDirections( + CFAttributedStringRef attributedString, + CFRange range, + int baseDirection, + ffi.Pointer bidiLevels, + ffi.Pointer baseDirections, + ) { + return _CFAttributedStringGetBidiLevelsAndResolvedDirections( + attributedString, + range, + baseDirection, + bidiLevels, + baseDirections, + ); + } + + late final _CFAttributedStringGetBidiLevelsAndResolvedDirectionsPtr = _lookup< + ffi.NativeFunction< + ffi.Bool Function(CFAttributedStringRef, CFRange, ffi.Int8, + ffi.Pointer, ffi.Pointer)>>( + 'CFAttributedStringGetBidiLevelsAndResolvedDirections'); + late final _CFAttributedStringGetBidiLevelsAndResolvedDirections = + _CFAttributedStringGetBidiLevelsAndResolvedDirectionsPtr.asFunction< + bool Function(CFAttributedStringRef, CFRange, int, + ffi.Pointer, ffi.Pointer)>(); + int CFURLEnumeratorGetTypeID() { return _CFURLEnumeratorGetTypeID(); } @@ -33361,6 +33515,36 @@ class NativeCupertinoHttp { _SecCertificateCopySerialNumberDataPtr.asFunction< CFDataRef Function(SecCertificateRef, ffi.Pointer)>(); + CFDateRef SecCertificateCopyNotValidBeforeDate( + SecCertificateRef certificate, + ) { + return _SecCertificateCopyNotValidBeforeDate( + certificate, + ); + } + + late final _SecCertificateCopyNotValidBeforeDatePtr = + _lookup>( + 'SecCertificateCopyNotValidBeforeDate'); + late final _SecCertificateCopyNotValidBeforeDate = + _SecCertificateCopyNotValidBeforeDatePtr.asFunction< + CFDateRef Function(SecCertificateRef)>(); + + CFDateRef SecCertificateCopyNotValidAfterDate( + SecCertificateRef certificate, + ) { + return _SecCertificateCopyNotValidAfterDate( + certificate, + ); + } + + late final _SecCertificateCopyNotValidAfterDatePtr = + _lookup>( + 'SecCertificateCopyNotValidAfterDate'); + late final _SecCertificateCopyNotValidAfterDate = + _SecCertificateCopyNotValidAfterDatePtr.asFunction< + CFDateRef Function(SecCertificateRef)>(); + CFDataRef SecCertificateCopySerialNumber( SecCertificateRef certificate, ffi.Pointer error, @@ -40507,30 +40691,98 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_1pl9qdv( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_1jdvcbf( + _NativeCupertinoHttp_wrapListenerBlock_xtuoz7( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_xtuoz7( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_wjovn7( + _NativeCupertinoHttp_wrapListenerBlock_18v1jvf( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_18v1jvf( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_1krhfwz( + _NativeCupertinoHttp_wrapListenerBlock_1o83rbn( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_1o83rbn( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) @@ -40539,6 +40791,23 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_tg5tbv( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) @@ -40547,6 +40816,23 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_1dqvvol( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) @@ -40555,14 +40841,48 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_6enxqz( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_qxvyq2( + _NativeCupertinoHttp_wrapListenerBlock_18kzm6a( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_18kzm6a( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) @@ -40571,14 +40891,48 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_9o8504( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_12a4qua( + _NativeCupertinoHttp_wrapListenerBlock_og5b6y( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_og5b6y( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) @@ -40587,6 +40941,23 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_gwxhxt( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) @@ -40595,6 +40966,23 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_k73ff5( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) @@ -40603,30 +40991,98 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_15f11yh( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_wjvic9( + _NativeCupertinoHttp_wrapListenerBlock_pfv6jd( + ffi.Pointer block, +); + +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_pfv6jd( ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, ); @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_91c9gi( + _NativeCupertinoHttp_wrapListenerBlock_18qun1e( + ffi.Pointer block, +); + +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_18qun1e( ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, ); @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_14pxqbs( + _NativeCupertinoHttp_wrapListenerBlock_o762yo( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_o762yo( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) @@ -40635,14 +41091,48 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_1s56lr9( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_1hcfngn( + _NativeCupertinoHttp_wrapListenerBlock_r8gdi7( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_r8gdi7( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) @@ -40651,124 +41141,396 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_16sve1d( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_1f43wec( + _NativeCupertinoHttp_wrapListenerBlock_xx612k( + ffi.Pointer block, +); + +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_xx612k( ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, ); @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_1r3kn8f( + _NativeCupertinoHttp_wrapListenerBlock_1tz5yf( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_1tz5yf( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_ao4xm9( + _NativeCupertinoHttp_wrapListenerBlock_fjrv01( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_fjrv01( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_mn1xu3( + _NativeCupertinoHttp_wrapListenerBlock_1otpo83( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_1otpo83( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_13vswqm( + _NativeCupertinoHttp_wrapListenerBlock_l2g8ke( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_l2g8ke( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_37btrl( + _NativeCupertinoHttp_wrapListenerBlock_n8yd09( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_n8yd09( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_12nszru( + _NativeCupertinoHttp_wrapListenerBlock_bklti2( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_bklti2( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_qm01og( + _NativeCupertinoHttp_wrapListenerBlock_jyim80( + ffi.Pointer block, +); + +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_jyim80( ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, ); @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_1uuez7b( + _NativeCupertinoHttp_wrapListenerBlock_h68abb( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_h68abb( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_9qxjkl( + _NativeCupertinoHttp_wrapListenerBlock_ly2579( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_ly2579( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_3lo3bb( + _NativeCupertinoHttp_wrapListenerBlock_1lx650f( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_1lx650f( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_16ko9u( + _NativeCupertinoHttp_wrapListenerBlock_1p9ui4q( + ffi.Pointer block, +); + +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_1p9ui4q( ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, ); @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_1j2nt86( + _NativeCupertinoHttp_wrapListenerBlock_1b3bb6a( + ffi.Pointer block, +); + +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_1b3bb6a( ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, ); @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_8wbg7l( + _NativeCupertinoHttp_wrapListenerBlock_lmc3p5( ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_lmc3p5( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_148br51( + _NativeCupertinoHttp_wrapListenerBlock_t8l8el( + ffi.Pointer block, +); + +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_t8l8el( ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, ); @ffi.Native< @@ -40779,6 +41541,23 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_vhbh5h( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) @@ -40787,6 +41566,23 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_zuf90e( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) @@ -40795,12 +41591,46 @@ external ffi.Pointer ffi.Pointer block, ); +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_ovsamd( + ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, +); + @ffi.Native< ffi.Pointer Function( ffi.Pointer)>(isLeaf: true) external ffi.Pointer - _NativeCupertinoHttp_wrapListenerBlock_4ya7yd( + _NativeCupertinoHttp_wrapListenerBlock_mlcr8l( + ffi.Pointer block, +); + +@ffi.Native< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer Function()>>, + ffi.Pointer< + ffi.NativeFunction)>>)>( + isLeaf: true) +external ffi.Pointer + _NativeCupertinoHttp_wrapBlockingBlock_mlcr8l( ffi.Pointer block, + ffi.Pointer listnerBlock, + ffi.Pointer Function()>> newWaiter, + ffi.Pointer)>> + awaitWaiter, ); typedef __int8_t = ffi.SignedChar; @@ -41040,6 +41870,14 @@ final class __darwin_arm_exception_state64 extends ffi.Struct { external int __exception; } +final class __darwin_arm_exception_state64_v2 extends ffi.Struct { + @__uint64_t() + external int __far; + + @__uint64_t() + external int __esr; +} + final class __darwin_arm_thread_state extends ffi.Struct { @ffi.Array.multi([13]) external ffi.Array<__uint32_t> __r; @@ -41997,7 +42835,16 @@ final class rusage_info_v6 extends ffi.Struct { @ffi.Uint64() external int ri_secure_ptime_in_system; - @ffi.Array.multi([12]) + @ffi.Uint64() + external int ri_neural_footprint; + + @ffi.Uint64() + external int ri_lifetime_max_neural_footprint; + + @ffi.Uint64() + external int ri_interval_max_neural_footprint; + + @ffi.Array.multi([9]) external ffi.Array ri_reserved; } @@ -42019,24 +42866,6 @@ final class proc_rlimit_control_wakeupmon extends ffi.Struct { external int wm_rate; } -@ffi.Packed(1) -final class _OSUnalignedU16 extends ffi.Struct { - @ffi.Uint16() - external int __val; -} - -@ffi.Packed(1) -final class _OSUnalignedU32 extends ffi.Struct { - @ffi.Uint32() - external int __val; -} - -@ffi.Packed(1) -final class _OSUnalignedU64 extends ffi.Struct { - @ffi.Uint64() - external int __val; -} - final class wait extends ffi.Opaque {} typedef ct_rune_t = __darwin_ct_rune_t; @@ -42104,6 +42933,33 @@ ffi.NativeCallable)> ffi.Void Function(ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_blockingTrampoline( + ffi.Pointer block, ffi.Pointer waiter) { + try { + (objc.getBlockClosure(block) as void Function())(); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_blockingCallable = ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_blockingListenerCallable = ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid { @@ -42155,6 +43011,29 @@ abstract final class ObjCBlock_ffiVoid { return objc.ObjCBlock(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking(void Function() fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_blockingCallable.nativeFunction.cast(), () => fn()); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_blockingListenerCallable.nativeFunction.cast(), + () => fn()); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1pl9qdv, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -42265,10 +43144,9 @@ extension ObjCBlock_ffiInt_ffiVoid_ffiVoid_CallExtension on objc ffi.Pointer)>()(ref.pointer, arg0, arg1); } -typedef ptrdiff_t = ffi.Long; -typedef Dartptrdiff_t = int; -typedef rsize_t = ffi.UnsignedLong; -typedef Dartrsize_t = int; +typedef ptrdiff_t = __darwin_ptrdiff_t; +typedef rsize_t = __darwin_size_t; +typedef wint_t = __darwin_wint_t; typedef u_char = ffi.UnsignedChar; typedef Dartu_char = int; typedef u_short = ffi.UnsignedShort; @@ -42349,8 +43227,8 @@ typedef DartNSUInteger = int; final class _NSZone extends ffi.Opaque {} -typedef va_list = __builtin_va_list; typedef __gnuc_va_list = __builtin_va_list; +typedef va_list = __builtin_va_list; typedef NSExceptionName = ffi.Pointer; typedef DartNSExceptionName = objc.NSString; typedef NSRunLoopMode = ffi.Pointer; @@ -42760,6 +43638,8 @@ typedef UnsignedWidePtr = ffi.Pointer; typedef extended80 = Float80; typedef extended96 = Float96; typedef VHSelect = SInt8; +typedef CFAllocatorTypeID = ffi.UnsignedLongLong; +typedef DartCFAllocatorTypeID = int; typedef CFTypeID = ffi.UnsignedLong; typedef DartCFTypeID = int; typedef CFOptionFlags = ffi.UnsignedLong; @@ -42908,7 +43788,7 @@ final _objc_msgSend_4sp4xj = objc.msgSendPointer void Function(ffi.Pointer, ffi.Pointer, int)>(); late final _sel_classForCoder = objc.registerName("classForCoder"); -final _objc_msgSend_1x359cv = objc.msgSendPointer +final _objc_msgSend_151sglz = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -42918,7 +43798,7 @@ final _objc_msgSend_1x359cv = objc.msgSendPointer ffi.Pointer, ffi.Pointer)>(); late final _sel_replacementObjectForCoder_ = objc.registerName("replacementObjectForCoder:"); -final _objc_msgSend_62nh5j = objc.msgSendPointer +final _objc_msgSend_1sotr3r = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -42945,13 +43825,13 @@ extension NSCoderMethods on objc.NSObject { /// classForCoder objc.ObjCObjectBase get classForCoder { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_classForCoder); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_classForCoder); return objc.ObjCObjectBase(_ret, retain: true, release: true); } /// replacementObjectForCoder: objc.ObjCObjectBase? replacementObjectForCoder_(objc.NSCoder coder) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_replacementObjectForCoder_, coder.ref.pointer); return _ret.address == 0 ? null @@ -42960,7 +43840,7 @@ extension NSCoderMethods on objc.NSObject { /// awakeAfterUsingCoder: objc.ObjCObjectBase? awakeAfterUsingCoder_(objc.NSCoder coder) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_awakeAfterUsingCoder_, coder.ref.pointer); return _ret.address == 0 ? null @@ -42969,7 +43849,7 @@ extension NSCoderMethods on objc.NSObject { } late final _sel_poseAsClass_ = objc.registerName("poseAsClass:"); -final _objc_msgSend_1jdvcbf = objc.msgSendPointer +final _objc_msgSend_xtuoz7 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -42984,7 +43864,7 @@ final _objc_msgSend_1jdvcbf = objc.msgSendPointer extension NSDeprecatedMethods on objc.NSObject { /// poseAsClass: static void poseAsClass_(objc.ObjCObjectBase aClass) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( _class_NSObject, _sel_poseAsClass_, aClass.ref.pointer); } } @@ -42997,7 +43877,7 @@ extension NSDiscardableContentProxy on objc.NSObject { /// autoContentAccessingProxy objc.ObjCObjectBase get autoContentAccessingProxy { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_autoContentAccessingProxy); + _objc_msgSend_151sglz(this.ref.pointer, _sel_autoContentAccessingProxy); return objc.ObjCObjectBase(_ret, retain: true, release: true); } } @@ -43062,7 +43942,7 @@ class NSCachedURLResponse extends objc.NSObject { late final _class_NSURLCache = objc.getClass("NSURLCache"); late final _sel_isKindOfClass_ = objc.registerName("isKindOfClass:"); -final _objc_msgSend_69e0x1 = objc.msgSendPointer +final _objc_msgSend_19nvye5 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Bool Function( @@ -43094,7 +43974,7 @@ class NSURLSessionDataTask extends NSURLSessionTask { late final _sel_storeCachedResponse_forDataTask_ = objc.registerName("storeCachedResponse:forDataTask:"); -final _objc_msgSend_wjvic9 = objc.msgSendPointer +final _objc_msgSend_pfv6jd = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -43149,6 +44029,40 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSCachedURLResponse_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_NSCachedURLResponse_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSCachedURLResponse_blockingCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSCachedURLResponse_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSCachedURLResponse_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSCachedURLResponse_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSCachedURLResponse { @@ -43212,11 +44126,45 @@ abstract final class ObjCBlock_ffiVoid_NSCachedURLResponse { ? null : NSCachedURLResponse.castFromPointer(arg0, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1jdvcbf(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xtuoz7(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(NSCachedURLResponse?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSCachedURLResponse_blockingCallable.nativeFunction + .cast(), + (ffi.Pointer arg0) => fn(arg0.address == 0 + ? null + : NSCachedURLResponse.castFromPointer(arg0, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSCachedURLResponse_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0) => fn(arg0.address == 0 + ? null + : NSCachedURLResponse.castFromPointer(arg0, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xtuoz7, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -43235,7 +44183,7 @@ extension ObjCBlock_ffiVoid_NSCachedURLResponse_CallExtension late final _sel_getCachedResponseForDataTask_completionHandler_ = objc.registerName("getCachedResponseForDataTask:completionHandler:"); -final _objc_msgSend_14pxqbs = objc.msgSendPointer +final _objc_msgSend_o762yo = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -43257,7 +44205,7 @@ extension NSURLSessionTaskAdditions on NSURLCache { /// storeCachedResponse:forDataTask: void storeCachedResponse_forDataTask_( NSCachedURLResponse cachedResponse, NSURLSessionDataTask dataTask) { - _objc_msgSend_wjvic9( + _objc_msgSend_pfv6jd( this.ref.pointer, _sel_storeCachedResponse_forDataTask_, cachedResponse.ref.pointer, @@ -43269,7 +44217,7 @@ extension NSURLSessionTaskAdditions on NSURLCache { NSURLSessionDataTask dataTask, objc.ObjCBlock completionHandler) { - _objc_msgSend_14pxqbs( + _objc_msgSend_o762yo( this.ref.pointer, _sel_getCachedResponseForDataTask_completionHandler_, dataTask.ref.pointer, @@ -43278,7 +44226,7 @@ extension NSURLSessionTaskAdditions on NSURLCache { /// removeCachedResponseForDataTask: void removeCachedResponseForDataTask_(NSURLSessionDataTask dataTask) { - _objc_msgSend_1jdvcbf(this.ref.pointer, + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_removeCachedResponseForDataTask_, dataTask.ref.pointer); } } @@ -43289,7 +44237,7 @@ typedef instancetype = ffi.Pointer; typedef Dartinstancetype = objc.ObjCObjectBase; late final _sel_initWithMemoryCapacity_diskCapacity_diskPath_ = objc.registerName("initWithMemoryCapacity:diskCapacity:diskPath:"); -final _objc_msgSend_1dlfwfh = objc.msgSendPointer +final _objc_msgSend_1dqnse5 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -43336,7 +44284,7 @@ extension NSHTTPURLRequest on NSURLRequest { /// @abstract Returns the HTTP request method of the receiver. /// @result the HTTP request method of the receiver. objc.NSString? get HTTPMethod { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_HTTPMethod); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_HTTPMethod); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -43349,7 +44297,7 @@ extension NSHTTPURLRequest on NSURLRequest { /// receiver. objc.NSDictionary? get allHTTPHeaderFields { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_allHTTPHeaderFields); + _objc_msgSend_151sglz(this.ref.pointer, _sel_allHTTPHeaderFields); return _ret.address == 0 ? null : objc.NSDictionary.castFromPointer(_ret, retain: true, release: true); @@ -43365,7 +44313,7 @@ extension NSHTTPURLRequest on NSURLRequest { /// @result the value associated with the given header field, or nil if /// there is no value associated with the given header field. objc.NSString? valueForHTTPHeaderField_(objc.NSString field) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_valueForHTTPHeaderField_, field.ref.pointer); return _ret.address == 0 ? null @@ -43378,7 +44326,7 @@ extension NSHTTPURLRequest on NSURLRequest { /// in done in an HTTP POST request. /// @result The request body data of the receiver. objc.NSData? get HTTPBody { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_HTTPBody); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_HTTPBody); return _ret.address == 0 ? null : objc.NSData.castFromPointer(_ret, retain: true, release: true); @@ -43395,7 +44343,7 @@ extension NSHTTPURLRequest on NSURLRequest { /// NSCoding protocol /// @result The request body stream of the receiver. objc.NSInputStream? get HTTPBodyStream { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_HTTPBodyStream); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_HTTPBodyStream); return _ret.address == 0 ? null : objc.NSInputStream.castFromPointer(_ret, retain: true, release: true); @@ -43582,7 +44530,7 @@ typedef NSTimeInterval = ffi.Double; typedef DartNSTimeInterval = double; late final _sel_requestWithURL_cachePolicy_timeoutInterval_ = objc.registerName("requestWithURL:cachePolicy:timeoutInterval:"); -final _objc_msgSend_3phu9v = objc.msgSendPointer +final _objc_msgSend_1ajs603 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -43759,10 +44707,11 @@ final _objc_msgSend_i3avs9 = objc.msgSendPointer ffi.Pointer, ffi.Pointer)>(); late final _sel_requiresDNSSECValidation = objc.registerName("requiresDNSSECValidation"); +late final _sel_allowsPersistentDNS = objc.registerName("allowsPersistentDNS"); late final _sel_init = objc.registerName("init"); late final _sel_new = objc.registerName("new"); late final _sel_allocWithZone_ = objc.registerName("allocWithZone:"); -final _objc_msgSend_hzlb60 = objc.msgSendPointer +final _objc_msgSend_1cwp428 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -43917,6 +44866,50 @@ ffi.NativeCallable< ffi.Pointer, ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSCoder_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_ffiVoid_NSCoder_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, ffi.Pointer))(arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSCoder_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSCoder_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSCoder_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSCoder_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, objc.NSCoder)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSCoder { @@ -43979,8 +44972,41 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSCoder { (ffi.Pointer arg0, ffi.Pointer arg1) => fn( arg0, objc.NSCoder.castFromPointer(arg1, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_wjovn7(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_18v1jvf(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, objc.NSCoder)>(wrapper, + retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock, objc.NSCoder)> + blocking(void Function(ffi.Pointer, objc.NSCoder) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSCoder_blockingCallable.nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1) => fn( + arg0, + objc.NSCoder.castFromPointer(arg1, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSCoder_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1) => fn( + arg0, + objc.NSCoder.castFromPointer(arg1, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_18v1jvf, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function(ffi.Pointer, objc.NSCoder)>(wrapper, retain: false, release: true); @@ -44128,7 +45154,7 @@ class NSURLRequest extends objc.NSObject { /// Returns whether [obj] is an instance of [NSURLRequest]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( obj.ref.pointer, _sel_isKindOfClass_, _class_NSURLRequest); } @@ -44142,7 +45168,7 @@ class NSURLRequest extends objc.NSObject { /// @param URL The URL for the request. /// @result A newly-created and autoreleased NSURLRequest instance. static NSURLRequest requestWithURL_(objc.NSURL URL) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSURLRequest, _sel_requestWithURL_, URL.ref.pointer); return NSURLRequest.castFromPointer(_ret, retain: true, release: true); } @@ -44166,7 +45192,7 @@ class NSURLRequest extends objc.NSObject { objc.NSURL URL, NSURLRequestCachePolicy cachePolicy, DartNSTimeInterval timeoutInterval) { - final _ret = _objc_msgSend_3phu9v( + final _ret = _objc_msgSend_1ajs603( _class_NSURLRequest, _sel_requestWithURL_cachePolicy_timeoutInterval_, URL.ref.pointer, @@ -44184,7 +45210,7 @@ class NSURLRequest extends objc.NSObject { /// @param URL The URL for the request. /// @result An initialized NSURLRequest. NSURLRequest initWithURL_(objc.NSURL URL) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.retainAndReturnPointer(), _sel_initWithURL_, URL.ref.pointer); return NSURLRequest.castFromPointer(_ret, retain: false, release: true); } @@ -44203,7 +45229,7 @@ class NSURLRequest extends objc.NSObject { /// @result An initialized NSURLRequest. NSURLRequest initWithURL_cachePolicy_timeoutInterval_(objc.NSURL URL, NSURLRequestCachePolicy cachePolicy, DartNSTimeInterval timeoutInterval) { - final _ret = _objc_msgSend_3phu9v( + final _ret = _objc_msgSend_1ajs603( this.ref.retainAndReturnPointer(), _sel_initWithURL_cachePolicy_timeoutInterval_, URL.ref.pointer, @@ -44216,7 +45242,7 @@ class NSURLRequest extends objc.NSObject { /// @abstract Returns the URL of the receiver. /// @result The URL of the receiver. objc.NSURL? get URL { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_URL); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_URL); return _ret.address == 0 ? null : objc.NSURL.castFromPointer(_ret, retain: true, release: true); @@ -44257,7 +45283,7 @@ class NSURLRequest extends objc.NSObject { /// See setMainDocumentURL: /// @result The main document URL. objc.NSURL? get mainDocumentURL { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_mainDocumentURL); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_mainDocumentURL); return _ret.address == 0 ? null : objc.NSURL.castFromPointer(_ret, retain: true, release: true); @@ -44331,59 +45357,69 @@ class NSURLRequest extends objc.NSObject { this.ref.pointer, _sel_requiresDNSSECValidation); } + /// ! + /// @abstract Allows storing and usage of DNS answers, potentially beyond TTL expiry, + /// in a persistent per-process cache. This should only be set for hostnames whose resolutions + /// are not expected to change across networks. + /// @discussion YES, if the DNS lookup for this request is allowed to use a persistent per-process cache, + /// NO otherwise. Defaults to NO. + bool get allowsPersistentDNS { + return _objc_msgSend_91o635(this.ref.pointer, _sel_allowsPersistentDNS); + } + /// init NSURLRequest init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSURLRequest.castFromPointer(_ret, retain: false, release: true); } /// new static NSURLRequest new1() { - final _ret = _objc_msgSend_1x359cv(_class_NSURLRequest, _sel_new); + final _ret = _objc_msgSend_151sglz(_class_NSURLRequest, _sel_new); return NSURLRequest.castFromPointer(_ret, retain: false, release: true); } /// allocWithZone: static NSURLRequest allocWithZone_(ffi.Pointer<_NSZone> zone) { final _ret = - _objc_msgSend_hzlb60(_class_NSURLRequest, _sel_allocWithZone_, zone); + _objc_msgSend_1cwp428(_class_NSURLRequest, _sel_allocWithZone_, zone); return NSURLRequest.castFromPointer(_ret, retain: false, release: true); } /// alloc static NSURLRequest alloc() { - final _ret = _objc_msgSend_1x359cv(_class_NSURLRequest, _sel_alloc); + final _ret = _objc_msgSend_151sglz(_class_NSURLRequest, _sel_alloc); return NSURLRequest.castFromPointer(_ret, retain: false, release: true); } /// self NSURLRequest self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSURLRequest.castFromPointer(_ret, retain: true, release: true); } /// retain NSURLRequest retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSURLRequest.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSURLRequest autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSURLRequest.castFromPointer(_ret, retain: true, release: true); } /// encodeWithCoder: void encodeWithCoder_(objc.NSCoder coder) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_encodeWithCoder_, coder.ref.pointer); } /// initWithCoder: NSURLRequest? initWithCoder_(objc.NSCoder coder) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithCoder_, coder.ref.pointer); return _ret.address == 0 ? null @@ -44449,7 +45485,7 @@ class NSURLCache extends objc.NSObject { /// Returns whether [obj] is an instance of [NSURLCache]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( obj.ref.pointer, _sel_isKindOfClass_, _class_NSURLCache); } @@ -44478,7 +45514,7 @@ class NSURLCache extends objc.NSObject { /// becoming unexpectedly unretrievable. /// @result the shared NSURLCache instance. static NSURLCache getSharedURLCache() { - final _ret = _objc_msgSend_1x359cv(_class_NSURLCache, _sel_sharedURLCache); + final _ret = _objc_msgSend_151sglz(_class_NSURLCache, _sel_sharedURLCache); return NSURLCache.castFromPointer(_ret, retain: true, release: true); } @@ -44507,7 +45543,7 @@ class NSURLCache extends objc.NSObject { /// becoming unexpectedly unretrievable. /// @result the shared NSURLCache instance. static void setSharedURLCache(NSURLCache value) { - return _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( _class_NSURLCache, _sel_setSharedURLCache_, value.ref.pointer); } @@ -44528,7 +45564,7 @@ class NSURLCache extends objc.NSObject { DartNSUInteger memoryCapacity, DartNSUInteger diskCapacity, objc.NSString? path) { - final _ret = _objc_msgSend_1dlfwfh( + final _ret = _objc_msgSend_1dqnse5( this.ref.retainAndReturnPointer(), _sel_initWithMemoryCapacity_diskCapacity_diskPath_, memoryCapacity, @@ -44548,7 +45584,7 @@ class NSURLCache extends objc.NSObject { DartNSUInteger memoryCapacity, DartNSUInteger diskCapacity, objc.NSURL? directoryURL) { - final _ret = _objc_msgSend_1dlfwfh( + final _ret = _objc_msgSend_1dqnse5( this.ref.retainAndReturnPointer(), _sel_initWithMemoryCapacity_diskCapacity_directoryURL_, memoryCapacity, @@ -44568,7 +45604,7 @@ class NSURLCache extends objc.NSObject { /// request, or nil if there is no NSCachedURLResponse stored with the /// given request. NSCachedURLResponse? cachedResponseForRequest_(NSURLRequest request) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_cachedResponseForRequest_, request.ref.pointer); return _ret.address == 0 ? null @@ -44584,7 +45620,7 @@ class NSURLCache extends objc.NSObject { /// @param request the NSURLRequest to use as a key for the storage. void storeCachedResponse_forRequest_( NSCachedURLResponse cachedResponse, NSURLRequest request) { - _objc_msgSend_wjvic9(this.ref.pointer, _sel_storeCachedResponse_forRequest_, + _objc_msgSend_pfv6jd(this.ref.pointer, _sel_storeCachedResponse_forRequest_, cachedResponse.ref.pointer, request.ref.pointer); } @@ -44596,8 +45632,8 @@ class NSURLCache extends objc.NSObject { /// stored with the given request. /// @param request the NSURLRequest to use as a key for the lookup. void removeCachedResponseForRequest_(NSURLRequest request) { - _objc_msgSend_1jdvcbf(this.ref.pointer, - _sel_removeCachedResponseForRequest_, request.ref.pointer); + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_removeCachedResponseForRequest_, + request.ref.pointer); } /// ! @@ -44612,8 +45648,8 @@ class NSURLCache extends objc.NSObject { /// @method removeCachedResponsesSince: /// @abstract Clears the given cache of any cached responses since the provided date. void removeCachedResponsesSinceDate_(objc.NSDate date) { - _objc_msgSend_1jdvcbf(this.ref.pointer, - _sel_removeCachedResponsesSinceDate_, date.ref.pointer); + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_removeCachedResponsesSinceDate_, + date.ref.pointer); } /// ! @@ -44629,8 +45665,7 @@ class NSURLCache extends objc.NSObject { /// @discussion At the time this call is made, the in-memory cache will truncate its contents to the size given, if necessary. /// @result The in-memory capacity, measured in bytes, for the receiver. set memoryCapacity(DartNSUInteger value) { - return _objc_msgSend_1i9r4xy( - this.ref.pointer, _sel_setMemoryCapacity_, value); + _objc_msgSend_1i9r4xy(this.ref.pointer, _sel_setMemoryCapacity_, value); } /// ! @@ -44644,8 +45679,7 @@ class NSURLCache extends objc.NSObject { /// @abstract The on-disk capacity of the receiver. /// @discussion The on-disk capacity, measured in bytes, for the receiver. On mutation the on-disk cache will truncate its contents to the size given, if necessary. set diskCapacity(DartNSUInteger value) { - return _objc_msgSend_1i9r4xy( - this.ref.pointer, _sel_setDiskCapacity_, value); + _objc_msgSend_1i9r4xy(this.ref.pointer, _sel_setDiskCapacity_, value); } /// ! @@ -44671,44 +45705,44 @@ class NSURLCache extends objc.NSObject { /// init NSURLCache init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSURLCache.castFromPointer(_ret, retain: false, release: true); } /// new static NSURLCache new1() { - final _ret = _objc_msgSend_1x359cv(_class_NSURLCache, _sel_new); + final _ret = _objc_msgSend_151sglz(_class_NSURLCache, _sel_new); return NSURLCache.castFromPointer(_ret, retain: false, release: true); } /// allocWithZone: static NSURLCache allocWithZone_(ffi.Pointer<_NSZone> zone) { final _ret = - _objc_msgSend_hzlb60(_class_NSURLCache, _sel_allocWithZone_, zone); + _objc_msgSend_1cwp428(_class_NSURLCache, _sel_allocWithZone_, zone); return NSURLCache.castFromPointer(_ret, retain: false, release: true); } /// alloc static NSURLCache alloc() { - final _ret = _objc_msgSend_1x359cv(_class_NSURLCache, _sel_alloc); + final _ret = _objc_msgSend_151sglz(_class_NSURLCache, _sel_alloc); return NSURLCache.castFromPointer(_ret, retain: false, release: true); } /// self NSURLCache self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSURLCache.castFromPointer(_ret, retain: true, release: true); } /// retain NSURLCache retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSURLCache.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSURLCache autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSURLCache.castFromPointer(_ret, retain: true, release: true); } } @@ -44718,7 +45752,7 @@ typedef DartNSNotificationName = objc.NSString; late final _class_NSNotification = objc.getClass("NSNotification"); late final _sel_notificationWithName_object_ = objc.registerName("notificationWithName:object:"); -final _objc_msgSend_rsfdlh = objc.msgSendPointer +final _objc_msgSend_15qeuct = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -44734,7 +45768,7 @@ final _objc_msgSend_rsfdlh = objc.msgSendPointer ffi.Pointer)>(); late final _sel_notificationWithName_object_userInfo_ = objc.registerName("notificationWithName:object:userInfo:"); -final _objc_msgSend_582s3n = objc.msgSendPointer +final _objc_msgSend_11spmsz = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -44756,7 +45790,7 @@ extension NSNotificationCreation on objc.NSNotification { /// notificationWithName:object: static objc.NSNotification notificationWithName_object_( DartNSNotificationName aName, objc.ObjCObjectBase? anObject) { - final _ret = _objc_msgSend_rsfdlh( + final _ret = _objc_msgSend_15qeuct( _class_NSNotification, _sel_notificationWithName_object_, aName.ref.pointer, @@ -44770,7 +45804,7 @@ extension NSNotificationCreation on objc.NSNotification { DartNSNotificationName aName, objc.ObjCObjectBase? anObject, objc.NSDictionary? aUserInfo) { - final _ret = _objc_msgSend_582s3n( + final _ret = _objc_msgSend_11spmsz( _class_NSNotification, _sel_notificationWithName_object_userInfo_, aName.ref.pointer, @@ -44783,7 +45817,7 @@ extension NSNotificationCreation on objc.NSNotification { /// init objc.NSNotification init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return objc.NSNotification.castFromPointer(_ret, retain: false, release: true); } @@ -44792,7 +45826,7 @@ extension NSNotificationCreation on objc.NSNotification { late final _class_NSDate = objc.getClass("NSDate"); late final _sel_timeIntervalSinceDate_ = objc.registerName("timeIntervalSinceDate:"); -final _objc_msgSend_hlyk7w = objc.msgSendPointer +final _objc_msgSend_mabicu = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Double Function( @@ -44802,7 +45836,7 @@ final _objc_msgSend_hlyk7w = objc.msgSendPointer .asFunction< double Function(ffi.Pointer, ffi.Pointer, ffi.Pointer)>(); -final _objc_msgSend_hlyk7wFpret = objc.msgSendFpretPointer +final _objc_msgSend_mabicuFpret = objc.msgSendFpretPointer .cast< ffi.NativeFunction< ffi.Double Function( @@ -44817,7 +45851,7 @@ late final _sel_timeIntervalSinceNow = late final _sel_timeIntervalSince1970 = objc.registerName("timeIntervalSince1970"); late final _sel_addTimeInterval_ = objc.registerName("addTimeInterval:"); -final _objc_msgSend_1x911p2 = objc.msgSendPointer +final _objc_msgSend_oa8mke = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -44830,7 +45864,7 @@ late final _sel_dateByAddingTimeInterval_ = late final _sel_earlierDate_ = objc.registerName("earlierDate:"); late final _sel_laterDate_ = objc.registerName("laterDate:"); late final _sel_compare_ = objc.registerName("compare:"); -final _objc_msgSend_1wpduvy = objc.msgSendPointer +final _objc_msgSend_1ym6zyw = objc.msgSendPointer .cast< ffi.NativeFunction< NSInteger Function( @@ -44852,9 +45886,9 @@ extension NSExtendedDate on objc.NSDate { /// timeIntervalSinceDate: DartNSTimeInterval timeIntervalSinceDate_(objc.NSDate anotherDate) { return objc.useMsgSendVariants - ? _objc_msgSend_hlyk7wFpret(this.ref.pointer, + ? _objc_msgSend_mabicuFpret(this.ref.pointer, _sel_timeIntervalSinceDate_, anotherDate.ref.pointer) - : _objc_msgSend_hlyk7w(this.ref.pointer, _sel_timeIntervalSinceDate_, + : _objc_msgSend_mabicu(this.ref.pointer, _sel_timeIntervalSinceDate_, anotherDate.ref.pointer); } @@ -44877,53 +45911,53 @@ extension NSExtendedDate on objc.NSDate { /// addTimeInterval: objc.ObjCObjectBase addTimeInterval_(DartNSTimeInterval seconds) { final _ret = - _objc_msgSend_1x911p2(this.ref.pointer, _sel_addTimeInterval_, seconds); + _objc_msgSend_oa8mke(this.ref.pointer, _sel_addTimeInterval_, seconds); return objc.ObjCObjectBase(_ret, retain: true, release: true); } /// dateByAddingTimeInterval: objc.NSDate dateByAddingTimeInterval_(DartNSTimeInterval ti) { - final _ret = _objc_msgSend_1x911p2( + final _ret = _objc_msgSend_oa8mke( this.ref.pointer, _sel_dateByAddingTimeInterval_, ti); return objc.NSDate.castFromPointer(_ret, retain: true, release: true); } /// earlierDate: objc.NSDate earlierDate_(objc.NSDate anotherDate) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_earlierDate_, anotherDate.ref.pointer); return objc.NSDate.castFromPointer(_ret, retain: true, release: true); } /// laterDate: objc.NSDate laterDate_(objc.NSDate anotherDate) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_laterDate_, anotherDate.ref.pointer); return objc.NSDate.castFromPointer(_ret, retain: true, release: true); } /// compare: objc.NSComparisonResult compare_(objc.NSDate other) { - final _ret = _objc_msgSend_1wpduvy( + final _ret = _objc_msgSend_1ym6zyw( this.ref.pointer, _sel_compare_, other.ref.pointer); return objc.NSComparisonResult.fromValue(_ret); } /// isEqualToDate: bool isEqualToDate_(objc.NSDate otherDate) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( this.ref.pointer, _sel_isEqualToDate_, otherDate.ref.pointer); } /// description objc.NSString get description { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_description); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_description); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// descriptionWithLocale: objc.NSString descriptionWithLocale_(objc.ObjCObjectBase? locale) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_descriptionWithLocale_, locale?.ref.pointer ?? ffi.nullptr); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -44947,7 +45981,7 @@ late final _sel_dateWithTimeIntervalSince1970_ = objc.registerName("dateWithTimeIntervalSince1970:"); late final _sel_dateWithTimeInterval_sinceDate_ = objc.registerName("dateWithTimeInterval:sinceDate:"); -final _objc_msgSend_xh7c7e = objc.msgSendPointer +final _objc_msgSend_1ozwf6k = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -44975,13 +46009,13 @@ late final _sel_initWithTimeInterval_sinceDate_ = extension NSDateCreation on objc.NSDate { /// date static objc.NSDate date() { - final _ret = _objc_msgSend_1x359cv(_class_NSDate, _sel_date); + final _ret = _objc_msgSend_151sglz(_class_NSDate, _sel_date); return objc.NSDate.castFromPointer(_ret, retain: true, release: true); } /// dateWithTimeIntervalSinceNow: static objc.NSDate dateWithTimeIntervalSinceNow_(DartNSTimeInterval secs) { - final _ret = _objc_msgSend_1x911p2( + final _ret = _objc_msgSend_oa8mke( _class_NSDate, _sel_dateWithTimeIntervalSinceNow_, secs); return objc.NSDate.castFromPointer(_ret, retain: true, release: true); } @@ -44989,14 +46023,14 @@ extension NSDateCreation on objc.NSDate { /// dateWithTimeIntervalSinceReferenceDate: static objc.NSDate dateWithTimeIntervalSinceReferenceDate_( DartNSTimeInterval ti) { - final _ret = _objc_msgSend_1x911p2( + final _ret = _objc_msgSend_oa8mke( _class_NSDate, _sel_dateWithTimeIntervalSinceReferenceDate_, ti); return objc.NSDate.castFromPointer(_ret, retain: true, release: true); } /// dateWithTimeIntervalSince1970: static objc.NSDate dateWithTimeIntervalSince1970_(DartNSTimeInterval secs) { - final _ret = _objc_msgSend_1x911p2( + final _ret = _objc_msgSend_oa8mke( _class_NSDate, _sel_dateWithTimeIntervalSince1970_, secs); return objc.NSDate.castFromPointer(_ret, retain: true, release: true); } @@ -45004,39 +46038,39 @@ extension NSDateCreation on objc.NSDate { /// dateWithTimeInterval:sinceDate: static objc.NSDate dateWithTimeInterval_sinceDate_( DartNSTimeInterval secsToBeAdded, objc.NSDate date) { - final _ret = _objc_msgSend_xh7c7e(_class_NSDate, + final _ret = _objc_msgSend_1ozwf6k(_class_NSDate, _sel_dateWithTimeInterval_sinceDate_, secsToBeAdded, date.ref.pointer); return objc.NSDate.castFromPointer(_ret, retain: true, release: true); } /// distantFuture static objc.NSDate getDistantFuture() { - final _ret = _objc_msgSend_1x359cv(_class_NSDate, _sel_distantFuture); + final _ret = _objc_msgSend_151sglz(_class_NSDate, _sel_distantFuture); return objc.NSDate.castFromPointer(_ret, retain: true, release: true); } /// distantPast static objc.NSDate getDistantPast() { - final _ret = _objc_msgSend_1x359cv(_class_NSDate, _sel_distantPast); + final _ret = _objc_msgSend_151sglz(_class_NSDate, _sel_distantPast); return objc.NSDate.castFromPointer(_ret, retain: true, release: true); } /// now static objc.NSDate getNow() { - final _ret = _objc_msgSend_1x359cv(_class_NSDate, _sel_now); + final _ret = _objc_msgSend_151sglz(_class_NSDate, _sel_now); return objc.NSDate.castFromPointer(_ret, retain: true, release: true); } /// initWithTimeIntervalSinceNow: objc.NSDate initWithTimeIntervalSinceNow_(DartNSTimeInterval secs) { - final _ret = _objc_msgSend_1x911p2(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_oa8mke(this.ref.retainAndReturnPointer(), _sel_initWithTimeIntervalSinceNow_, secs); return objc.NSDate.castFromPointer(_ret, retain: false, release: true); } /// initWithTimeIntervalSince1970: objc.NSDate initWithTimeIntervalSince1970_(DartNSTimeInterval secs) { - final _ret = _objc_msgSend_1x911p2(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_oa8mke(this.ref.retainAndReturnPointer(), _sel_initWithTimeIntervalSince1970_, secs); return objc.NSDate.castFromPointer(_ret, retain: false, release: true); } @@ -45044,7 +46078,7 @@ extension NSDateCreation on objc.NSDate { /// initWithTimeInterval:sinceDate: objc.NSDate initWithTimeInterval_sinceDate_( DartNSTimeInterval secsToBeAdded, objc.NSDate date) { - final _ret = _objc_msgSend_xh7c7e(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1ozwf6k(this.ref.retainAndReturnPointer(), _sel_initWithTimeInterval_sinceDate_, secsToBeAdded, date.ref.pointer); return objc.NSDate.castFromPointer(_ret, retain: false, release: true); } @@ -45081,14 +46115,14 @@ extension NSMutableHTTPURLRequest on NSMutableURLRequest { /// ! /// @abstract Sets the HTTP request method of the receiver. objc.NSString get HTTPMethod { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_HTTPMethod); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_HTTPMethod); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// ! /// @abstract Sets the HTTP request method of the receiver. set HTTPMethod(objc.NSString value) { - return _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_setHTTPMethod_, value.ref.pointer); } @@ -45104,7 +46138,7 @@ extension NSMutableHTTPURLRequest on NSMutableURLRequest { /// message, the key-value pair is skipped. objc.NSDictionary? get allHTTPHeaderFields { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_allHTTPHeaderFields); + _objc_msgSend_151sglz(this.ref.pointer, _sel_allHTTPHeaderFields); return _ret.address == 0 ? null : objc.NSDictionary.castFromPointer(_ret, retain: true, release: true); @@ -45121,7 +46155,7 @@ extension NSMutableHTTPURLRequest on NSMutableURLRequest { /// the key or value for a key-value pair answers NO when sent this /// message, the key-value pair is skipped. set allHTTPHeaderFields(objc.NSDictionary? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_setAllHTTPHeaderFields_, + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setAllHTTPHeaderFields_, value?.ref.pointer ?? ffi.nullptr); } @@ -45135,7 +46169,7 @@ extension NSMutableHTTPURLRequest on NSMutableURLRequest { /// @param value the header field value. /// @param field the header field name (case-insensitive). void setValue_forHTTPHeaderField_(objc.NSString? value, objc.NSString field) { - _objc_msgSend_wjvic9(this.ref.pointer, _sel_setValue_forHTTPHeaderField_, + _objc_msgSend_pfv6jd(this.ref.pointer, _sel_setValue_forHTTPHeaderField_, value?.ref.pointer ?? ffi.nullptr, field.ref.pointer); } @@ -45153,7 +46187,7 @@ extension NSMutableHTTPURLRequest on NSMutableURLRequest { /// @param value the header field value. /// @param field the header field name (case-insensitive). void addValue_forHTTPHeaderField_(objc.NSString value, objc.NSString field) { - _objc_msgSend_wjvic9(this.ref.pointer, _sel_addValue_forHTTPHeaderField_, + _objc_msgSend_pfv6jd(this.ref.pointer, _sel_addValue_forHTTPHeaderField_, value.ref.pointer, field.ref.pointer); } @@ -45162,7 +46196,7 @@ extension NSMutableHTTPURLRequest on NSMutableURLRequest { /// @discussion This data is sent as the message body of the request, as /// in done in an HTTP POST request. objc.NSData? get HTTPBody { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_HTTPBody); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_HTTPBody); return _ret.address == 0 ? null : objc.NSData.castFromPointer(_ret, retain: true, release: true); @@ -45173,7 +46207,7 @@ extension NSMutableHTTPURLRequest on NSMutableURLRequest { /// @discussion This data is sent as the message body of the request, as /// in done in an HTTP POST request. set HTTPBody(objc.NSData? value) { - return _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_setHTTPBody_, value?.ref.pointer ?? ffi.nullptr); } @@ -45185,7 +46219,7 @@ extension NSMutableHTTPURLRequest on NSMutableURLRequest { /// and the body data (set by setHTTPBody:, above) are mutually exclusive /// - setting one will clear the other. objc.NSInputStream? get HTTPBodyStream { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_HTTPBodyStream); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_HTTPBodyStream); return _ret.address == 0 ? null : objc.NSInputStream.castFromPointer(_ret, retain: true, release: true); @@ -45199,7 +46233,7 @@ extension NSMutableHTTPURLRequest on NSMutableURLRequest { /// and the body data (set by setHTTPBody:, above) are mutually exclusive /// - setting one will clear the other. set HTTPBodyStream(objc.NSInputStream? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_setHTTPBodyStream_, + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setHTTPBodyStream_, value?.ref.pointer ?? ffi.nullptr); } @@ -45222,7 +46256,7 @@ extension NSMutableHTTPURLRequest on NSMutableURLRequest { /// stored to the cookie manager by default. /// NOTE: In releases prior to 10.3, this value is ignored set HTTPShouldHandleCookies(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setHTTPShouldHandleCookies_, value); } @@ -45261,7 +46295,7 @@ extension NSMutableHTTPURLRequest on NSMutableURLRequest { /// pipelining (disconnecting, sending resources misordered, omitting part of /// a resource, etc.). set HTTPShouldUsePipelining(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setHTTPShouldUsePipelining_, value); } } @@ -45315,6 +46349,8 @@ final _objc_msgSend_1nw1jep = objc.msgSendPointer ffi.Pointer, int)>(); late final _sel_setRequiresDNSSECValidation_ = objc.registerName("setRequiresDNSSECValidation:"); +late final _sel_setAllowsPersistentDNS_ = + objc.registerName("setAllowsPersistentDNS:"); /// ! /// @class NSMutableURLRequest @@ -45360,14 +46396,14 @@ class NSMutableURLRequest extends NSURLRequest { /// Returns whether [obj] is an instance of [NSMutableURLRequest]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( obj.ref.pointer, _sel_isKindOfClass_, _class_NSMutableURLRequest); } /// ! /// @abstract The URL of the receiver. objc.NSURL? get URL { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_URL); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_URL); return _ret.address == 0 ? null : objc.NSURL.castFromPointer(_ret, retain: true, release: true); @@ -45376,7 +46412,7 @@ class NSMutableURLRequest extends NSURLRequest { /// ! /// @abstract The URL of the receiver. set URL(objc.NSURL? value) { - return _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_setURL_, value?.ref.pointer ?? ffi.nullptr); } @@ -45390,8 +46426,7 @@ class NSMutableURLRequest extends NSURLRequest { /// ! /// @abstract The cache policy of the receiver. set cachePolicy(NSURLRequestCachePolicy value) { - return _objc_msgSend_1yjxuv2( - this.ref.pointer, _sel_setCachePolicy_, value.value); + _objc_msgSend_1yjxuv2(this.ref.pointer, _sel_setCachePolicy_, value.value); } /// ! @@ -45425,8 +46460,7 @@ class NSMutableURLRequest extends NSURLRequest { /// is considered to have timed out. This timeout interval is measured /// in seconds. set timeoutInterval(DartNSTimeInterval value) { - return _objc_msgSend_hwm8nu( - this.ref.pointer, _sel_setTimeoutInterval_, value); + _objc_msgSend_hwm8nu(this.ref.pointer, _sel_setTimeoutInterval_, value); } /// ! @@ -45439,7 +46473,7 @@ class NSMutableURLRequest extends NSURLRequest { /// as a sub-resource of a user-specified URL, and possibly other things /// in the future. objc.NSURL? get mainDocumentURL { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_mainDocumentURL); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_mainDocumentURL); return _ret.address == 0 ? null : objc.NSURL.castFromPointer(_ret, retain: true, release: true); @@ -45455,7 +46489,7 @@ class NSMutableURLRequest extends NSURLRequest { /// as a sub-resource of a user-specified URL, and possibly other things /// in the future. set mainDocumentURL(objc.NSURL? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_setMainDocumentURL_, + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setMainDocumentURL_, value?.ref.pointer ?? ffi.nullptr); } @@ -45474,7 +46508,7 @@ class NSMutableURLRequest extends NSURLRequest { /// @discussion This method is used to provide the network layers with a hint as to the purpose /// of the request. Most clients should not need to use this method. set networkServiceType(NSURLRequestNetworkServiceType value) { - return _objc_msgSend_1mse4s1( + _objc_msgSend_1mse4s1( this.ref.pointer, _sel_setNetworkServiceType_, value.value); } @@ -45493,7 +46527,7 @@ class NSMutableURLRequest extends NSURLRequest { /// @discussion NO if the receiver should not be allowed to use the built in /// cellular radios to satisfy the request, YES otherwise. The default is YES. set allowsCellularAccess(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setAllowsCellularAccess_, value); } @@ -45513,7 +46547,7 @@ class NSMutableURLRequest extends NSURLRequest { /// @discussion NO if the receiver should not be allowed to use an interface marked as expensive to /// satisfy the request, YES otherwise. set allowsExpensiveNetworkAccess(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setAllowsExpensiveNetworkAccess_, value); } @@ -45533,7 +46567,7 @@ class NSMutableURLRequest extends NSURLRequest { /// @discussion NO if the receiver should not be allowed to use an interface marked as constrained to /// satisfy the request, YES otherwise. set allowsConstrainedNetworkAccess(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setAllowsConstrainedNetworkAccess_, value); } @@ -45552,7 +46586,7 @@ class NSMutableURLRequest extends NSURLRequest { /// @result YES if server endpoint is known to support HTTP/3. Defaults to NO. /// The default may be YES in a future OS update. set assumesHTTP3Capable(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setAssumesHTTP3Capable_, value); } @@ -45570,8 +46604,7 @@ class NSMutableURLRequest extends NSURLRequest { /// @discussion Set to NSURLRequestAttributionUser if the URL was specified by the /// user. Defaults to NSURLRequestAttributionDeveloper. set attribution(NSURLRequestAttribution value) { - return _objc_msgSend_1nw1jep( - this.ref.pointer, _sel_setAttribution_, value.value); + _objc_msgSend_1nw1jep(this.ref.pointer, _sel_setAttribution_, value.value); } /// ! @@ -45588,10 +46621,31 @@ class NSMutableURLRequest extends NSURLRequest { /// @discussion YES, if the DNS lookup for this request should require DNSSEC validation, /// No otherwise. Defaults to NO. set requiresDNSSECValidation(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setRequiresDNSSECValidation_, value); } + /// ! + /// @abstract Allows storing and usage of DNS answers, potentially beyond TTL expiry, + /// in a persistent per-process cache. This should only be set for hostnames whose resolutions + /// are not expected to change across networks. + /// @discussion YES, if the DNS lookup for this request is allowed to use a persistent per-process cache, + /// NO otherwise. Defaults to NO. + bool get allowsPersistentDNS { + return _objc_msgSend_91o635(this.ref.pointer, _sel_allowsPersistentDNS); + } + + /// ! + /// @abstract Allows storing and usage of DNS answers, potentially beyond TTL expiry, + /// in a persistent per-process cache. This should only be set for hostnames whose resolutions + /// are not expected to change across networks. + /// @discussion YES, if the DNS lookup for this request is allowed to use a persistent per-process cache, + /// NO otherwise. Defaults to NO. + set allowsPersistentDNS(bool value) { + _objc_msgSend_1s56lr9( + this.ref.pointer, _sel_setAllowsPersistentDNS_, value); + } + /// ! /// @method requestWithURL: /// @abstract Allocates and initializes an NSURLRequest with the given @@ -45602,7 +46656,7 @@ class NSMutableURLRequest extends NSURLRequest { /// @param URL The URL for the request. /// @result A newly-created and autoreleased NSURLRequest instance. static NSMutableURLRequest requestWithURL_(objc.NSURL URL) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSMutableURLRequest, _sel_requestWithURL_, URL.ref.pointer); return NSMutableURLRequest.castFromPointer(_ret, retain: true, release: true); @@ -45628,7 +46682,7 @@ class NSMutableURLRequest extends NSURLRequest { objc.NSURL URL, NSURLRequestCachePolicy cachePolicy, DartNSTimeInterval timeoutInterval) { - final _ret = _objc_msgSend_3phu9v( + final _ret = _objc_msgSend_1ajs603( _class_NSMutableURLRequest, _sel_requestWithURL_cachePolicy_timeoutInterval_, URL.ref.pointer, @@ -45647,7 +46701,7 @@ class NSMutableURLRequest extends NSURLRequest { /// @param URL The URL for the request. /// @result An initialized NSURLRequest. NSMutableURLRequest initWithURL_(objc.NSURL URL) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.retainAndReturnPointer(), _sel_initWithURL_, URL.ref.pointer); return NSMutableURLRequest.castFromPointer(_ret, retain: false, release: true); @@ -45667,7 +46721,7 @@ class NSMutableURLRequest extends NSURLRequest { /// @result An initialized NSURLRequest. NSMutableURLRequest initWithURL_cachePolicy_timeoutInterval_(objc.NSURL URL, NSURLRequestCachePolicy cachePolicy, DartNSTimeInterval timeoutInterval) { - final _ret = _objc_msgSend_3phu9v( + final _ret = _objc_msgSend_1ajs603( this.ref.retainAndReturnPointer(), _sel_initWithURL_cachePolicy_timeoutInterval_, URL.ref.pointer, @@ -45680,21 +46734,21 @@ class NSMutableURLRequest extends NSURLRequest { /// init NSMutableURLRequest init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSMutableURLRequest.castFromPointer(_ret, retain: false, release: true); } /// new static NSMutableURLRequest new1() { - final _ret = _objc_msgSend_1x359cv(_class_NSMutableURLRequest, _sel_new); + final _ret = _objc_msgSend_151sglz(_class_NSMutableURLRequest, _sel_new); return NSMutableURLRequest.castFromPointer(_ret, retain: false, release: true); } /// allocWithZone: static NSMutableURLRequest allocWithZone_(ffi.Pointer<_NSZone> zone) { - final _ret = _objc_msgSend_hzlb60( + final _ret = _objc_msgSend_1cwp428( _class_NSMutableURLRequest, _sel_allocWithZone_, zone); return NSMutableURLRequest.castFromPointer(_ret, retain: false, release: true); @@ -45702,35 +46756,35 @@ class NSMutableURLRequest extends NSURLRequest { /// alloc static NSMutableURLRequest alloc() { - final _ret = _objc_msgSend_1x359cv(_class_NSMutableURLRequest, _sel_alloc); + final _ret = _objc_msgSend_151sglz(_class_NSMutableURLRequest, _sel_alloc); return NSMutableURLRequest.castFromPointer(_ret, retain: false, release: true); } /// self NSMutableURLRequest self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSMutableURLRequest.castFromPointer(_ret, retain: true, release: true); } /// retain NSMutableURLRequest retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSMutableURLRequest.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSMutableURLRequest autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSMutableURLRequest.castFromPointer(_ret, retain: true, release: true); } /// initWithCoder: NSMutableURLRequest? initWithCoder_(objc.NSCoder coder) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithCoder_, coder.ref.pointer); return _ret.address == 0 ? null @@ -45784,7 +46838,7 @@ late final _class_NSURLResponse = objc.getClass("NSURLResponse"); late final _sel_initWithURL_MIMEType_expectedContentLength_textEncodingName_ = objc.registerName( "initWithURL:MIMEType:expectedContentLength:textEncodingName:"); -final _objc_msgSend_13tl325 = objc.msgSendPointer +final _objc_msgSend_l9ppnx = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -45833,7 +46887,7 @@ class NSURLResponse extends objc.NSObject { /// Returns whether [obj] is an instance of [NSURLResponse]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( obj.ref.pointer, _sel_isKindOfClass_, _class_NSURLResponse); } @@ -45851,7 +46905,7 @@ class NSURLResponse extends objc.NSObject { objc.NSString? MIMEType, DartNSInteger length, objc.NSString? name) { - final _ret = _objc_msgSend_13tl325( + final _ret = _objc_msgSend_l9ppnx( this.ref.retainAndReturnPointer(), _sel_initWithURL_MIMEType_expectedContentLength_textEncodingName_, URL.ref.pointer, @@ -45865,7 +46919,7 @@ class NSURLResponse extends objc.NSObject { /// @abstract Returns the URL of the receiver. /// @result The URL of the receiver. objc.NSURL? get URL { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_URL); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_URL); return _ret.address == 0 ? null : objc.NSURL.castFromPointer(_ret, retain: true, release: true); @@ -45881,7 +46935,7 @@ class NSURLResponse extends objc.NSObject { /// be made if the origin source did not report any such information. /// @result The MIME type of the receiver. objc.NSString? get MIMEType { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_MIMEType); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_MIMEType); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -45912,7 +46966,7 @@ class NSURLResponse extends objc.NSObject { /// @result The name of the text encoding of the receiver, or nil if no /// text encoding was specified. objc.NSString? get textEncodingName { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_textEncodingName); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_textEncodingName); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -45930,7 +46984,7 @@ class NSURLResponse extends objc.NSObject { /// @result A suggested filename to use if saving the resource to disk. objc.NSString? get suggestedFilename { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_suggestedFilename); + _objc_msgSend_151sglz(this.ref.pointer, _sel_suggestedFilename); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -45939,44 +46993,44 @@ class NSURLResponse extends objc.NSObject { /// init NSURLResponse init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSURLResponse.castFromPointer(_ret, retain: false, release: true); } /// new static NSURLResponse new1() { - final _ret = _objc_msgSend_1x359cv(_class_NSURLResponse, _sel_new); + final _ret = _objc_msgSend_151sglz(_class_NSURLResponse, _sel_new); return NSURLResponse.castFromPointer(_ret, retain: false, release: true); } /// allocWithZone: static NSURLResponse allocWithZone_(ffi.Pointer<_NSZone> zone) { final _ret = - _objc_msgSend_hzlb60(_class_NSURLResponse, _sel_allocWithZone_, zone); + _objc_msgSend_1cwp428(_class_NSURLResponse, _sel_allocWithZone_, zone); return NSURLResponse.castFromPointer(_ret, retain: false, release: true); } /// alloc static NSURLResponse alloc() { - final _ret = _objc_msgSend_1x359cv(_class_NSURLResponse, _sel_alloc); + final _ret = _objc_msgSend_151sglz(_class_NSURLResponse, _sel_alloc); return NSURLResponse.castFromPointer(_ret, retain: false, release: true); } /// self NSURLResponse self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSURLResponse.castFromPointer(_ret, retain: true, release: true); } /// retain NSURLResponse retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSURLResponse.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSURLResponse autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSURLResponse.castFromPointer(_ret, retain: true, release: true); } @@ -45988,13 +47042,13 @@ class NSURLResponse extends objc.NSObject { /// encodeWithCoder: void encodeWithCoder_(objc.NSCoder coder) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_encodeWithCoder_, coder.ref.pointer); } /// initWithCoder: NSURLResponse? initWithCoder_(objc.NSCoder coder) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithCoder_, coder.ref.pointer); return _ret.address == 0 ? null @@ -46236,7 +47290,7 @@ class NSURLSessionTask extends objc.NSObject { /// Returns whether [obj] is an instance of [NSURLSessionTask]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( obj.ref.pointer, _sel_isKindOfClass_, _class_NSURLSessionTask); } @@ -46247,7 +47301,7 @@ class NSURLSessionTask extends objc.NSObject { /// may be nil if this is a stream task NSURLRequest? get originalRequest { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_originalRequest); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_originalRequest); return _ret.address == 0 ? null : NSURLRequest.castFromPointer(_ret, retain: true, release: true); @@ -46255,7 +47309,7 @@ class NSURLSessionTask extends objc.NSObject { /// may differ from originalRequest due to http server redirection NSURLRequest? get currentRequest { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_currentRequest); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_currentRequest); return _ret.address == 0 ? null : NSURLRequest.castFromPointer(_ret, retain: true, release: true); @@ -46263,7 +47317,7 @@ class NSURLSessionTask extends objc.NSObject { /// may be nil if no response has been received NSURLResponse? get response { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_response); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_response); return _ret.address == 0 ? null : NSURLResponse.castFromPointer(_ret, retain: true, release: true); @@ -46277,7 +47331,7 @@ class NSURLSessionTask extends objc.NSObject { /// Delegate is strongly referenced until the task completes, after which it is /// reset to `nil`. objc.ObjCObjectBase? get delegate { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_delegate); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_delegate); return _ret.address == 0 ? null : objc.ObjCObjectBase(_ret, retain: true, release: true); @@ -46291,13 +47345,13 @@ class NSURLSessionTask extends objc.NSObject { /// Delegate is strongly referenced until the task completes, after which it is /// reset to `nil`. set delegate(objc.ObjCObjectBase? value) { - return _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_setDelegate_, value?.ref.pointer ?? ffi.nullptr); } /// progress NSProgress get progress { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_progress); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_progress); return NSProgress.castFromPointer(_ret, retain: true, release: true); } @@ -46308,7 +47362,7 @@ class NSURLSessionTask extends objc.NSObject { /// effect for tasks created from other session types. objc.NSDate? get earliestBeginDate { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_earliestBeginDate); + _objc_msgSend_151sglz(this.ref.pointer, _sel_earliestBeginDate); return _ret.address == 0 ? null : objc.NSDate.castFromPointer(_ret, retain: true, release: true); @@ -46320,7 +47374,7 @@ class NSURLSessionTask extends objc.NSObject { /// Only applies to tasks created from background NSURLSession instances; has no /// effect for tasks created from other session types. set earliestBeginDate(objc.NSDate? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_setEarliestBeginDate_, + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setEarliestBeginDate_, value?.ref.pointer ?? ffi.nullptr); } @@ -46336,7 +47390,7 @@ class NSURLSessionTask extends objc.NSObject { /// be sent and received by this task. These values are used by system scheduling /// policy. If unspecified, NSURLSessionTransferSizeUnknown is used. set countOfBytesClientExpectsToSend(int value) { - return _objc_msgSend_17gvxvj( + _objc_msgSend_17gvxvj( this.ref.pointer, _sel_setCountOfBytesClientExpectsToSend_, value); } @@ -46348,7 +47402,7 @@ class NSURLSessionTask extends objc.NSObject { /// setCountOfBytesClientExpectsToReceive: set countOfBytesClientExpectsToReceive(int value) { - return _objc_msgSend_17gvxvj( + _objc_msgSend_17gvxvj( this.ref.pointer, _sel_setCountOfBytesClientExpectsToReceive_, value); } @@ -46377,7 +47431,7 @@ class NSURLSessionTask extends objc.NSObject { /// The taskDescription property is available for the developer to /// provide a descriptive label for the task. objc.NSString? get taskDescription { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_taskDescription); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_taskDescription); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -46386,7 +47440,7 @@ class NSURLSessionTask extends objc.NSObject { /// The taskDescription property is available for the developer to /// provide a descriptive label for the task. set taskDescription(objc.NSString? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_setTaskDescription_, + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setTaskDescription_, value?.ref.pointer ?? ffi.nullptr); } @@ -46408,7 +47462,7 @@ class NSURLSessionTask extends objc.NSObject { /// The error, if any, delivered via -URLSession:task:didCompleteWithError: /// This property will be nil in the event that no error occurred. objc.NSError? get error { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_error); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_error); return _ret.address == 0 ? null : objc.NSError.castFromPointer(_ret, retain: true, release: true); @@ -46463,7 +47517,7 @@ class NSURLSessionTask extends objc.NSObject { /// priority levels are provided: NSURLSessionTaskPriorityLow and /// NSURLSessionTaskPriorityHigh, but use is not restricted to these. set priority(double value) { - return _objc_msgSend_v5hmet(this.ref.pointer, _sel_setPriority_, value); + _objc_msgSend_v5hmet(this.ref.pointer, _sel_setPriority_, value); } /// Provides a hint indicating if incremental delivery of a partial response body @@ -46488,51 +47542,51 @@ class NSURLSessionTask extends objc.NSObject { /// Defaults to true unless this task is created with completion-handler based /// convenience methods, or if it is a download task. set prefersIncrementalDelivery(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setPrefersIncrementalDelivery_, value); } /// init NSURLSessionTask init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSURLSessionTask.castFromPointer(_ret, retain: false, release: true); } /// new static NSURLSessionTask new1() { - final _ret = _objc_msgSend_1x359cv(_class_NSURLSessionTask, _sel_new); + final _ret = _objc_msgSend_151sglz(_class_NSURLSessionTask, _sel_new); return NSURLSessionTask.castFromPointer(_ret, retain: false, release: true); } /// allocWithZone: static NSURLSessionTask allocWithZone_(ffi.Pointer<_NSZone> zone) { - final _ret = _objc_msgSend_hzlb60( + final _ret = _objc_msgSend_1cwp428( _class_NSURLSessionTask, _sel_allocWithZone_, zone); return NSURLSessionTask.castFromPointer(_ret, retain: false, release: true); } /// alloc static NSURLSessionTask alloc() { - final _ret = _objc_msgSend_1x359cv(_class_NSURLSessionTask, _sel_alloc); + final _ret = _objc_msgSend_151sglz(_class_NSURLSessionTask, _sel_alloc); return NSURLSessionTask.castFromPointer(_ret, retain: false, release: true); } /// self NSURLSessionTask self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSURLSessionTask.castFromPointer(_ret, retain: true, release: true); } /// retain NSURLSessionTask retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSURLSessionTask.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSURLSessionTask autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSURLSessionTask.castFromPointer(_ret, retain: true, release: true); } } @@ -46579,6 +47633,39 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_objcObjCObject_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_objcObjCObject_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_objcObjCObject_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_objcObjCObject_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_objcObjCObject_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_objcObjCObject_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock?)>`. abstract final class ObjCBlock_ffiVoid_objcObjCObject { @@ -46641,8 +47728,42 @@ abstract final class ObjCBlock_ffiVoid_objcObjCObject { (ffi.Pointer arg0) => fn(arg0.address == 0 ? null : objc.ObjCObjectBase(arg0, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1jdvcbf(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xtuoz7(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock?)>( + wrapper, + retain: false, + release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock?)> + blocking(void Function(objc.ObjCObjectBase?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_objcObjCObject_blockingCallable.nativeFunction + .cast(), + (ffi.Pointer arg0) => fn(arg0.address == 0 + ? null + : objc.ObjCObjectBase(arg0, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_objcObjCObject_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0) => fn(arg0.address == 0 + ? null + : objc.ObjCObjectBase(arg0, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xtuoz7, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock?)>( wrapper, retain: false, @@ -46672,7 +47793,7 @@ extension NSURLSessionTaskAdditions1 on NSHTTPCookieStorage { /// storeCookies:forTask: void storeCookies_forTask_( objc.ObjCObjectBase cookies, NSURLSessionTask task) { - _objc_msgSend_wjvic9(this.ref.pointer, _sel_storeCookies_forTask_, + _objc_msgSend_pfv6jd(this.ref.pointer, _sel_storeCookies_forTask_, cookies.ref.pointer, task.ref.pointer); } @@ -46681,7 +47802,7 @@ extension NSURLSessionTaskAdditions1 on NSHTTPCookieStorage { NSURLSessionTask task, objc.ObjCBlock?)> completionHandler) { - _objc_msgSend_14pxqbs( + _objc_msgSend_o762yo( this.ref.pointer, _sel_getCookiesForTask_completionHandler_, task.ref.pointer, @@ -46696,7 +47817,7 @@ late final _sel_allObjects = objc.registerName("allObjects"); extension NSExtendedEnumerator on objc.NSEnumerator { /// allObjects objc.ObjCObjectBase get allObjects { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_allObjects); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_allObjects); return objc.ObjCObjectBase(_ret, retain: true, release: true); } } @@ -46709,7 +47830,7 @@ late final _sel_descriptionInStringsFileFormat = objc.registerName("descriptionInStringsFileFormat"); late final _sel_descriptionWithLocale_indent_ = objc.registerName("descriptionWithLocale:indent:"); -final _objc_msgSend_dcd68g = objc.msgSendPointer +final _objc_msgSend_1k4kd9s = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -46729,7 +47850,7 @@ late final _sel_objectEnumerator = objc.registerName("objectEnumerator"); late final _sel_objectsForKeys_notFoundMarker_ = objc.registerName("objectsForKeys:notFoundMarker:"); late final _sel_writeToURL_error_ = objc.registerName("writeToURL:error:"); -final _objc_msgSend_blqzg8 = objc.msgSendPointer +final _objc_msgSend_l9p60w = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Bool Function( @@ -46745,7 +47866,7 @@ final _objc_msgSend_blqzg8 = objc.msgSendPointer ffi.Pointer>)>(); late final _sel_keysSortedByValueUsingSelector_ = objc.registerName("keysSortedByValueUsingSelector:"); -final _objc_msgSend_19hbqky = objc.msgSendPointer +final _objc_msgSend_3ctkt6 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -46844,6 +47965,56 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_bool_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_bool_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2) { + try { + (objc.getBlockClosure(block) as void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer))(arg0, arg1, arg2); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_bool_blockingCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_bool_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_bool_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_bool_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, ffi.Pointer, ffi.Pointer)>`. abstract final class ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_bool { @@ -46917,8 +48088,50 @@ abstract final class ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_bool { ffi.Pointer arg2) => fn(objc.ObjCObjectBase(arg0, retain: false, release: true), objc.ObjCObjectBase(arg1, retain: false, release: true), arg2)); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1krhfwz(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1o83rbn(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>(wrapper, retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> blocking( + void Function( + objc.ObjCObjectBase, objc.ObjCObjectBase, ffi.Pointer) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_bool_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2) => + fn(objc.ObjCObjectBase(arg0, retain: false, release: true), + objc.ObjCObjectBase(arg1, retain: false, release: true), arg2)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_bool_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2) => + fn(objc.ObjCObjectBase(arg0, retain: false, release: true), + objc.ObjCObjectBase(arg1, retain: false, release: true), arg2)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1o83rbn, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function( ffi.Pointer, @@ -46981,7 +48194,7 @@ final _objc_msgSend_yx8yc6 = objc.msgSendPointer ffi.Pointer)>(); late final _sel_keysSortedByValueUsingComparator_ = objc.registerName("keysSortedByValueUsingComparator:"); -final _objc_msgSend_cy99le = objc.msgSendPointer +final _objc_msgSend_nnxkei = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -46993,7 +48206,7 @@ final _objc_msgSend_cy99le = objc.msgSendPointer ffi.Pointer, ffi.Pointer)>(); late final _sel_keysSortedByValueWithOptions_usingComparator_ = objc.registerName("keysSortedByValueWithOptions:usingComparator:"); -final _objc_msgSend_1u2b7ut = objc.msgSendPointer +final _objc_msgSend_1x5ew3h = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -47132,7 +48345,7 @@ late final _sel_keysOfEntriesPassingTest_ = objc.registerName("keysOfEntriesPassingTest:"); late final _sel_keysOfEntriesWithOptions_passingTest_ = objc.registerName("keysOfEntriesWithOptions:passingTest:"); -final _objc_msgSend_hd4f96 = objc.msgSendPointer +final _objc_msgSend_13x5boi = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -47151,39 +48364,39 @@ final _objc_msgSend_hd4f96 = objc.msgSendPointer extension NSExtendedDictionary on objc.NSDictionary { /// allKeys objc.ObjCObjectBase get allKeys { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_allKeys); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_allKeys); return objc.ObjCObjectBase(_ret, retain: true, release: true); } /// allKeysForObject: objc.ObjCObjectBase allKeysForObject_(objc.ObjCObjectBase anObject) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_allKeysForObject_, anObject.ref.pointer); return objc.ObjCObjectBase(_ret, retain: true, release: true); } /// allValues objc.ObjCObjectBase get allValues { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_allValues); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_allValues); return objc.ObjCObjectBase(_ret, retain: true, release: true); } /// description objc.NSString get description { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_description); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_description); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// descriptionInStringsFileFormat objc.NSString get descriptionInStringsFileFormat { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_descriptionInStringsFileFormat); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// descriptionWithLocale: objc.NSString descriptionWithLocale_(objc.ObjCObjectBase? locale) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_descriptionWithLocale_, locale?.ref.pointer ?? ffi.nullptr); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -47191,7 +48404,7 @@ extension NSExtendedDictionary on objc.NSDictionary { /// descriptionWithLocale:indent: objc.NSString descriptionWithLocale_indent_( objc.ObjCObjectBase? locale, DartNSUInteger level) { - final _ret = _objc_msgSend_dcd68g( + final _ret = _objc_msgSend_1k4kd9s( this.ref.pointer, _sel_descriptionWithLocale_indent_, locale?.ref.pointer ?? ffi.nullptr, @@ -47201,20 +48414,20 @@ extension NSExtendedDictionary on objc.NSDictionary { /// isEqualToDictionary: bool isEqualToDictionary_(objc.NSDictionary otherDictionary) { - return _objc_msgSend_69e0x1(this.ref.pointer, _sel_isEqualToDictionary_, + return _objc_msgSend_19nvye5(this.ref.pointer, _sel_isEqualToDictionary_, otherDictionary.ref.pointer); } /// objectEnumerator objc.NSEnumerator objectEnumerator() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_objectEnumerator); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_objectEnumerator); return objc.NSEnumerator.castFromPointer(_ret, retain: true, release: true); } /// objectsForKeys:notFoundMarker: objc.ObjCObjectBase objectsForKeys_notFoundMarker_( objc.ObjCObjectBase keys, objc.ObjCObjectBase marker) { - final _ret = _objc_msgSend_rsfdlh( + final _ret = _objc_msgSend_15qeuct( this.ref.pointer, _sel_objectsForKeys_notFoundMarker_, keys.ref.pointer, @@ -47225,14 +48438,14 @@ extension NSExtendedDictionary on objc.NSDictionary { /// writeToURL:error: bool writeToURL_error_( objc.NSURL url, ffi.Pointer> error) { - return _objc_msgSend_blqzg8( + return _objc_msgSend_l9p60w( this.ref.pointer, _sel_writeToURL_error_, url.ref.pointer, error); } /// keysSortedByValueUsingSelector: objc.ObjCObjectBase keysSortedByValueUsingSelector_( ffi.Pointer comparator) { - final _ret = _objc_msgSend_19hbqky( + final _ret = _objc_msgSend_3ctkt6( this.ref.pointer, _sel_keysSortedByValueUsingSelector_, comparator); return objc.ObjCObjectBase(_ret, retain: true, release: true); } @@ -47248,7 +48461,7 @@ extension NSExtendedDictionary on objc.NSDictionary { /// objectForKeyedSubscript: objc.ObjCObjectBase? objectForKeyedSubscript_(objc.ObjCObjectBase key) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_objectForKeyedSubscript_, key.ref.pointer); return _ret.address == 0 ? null @@ -47282,7 +48495,7 @@ extension NSExtendedDictionary on objc.NSDictionary { /// keysSortedByValueUsingComparator: objc.ObjCObjectBase keysSortedByValueUsingComparator_( DartNSComparator cmptr) { - final _ret = _objc_msgSend_cy99le(this.ref.pointer, + final _ret = _objc_msgSend_nnxkei(this.ref.pointer, _sel_keysSortedByValueUsingComparator_, cmptr.ref.pointer); return objc.ObjCObjectBase(_ret, retain: true, release: true); } @@ -47290,7 +48503,7 @@ extension NSExtendedDictionary on objc.NSDictionary { /// keysSortedByValueWithOptions:usingComparator: objc.ObjCObjectBase keysSortedByValueWithOptions_usingComparator_( objc.NSSortOptions opts, DartNSComparator cmptr) { - final _ret = _objc_msgSend_1u2b7ut( + final _ret = _objc_msgSend_1x5ew3h( this.ref.pointer, _sel_keysSortedByValueWithOptions_usingComparator_, opts.value, @@ -47304,7 +48517,7 @@ extension NSExtendedDictionary on objc.NSDictionary { ffi.Bool Function(ffi.Pointer, ffi.Pointer, ffi.Pointer)> predicate) { - final _ret = _objc_msgSend_cy99le(this.ref.pointer, + final _ret = _objc_msgSend_nnxkei(this.ref.pointer, _sel_keysOfEntriesPassingTest_, predicate.ref.pointer); return objc.ObjCObjectBase(_ret, retain: true, release: true); } @@ -47316,7 +48529,7 @@ extension NSExtendedDictionary on objc.NSDictionary { ffi.Bool Function(ffi.Pointer, ffi.Pointer, ffi.Pointer)> predicate) { - final _ret = _objc_msgSend_hd4f96( + final _ret = _objc_msgSend_13x5boi( this.ref.pointer, _sel_keysOfEntriesWithOptions_passingTest_, opts.value, @@ -47350,7 +48563,7 @@ late final _sel_initWithContentsOfURL_ = objc.registerName("initWithContentsOfURL:"); late final _sel_writeToFile_atomically_ = objc.registerName("writeToFile:atomically:"); -final _objc_msgSend_w8pbfh = objc.msgSendPointer +final _objc_msgSend_1iyq28l = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Bool Function( @@ -47378,7 +48591,7 @@ extension NSDeprecated on objc.NSDictionary { /// dictionaryWithContentsOfFile: static objc.NSDictionary? dictionaryWithContentsOfFile_(objc.NSString path) { - final _ret = _objc_msgSend_62nh5j(_class_NSDictionary, + final _ret = _objc_msgSend_1sotr3r(_class_NSDictionary, _sel_dictionaryWithContentsOfFile_, path.ref.pointer); return _ret.address == 0 ? null @@ -47387,7 +48600,7 @@ extension NSDeprecated on objc.NSDictionary { /// dictionaryWithContentsOfURL: static objc.NSDictionary? dictionaryWithContentsOfURL_(objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j(_class_NSDictionary, + final _ret = _objc_msgSend_1sotr3r(_class_NSDictionary, _sel_dictionaryWithContentsOfURL_, url.ref.pointer); return _ret.address == 0 ? null @@ -47396,7 +48609,7 @@ extension NSDeprecated on objc.NSDictionary { /// initWithContentsOfFile: objc.NSDictionary? initWithContentsOfFile_(objc.NSString path) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithContentsOfFile_, path.ref.pointer); return _ret.address == 0 ? null @@ -47405,7 +48618,7 @@ extension NSDeprecated on objc.NSDictionary { /// initWithContentsOfURL: objc.NSDictionary? initWithContentsOfURL_(objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithContentsOfURL_, url.ref.pointer); return _ret.address == 0 ? null @@ -47414,13 +48627,13 @@ extension NSDeprecated on objc.NSDictionary { /// writeToFile:atomically: bool writeToFile_atomically_(objc.NSString path, bool useAuxiliaryFile) { - return _objc_msgSend_w8pbfh(this.ref.pointer, _sel_writeToFile_atomically_, + return _objc_msgSend_1iyq28l(this.ref.pointer, _sel_writeToFile_atomically_, path.ref.pointer, useAuxiliaryFile); } /// writeToURL:atomically: bool writeToURL_atomically_(objc.NSURL url, bool atomically) { - return _objc_msgSend_w8pbfh(this.ref.pointer, _sel_writeToURL_atomically_, + return _objc_msgSend_1iyq28l(this.ref.pointer, _sel_writeToURL_atomically_, url.ref.pointer, atomically); } } @@ -47430,7 +48643,7 @@ late final _sel_dictionaryWithObject_forKey_ = objc.registerName("dictionaryWithObject:forKey:"); late final _sel_dictionaryWithObjects_forKeys_count_ = objc.registerName("dictionaryWithObjects:forKeys:count:"); -final _objc_msgSend_cfqbni = objc.msgSendPointer +final _objc_msgSend_1dydpdi = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -47457,7 +48670,7 @@ late final _sel_initWithObjectsAndKeys_ = late final _sel_initWithDictionary_ = objc.registerName("initWithDictionary:"); late final _sel_initWithDictionary_copyItems_ = objc.registerName("initWithDictionary:copyItems:"); -final _objc_msgSend_1bdmr5f = objc.msgSendPointer +final _objc_msgSend_17amj0z = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -47475,7 +48688,7 @@ late final _sel_initWithObjects_forKeys_ = objc.registerName("initWithObjects:forKeys:"); late final _sel_initWithContentsOfURL_error_ = objc.registerName("initWithContentsOfURL:error:"); -final _objc_msgSend_1705co6 = objc.msgSendPointer +final _objc_msgSend_1lhpu4m = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -47496,14 +48709,14 @@ late final _sel_dictionaryWithContentsOfURL_error_ = extension NSDictionaryCreation on objc.NSDictionary { /// dictionary static objc.NSDictionary dictionary() { - final _ret = _objc_msgSend_1x359cv(_class_NSDictionary, _sel_dictionary); + final _ret = _objc_msgSend_151sglz(_class_NSDictionary, _sel_dictionary); return objc.NSDictionary.castFromPointer(_ret, retain: true, release: true); } /// dictionaryWithObject:forKey: static objc.NSDictionary dictionaryWithObject_forKey_( objc.ObjCObjectBase object, objc.ObjCObjectBase key) { - final _ret = _objc_msgSend_rsfdlh(_class_NSDictionary, + final _ret = _objc_msgSend_15qeuct(_class_NSDictionary, _sel_dictionaryWithObject_forKey_, object.ref.pointer, key.ref.pointer); return objc.NSDictionary.castFromPointer(_ret, retain: true, release: true); } @@ -47513,7 +48726,7 @@ extension NSDictionaryCreation on objc.NSDictionary { ffi.Pointer> objects, ffi.Pointer> keys, DartNSUInteger cnt) { - final _ret = _objc_msgSend_cfqbni(_class_NSDictionary, + final _ret = _objc_msgSend_1dydpdi(_class_NSDictionary, _sel_dictionaryWithObjects_forKeys_count_, objects, keys, cnt); return objc.NSDictionary.castFromPointer(_ret, retain: true, release: true); } @@ -47521,14 +48734,14 @@ extension NSDictionaryCreation on objc.NSDictionary { /// dictionaryWithObjectsAndKeys: static objc.NSDictionary dictionaryWithObjectsAndKeys_( objc.ObjCObjectBase firstObject) { - final _ret = _objc_msgSend_62nh5j(_class_NSDictionary, + final _ret = _objc_msgSend_1sotr3r(_class_NSDictionary, _sel_dictionaryWithObjectsAndKeys_, firstObject.ref.pointer); return objc.NSDictionary.castFromPointer(_ret, retain: true, release: true); } /// dictionaryWithDictionary: static objc.NSDictionary dictionaryWithDictionary_(objc.NSDictionary dict) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSDictionary, _sel_dictionaryWithDictionary_, dict.ref.pointer); return objc.NSDictionary.castFromPointer(_ret, retain: true, release: true); } @@ -47536,7 +48749,7 @@ extension NSDictionaryCreation on objc.NSDictionary { /// dictionaryWithObjects:forKeys: static objc.NSDictionary dictionaryWithObjects_forKeys_( objc.ObjCObjectBase objects, objc.ObjCObjectBase keys) { - final _ret = _objc_msgSend_rsfdlh( + final _ret = _objc_msgSend_15qeuct( _class_NSDictionary, _sel_dictionaryWithObjects_forKeys_, objects.ref.pointer, @@ -47546,7 +48759,7 @@ extension NSDictionaryCreation on objc.NSDictionary { /// initWithObjectsAndKeys: objc.NSDictionary initWithObjectsAndKeys_(objc.ObjCObjectBase firstObject) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithObjectsAndKeys_, firstObject.ref.pointer); return objc.NSDictionary.castFromPointer(_ret, retain: false, release: true); @@ -47554,7 +48767,7 @@ extension NSDictionaryCreation on objc.NSDictionary { /// initWithDictionary: objc.NSDictionary initWithDictionary_(objc.NSDictionary otherDictionary) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithDictionary_, otherDictionary.ref.pointer); return objc.NSDictionary.castFromPointer(_ret, retain: false, release: true); @@ -47563,7 +48776,7 @@ extension NSDictionaryCreation on objc.NSDictionary { /// initWithDictionary:copyItems: objc.NSDictionary initWithDictionary_copyItems_( objc.NSDictionary otherDictionary, bool flag) { - final _ret = _objc_msgSend_1bdmr5f(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_17amj0z(this.ref.retainAndReturnPointer(), _sel_initWithDictionary_copyItems_, otherDictionary.ref.pointer, flag); return objc.NSDictionary.castFromPointer(_ret, retain: false, release: true); @@ -47572,7 +48785,7 @@ extension NSDictionaryCreation on objc.NSDictionary { /// initWithObjects:forKeys: objc.NSDictionary initWithObjects_forKeys_( objc.ObjCObjectBase objects, objc.ObjCObjectBase keys) { - final _ret = _objc_msgSend_rsfdlh(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_15qeuct(this.ref.retainAndReturnPointer(), _sel_initWithObjects_forKeys_, objects.ref.pointer, keys.ref.pointer); return objc.NSDictionary.castFromPointer(_ret, retain: false, release: true); @@ -47581,7 +48794,7 @@ extension NSDictionaryCreation on objc.NSDictionary { /// initWithContentsOfURL:error: objc.NSDictionary? initWithContentsOfURL_error_( objc.NSURL url, ffi.Pointer> error) { - final _ret = _objc_msgSend_1705co6(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1lhpu4m(this.ref.retainAndReturnPointer(), _sel_initWithContentsOfURL_error_, url.ref.pointer, error); return _ret.address == 0 ? null @@ -47591,7 +48804,7 @@ extension NSDictionaryCreation on objc.NSDictionary { /// dictionaryWithContentsOfURL:error: static objc.NSDictionary? dictionaryWithContentsOfURL_error_( objc.NSURL url, ffi.Pointer> error) { - final _ret = _objc_msgSend_1705co6(_class_NSDictionary, + final _ret = _objc_msgSend_1lhpu4m(_class_NSDictionary, _sel_dictionaryWithContentsOfURL_error_, url.ref.pointer, error); return _ret.address == 0 ? null @@ -47613,7 +48826,7 @@ late final _sel_setObject_forKeyedSubscript_ = extension NSExtendedMutableDictionary on objc.NSMutableDictionary { /// addEntriesFromDictionary: void addEntriesFromDictionary_(objc.NSDictionary otherDictionary) { - _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_addEntriesFromDictionary_, + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_addEntriesFromDictionary_, otherDictionary.ref.pointer); } @@ -47624,27 +48837,27 @@ extension NSExtendedMutableDictionary on objc.NSMutableDictionary { /// removeObjectsForKeys: void removeObjectsForKeys_(objc.ObjCObjectBase keyArray) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_removeObjectsForKeys_, keyArray.ref.pointer); } /// setDictionary: void setDictionary_(objc.NSDictionary otherDictionary) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_setDictionary_, otherDictionary.ref.pointer); } /// setObject:forKeyedSubscript: void setObject_forKeyedSubscript_( objc.ObjCObjectBase? obj, objc.ObjCObjectBase key) { - _objc_msgSend_wjvic9(this.ref.pointer, _sel_setObject_forKeyedSubscript_, + _objc_msgSend_pfv6jd(this.ref.pointer, _sel_setObject_forKeyedSubscript_, obj?.ref.pointer ?? ffi.nullptr, key.ref.pointer); } } late final _sel_dictionaryWithCapacity_ = objc.registerName("dictionaryWithCapacity:"); -final _objc_msgSend_1qrcblu = objc.msgSendPointer +final _objc_msgSend_14hpxwa = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -47658,7 +48871,7 @@ extension NSMutableDictionaryCreation on objc.NSMutableDictionary { /// dictionaryWithCapacity: static objc.NSMutableDictionary dictionaryWithCapacity_( DartNSUInteger numItems) { - final _ret = _objc_msgSend_1qrcblu( + final _ret = _objc_msgSend_14hpxwa( _class_NSMutableDictionary, _sel_dictionaryWithCapacity_, numItems); return objc.NSMutableDictionary.castFromPointer(_ret, retain: true, release: true); @@ -47667,7 +48880,7 @@ extension NSMutableDictionaryCreation on objc.NSMutableDictionary { /// dictionaryWithContentsOfFile: static objc.NSMutableDictionary? dictionaryWithContentsOfFile_( objc.NSString path) { - final _ret = _objc_msgSend_62nh5j(_class_NSMutableDictionary, + final _ret = _objc_msgSend_1sotr3r(_class_NSMutableDictionary, _sel_dictionaryWithContentsOfFile_, path.ref.pointer); return _ret.address == 0 ? null @@ -47678,7 +48891,7 @@ extension NSMutableDictionaryCreation on objc.NSMutableDictionary { /// dictionaryWithContentsOfURL: static objc.NSMutableDictionary? dictionaryWithContentsOfURL_( objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j(_class_NSMutableDictionary, + final _ret = _objc_msgSend_1sotr3r(_class_NSMutableDictionary, _sel_dictionaryWithContentsOfURL_, url.ref.pointer); return _ret.address == 0 ? null @@ -47688,7 +48901,7 @@ extension NSMutableDictionaryCreation on objc.NSMutableDictionary { /// initWithContentsOfFile: objc.NSMutableDictionary? initWithContentsOfFile_(objc.NSString path) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithContentsOfFile_, path.ref.pointer); return _ret.address == 0 ? null @@ -47698,7 +48911,7 @@ extension NSMutableDictionaryCreation on objc.NSMutableDictionary { /// initWithContentsOfURL: objc.NSMutableDictionary? initWithContentsOfURL_(objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithContentsOfURL_, url.ref.pointer); return _ret.address == 0 ? null @@ -47714,7 +48927,7 @@ late final _sel_sharedKeySetForKeys_ = extension NSSharedKeySetDictionary on objc.NSDictionary { /// sharedKeySetForKeys: static objc.ObjCObjectBase sharedKeySetForKeys_(objc.ObjCObjectBase keys) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSDictionary, _sel_sharedKeySetForKeys_, keys.ref.pointer); return objc.ObjCObjectBase(_ret, retain: true, release: true); } @@ -47728,7 +48941,7 @@ extension NSSharedKeySetDictionary1 on objc.NSMutableDictionary { /// dictionaryWithSharedKeySet: static objc.NSMutableDictionary dictionaryWithSharedKeySet_( objc.ObjCObjectBase keyset) { - final _ret = _objc_msgSend_62nh5j(_class_NSMutableDictionary, + final _ret = _objc_msgSend_1sotr3r(_class_NSMutableDictionary, _sel_dictionaryWithSharedKeySet_, keyset.ref.pointer); return objc.NSMutableDictionary.castFromPointer(_ret, retain: true, release: true); @@ -48187,8 +49400,6 @@ final class SecKeychainAttributeInfo extends ffi.Struct { external ffi.Pointer format; } -typedef wint_t = __darwin_wint_t; - final class _RuneEntry extends ffi.Struct { @__darwin_rune_t() external int __min; @@ -48630,6 +49841,25 @@ final class __CFBitVector extends ffi.Opaque {} typedef CFBitVectorRef = ffi.Pointer<__CFBitVector>; typedef CFMutableBitVectorRef = ffi.Pointer<__CFBitVector>; + +@ffi.Packed(1) +final class _OSUnalignedU16 extends ffi.Struct { + @ffi.Uint16() + external int __val; +} + +@ffi.Packed(1) +final class _OSUnalignedU32 extends ffi.Struct { + @ffi.Uint32() + external int __val; +} + +@ffi.Packed(1) +final class _OSUnalignedU64 extends ffi.Struct { + @ffi.Uint64() + external int __val; +} + typedef CFByteOrder = CFIndex; final class CFSwappedFloat32 extends ffi.Struct { @@ -49013,7 +50243,8 @@ enum CFCalendarUnit { kCFCalendarUnitQuarter(2048), kCFCalendarUnitWeekOfMonth(4096), kCFCalendarUnitWeekOfYear(8192), - kCFCalendarUnitYearForWeekOfYear(16384); + kCFCalendarUnitYearForWeekOfYear(16384), + kCFCalendarUnitDayOfYear(65536); final int value; const CFCalendarUnit(this.value); @@ -49033,6 +50264,7 @@ enum CFCalendarUnit { 4096 => kCFCalendarUnitWeekOfMonth, 8192 => kCFCalendarUnitWeekOfYear, 16384 => kCFCalendarUnitYearForWeekOfYear, + 65536 => kCFCalendarUnitDayOfYear, _ => throw ArgumentError("Unknown value for CFCalendarUnit: $value"), }; } @@ -49743,6 +50975,46 @@ ffi.NativeCallable< CFRunLoopObserverRef, CFOptionFlags)>.listener( _ObjCBlock_ffiVoid_CFRunLoopObserverRef_CFRunLoopActivity_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_CFRunLoopObserverRef_CFRunLoopActivity_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + CFRunLoopObserverRef arg0, + int arg1) { + try { + (objc.getBlockClosure(block) as void Function(CFRunLoopObserverRef, int))( + arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, CFRunLoopObserverRef, CFOptionFlags)> + _ObjCBlock_ffiVoid_CFRunLoopObserverRef_CFRunLoopActivity_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + CFRunLoopObserverRef, + CFOptionFlags)>.isolateLocal( + _ObjCBlock_ffiVoid_CFRunLoopObserverRef_CFRunLoopActivity_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, CFRunLoopObserverRef, CFOptionFlags)> + _ObjCBlock_ffiVoid_CFRunLoopObserverRef_CFRunLoopActivity_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + CFRunLoopObserverRef, + CFOptionFlags)>.listener( + _ObjCBlock_ffiVoid_CFRunLoopObserverRef_CFRunLoopActivity_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, CFOptionFlags)>`. abstract final class ObjCBlock_ffiVoid_CFRunLoopObserverRef_CFRunLoopActivity { @@ -49814,6 +51086,39 @@ abstract final class ObjCBlock_ffiVoid_CFRunLoopObserverRef_CFRunLoopActivity { ffi.Void Function(ffi.Pointer<__CFRunLoopObserver>, CFOptionFlags)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer<__CFRunLoopObserver>, CFOptionFlags)> + blocking(void Function(CFRunLoopObserverRef, CFRunLoopActivity) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_CFRunLoopObserverRef_CFRunLoopActivity_blockingCallable + .nativeFunction + .cast(), + (CFRunLoopObserverRef arg0, int arg1) => + fn(arg0, CFRunLoopActivity.fromValue(arg1))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_CFRunLoopObserverRef_CFRunLoopActivity_blockingListenerCallable + .nativeFunction + .cast(), + (CFRunLoopObserverRef arg0, int arg1) => + fn(arg0, CFRunLoopActivity.fromValue(arg1))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_tg5tbv, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer<__CFRunLoopObserver>, + CFOptionFlags)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, CFOptionFlags)>`. @@ -49889,6 +51194,36 @@ ffi.NativeCallable< ffi.Pointer, CFRunLoopTimerRef)>.listener( _ObjCBlock_ffiVoid_CFRunLoopTimerRef_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_CFRunLoopTimerRef_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + CFRunLoopTimerRef arg0) { + try { + (objc.getBlockClosure(block) as void Function(CFRunLoopTimerRef))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, CFRunLoopTimerRef)> + _ObjCBlock_ffiVoid_CFRunLoopTimerRef_blockingCallable = ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, CFRunLoopTimerRef)>.isolateLocal( + _ObjCBlock_ffiVoid_CFRunLoopTimerRef_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, CFRunLoopTimerRef)> + _ObjCBlock_ffiVoid_CFRunLoopTimerRef_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, CFRunLoopTimerRef)>.listener( + _ObjCBlock_ffiVoid_CFRunLoopTimerRef_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_CFRunLoopTimerRef { @@ -49952,6 +51287,36 @@ abstract final class ObjCBlock_ffiVoid_CFRunLoopTimerRef { retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock)> + blocking(void Function(CFRunLoopTimerRef) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_CFRunLoopTimerRef_blockingCallable.nativeFunction + .cast(), + (CFRunLoopTimerRef arg0) => fn(arg0)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_CFRunLoopTimerRef_blockingListenerCallable + .nativeFunction + .cast(), + (CFRunLoopTimerRef arg0) => fn(arg0)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1dqvvol, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock)>( + wrapper, + retain: false, + release: true); + } } /// Call operator for `objc.ObjCBlock)>`. @@ -50461,6 +51826,36 @@ ffi.NativeCallable, ffi.Size)> ffi.Void Function(ffi.Pointer, ffi.Size)>.listener(_ObjCBlock_ffiVoid_ffiSize_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_ffiSize_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + int arg0) { + try { + (objc.getBlockClosure(block) as void Function(int))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, ffi.Pointer, ffi.Size)> + _ObjCBlock_ffiVoid_ffiSize_blockingCallable = ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Size)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiSize_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, ffi.Pointer, ffi.Size)> + _ObjCBlock_ffiVoid_ffiSize_blockingListenerCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Size)>.listener(_ObjCBlock_ffiVoid_ffiSize_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_ffiSize { @@ -50518,6 +51913,32 @@ abstract final class ObjCBlock_ffiVoid_ffiSize { return objc.ObjCBlock(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(int) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiSize_blockingCallable.nativeFunction.cast(), + (int arg0) => fn(arg0)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiSize_blockingListenerCallable.nativeFunction + .cast(), + (int arg0) => fn(arg0)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_6enxqz, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -50990,6 +52411,41 @@ ffi.NativeCallable< ffi.Int)>.listener( _ObjCBlock_ffiVoid_dispatchdatat_ffiInt_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_dispatchdatat_ffiInt_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + dispatch_data_t arg0, + int arg1) { + try { + (objc.getBlockClosure(block) as void Function(dispatch_data_t, int))( + arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + dispatch_data_t, + ffi.Int)> _ObjCBlock_ffiVoid_dispatchdatat_ffiInt_blockingCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t, ffi.Int)>.isolateLocal( + _ObjCBlock_ffiVoid_dispatchdatat_ffiInt_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t, ffi.Int)> + _ObjCBlock_ffiVoid_dispatchdatat_ffiInt_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t, ffi.Int)>.listener( + _ObjCBlock_ffiVoid_dispatchdatat_ffiInt_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_dispatchdatat_ffiInt { @@ -51050,8 +52506,40 @@ abstract final class ObjCBlock_ffiVoid_dispatchdatat_ffiInt { (dispatch_data_t arg0, int arg1) => fn( objc.NSObject.castFromPointer(arg0, retain: false, release: true), arg1)); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_qxvyq2(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_18kzm6a(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(Dartdispatch_data_t, int) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_dispatchdatat_ffiInt_blockingCallable.nativeFunction + .cast(), + (dispatch_data_t arg0, int arg1) => fn( + objc.NSObject.castFromPointer(arg0, retain: false, release: true), + arg1)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_dispatchdatat_ffiInt_blockingListenerCallable + .nativeFunction + .cast(), + (dispatch_data_t arg0, int arg1) => fn( + objc.NSObject.castFromPointer(arg0, retain: false, release: true), + arg1)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_18kzm6a, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock(wrapper, retain: false, release: true); } @@ -51113,6 +52601,39 @@ ffi.NativeCallable< ffi.Int)>.listener( _ObjCBlock_ffiVoid_dispatchdatat_ffiInt1_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_dispatchdatat_ffiInt1_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + dispatch_data_t arg0, + int arg1) { + try { + (objc.getBlockClosure(block) as void Function(dispatch_data_t, int))( + arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t, ffi.Int)> + _ObjCBlock_ffiVoid_dispatchdatat_ffiInt1_blockingCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t, ffi.Int)>.isolateLocal( + _ObjCBlock_ffiVoid_dispatchdatat_ffiInt1_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t, ffi.Int)> + _ObjCBlock_ffiVoid_dispatchdatat_ffiInt1_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t, ffi.Int)>.listener( + _ObjCBlock_ffiVoid_dispatchdatat_ffiInt1_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_dispatchdatat_ffiInt1 { @@ -51178,11 +52699,49 @@ abstract final class ObjCBlock_ffiVoid_dispatchdatat_ffiInt1 { : objc.NSObject.castFromPointer(arg0, retain: false, release: true), arg1)); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_qxvyq2(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_18kzm6a(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(Dartdispatch_data_t?, int) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_dispatchdatat_ffiInt1_blockingCallable.nativeFunction + .cast(), + (dispatch_data_t arg0, int arg1) => fn( + arg0.address == 0 + ? null + : objc.NSObject.castFromPointer(arg0, + retain: false, release: true), + arg1)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_dispatchdatat_ffiInt1_blockingListenerCallable + .nativeFunction + .cast(), + (dispatch_data_t arg0, int arg1) => fn( + arg0.address == 0 + ? null + : objc.NSObject.castFromPointer(arg0, + retain: false, release: true), + arg1)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_18kzm6a, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -51231,6 +52790,37 @@ ffi.NativeCallable, ffi.Int)> ffi.Void Function(ffi.Pointer, ffi.Int)>.listener(_ObjCBlock_ffiVoid_ffiInt_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_ffiInt_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + int arg0) { + try { + (objc.getBlockClosure(block) as void Function(int))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, ffi.Pointer, ffi.Int)> + _ObjCBlock_ffiVoid_ffiInt_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int)>.isolateLocal(_ObjCBlock_ffiVoid_ffiInt_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, ffi.Pointer, ffi.Int)> + _ObjCBlock_ffiVoid_ffiInt_blockingListenerCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int)>.listener(_ObjCBlock_ffiVoid_ffiInt_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_ffiInt { @@ -51288,6 +52878,32 @@ abstract final class ObjCBlock_ffiVoid_ffiInt { return objc.ObjCBlock(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(int) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiInt_blockingCallable.nativeFunction.cast(), + (int arg0) => fn(arg0)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiInt_blockingListenerCallable.nativeFunction + .cast(), + (int arg0) => fn(arg0)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_9o8504, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -51354,6 +52970,48 @@ ffi.NativeCallable< dispatch_data_t, ffi.Int)>.listener( _ObjCBlock_ffiVoid_bool_dispatchdatat_ffiInt_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_bool_dispatchdatat_ffiInt_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + bool arg0, + dispatch_data_t arg1, + int arg2) { + try { + (objc.getBlockClosure(block) as void Function(bool, dispatch_data_t, int))( + arg0, arg1, arg2); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Bool, dispatch_data_t, ffi.Int)> + _ObjCBlock_ffiVoid_bool_dispatchdatat_ffiInt_blockingCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Bool, + dispatch_data_t, + ffi.Int)>.isolateLocal( + _ObjCBlock_ffiVoid_bool_dispatchdatat_ffiInt_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Bool, dispatch_data_t, ffi.Int)> + _ObjCBlock_ffiVoid_bool_dispatchdatat_ffiInt_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Bool, + dispatch_data_t, + ffi.Int)>.listener( + _ObjCBlock_ffiVoid_bool_dispatchdatat_ffiInt_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_bool_dispatchdatat_ffiInt { @@ -51423,8 +53081,51 @@ abstract final class ObjCBlock_ffiVoid_bool_dispatchdatat_ffiInt { : objc.NSObject.castFromPointer(arg1, retain: false, release: true), arg2)); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_12a4qua(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_og5b6y(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock( + wrapper, + retain: false, + release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock + blocking(void Function(bool, Dartdispatch_data_t?, int) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_bool_dispatchdatat_ffiInt_blockingCallable + .nativeFunction + .cast(), + (bool arg0, dispatch_data_t arg1, int arg2) => fn( + arg0, + arg1.address == 0 + ? null + : objc.NSObject.castFromPointer(arg1, + retain: false, release: true), + arg2)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_bool_dispatchdatat_ffiInt_blockingListenerCallable + .nativeFunction + .cast(), + (bool arg0, dispatch_data_t arg1, int arg2) => fn( + arg0, + arg1.address == 0 + ? null + : objc.NSObject.castFromPointer(arg1, + retain: false, release: true), + arg2)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_og5b6y, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock( wrapper, retain: false, @@ -55092,6 +56793,39 @@ ffi.NativeCallable< ffi.Uint32)>.listener( _ObjCBlock_ffiVoid_SecTrustRef_SecTrustResultType_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_SecTrustRef_SecTrustResultType_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + SecTrustRef arg0, + int arg1) { + try { + (objc.getBlockClosure(block) as void Function(SecTrustRef, int))( + arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, SecTrustRef, ffi.Uint32)> + _ObjCBlock_ffiVoid_SecTrustRef_SecTrustResultType_blockingCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, SecTrustRef, ffi.Uint32)>.isolateLocal( + _ObjCBlock_ffiVoid_SecTrustRef_SecTrustResultType_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, SecTrustRef, ffi.Uint32)> + _ObjCBlock_ffiVoid_SecTrustRef_SecTrustResultType_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, SecTrustRef, ffi.Uint32)>.listener( + _ObjCBlock_ffiVoid_SecTrustRef_SecTrustResultType_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, ffi.Uint32)>`. abstract final class ObjCBlock_ffiVoid_SecTrustRef_SecTrustResultType { @@ -55158,6 +56892,38 @@ abstract final class ObjCBlock_ffiVoid_SecTrustRef_SecTrustResultType { ffi.Void Function(ffi.Pointer<__SecTrust>, ffi.Uint32)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock, ffi.Uint32)> + blocking(void Function(SecTrustRef, SecTrustResultType) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_SecTrustRef_SecTrustResultType_blockingCallable + .nativeFunction + .cast(), + (SecTrustRef arg0, int arg1) => + fn(arg0, SecTrustResultType.fromValue(arg1))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_SecTrustRef_SecTrustResultType_blockingListenerCallable + .nativeFunction + .cast(), + (SecTrustRef arg0, int arg1) => + fn(arg0, SecTrustResultType.fromValue(arg1))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_gwxhxt, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer<__SecTrust>, ffi.Uint32)>(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, ffi.Uint32)>`. @@ -55228,6 +56994,48 @@ ffi.NativeCallable< ffi.Bool, CFErrorRef)>.listener( _ObjCBlock_ffiVoid_SecTrustRef_bool_CFErrorRef_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_SecTrustRef_bool_CFErrorRef_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + SecTrustRef arg0, + bool arg1, + CFErrorRef arg2) { + try { + (objc.getBlockClosure(block) as void Function( + SecTrustRef, bool, CFErrorRef))(arg0, arg1, arg2); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, SecTrustRef, ffi.Bool, CFErrorRef)> + _ObjCBlock_ffiVoid_SecTrustRef_bool_CFErrorRef_blockingCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + SecTrustRef, + ffi.Bool, + CFErrorRef)>.isolateLocal( + _ObjCBlock_ffiVoid_SecTrustRef_bool_CFErrorRef_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, SecTrustRef, ffi.Bool, CFErrorRef)> + _ObjCBlock_ffiVoid_SecTrustRef_bool_CFErrorRef_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + SecTrustRef, + ffi.Bool, + CFErrorRef)>.listener( + _ObjCBlock_ffiVoid_SecTrustRef_bool_CFErrorRef_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, ffi.Bool, ffi.Pointer<__CFError>)>`. abstract final class ObjCBlock_ffiVoid_SecTrustRef_bool_CFErrorRef { @@ -55300,6 +57108,38 @@ abstract final class ObjCBlock_ffiVoid_SecTrustRef_bool_CFErrorRef { ffi.Void Function(ffi.Pointer<__SecTrust>, ffi.Bool, ffi.Pointer<__CFError>)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer<__SecTrust>, ffi.Bool, ffi.Pointer<__CFError>)> blocking( + void Function(SecTrustRef, bool, CFErrorRef) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_SecTrustRef_bool_CFErrorRef_blockingCallable + .nativeFunction + .cast(), + (SecTrustRef arg0, bool arg1, CFErrorRef arg2) => fn(arg0, arg1, arg2)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_SecTrustRef_bool_CFErrorRef_blockingListenerCallable + .nativeFunction + .cast(), + (SecTrustRef arg0, bool arg1, CFErrorRef arg2) => fn(arg0, arg1, arg2)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_k73ff5, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer<__SecTrust>, ffi.Bool, + ffi.Pointer<__CFError>)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, ffi.Bool, ffi.Pointer<__CFError>)>`. @@ -55554,6 +57394,36 @@ ffi.NativeCallable< ffi.Pointer, sec_certificate_t)>.listener( _ObjCBlock_ffiVoid_seccertificatet_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_seccertificatet_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + sec_certificate_t arg0) { + try { + (objc.getBlockClosure(block) as void Function(sec_certificate_t))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, sec_certificate_t)> + _ObjCBlock_ffiVoid_seccertificatet_blockingCallable = ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, sec_certificate_t)>.isolateLocal( + _ObjCBlock_ffiVoid_seccertificatet_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, sec_certificate_t)> + _ObjCBlock_ffiVoid_seccertificatet_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, sec_certificate_t)>.listener( + _ObjCBlock_ffiVoid_seccertificatet_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_seccertificatet { @@ -55611,11 +57481,41 @@ abstract final class ObjCBlock_ffiVoid_seccertificatet { .cast(), (sec_certificate_t arg0) => fn( objc.NSObject.castFromPointer(arg0, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1jdvcbf(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xtuoz7(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(Dartsec_certificate_t) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_seccertificatet_blockingCallable.nativeFunction + .cast(), + (sec_certificate_t arg0) => fn( + objc.NSObject.castFromPointer(arg0, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_seccertificatet_blockingListenerCallable + .nativeFunction + .cast(), + (sec_certificate_t arg0) => fn( + objc.NSObject.castFromPointer(arg0, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xtuoz7, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -55663,6 +57563,36 @@ ffi.NativeCallable< ffi.Void Function(ffi.Pointer, ffi.Uint16)>.listener(_ObjCBlock_ffiVoid_Uint16_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_Uint16_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + int arg0) { + try { + (objc.getBlockClosure(block) as void Function(int))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, ffi.Pointer, ffi.Uint16)> + _ObjCBlock_ffiVoid_Uint16_blockingCallable = ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Uint16)>.isolateLocal( + _ObjCBlock_ffiVoid_Uint16_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, ffi.Pointer, ffi.Uint16)> + _ObjCBlock_ffiVoid_Uint16_blockingListenerCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Uint16)>.listener(_ObjCBlock_ffiVoid_Uint16_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_Uint16 { @@ -55720,6 +57650,32 @@ abstract final class ObjCBlock_ffiVoid_Uint16 { return objc.ObjCBlock(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(int) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_Uint16_blockingCallable.nativeFunction.cast(), + (int arg0) => fn(arg0)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_Uint16_blockingListenerCallable.nativeFunction + .cast(), + (int arg0) => fn(arg0)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_15f11yh, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -55783,6 +57739,45 @@ ffi.NativeCallable< dispatch_data_t)>.listener( _ObjCBlock_ffiVoid_dispatchdatat_dispatchdatat_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_dispatchdatat_dispatchdatat_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + dispatch_data_t arg0, + dispatch_data_t arg1) { + try { + (objc.getBlockClosure(block) as void Function( + dispatch_data_t, dispatch_data_t))(arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t, dispatch_data_t)> + _ObjCBlock_ffiVoid_dispatchdatat_dispatchdatat_blockingCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + dispatch_data_t, + dispatch_data_t)>.isolateLocal( + _ObjCBlock_ffiVoid_dispatchdatat_dispatchdatat_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t, dispatch_data_t)> + _ObjCBlock_ffiVoid_dispatchdatat_dispatchdatat_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + dispatch_data_t, + dispatch_data_t)>.listener( + _ObjCBlock_ffiVoid_dispatchdatat_dispatchdatat_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_dispatchdatat_dispatchdatat { @@ -55846,13 +57841,48 @@ abstract final class ObjCBlock_ffiVoid_dispatchdatat_dispatchdatat { (dispatch_data_t arg0, dispatch_data_t arg1) => fn( objc.NSObject.castFromPointer(arg0, retain: false, release: true), objc.NSObject.castFromPointer(arg1, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_wjvic9(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_pfv6jd(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock( wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock + blocking(void Function(Dartdispatch_data_t, Dartdispatch_data_t) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_dispatchdatat_dispatchdatat_blockingCallable + .nativeFunction + .cast(), + (dispatch_data_t arg0, dispatch_data_t arg1) => fn( + objc.NSObject.castFromPointer(arg0, retain: false, release: true), + objc.NSObject.castFromPointer(arg1, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_dispatchdatat_dispatchdatat_blockingListenerCallable + .nativeFunction + .cast(), + (dispatch_data_t arg0, dispatch_data_t arg1) => fn( + objc.NSObject.castFromPointer(arg0, retain: false, release: true), + objc.NSObject.castFromPointer(arg1, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_pfv6jd, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock( + wrapper, + retain: false, + release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -55905,6 +57935,36 @@ ffi.NativeCallable< ffi.Pointer, dispatch_data_t)>.listener( _ObjCBlock_ffiVoid_dispatchdatat_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_dispatchdatat_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + dispatch_data_t arg0) { + try { + (objc.getBlockClosure(block) as void Function(dispatch_data_t))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t)> + _ObjCBlock_ffiVoid_dispatchdatat_blockingCallable = ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t)>.isolateLocal( + _ObjCBlock_ffiVoid_dispatchdatat_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t)> + _ObjCBlock_ffiVoid_dispatchdatat_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, dispatch_data_t)>.listener( + _ObjCBlock_ffiVoid_dispatchdatat_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_dispatchdatat { @@ -55965,8 +58025,40 @@ abstract final class ObjCBlock_ffiVoid_dispatchdatat { ? null : objc.NSObject.castFromPointer(arg0, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1jdvcbf(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xtuoz7(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(Dartdispatch_data_t?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_dispatchdatat_blockingCallable.nativeFunction.cast(), + (dispatch_data_t arg0) => fn(arg0.address == 0 + ? null + : objc.NSObject.castFromPointer(arg0, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_dispatchdatat_blockingListenerCallable.nativeFunction + .cast(), + (dispatch_data_t arg0) => fn(arg0.address == 0 + ? null + : objc.NSObject.castFromPointer(arg0, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xtuoz7, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock(wrapper, retain: false, release: true); } @@ -56067,6 +58159,59 @@ ffi.NativeCallable< sec_protocol_pre_shared_key_selection_complete_t)>.listener( _ObjCBlock_ffiVoid_secprotocolmetadatat_dispatchdatat_secprotocolpresharedkeyselectioncompletet_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_secprotocolmetadatat_dispatchdatat_secprotocolpresharedkeyselectioncompletet_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + sec_protocol_metadata_t arg0, + dispatch_data_t arg1, + sec_protocol_pre_shared_key_selection_complete_t arg2) { + try { + (objc.getBlockClosure(block) as void Function( + sec_protocol_metadata_t, + dispatch_data_t, + sec_protocol_pre_shared_key_selection_complete_t))(arg0, arg1, arg2); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + dispatch_data_t, + sec_protocol_pre_shared_key_selection_complete_t)> + _ObjCBlock_ffiVoid_secprotocolmetadatat_dispatchdatat_secprotocolpresharedkeyselectioncompletet_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + dispatch_data_t, + sec_protocol_pre_shared_key_selection_complete_t)>.isolateLocal( + _ObjCBlock_ffiVoid_secprotocolmetadatat_dispatchdatat_secprotocolpresharedkeyselectioncompletet_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + dispatch_data_t, + sec_protocol_pre_shared_key_selection_complete_t)> + _ObjCBlock_ffiVoid_secprotocolmetadatat_dispatchdatat_secprotocolpresharedkeyselectioncompletet_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + dispatch_data_t, + sec_protocol_pre_shared_key_selection_complete_t)>.listener( + _ObjCBlock_ffiVoid_secprotocolmetadatat_dispatchdatat_secprotocolpresharedkeyselectioncompletet_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_secprotocolmetadatat_dispatchdatat_secprotocolpresharedkeyselectioncompletet { @@ -56144,8 +58289,63 @@ abstract final class ObjCBlock_ffiVoid_secprotocolmetadatat_dispatchdatat_secpro retain: false, release: true), ObjCBlock_ffiVoid_dispatchdatat.castFromPointer(arg2, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_91c9gi(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_18qun1e(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function(objc.NSObject, objc.NSObject?, + objc.ObjCBlock)>(wrapper, + retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(objc.NSObject, objc.NSObject?, + objc.ObjCBlock)> blocking( + void Function(Dartsec_protocol_metadata_t, Dartdispatch_data_t?, + Dartsec_protocol_pre_shared_key_selection_complete_t) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_secprotocolmetadatat_dispatchdatat_secprotocolpresharedkeyselectioncompletet_blockingCallable + .nativeFunction + .cast(), + (sec_protocol_metadata_t arg0, dispatch_data_t arg1, + sec_protocol_pre_shared_key_selection_complete_t arg2) => + fn( + objc.NSObject.castFromPointer(arg0, + retain: false, release: true), + arg1.address == 0 + ? null + : objc.NSObject.castFromPointer(arg1, + retain: false, release: true), + ObjCBlock_ffiVoid_dispatchdatat.castFromPointer(arg2, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_secprotocolmetadatat_dispatchdatat_secprotocolpresharedkeyselectioncompletet_blockingListenerCallable + .nativeFunction + .cast(), + (sec_protocol_metadata_t arg0, dispatch_data_t arg1, + sec_protocol_pre_shared_key_selection_complete_t arg2) => + fn( + objc.NSObject.castFromPointer(arg0, + retain: false, release: true), + arg1.address == 0 + ? null + : objc.NSObject.castFromPointer(arg1, + retain: false, release: true), + ObjCBlock_ffiVoid_dispatchdatat.castFromPointer(arg2, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_18qun1e, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function(objc.NSObject, objc.NSObject?, objc.ObjCBlock)>(wrapper, @@ -56249,6 +58449,52 @@ ffi.NativeCallable< sec_protocol_key_update_complete_t)>.listener( _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolkeyupdatecompletet_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolkeyupdatecompletet_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + sec_protocol_metadata_t arg0, + sec_protocol_key_update_complete_t arg1) { + try { + (objc.getBlockClosure(block) as void Function(sec_protocol_metadata_t, + sec_protocol_key_update_complete_t))(arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + sec_protocol_key_update_complete_t)> + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolkeyupdatecompletet_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + sec_protocol_key_update_complete_t)>.isolateLocal( + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolkeyupdatecompletet_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + sec_protocol_key_update_complete_t)> + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolkeyupdatecompletet_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + sec_protocol_key_update_complete_t)>.listener( + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolkeyupdatecompletet_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolkeyupdatecompletet { @@ -56323,8 +58569,55 @@ abstract final class ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolkeyupdate retain: false, release: true), ObjCBlock_ffiVoid.castFromPointer(arg1, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_14pxqbs(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_o762yo(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function( + objc.NSObject, objc.ObjCBlock)>(wrapper, + retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(objc.NSObject, objc.ObjCBlock)> + blocking( + void Function(Dartsec_protocol_metadata_t, + Dartsec_protocol_key_update_complete_t) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolkeyupdatecompletet_blockingCallable + .nativeFunction + .cast(), + (sec_protocol_metadata_t arg0, + sec_protocol_key_update_complete_t arg1) => + fn( + objc.NSObject.castFromPointer(arg0, + retain: false, release: true), + ObjCBlock_ffiVoid.castFromPointer(arg1, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolkeyupdatecompletet_blockingListenerCallable + .nativeFunction + .cast(), + (sec_protocol_metadata_t arg0, + sec_protocol_key_update_complete_t arg1) => + fn( + objc.NSObject.castFromPointer(arg0, + retain: false, release: true), + ObjCBlock_ffiVoid.castFromPointer(arg1, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_o762yo, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function( objc.NSObject, objc.ObjCBlock)>(wrapper, @@ -56418,6 +58711,52 @@ ffi.NativeCallable< sec_protocol_challenge_complete_t)>.listener( _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolchallengecompletet_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolchallengecompletet_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + sec_protocol_metadata_t arg0, + sec_protocol_challenge_complete_t arg1) { + try { + (objc.getBlockClosure(block) as void Function(sec_protocol_metadata_t, + sec_protocol_challenge_complete_t))(arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + sec_protocol_challenge_complete_t)> + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolchallengecompletet_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + sec_protocol_challenge_complete_t)>.isolateLocal( + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolchallengecompletet_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + sec_protocol_challenge_complete_t)> + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolchallengecompletet_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + sec_protocol_challenge_complete_t)>.listener( + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolchallengecompletet_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolchallengecompletet { @@ -56495,13 +58834,61 @@ abstract final class ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolchallenge retain: false, release: true), ObjCBlock_ffiVoid_dispatchdatat.castFromPointer(arg1, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_14pxqbs(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_o762yo(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function(objc.NSObject, objc.ObjCBlock)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function( + objc.NSObject, objc.ObjCBlock)> + blocking( + void Function(Dartsec_protocol_metadata_t, + Dartsec_protocol_challenge_complete_t) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolchallengecompletet_blockingCallable + .nativeFunction + .cast(), + (sec_protocol_metadata_t arg0, + sec_protocol_challenge_complete_t arg1) => + fn( + objc.NSObject.castFromPointer(arg0, + retain: false, release: true), + ObjCBlock_ffiVoid_dispatchdatat.castFromPointer(arg1, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_secprotocolmetadatat_secprotocolchallengecompletet_blockingListenerCallable + .nativeFunction + .cast(), + (sec_protocol_metadata_t arg0, + sec_protocol_challenge_complete_t arg1) => + fn( + objc.NSObject.castFromPointer(arg0, + retain: false, release: true), + ObjCBlock_ffiVoid_dispatchdatat.castFromPointer(arg1, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_o762yo, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function(objc.NSObject, + objc.ObjCBlock)>(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock)>`. @@ -56559,6 +58946,37 @@ ffi.NativeCallable, ffi.Bool)> ffi.Void Function(ffi.Pointer, ffi.Bool)>.listener(_ObjCBlock_ffiVoid_bool_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_bool_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + bool arg0) { + try { + (objc.getBlockClosure(block) as void Function(bool))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, ffi.Pointer, ffi.Bool)> + _ObjCBlock_ffiVoid_bool_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Bool)>.isolateLocal(_ObjCBlock_ffiVoid_bool_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, ffi.Pointer, ffi.Bool)> + _ObjCBlock_ffiVoid_bool_blockingListenerCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Bool)>.listener(_ObjCBlock_ffiVoid_bool_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_bool { @@ -56616,6 +59034,31 @@ abstract final class ObjCBlock_ffiVoid_bool { return objc.ObjCBlock(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(bool) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_bool_blockingCallable.nativeFunction.cast(), + (bool arg0) => fn(arg0)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_bool_blockingListenerCallable.nativeFunction.cast(), + (bool arg0) => fn(arg0)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1s56lr9, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -56703,6 +59146,57 @@ ffi.NativeCallable< sec_protocol_verify_complete_t)>.listener( _ObjCBlock_ffiVoid_secprotocolmetadatat_sectrustt_secprotocolverifycompletet_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_secprotocolmetadatat_sectrustt_secprotocolverifycompletet_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + sec_protocol_metadata_t arg0, + sec_trust_t arg1, + sec_protocol_verify_complete_t arg2) { + try { + (objc.getBlockClosure(block) as void Function(sec_protocol_metadata_t, + sec_trust_t, sec_protocol_verify_complete_t))(arg0, arg1, arg2); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + sec_trust_t, + sec_protocol_verify_complete_t)> + _ObjCBlock_ffiVoid_secprotocolmetadatat_sectrustt_secprotocolverifycompletet_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + sec_trust_t, + sec_protocol_verify_complete_t)>.isolateLocal( + _ObjCBlock_ffiVoid_secprotocolmetadatat_sectrustt_secprotocolverifycompletet_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + sec_trust_t, + sec_protocol_verify_complete_t)> + _ObjCBlock_ffiVoid_secprotocolmetadatat_sectrustt_secprotocolverifycompletet_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + sec_protocol_metadata_t, + sec_trust_t, + sec_protocol_verify_complete_t)>.listener( + _ObjCBlock_ffiVoid_secprotocolmetadatat_sectrustt_secprotocolverifycompletet_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_secprotocolmetadatat_sectrustt_secprotocolverifycompletet { @@ -56779,8 +59273,59 @@ abstract final class ObjCBlock_ffiVoid_secprotocolmetadatat_sectrustt_secprotoco retain: false, release: true), ObjCBlock_ffiVoid_bool.castFromPointer(arg2, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_91c9gi(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_18qun1e(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function(objc.NSObject, objc.NSObject, + objc.ObjCBlock)>(wrapper, + retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(objc.NSObject, objc.NSObject, + objc.ObjCBlock)> blocking( + void Function(Dartsec_protocol_metadata_t, Dartsec_trust_t, + Dartsec_protocol_verify_complete_t) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_secprotocolmetadatat_sectrustt_secprotocolverifycompletet_blockingCallable + .nativeFunction + .cast(), + (sec_protocol_metadata_t arg0, sec_trust_t arg1, + sec_protocol_verify_complete_t arg2) => + fn( + objc.NSObject.castFromPointer(arg0, + retain: false, release: true), + objc.NSObject.castFromPointer(arg1, + retain: false, release: true), + ObjCBlock_ffiVoid_bool.castFromPointer(arg2, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_secprotocolmetadatat_sectrustt_secprotocolverifycompletet_blockingListenerCallable + .nativeFunction + .cast(), + (sec_protocol_metadata_t arg0, sec_trust_t arg1, + sec_protocol_verify_complete_t arg2) => + fn( + objc.NSObject.castFromPointer(arg0, + retain: false, release: true), + objc.NSObject.castFromPointer(arg1, + retain: false, release: true), + ObjCBlock_ffiVoid_bool.castFromPointer(arg2, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_18qun1e, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function(objc.NSObject, objc.NSObject, objc.ObjCBlock)>(wrapper, @@ -57024,6 +59569,58 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSData_NSURLResponse_NSError_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_NSData_NSURLResponse_NSError_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSData_NSURLResponse_NSError_blockingCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSData_NSURLResponse_NSError_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSData_NSURLResponse_NSError_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSData_NSURLResponse_NSError_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSData_NSURLResponse_NSError { @@ -57105,12 +59702,71 @@ abstract final class ObjCBlock_ffiVoid_NSData_NSURLResponse_NSError { ? null : objc.NSError.castFromPointer(arg2, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1hcfngn(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_r8gdi7(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function(objc.NSData?, NSURLResponse?, objc.NSError?)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc + .ObjCBlock + blocking(void Function(objc.NSData?, NSURLResponse?, objc.NSError?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSData_NSURLResponse_NSError_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2) => + fn( + arg0.address == 0 + ? null + : objc.NSData.castFromPointer(arg0, + retain: false, release: true), + arg1.address == 0 + ? null + : NSURLResponse.castFromPointer(arg1, + retain: false, release: true), + arg2.address == 0 + ? null + : objc.NSError.castFromPointer(arg2, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSData_NSURLResponse_NSError_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2) => + fn( + arg0.address == 0 + ? null + : objc.NSData.castFromPointer(arg0, + retain: false, release: true), + arg1.address == 0 + ? null + : NSURLResponse.castFromPointer(arg1, + retain: false, release: true), + arg2.address == 0 + ? null + : objc.NSError.castFromPointer(arg2, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_r8gdi7, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function(objc.NSData?, NSURLResponse?, + objc.NSError?)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -57139,7 +59795,7 @@ extension ObjCBlock_ffiVoid_NSData_NSURLResponse_NSError_CallExtension on objc late final _sel_dataTaskWithRequest_completionHandler_ = objc.registerName("dataTaskWithRequest:completionHandler:"); -final _objc_msgSend_o4sqyk = objc.msgSendPointer +final _objc_msgSend_r0bo0s = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -57180,7 +59836,7 @@ class NSURLSessionUploadTask extends NSURLSessionDataTask { late final _sel_uploadTaskWithRequest_fromFile_completionHandler_ = objc.registerName("uploadTaskWithRequest:fromFile:completionHandler:"); -final _objc_msgSend_but05y = objc.msgSendPointer +final _objc_msgSend_2wiv66 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -57242,6 +59898,38 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSData_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_NSData_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSData_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSData_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSData_blockingListenerCallable = ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSData_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSData { @@ -57302,11 +59990,41 @@ abstract final class ObjCBlock_ffiVoid_NSData { (ffi.Pointer arg0) => fn(arg0.address == 0 ? null : objc.NSData.castFromPointer(arg0, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1jdvcbf(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xtuoz7(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(objc.NSData?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSData_blockingCallable.nativeFunction.cast(), + (ffi.Pointer arg0) => fn(arg0.address == 0 + ? null + : objc.NSData.castFromPointer(arg0, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSData_blockingListenerCallable.nativeFunction + .cast(), + (ffi.Pointer arg0) => fn(arg0.address == 0 + ? null + : objc.NSData.castFromPointer(arg0, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xtuoz7, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -57344,7 +60062,7 @@ class NSURLSessionDownloadTask extends NSURLSessionTask { /// Returns whether [obj] is an instance of [NSURLSessionDownloadTask]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( obj.ref.pointer, _sel_isKindOfClass_, _class_NSURLSessionDownloadTask); } @@ -57363,7 +60081,7 @@ class NSURLSessionDownloadTask extends NSURLSessionTask { /// init NSURLSessionDownloadTask init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSURLSessionDownloadTask.castFromPointer(_ret, retain: false, release: true); } @@ -57371,14 +60089,14 @@ class NSURLSessionDownloadTask extends NSURLSessionTask { /// new static NSURLSessionDownloadTask new1() { final _ret = - _objc_msgSend_1x359cv(_class_NSURLSessionDownloadTask, _sel_new); + _objc_msgSend_151sglz(_class_NSURLSessionDownloadTask, _sel_new); return NSURLSessionDownloadTask.castFromPointer(_ret, retain: false, release: true); } /// allocWithZone: static NSURLSessionDownloadTask allocWithZone_(ffi.Pointer<_NSZone> zone) { - final _ret = _objc_msgSend_hzlb60( + final _ret = _objc_msgSend_1cwp428( _class_NSURLSessionDownloadTask, _sel_allocWithZone_, zone); return NSURLSessionDownloadTask.castFromPointer(_ret, retain: false, release: true); @@ -57387,28 +60105,28 @@ class NSURLSessionDownloadTask extends NSURLSessionTask { /// alloc static NSURLSessionDownloadTask alloc() { final _ret = - _objc_msgSend_1x359cv(_class_NSURLSessionDownloadTask, _sel_alloc); + _objc_msgSend_151sglz(_class_NSURLSessionDownloadTask, _sel_alloc); return NSURLSessionDownloadTask.castFromPointer(_ret, retain: false, release: true); } /// self NSURLSessionDownloadTask self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSURLSessionDownloadTask.castFromPointer(_ret, retain: true, release: true); } /// retain NSURLSessionDownloadTask retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSURLSessionDownloadTask.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSURLSessionDownloadTask autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSURLSessionDownloadTask.castFromPointer(_ret, retain: true, release: true); } @@ -57487,6 +60205,58 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSURL_NSURLResponse_NSError_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_NSURL_NSURLResponse_NSError_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSURL_NSURLResponse_NSError_blockingCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSURL_NSURLResponse_NSError_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSURL_NSURLResponse_NSError_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSURL_NSURLResponse_NSError_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSURL_NSURLResponse_NSError { @@ -57568,8 +60338,67 @@ abstract final class ObjCBlock_ffiVoid_NSURL_NSURLResponse_NSError { ? null : objc.NSError.castFromPointer(arg2, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1hcfngn(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_r8gdi7(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function(objc.NSURL?, NSURLResponse?, + objc.NSError?)>(wrapper, retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc + .ObjCBlock + blocking(void Function(objc.NSURL?, NSURLResponse?, objc.NSError?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSURL_NSURLResponse_NSError_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2) => + fn( + arg0.address == 0 + ? null + : objc.NSURL + .castFromPointer(arg0, retain: false, release: true), + arg1.address == 0 + ? null + : NSURLResponse.castFromPointer(arg1, + retain: false, release: true), + arg2.address == 0 + ? null + : objc.NSError.castFromPointer(arg2, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSURL_NSURLResponse_NSError_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2) => + fn( + arg0.address == 0 + ? null + : objc.NSURL + .castFromPointer(arg0, retain: false, release: true), + arg1.address == 0 + ? null + : NSURLResponse.castFromPointer(arg1, + retain: false, release: true), + arg2.address == 0 + ? null + : objc.NSError.castFromPointer(arg2, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_r8gdi7, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function(objc.NSURL?, NSURLResponse?, objc.NSError?)>(wrapper, retain: false, release: true); @@ -57626,7 +60455,7 @@ extension NSURLSessionAsynchronousConvenience on NSURLSession { objc.ObjCBlock< ffi.Void Function(objc.NSData?, NSURLResponse?, objc.NSError?)> completionHandler) { - final _ret = _objc_msgSend_o4sqyk( + final _ret = _objc_msgSend_r0bo0s( this.ref.pointer, _sel_dataTaskWithRequest_completionHandler_, request.ref.pointer, @@ -57641,7 +60470,7 @@ extension NSURLSessionAsynchronousConvenience on NSURLSession { objc.ObjCBlock< ffi.Void Function(objc.NSData?, NSURLResponse?, objc.NSError?)> completionHandler) { - final _ret = _objc_msgSend_o4sqyk( + final _ret = _objc_msgSend_r0bo0s( this.ref.pointer, _sel_dataTaskWithURL_completionHandler_, url.ref.pointer, @@ -57657,7 +60486,7 @@ extension NSURLSessionAsynchronousConvenience on NSURLSession { objc.ObjCBlock< ffi.Void Function(objc.NSData?, NSURLResponse?, objc.NSError?)> completionHandler) { - final _ret = _objc_msgSend_but05y( + final _ret = _objc_msgSend_2wiv66( this.ref.pointer, _sel_uploadTaskWithRequest_fromFile_completionHandler_, request.ref.pointer, @@ -57674,7 +60503,7 @@ extension NSURLSessionAsynchronousConvenience on NSURLSession { objc.ObjCBlock< ffi.Void Function(objc.NSData?, NSURLResponse?, objc.NSError?)> completionHandler) { - final _ret = _objc_msgSend_but05y( + final _ret = _objc_msgSend_2wiv66( this.ref.pointer, _sel_uploadTaskWithRequest_fromData_completionHandler_, request.ref.pointer, @@ -57695,7 +60524,7 @@ extension NSURLSessionAsynchronousConvenience on NSURLSession { objc.ObjCBlock< ffi.Void Function(objc.NSData?, NSURLResponse?, objc.NSError?)> completionHandler) { - final _ret = _objc_msgSend_o4sqyk( + final _ret = _objc_msgSend_r0bo0s( this.ref.pointer, _sel_uploadTaskWithResumeData_completionHandler_, resumeData.ref.pointer, @@ -57713,7 +60542,7 @@ extension NSURLSessionAsynchronousConvenience on NSURLSession { objc.ObjCBlock< ffi.Void Function(objc.NSURL?, NSURLResponse?, objc.NSError?)> completionHandler) { - final _ret = _objc_msgSend_o4sqyk( + final _ret = _objc_msgSend_r0bo0s( this.ref.pointer, _sel_downloadTaskWithRequest_completionHandler_, request.ref.pointer, @@ -57728,7 +60557,7 @@ extension NSURLSessionAsynchronousConvenience on NSURLSession { objc.ObjCBlock< ffi.Void Function(objc.NSURL?, NSURLResponse?, objc.NSError?)> completionHandler) { - final _ret = _objc_msgSend_o4sqyk( + final _ret = _objc_msgSend_r0bo0s( this.ref.pointer, _sel_downloadTaskWithURL_completionHandler_, url.ref.pointer, @@ -57743,7 +60572,7 @@ extension NSURLSessionAsynchronousConvenience on NSURLSession { objc.ObjCBlock< ffi.Void Function(objc.NSURL?, NSURLResponse?, objc.NSError?)> completionHandler) { - final _ret = _objc_msgSend_o4sqyk( + final _ret = _objc_msgSend_r0bo0s( this.ref.pointer, _sel_downloadTaskWithResumeData_completionHandler_, resumeData.ref.pointer, @@ -57764,7 +60593,7 @@ extension NSURLSessionDeprecated on NSURLSessionConfiguration { /// backgroundSessionConfiguration: static NSURLSessionConfiguration backgroundSessionConfiguration_( objc.NSString identifier) { - final _ret = _objc_msgSend_62nh5j(_class_NSURLSessionConfiguration, + final _ret = _objc_msgSend_1sotr3r(_class_NSURLSessionConfiguration, _sel_backgroundSessionConfiguration_, identifier.ref.pointer); return NSURLSessionConfiguration.castFromPointer(_ret, retain: true, release: true); @@ -57997,8 +60826,8 @@ final _objc_msgSend_1hx005a = objc.msgSendPointer /// created, a copy of the configuration object is made - you cannot /// modify the configuration of a session after it has been created. /// -/// The shared session uses the global singleton credential, cache -/// and cookie storage objects. +/// The shared session uses the global credential, cache and cookie +/// storage objects. /// /// An ephemeral session has no persistent disk storage for cookies, /// cache or credentials. @@ -58021,13 +60850,13 @@ class NSURLSessionConfiguration extends objc.NSObject { /// Returns whether [obj] is an instance of [NSURLSessionConfiguration]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( obj.ref.pointer, _sel_isKindOfClass_, _class_NSURLSessionConfiguration); } /// defaultSessionConfiguration static NSURLSessionConfiguration getDefaultSessionConfiguration() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( _class_NSURLSessionConfiguration, _sel_defaultSessionConfiguration); return NSURLSessionConfiguration.castFromPointer(_ret, retain: true, release: true); @@ -58035,7 +60864,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// ephemeralSessionConfiguration static NSURLSessionConfiguration getEphemeralSessionConfiguration() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( _class_NSURLSessionConfiguration, _sel_ephemeralSessionConfiguration); return NSURLSessionConfiguration.castFromPointer(_ret, retain: true, release: true); @@ -58044,7 +60873,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// backgroundSessionConfigurationWithIdentifier: static NSURLSessionConfiguration backgroundSessionConfigurationWithIdentifier_(objc.NSString identifier) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSURLSessionConfiguration, _sel_backgroundSessionConfigurationWithIdentifier_, identifier.ref.pointer); @@ -58054,7 +60883,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// identifier for the background session configuration objc.NSString? get identifier { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_identifier); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_identifier); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -58069,7 +60898,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// default cache policy for requests set requestCachePolicy(NSURLRequestCachePolicy value) { - return _objc_msgSend_1yjxuv2( + _objc_msgSend_1yjxuv2( this.ref.pointer, _sel_setRequestCachePolicy_, value.value); } @@ -58084,7 +60913,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// default timeout for requests. This will cause a timeout if no data is transmitted for the given timeout value, and is reset whenever data is transmitted. set timeoutIntervalForRequest(DartNSTimeInterval value) { - return _objc_msgSend_hwm8nu( + _objc_msgSend_hwm8nu( this.ref.pointer, _sel_setTimeoutIntervalForRequest_, value); } @@ -58099,7 +60928,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// default timeout for requests. This will cause a timeout if a resource is not able to be retrieved within a given timeout. set timeoutIntervalForResource(DartNSTimeInterval value) { - return _objc_msgSend_hwm8nu( + _objc_msgSend_hwm8nu( this.ref.pointer, _sel_setTimeoutIntervalForResource_, value); } @@ -58112,7 +60941,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// type of service for requests. set networkServiceType(NSURLRequestNetworkServiceType value) { - return _objc_msgSend_1mse4s1( + _objc_msgSend_1mse4s1( this.ref.pointer, _sel_setNetworkServiceType_, value.value); } @@ -58123,7 +60952,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// allow request to route over cellular. set allowsCellularAccess(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setAllowsCellularAccess_, value); } @@ -58135,7 +60964,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// allow request to route over expensive networks. Defaults to YES. set allowsExpensiveNetworkAccess(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setAllowsExpensiveNetworkAccess_, value); } @@ -58147,7 +60976,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// allow request to route over networks in constrained mode. Defaults to YES. set allowsConstrainedNetworkAccess(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setAllowsConstrainedNetworkAccess_, value); } @@ -58159,7 +60988,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// requires requests from the session to be made with DNSSEC validation enabled. Defaults to NO. set requiresDNSSECValidation(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setRequiresDNSSECValidation_, value); } @@ -58192,7 +61021,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// Default value is NO. Ignored by background sessions, as background sessions /// always wait for connectivity. set waitsForConnectivity(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setWaitsForConnectivity_, value); } @@ -58203,8 +61032,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// allows background tasks to be scheduled at the discretion of the system for optimal performance. set discretionary(bool value) { - return _objc_msgSend_1s56lr9( - this.ref.pointer, _sel_setDiscretionary_, value); + _objc_msgSend_1s56lr9(this.ref.pointer, _sel_setDiscretionary_, value); } /// The identifier of the shared data container into which files in background sessions should be downloaded. @@ -58212,7 +61040,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// all transfers in that session will fail with NSURLErrorBackgroundSessionRequiresSharedContainer. objc.NSString? get sharedContainerIdentifier { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_sharedContainerIdentifier); + _objc_msgSend_151sglz(this.ref.pointer, _sel_sharedContainerIdentifier); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -58222,8 +61050,8 @@ class NSURLSessionConfiguration extends objc.NSObject { /// App extensions wishing to use background sessions *must* set this property to a valid container identifier, or /// all transfers in that session will fail with NSURLErrorBackgroundSessionRequiresSharedContainer. set sharedContainerIdentifier(objc.NSString? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, - _sel_setSharedContainerIdentifier_, value?.ref.pointer ?? ffi.nullptr); + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setSharedContainerIdentifier_, + value?.ref.pointer ?? ffi.nullptr); } /// Allows the app to be resumed or launched in the background when tasks in background sessions complete @@ -58242,14 +61070,14 @@ class NSURLSessionConfiguration extends objc.NSObject { /// /// NOTE: macOS apps based on AppKit do not support background launch. set sessionSendsLaunchEvents(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setSessionSendsLaunchEvents_, value); } /// The proxy dictionary, as described by objc.NSDictionary? get connectionProxyDictionary { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_connectionProxyDictionary); + _objc_msgSend_151sglz(this.ref.pointer, _sel_connectionProxyDictionary); return _ret.address == 0 ? null : objc.NSDictionary.castFromPointer(_ret, retain: true, release: true); @@ -58257,8 +61085,8 @@ class NSURLSessionConfiguration extends objc.NSObject { /// The proxy dictionary, as described by set connectionProxyDictionary(objc.NSDictionary? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, - _sel_setConnectionProxyDictionary_, value?.ref.pointer ?? ffi.nullptr); + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setConnectionProxyDictionary_, + value?.ref.pointer ?? ffi.nullptr); } /// The minimum allowable versions of the TLS protocol, from @@ -58270,7 +61098,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// The minimum allowable versions of the TLS protocol, from set TLSMinimumSupportedProtocol(SSLProtocol value) { - return _objc_msgSend_268k8x( + _objc_msgSend_268k8x( this.ref.pointer, _sel_setTLSMinimumSupportedProtocol_, value.value); } @@ -58283,7 +61111,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// The maximum allowable versions of the TLS protocol, from set TLSMaximumSupportedProtocol(SSLProtocol value) { - return _objc_msgSend_268k8x( + _objc_msgSend_268k8x( this.ref.pointer, _sel_setTLSMaximumSupportedProtocol_, value.value); } @@ -58296,7 +61124,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// The minimum allowable versions of the TLS protocol, from set TLSMinimumSupportedProtocolVersion(tls_protocol_version_t value) { - return _objc_msgSend_1mvuct7(this.ref.pointer, + _objc_msgSend_1mvuct7(this.ref.pointer, _sel_setTLSMinimumSupportedProtocolVersion_, value.value); } @@ -58309,7 +61137,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// The maximum allowable versions of the TLS protocol, from set TLSMaximumSupportedProtocolVersion(tls_protocol_version_t value) { - return _objc_msgSend_1mvuct7(this.ref.pointer, + _objc_msgSend_1mvuct7(this.ref.pointer, _sel_setTLSMaximumSupportedProtocolVersion_, value.value); } @@ -58320,7 +61148,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// Allow the use of HTTP pipelining set HTTPShouldUsePipelining(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setHTTPShouldUsePipelining_, value); } @@ -58331,7 +61159,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// Allow the session to set cookies on requests set HTTPShouldSetCookies(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setHTTPShouldSetCookies_, value); } @@ -58344,7 +61172,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// Policy for accepting cookies. This overrides the policy otherwise specified by the cookie storage. set HTTPCookieAcceptPolicy(NSHTTPCookieAcceptPolicy value) { - return _objc_msgSend_3q55ys( + _objc_msgSend_3q55ys( this.ref.pointer, _sel_setHTTPCookieAcceptPolicy_, value.value); } @@ -58352,7 +61180,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// Note that these headers are added to the request only if not already present. objc.NSDictionary? get HTTPAdditionalHeaders { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_HTTPAdditionalHeaders); + _objc_msgSend_151sglz(this.ref.pointer, _sel_HTTPAdditionalHeaders); return _ret.address == 0 ? null : objc.NSDictionary.castFromPointer(_ret, retain: true, release: true); @@ -58361,8 +61189,8 @@ class NSURLSessionConfiguration extends objc.NSObject { /// Specifies additional headers which will be set on outgoing requests. /// Note that these headers are added to the request only if not already present. set HTTPAdditionalHeaders(objc.NSDictionary? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, - _sel_setHTTPAdditionalHeaders_, value?.ref.pointer ?? ffi.nullptr); + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setHTTPAdditionalHeaders_, + value?.ref.pointer ?? ffi.nullptr); } /// The maximum number of simultaneous persistent connections per host @@ -58373,14 +61201,14 @@ class NSURLSessionConfiguration extends objc.NSObject { /// The maximum number of simultaneous persistent connections per host set HTTPMaximumConnectionsPerHost(DartNSInteger value) { - return _objc_msgSend_4sp4xj( + _objc_msgSend_4sp4xj( this.ref.pointer, _sel_setHTTPMaximumConnectionsPerHost_, value); } /// The cookie storage object to use, or nil to indicate that no cookies should be handled NSHTTPCookieStorage? get HTTPCookieStorage { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_HTTPCookieStorage); + _objc_msgSend_151sglz(this.ref.pointer, _sel_HTTPCookieStorage); return _ret.address == 0 ? null : NSHTTPCookieStorage.castFromPointer(_ret, @@ -58389,14 +61217,14 @@ class NSURLSessionConfiguration extends objc.NSObject { /// The cookie storage object to use, or nil to indicate that no cookies should be handled set HTTPCookieStorage(NSHTTPCookieStorage? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_setHTTPCookieStorage_, + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setHTTPCookieStorage_, value?.ref.pointer ?? ffi.nullptr); } /// The credential storage object, or nil to indicate that no credential storage is to be used NSURLCredentialStorage? get URLCredentialStorage { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_URLCredentialStorage); + _objc_msgSend_151sglz(this.ref.pointer, _sel_URLCredentialStorage); return _ret.address == 0 ? null : NSURLCredentialStorage.castFromPointer(_ret, @@ -58405,13 +61233,13 @@ class NSURLSessionConfiguration extends objc.NSObject { /// The credential storage object, or nil to indicate that no credential storage is to be used set URLCredentialStorage(NSURLCredentialStorage? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, - _sel_setURLCredentialStorage_, value?.ref.pointer ?? ffi.nullptr); + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setURLCredentialStorage_, + value?.ref.pointer ?? ffi.nullptr); } /// The URL resource cache, or nil to indicate that no caching is to be performed NSURLCache? get URLCache { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_URLCache); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_URLCache); return _ret.address == 0 ? null : NSURLCache.castFromPointer(_ret, retain: true, release: true); @@ -58419,7 +61247,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// The URL resource cache, or nil to indicate that no caching is to be performed set URLCache(NSURLCache? value) { - return _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_setURLCache_, value?.ref.pointer ?? ffi.nullptr); } @@ -58433,7 +61261,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// Enable extended background idle mode for any tcp sockets created. Enabling this mode asks the system to keep the socket open /// and delay reclaiming it when the process moves to the background (see https://developer.apple.com/library/ios/technotes/tn2277/_index.html) set shouldUseExtendedBackgroundIdleMode(bool value) { - return _objc_msgSend_1s56lr9( + _objc_msgSend_1s56lr9( this.ref.pointer, _sel_setShouldUseExtendedBackgroundIdleMode_, value); } @@ -58446,7 +61274,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// Custom NSURLProtocol subclasses are not available to background /// sessions. objc.ObjCObjectBase? get protocolClasses { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_protocolClasses); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_protocolClasses); return _ret.address == 0 ? null : objc.ObjCObjectBase(_ret, retain: true, release: true); @@ -58461,7 +61289,7 @@ class NSURLSessionConfiguration extends objc.NSObject { /// Custom NSURLProtocol subclasses are not available to background /// sessions. set protocolClasses(objc.ObjCObjectBase? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_setProtocolClasses_, + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setProtocolClasses_, value?.ref.pointer ?? ffi.nullptr); } @@ -58474,14 +61302,14 @@ class NSURLSessionConfiguration extends objc.NSObject { /// multipath service type to use for connections. The default is NSURLSessionMultipathServiceTypeNone set multipathServiceType(NSURLSessionMultipathServiceType value) { - return _objc_msgSend_1hx005a( + _objc_msgSend_1hx005a( this.ref.pointer, _sel_setMultipathServiceType_, value.value); } /// init NSURLSessionConfiguration init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSURLSessionConfiguration.castFromPointer(_ret, retain: false, release: true); } @@ -58489,14 +61317,14 @@ class NSURLSessionConfiguration extends objc.NSObject { /// new static NSURLSessionConfiguration new1() { final _ret = - _objc_msgSend_1x359cv(_class_NSURLSessionConfiguration, _sel_new); + _objc_msgSend_151sglz(_class_NSURLSessionConfiguration, _sel_new); return NSURLSessionConfiguration.castFromPointer(_ret, retain: false, release: true); } /// allocWithZone: static NSURLSessionConfiguration allocWithZone_(ffi.Pointer<_NSZone> zone) { - final _ret = _objc_msgSend_hzlb60( + final _ret = _objc_msgSend_1cwp428( _class_NSURLSessionConfiguration, _sel_allocWithZone_, zone); return NSURLSessionConfiguration.castFromPointer(_ret, retain: false, release: true); @@ -58505,28 +61333,28 @@ class NSURLSessionConfiguration extends objc.NSObject { /// alloc static NSURLSessionConfiguration alloc() { final _ret = - _objc_msgSend_1x359cv(_class_NSURLSessionConfiguration, _sel_alloc); + _objc_msgSend_151sglz(_class_NSURLSessionConfiguration, _sel_alloc); return NSURLSessionConfiguration.castFromPointer(_ret, retain: false, release: true); } /// self NSURLSessionConfiguration self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSURLSessionConfiguration.castFromPointer(_ret, retain: true, release: true); } /// retain NSURLSessionConfiguration retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSURLSessionConfiguration.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSURLSessionConfiguration autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSURLSessionConfiguration.castFromPointer(_ret, retain: true, release: true); } @@ -58542,7 +61370,7 @@ late final _sel_operationCount = objc.registerName("operationCount"); extension NSDeprecated1 on NSOperationQueue { /// These two functions are inherently a race condition and should be avoided if possible objc.NSArray get operations { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_operations); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_operations); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } @@ -58574,7 +61402,7 @@ class NSOperation extends objc.NSObject { late final _sel_addOperation_ = objc.registerName("addOperation:"); late final _sel_addOperations_waitUntilFinished_ = objc.registerName("addOperations:waitUntilFinished:"); -final _objc_msgSend_gk45w7 = objc.msgSendPointer +final _objc_msgSend_6p7ndb = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -58618,6 +61446,29 @@ final _objc_msgSend_n2da1l = objc.msgSendPointer .asFunction< void Function(ffi.Pointer, ffi.Pointer, int)>(); + +/// ! +/// @typedef dispatch_queue_t +/// +/// @abstract +/// Dispatch queues invoke workitems submitted to them. +/// +/// @discussion +/// Dispatch queues come in many flavors, the most common one being the dispatch +/// serial queue (See dispatch_queue_serial_t). +/// +/// The system manages a pool of threads which process dispatch queues and invoke +/// workitems submitted to them. +/// +/// Conceptually a dispatch queue may have its own thread of execution, and +/// interaction between queues is highly asynchronous. +/// +/// Dispatch queues are reference counted via calls to dispatch_retain() and +/// dispatch_release(). Pending workitems submitted to a queue also hold a +/// reference to the queue until they have finished. Once all references to a +/// queue have been released, the queue will be deallocated by the system. +typedef dispatch_queue_t1 = ffi.Pointer; +typedef Dartdispatch_queue_t1 = objc.NSObject; late final _sel_underlyingQueue = objc.registerName("underlyingQueue"); late final _sel_setUnderlyingQueue_ = objc.registerName("setUnderlyingQueue:"); late final _sel_cancelAllOperations = objc.registerName("cancelAllOperations"); @@ -58643,24 +61494,24 @@ class NSOperationQueue extends objc.NSObject { /// Returns whether [obj] is an instance of [NSOperationQueue]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( obj.ref.pointer, _sel_isKindOfClass_, _class_NSOperationQueue); } /// progress NSProgress get progress { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_progress); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_progress); return NSProgress.castFromPointer(_ret, retain: true, release: true); } /// addOperation: void addOperation_(NSOperation op) { - _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_addOperation_, op.ref.pointer); + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_addOperation_, op.ref.pointer); } /// addOperations:waitUntilFinished: void addOperations_waitUntilFinished_(objc.NSArray ops, bool wait) { - _objc_msgSend_gk45w7(this.ref.pointer, + _objc_msgSend_6p7ndb(this.ref.pointer, _sel_addOperations_waitUntilFinished_, ops.ref.pointer, wait); } @@ -58688,7 +61539,7 @@ class NSOperationQueue extends objc.NSObject { /// setMaxConcurrentOperationCount: set maxConcurrentOperationCount(DartNSInteger value) { - return _objc_msgSend_4sp4xj( + _objc_msgSend_4sp4xj( this.ref.pointer, _sel_setMaxConcurrentOperationCount_, value); } @@ -58699,12 +61550,12 @@ class NSOperationQueue extends objc.NSObject { /// setSuspended: set suspended(bool value) { - return _objc_msgSend_1s56lr9(this.ref.pointer, _sel_setSuspended_, value); + _objc_msgSend_1s56lr9(this.ref.pointer, _sel_setSuspended_, value); } /// name objc.NSString? get name { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_name); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_name); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -58712,7 +61563,7 @@ class NSOperationQueue extends objc.NSObject { /// setName: set name(objc.NSString? value) { - return _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_setName_, value?.ref.pointer ?? ffi.nullptr); } @@ -58724,21 +61575,21 @@ class NSOperationQueue extends objc.NSObject { /// setQualityOfService: set qualityOfService(NSQualityOfService value) { - return _objc_msgSend_n2da1l( + _objc_msgSend_n2da1l( this.ref.pointer, _sel_setQualityOfService_, value.value); } /// actually retain - Dartdispatch_queue_t? get underlyingQueue { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_underlyingQueue); + Dartdispatch_queue_t1? get underlyingQueue { + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_underlyingQueue); return _ret.address == 0 ? null : objc.NSObject.castFromPointer(_ret, retain: true, release: true); } /// actually retain - set underlyingQueue(Dartdispatch_queue_t? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_setUnderlyingQueue_, + set underlyingQueue(Dartdispatch_queue_t1? value) { + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setUnderlyingQueue_, value?.ref.pointer ?? ffi.nullptr); } @@ -58756,7 +61607,7 @@ class NSOperationQueue extends objc.NSObject { /// currentQueue static NSOperationQueue? getCurrentQueue() { final _ret = - _objc_msgSend_1x359cv(_class_NSOperationQueue, _sel_currentQueue); + _objc_msgSend_151sglz(_class_NSOperationQueue, _sel_currentQueue); return _ret.address == 0 ? null : NSOperationQueue.castFromPointer(_ret, retain: true, release: true); @@ -58764,51 +61615,51 @@ class NSOperationQueue extends objc.NSObject { /// mainQueue static NSOperationQueue getMainQueue() { - final _ret = _objc_msgSend_1x359cv(_class_NSOperationQueue, _sel_mainQueue); + final _ret = _objc_msgSend_151sglz(_class_NSOperationQueue, _sel_mainQueue); return NSOperationQueue.castFromPointer(_ret, retain: true, release: true); } /// init NSOperationQueue init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSOperationQueue.castFromPointer(_ret, retain: false, release: true); } /// new static NSOperationQueue new1() { - final _ret = _objc_msgSend_1x359cv(_class_NSOperationQueue, _sel_new); + final _ret = _objc_msgSend_151sglz(_class_NSOperationQueue, _sel_new); return NSOperationQueue.castFromPointer(_ret, retain: false, release: true); } /// allocWithZone: static NSOperationQueue allocWithZone_(ffi.Pointer<_NSZone> zone) { - final _ret = _objc_msgSend_hzlb60( + final _ret = _objc_msgSend_1cwp428( _class_NSOperationQueue, _sel_allocWithZone_, zone); return NSOperationQueue.castFromPointer(_ret, retain: false, release: true); } /// alloc static NSOperationQueue alloc() { - final _ret = _objc_msgSend_1x359cv(_class_NSOperationQueue, _sel_alloc); + final _ret = _objc_msgSend_151sglz(_class_NSOperationQueue, _sel_alloc); return NSOperationQueue.castFromPointer(_ret, retain: false, release: true); } /// self NSOperationQueue self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSOperationQueue.castFromPointer(_ret, retain: true, release: true); } /// retain NSOperationQueue retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSOperationQueue.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSOperationQueue autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSOperationQueue.castFromPointer(_ret, retain: true, release: true); } } @@ -58903,6 +61754,59 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_objcObjCObject_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_objcObjCObject_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_objcObjCObject_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_objcObjCObject_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_objcObjCObject_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_objcObjCObject_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, ffi.Pointer, ffi.Pointer)>`. abstract final class ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_objcObjCObject { @@ -58980,7 +61884,7 @@ abstract final class ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_objcObjCObj objc.ObjCObjectBase(arg0, retain: false, release: true), objc.ObjCObjectBase(arg1, retain: false, release: true), objc.ObjCObjectBase(arg2, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1hcfngn(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_r8gdi7(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -58989,6 +61893,53 @@ abstract final class ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_objcObjCObj ffi.Pointer)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> blocking( + void Function( + objc.ObjCObjectBase, objc.ObjCObjectBase, objc.ObjCObjectBase) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_objcObjCObject_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2) => + fn( + objc.ObjCObjectBase(arg0, retain: false, release: true), + objc.ObjCObjectBase(arg1, retain: false, release: true), + objc.ObjCObjectBase(arg2, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_objcObjCObject_objcObjCObject_objcObjCObject_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2) => + fn( + objc.ObjCObjectBase(arg0, retain: false, release: true), + objc.ObjCObjectBase(arg1, retain: false, release: true), + objc.ObjCObjectBase(arg2, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_r8gdi7, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, ffi.Pointer, ffi.Pointer)>`. @@ -59057,6 +62008,39 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_objcObjCObject1_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_objcObjCObject1_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_objcObjCObject1_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_objcObjCObject1_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_objcObjCObject1_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_objcObjCObject1_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_objcObjCObject1 { @@ -59116,13 +62100,45 @@ abstract final class ObjCBlock_ffiVoid_objcObjCObject1 { .cast(), (ffi.Pointer arg0) => fn(objc.ObjCObjectBase(arg0, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1jdvcbf(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xtuoz7(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock)>( wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock)> + blocking(void Function(objc.ObjCObjectBase) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_objcObjCObject1_blockingCallable.nativeFunction + .cast(), + (ffi.Pointer arg0) => + fn(objc.ObjCObjectBase(arg0, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_objcObjCObject1_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0) => + fn(objc.ObjCObjectBase(arg0, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xtuoz7, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock)>( + wrapper, + retain: false, + release: true); + } } /// Call operator for `objc.ObjCBlock)>`. @@ -59198,7 +62214,7 @@ class NSURLSessionStreamTask extends NSURLSessionTask { late final _sel_streamTaskWithHostName_port_ = objc.registerName("streamTaskWithHostName:port:"); -final _objc_msgSend_1i26p99 = objc.msgSendPointer +final _objc_msgSend_9slupp = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -59290,13 +62306,13 @@ class NSURLSessionWebSocketMessage extends objc.NSObject { /// Returns whether [obj] is an instance of [NSURLSessionWebSocketMessage]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1(obj.ref.pointer, _sel_isKindOfClass_, + return _objc_msgSend_19nvye5(obj.ref.pointer, _sel_isKindOfClass_, _class_NSURLSessionWebSocketMessage); } /// Create a message with data type NSURLSessionWebSocketMessage initWithData_(objc.NSData data) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithData_, data.ref.pointer); return NSURLSessionWebSocketMessage.castFromPointer(_ret, retain: false, release: true); @@ -59304,7 +62320,7 @@ class NSURLSessionWebSocketMessage extends objc.NSObject { /// Create a message with string type NSURLSessionWebSocketMessage initWithString_(objc.NSString string) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithString_, string.ref.pointer); return NSURLSessionWebSocketMessage.castFromPointer(_ret, retain: false, release: true); @@ -59318,7 +62334,7 @@ class NSURLSessionWebSocketMessage extends objc.NSObject { /// data objc.NSData? get data { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_data); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_data); return _ret.address == 0 ? null : objc.NSData.castFromPointer(_ret, retain: true, release: true); @@ -59326,7 +62342,7 @@ class NSURLSessionWebSocketMessage extends objc.NSObject { /// string objc.NSString? get string { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_string); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_string); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -59335,7 +62351,7 @@ class NSURLSessionWebSocketMessage extends objc.NSObject { /// init NSURLSessionWebSocketMessage init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSURLSessionWebSocketMessage.castFromPointer(_ret, retain: false, release: true); } @@ -59343,7 +62359,7 @@ class NSURLSessionWebSocketMessage extends objc.NSObject { /// new static NSURLSessionWebSocketMessage new1() { final _ret = - _objc_msgSend_1x359cv(_class_NSURLSessionWebSocketMessage, _sel_new); + _objc_msgSend_151sglz(_class_NSURLSessionWebSocketMessage, _sel_new); return NSURLSessionWebSocketMessage.castFromPointer(_ret, retain: false, release: true); } @@ -59351,7 +62367,7 @@ class NSURLSessionWebSocketMessage extends objc.NSObject { /// allocWithZone: static NSURLSessionWebSocketMessage allocWithZone_( ffi.Pointer<_NSZone> zone) { - final _ret = _objc_msgSend_hzlb60( + final _ret = _objc_msgSend_1cwp428( _class_NSURLSessionWebSocketMessage, _sel_allocWithZone_, zone); return NSURLSessionWebSocketMessage.castFromPointer(_ret, retain: false, release: true); @@ -59360,28 +62376,28 @@ class NSURLSessionWebSocketMessage extends objc.NSObject { /// alloc static NSURLSessionWebSocketMessage alloc() { final _ret = - _objc_msgSend_1x359cv(_class_NSURLSessionWebSocketMessage, _sel_alloc); + _objc_msgSend_151sglz(_class_NSURLSessionWebSocketMessage, _sel_alloc); return NSURLSessionWebSocketMessage.castFromPointer(_ret, retain: false, release: true); } /// self NSURLSessionWebSocketMessage self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSURLSessionWebSocketMessage.castFromPointer(_ret, retain: true, release: true); } /// retain NSURLSessionWebSocketMessage retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSURLSessionWebSocketMessage.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSURLSessionWebSocketMessage autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSURLSessionWebSocketMessage.castFromPointer(_ret, retain: true, release: true); } @@ -59427,6 +62443,38 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSError_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_NSError_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSError_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSError_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSError_blockingListenerCallable = ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSError_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSError { @@ -59488,11 +62536,43 @@ abstract final class ObjCBlock_ffiVoid_NSError { ? null : objc.NSError.castFromPointer(arg0, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1jdvcbf(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xtuoz7(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(objc.NSError?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSError_blockingCallable.nativeFunction.cast(), + (ffi.Pointer arg0) => fn(arg0.address == 0 + ? null + : objc.NSError.castFromPointer(arg0, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSError_blockingListenerCallable.nativeFunction + .cast(), + (ffi.Pointer arg0) => fn(arg0.address == 0 + ? null + : objc.NSError.castFromPointer(arg0, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xtuoz7, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -59567,6 +62647,51 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSURLSessionWebSocketMessage_NSError_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_NSURLSessionWebSocketMessage_NSError_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1) { + try { + (objc.getBlockClosure(block) as void Function(ffi.Pointer, + ffi.Pointer))(arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSURLSessionWebSocketMessage_NSError_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSURLSessionWebSocketMessage_NSError_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSURLSessionWebSocketMessage_NSError_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSURLSessionWebSocketMessage_NSError_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSURLSessionWebSocketMessage_NSError { @@ -59640,8 +62765,59 @@ abstract final class ObjCBlock_ffiVoid_NSURLSessionWebSocketMessage_NSError { ? null : objc.NSError.castFromPointer(arg1, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_wjvic9(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_pfv6jd(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function(NSURLSessionWebSocketMessage?, + objc.NSError?)>(wrapper, retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(NSURLSessionWebSocketMessage?, objc.NSError?)> + blocking(void Function(NSURLSessionWebSocketMessage?, objc.NSError?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSURLSessionWebSocketMessage_NSError_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1) => + fn( + arg0.address == 0 + ? null + : NSURLSessionWebSocketMessage.castFromPointer(arg0, + retain: false, release: true), + arg1.address == 0 + ? null + : objc.NSError.castFromPointer(arg1, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSURLSessionWebSocketMessage_NSError_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1) => + fn( + arg0.address == 0 + ? null + : NSURLSessionWebSocketMessage.castFromPointer(arg0, + retain: false, release: true), + arg1.address == 0 + ? null + : objc.NSError.castFromPointer(arg1, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_pfv6jd, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function(NSURLSessionWebSocketMessage?, objc.NSError?)>(wrapper, retain: false, release: true); @@ -59692,7 +62868,7 @@ sealed class NSURLSessionWebSocketCloseCode { late final _sel_cancelWithCloseCode_reason_ = objc.registerName("cancelWithCloseCode:reason:"); -final _objc_msgSend_xb0psz = objc.msgSendPointer +final _objc_msgSend_tqzk0b = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -59744,7 +62920,7 @@ class NSURLSessionWebSocketTask extends NSURLSessionTask { /// Returns whether [obj] is an instance of [NSURLSessionWebSocketTask]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( obj.ref.pointer, _sel_isKindOfClass_, _class_NSURLSessionWebSocketTask); } @@ -59754,7 +62930,7 @@ class NSURLSessionWebSocketTask extends NSURLSessionTask { /// that they have been written to the kernel. void sendMessage_completionHandler_(NSURLSessionWebSocketMessage message, objc.ObjCBlock completionHandler) { - _objc_msgSend_14pxqbs(this.ref.pointer, _sel_sendMessage_completionHandler_, + _objc_msgSend_o762yo(this.ref.pointer, _sel_sendMessage_completionHandler_, message.ref.pointer, completionHandler.ref.pointer); } @@ -59785,7 +62961,7 @@ class NSURLSessionWebSocketTask extends NSURLSessionTask { /// Simply calling cancel on the task will result in a cancellation frame being sent without any reason. void cancelWithCloseCode_reason_( DartNSInteger closeCode, objc.NSData? reason) { - _objc_msgSend_xb0psz(this.ref.pointer, _sel_cancelWithCloseCode_reason_, + _objc_msgSend_tqzk0b(this.ref.pointer, _sel_cancelWithCloseCode_reason_, closeCode, reason?.ref.pointer ?? ffi.nullptr); } @@ -59796,8 +62972,7 @@ class NSURLSessionWebSocketTask extends NSURLSessionTask { /// The maximum number of bytes to be buffered before erroring out. This includes the sum of all bytes from continuation frames. Receive calls will error out if this value is reached set maximumMessageSize(DartNSInteger value) { - return _objc_msgSend_4sp4xj( - this.ref.pointer, _sel_setMaximumMessageSize_, value); + _objc_msgSend_4sp4xj(this.ref.pointer, _sel_setMaximumMessageSize_, value); } /// A task can be queried for it's close code at any point. When the task is not closed, it will be set to NSURLSessionWebSocketCloseCodeInvalid @@ -59807,7 +62982,7 @@ class NSURLSessionWebSocketTask extends NSURLSessionTask { /// A task can be queried for it's close reason at any point. A nil value indicates no closeReason or that the task is still running objc.NSData? get closeReason { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_closeReason); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_closeReason); return _ret.address == 0 ? null : objc.NSData.castFromPointer(_ret, retain: true, release: true); @@ -59816,7 +62991,7 @@ class NSURLSessionWebSocketTask extends NSURLSessionTask { /// init NSURLSessionWebSocketTask init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSURLSessionWebSocketTask.castFromPointer(_ret, retain: false, release: true); } @@ -59824,14 +62999,14 @@ class NSURLSessionWebSocketTask extends NSURLSessionTask { /// new static NSURLSessionWebSocketTask new1() { final _ret = - _objc_msgSend_1x359cv(_class_NSURLSessionWebSocketTask, _sel_new); + _objc_msgSend_151sglz(_class_NSURLSessionWebSocketTask, _sel_new); return NSURLSessionWebSocketTask.castFromPointer(_ret, retain: false, release: true); } /// allocWithZone: static NSURLSessionWebSocketTask allocWithZone_(ffi.Pointer<_NSZone> zone) { - final _ret = _objc_msgSend_hzlb60( + final _ret = _objc_msgSend_1cwp428( _class_NSURLSessionWebSocketTask, _sel_allocWithZone_, zone); return NSURLSessionWebSocketTask.castFromPointer(_ret, retain: false, release: true); @@ -59840,28 +63015,28 @@ class NSURLSessionWebSocketTask extends NSURLSessionTask { /// alloc static NSURLSessionWebSocketTask alloc() { final _ret = - _objc_msgSend_1x359cv(_class_NSURLSessionWebSocketTask, _sel_alloc); + _objc_msgSend_151sglz(_class_NSURLSessionWebSocketTask, _sel_alloc); return NSURLSessionWebSocketTask.castFromPointer(_ret, retain: false, release: true); } /// self NSURLSessionWebSocketTask self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSURLSessionWebSocketTask.castFromPointer(_ret, retain: true, release: true); } /// retain NSURLSessionWebSocketTask retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSURLSessionWebSocketTask.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSURLSessionWebSocketTask autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSURLSessionWebSocketTask.castFromPointer(_ret, retain: true, release: true); } @@ -59949,14 +63124,14 @@ class NSURLSession extends objc.NSObject { /// Returns whether [obj] is an instance of [NSURLSession]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( obj.ref.pointer, _sel_isKindOfClass_, _class_NSURLSession); } /// The shared session uses the currently set global NSURLCache, /// NSHTTPCookieStorage and NSURLCredentialStorage objects. static NSURLSession getSharedSession() { - final _ret = _objc_msgSend_1x359cv(_class_NSURLSession, _sel_sharedSession); + final _ret = _objc_msgSend_151sglz(_class_NSURLSession, _sel_sharedSession); return NSURLSession.castFromPointer(_ret, retain: true, release: true); } @@ -59967,7 +63142,7 @@ class NSURLSession extends objc.NSObject { /// the delegate has been sent the URLSession:didBecomeInvalidWithError: message. static NSURLSession sessionWithConfiguration_( NSURLSessionConfiguration configuration) { - final _ret = _objc_msgSend_62nh5j(_class_NSURLSession, + final _ret = _objc_msgSend_1sotr3r(_class_NSURLSession, _sel_sessionWithConfiguration_, configuration.ref.pointer); return NSURLSession.castFromPointer(_ret, retain: true, release: true); } @@ -59977,7 +63152,7 @@ class NSURLSession extends objc.NSObject { NSURLSessionConfiguration configuration, objc.ObjCObjectBase? delegate, NSOperationQueue? queue) { - final _ret = _objc_msgSend_582s3n( + final _ret = _objc_msgSend_11spmsz( _class_NSURLSession, _sel_sessionWithConfiguration_delegate_delegateQueue_, configuration.ref.pointer, @@ -59988,13 +63163,13 @@ class NSURLSession extends objc.NSObject { /// delegateQueue NSOperationQueue get delegateQueue { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_delegateQueue); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_delegateQueue); return NSOperationQueue.castFromPointer(_ret, retain: true, release: true); } /// delegate objc.ObjCObjectBase? get delegate { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_delegate); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_delegate); return _ret.address == 0 ? null : objc.ObjCObjectBase(_ret, retain: true, release: true); @@ -60002,7 +63177,7 @@ class NSURLSession extends objc.NSObject { /// configuration NSURLSessionConfiguration get configuration { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_configuration); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_configuration); return NSURLSessionConfiguration.castFromPointer(_ret, retain: true, release: true); } @@ -60011,7 +63186,7 @@ class NSURLSession extends objc.NSObject { /// provide a descriptive label for the session. objc.NSString? get sessionDescription { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_sessionDescription); + _objc_msgSend_151sglz(this.ref.pointer, _sel_sessionDescription); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -60020,7 +63195,7 @@ class NSURLSession extends objc.NSObject { /// The sessionDescription property is available for the developer to /// provide a descriptive label for the session. set sessionDescription(objc.NSString? value) { - return _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_setSessionDescription_, + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_setSessionDescription_, value?.ref.pointer ?? ffi.nullptr); } @@ -60030,7 +63205,7 @@ class NSURLSession extends objc.NSObject { /// has been issued. /// /// -finishTasksAndInvalidate and -invalidateAndCancel do not - /// have any effect on the shared session singleton. + /// have any effect on the shared session instance. /// /// When invalidating a background session, it is not safe to create another background /// session with the same identifier until URLSession:didBecomeInvalidWithError: has @@ -60081,7 +63256,7 @@ class NSURLSession extends objc.NSObject { /// Creates a data task with the given request. The request may have a body stream. NSURLSessionDataTask dataTaskWithRequest_(NSURLRequest request) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_dataTaskWithRequest_, request.ref.pointer); return NSURLSessionDataTask.castFromPointer(_ret, retain: true, release: true); @@ -60089,7 +63264,7 @@ class NSURLSession extends objc.NSObject { /// Creates a data task to retrieve the contents of the given URL. NSURLSessionDataTask dataTaskWithURL_(objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_dataTaskWithURL_, url.ref.pointer); return NSURLSessionDataTask.castFromPointer(_ret, retain: true, release: true); @@ -60098,7 +63273,7 @@ class NSURLSession extends objc.NSObject { /// Creates an upload task with the given request. The body of the request will be created from the file referenced by fileURL NSURLSessionUploadTask uploadTaskWithRequest_fromFile_( NSURLRequest request, objc.NSURL fileURL) { - final _ret = _objc_msgSend_rsfdlh( + final _ret = _objc_msgSend_15qeuct( this.ref.pointer, _sel_uploadTaskWithRequest_fromFile_, request.ref.pointer, @@ -60110,7 +63285,7 @@ class NSURLSession extends objc.NSObject { /// Creates an upload task with the given request. The body of the request is provided from the bodyData. NSURLSessionUploadTask uploadTaskWithRequest_fromData_( NSURLRequest request, objc.NSData bodyData) { - final _ret = _objc_msgSend_rsfdlh( + final _ret = _objc_msgSend_15qeuct( this.ref.pointer, _sel_uploadTaskWithRequest_fromData_, request.ref.pointer, @@ -60128,7 +63303,7 @@ class NSURLSession extends objc.NSObject { /// - Parameter resumeData: Resume data blob from an incomplete upload, such as data returned by the cancelByProducingResumeData: method. /// - Returns: A new session upload task, or nil if the resumeData is invalid. NSURLSessionUploadTask uploadTaskWithResumeData_(objc.NSData resumeData) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_uploadTaskWithResumeData_, resumeData.ref.pointer); return NSURLSessionUploadTask.castFromPointer(_ret, retain: true, release: true); @@ -60136,7 +63311,7 @@ class NSURLSession extends objc.NSObject { /// Creates an upload task with the given request. The previously set body stream of the request (if any) is ignored and the URLSession:task:needNewBodyStream: delegate will be called when the body payload is required. NSURLSessionUploadTask uploadTaskWithStreamedRequest_(NSURLRequest request) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_uploadTaskWithStreamedRequest_, request.ref.pointer); return NSURLSessionUploadTask.castFromPointer(_ret, retain: true, release: true); @@ -60144,7 +63319,7 @@ class NSURLSession extends objc.NSObject { /// Creates a download task with the given request. NSURLSessionDownloadTask downloadTaskWithRequest_(NSURLRequest request) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_downloadTaskWithRequest_, request.ref.pointer); return NSURLSessionDownloadTask.castFromPointer(_ret, retain: true, release: true); @@ -60152,7 +63327,7 @@ class NSURLSession extends objc.NSObject { /// Creates a download task to download the contents of the given URL. NSURLSessionDownloadTask downloadTaskWithURL_(objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_downloadTaskWithURL_, url.ref.pointer); return NSURLSessionDownloadTask.castFromPointer(_ret, retain: true, release: true); @@ -60160,7 +63335,7 @@ class NSURLSession extends objc.NSObject { /// Creates a download task with the resume data. If the download cannot be successfully resumed, URLSession:task:didCompleteWithError: will be called. NSURLSessionDownloadTask downloadTaskWithResumeData_(objc.NSData resumeData) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_downloadTaskWithResumeData_, resumeData.ref.pointer); return NSURLSessionDownloadTask.castFromPointer(_ret, retain: true, release: true); @@ -60169,7 +63344,7 @@ class NSURLSession extends objc.NSObject { /// Creates a bidirectional stream task to a given host and port. NSURLSessionStreamTask streamTaskWithHostName_port_( objc.NSString hostname, DartNSInteger port) { - final _ret = _objc_msgSend_1i26p99(this.ref.pointer, + final _ret = _objc_msgSend_9slupp(this.ref.pointer, _sel_streamTaskWithHostName_port_, hostname.ref.pointer, port); return NSURLSessionStreamTask.castFromPointer(_ret, retain: true, release: true); @@ -60178,7 +63353,7 @@ class NSURLSession extends objc.NSObject { /// Creates a bidirectional stream task with an NSNetService to identify the endpoint. /// The NSNetService will be resolved before any IO completes. NSURLSessionStreamTask streamTaskWithNetService_(NSNetService service) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_streamTaskWithNetService_, service.ref.pointer); return NSURLSessionStreamTask.castFromPointer(_ret, retain: true, release: true); @@ -60186,7 +63361,7 @@ class NSURLSession extends objc.NSObject { /// Creates a WebSocket task given the url. The given url must have a ws or wss scheme. NSURLSessionWebSocketTask webSocketTaskWithURL_(objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_webSocketTaskWithURL_, url.ref.pointer); return NSURLSessionWebSocketTask.castFromPointer(_ret, retain: true, release: true); @@ -60197,7 +63372,7 @@ class NSURLSession extends objc.NSObject { /// Note - The protocol will not affect the WebSocket framing. More details on the protocol can be found by reading the WebSocket RFC NSURLSessionWebSocketTask webSocketTaskWithURL_protocols_( objc.NSURL url, objc.ObjCObjectBase protocols) { - final _ret = _objc_msgSend_rsfdlh( + final _ret = _objc_msgSend_15qeuct( this.ref.pointer, _sel_webSocketTaskWithURL_protocols_, url.ref.pointer, @@ -60210,7 +63385,7 @@ class NSURLSession extends objc.NSObject { /// Clients who want to add custom protocols can do so by directly adding headers with the key Sec-WebSocket-Protocol /// and a comma separated list of protocols they wish to negotiate with the server. The custom HTTP headers provided by the client will remain unchanged for the handshake with the server. NSURLSessionWebSocketTask webSocketTaskWithRequest_(NSURLRequest request) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_webSocketTaskWithRequest_, request.ref.pointer); return NSURLSessionWebSocketTask.castFromPointer(_ret, retain: true, release: true); @@ -60219,44 +63394,44 @@ class NSURLSession extends objc.NSObject { /// init NSURLSession init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSURLSession.castFromPointer(_ret, retain: false, release: true); } /// new static NSURLSession new1() { - final _ret = _objc_msgSend_1x359cv(_class_NSURLSession, _sel_new); + final _ret = _objc_msgSend_151sglz(_class_NSURLSession, _sel_new); return NSURLSession.castFromPointer(_ret, retain: false, release: true); } /// allocWithZone: static NSURLSession allocWithZone_(ffi.Pointer<_NSZone> zone) { final _ret = - _objc_msgSend_hzlb60(_class_NSURLSession, _sel_allocWithZone_, zone); + _objc_msgSend_1cwp428(_class_NSURLSession, _sel_allocWithZone_, zone); return NSURLSession.castFromPointer(_ret, retain: false, release: true); } /// alloc static NSURLSession alloc() { - final _ret = _objc_msgSend_1x359cv(_class_NSURLSession, _sel_alloc); + final _ret = _objc_msgSend_151sglz(_class_NSURLSession, _sel_alloc); return NSURLSession.castFromPointer(_ret, retain: false, release: true); } /// self NSURLSession self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSURLSession.castFromPointer(_ret, retain: true, release: true); } /// retain NSURLSession retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSURLSession.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSURLSession autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSURLSession.castFromPointer(_ret, retain: true, release: true); } } @@ -60375,6 +63550,37 @@ ffi.NativeCallable< ffi.Pointer, NSInteger)>.listener( _ObjCBlock_ffiVoid_NSURLSessionResponseDisposition_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_NSURLSessionResponseDisposition_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + int arg0) { + try { + (objc.getBlockClosure(block) as void Function(int))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, ffi.Pointer, NSInteger)> + _ObjCBlock_ffiVoid_NSURLSessionResponseDisposition_blockingCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, NSInteger)>.isolateLocal( + _ObjCBlock_ffiVoid_NSURLSessionResponseDisposition_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, ffi.Pointer, NSInteger)> + _ObjCBlock_ffiVoid_NSURLSessionResponseDisposition_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, NSInteger)>.listener( + _ObjCBlock_ffiVoid_NSURLSessionResponseDisposition_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSURLSessionResponseDisposition { @@ -60437,6 +63643,35 @@ abstract final class ObjCBlock_ffiVoid_NSURLSessionResponseDisposition { return objc.ObjCBlock(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(NSURLSessionResponseDisposition) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSURLSessionResponseDisposition_blockingCallable + .nativeFunction + .cast(), + (int arg0) => fn(NSURLSessionResponseDisposition.fromValue(arg0))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSURLSessionResponseDisposition_blockingListenerCallable + .nativeFunction + .cast(), + (int arg0) => fn(NSURLSessionResponseDisposition.fromValue(arg0))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_16sve1d, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -60552,6 +63787,71 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLResponse_ffiVoidNSURLSessionResponseDisposition_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLResponse_ffiVoidNSURLSessionResponseDisposition_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3, arg4); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLResponse_ffiVoidNSURLSessionResponseDisposition_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLResponse_ffiVoidNSURLSessionResponseDisposition_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLResponse_ffiVoidNSURLSessionResponseDisposition_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLResponse_ffiVoidNSURLSessionResponseDisposition_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionDataTask, NSURLResponse, objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLResponse_ffiVoidNSURLSessionResponseDisposition { @@ -60653,8 +63953,79 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask retain: false, release: true), ObjCBlock_ffiVoid_NSURLSessionResponseDisposition .castFromPointer(arg4, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1f43wec(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xx612k(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionDataTask, + NSURLResponse, + objc.ObjCBlock)>(wrapper, + retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionDataTask, + NSURLResponse, + objc.ObjCBlock)> blocking( + void Function(ffi.Pointer, NSURLSession, NSURLSessionDataTask, + NSURLResponse, objc.ObjCBlock) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLResponse_ffiVoidNSURLSessionResponseDisposition_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDataTask.castFromPointer(arg2, + retain: false, release: true), + NSURLResponse.castFromPointer(arg3, + retain: false, release: true), + ObjCBlock_ffiVoid_NSURLSessionResponseDisposition + .castFromPointer(arg4, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLResponse_ffiVoidNSURLSessionResponseDisposition_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDataTask.castFromPointer(arg2, + retain: false, release: true), + NSURLResponse.castFromPointer(arg3, + retain: false, release: true), + ObjCBlock_ffiVoid_NSURLSessionResponseDisposition + .castFromPointer(arg4, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xx612k, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function( ffi.Pointer, @@ -60796,6 +64167,65 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionDownloadTask_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionDownloadTask_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionDownloadTask_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionDownloadTask_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionDownloadTask_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionDownloadTask_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionDataTask, NSURLSessionDownloadTask)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionDownloadTask { @@ -60878,7 +64308,7 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask retain: false, release: true), NSURLSessionDownloadTask.castFromPointer(arg3, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1r3kn8f(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1tz5yf(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -60887,6 +64317,65 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask NSURLSessionDataTask, NSURLSessionDownloadTask)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, + NSURLSessionDataTask, NSURLSessionDownloadTask)> blocking( + void Function(ffi.Pointer, NSURLSession, NSURLSessionDataTask, + NSURLSessionDownloadTask) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionDownloadTask_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDataTask.castFromPointer(arg2, + retain: false, release: true), + NSURLSessionDownloadTask.castFromPointer(arg3, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionDownloadTask_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDataTask.castFromPointer(arg2, + retain: false, release: true), + NSURLSessionDownloadTask.castFromPointer(arg3, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1tz5yf, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionDataTask, + NSURLSessionDownloadTask)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionDataTask, NSURLSessionDownloadTask)>`. @@ -61004,6 +64493,65 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionStreamTask_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionStreamTask_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionStreamTask_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionStreamTask_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionStreamTask_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionStreamTask_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionDataTask, NSURLSessionStreamTask)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionStreamTask { @@ -61086,7 +64634,7 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask retain: false, release: true), NSURLSessionStreamTask.castFromPointer(arg3, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1r3kn8f(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1tz5yf(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -61095,6 +64643,65 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask NSURLSessionDataTask, NSURLSessionStreamTask)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, + NSURLSessionDataTask, NSURLSessionStreamTask)> blocking( + void Function(ffi.Pointer, NSURLSession, NSURLSessionDataTask, + NSURLSessionStreamTask) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionStreamTask_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDataTask.castFromPointer(arg2, + retain: false, release: true), + NSURLSessionStreamTask.castFromPointer(arg3, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionStreamTask_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDataTask.castFromPointer(arg2, + retain: false, release: true), + NSURLSessionStreamTask.castFromPointer(arg3, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1tz5yf, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionDataTask, + NSURLSessionStreamTask)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionDataTask, NSURLSessionStreamTask)>`. @@ -61212,6 +64819,65 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSData_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSData_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSData_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSData_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSData_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSData_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionDataTask, objc.NSData)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSData { @@ -61296,8 +64962,67 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask retain: false, release: true), objc.NSData.castFromPointer(arg3, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1r3kn8f(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1tz5yf(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionDataTask, + objc.NSData)>(wrapper, retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, + NSURLSessionDataTask, objc.NSData)> blocking( + void Function(ffi.Pointer, NSURLSession, NSURLSessionDataTask, + objc.NSData) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSData_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDataTask.castFromPointer(arg2, + retain: false, release: true), + objc.NSData.castFromPointer(arg3, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSData_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDataTask.castFromPointer(arg2, + retain: false, release: true), + objc.NSData.castFromPointer(arg3, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1tz5yf, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function( ffi.Pointer, @@ -61434,6 +65159,71 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSCachedURLResponse_ffiVoidNSCachedURLResponse_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSCachedURLResponse_ffiVoidNSCachedURLResponse_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3, arg4); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSCachedURLResponse_ffiVoidNSCachedURLResponse_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSCachedURLResponse_ffiVoidNSCachedURLResponse_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSCachedURLResponse_ffiVoidNSCachedURLResponse_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSCachedURLResponse_ffiVoidNSCachedURLResponse_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionDataTask, NSCachedURLResponse, objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSCachedURLResponse_ffiVoidNSCachedURLResponse { @@ -61539,7 +65329,7 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask retain: false, release: true), ObjCBlock_ffiVoid_NSCachedURLResponse.castFromPointer(arg4, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1f43wec(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xx612k(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -61552,6 +65342,83 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionDataTask, + NSCachedURLResponse, + objc.ObjCBlock)> blocking( + void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionDataTask, + NSCachedURLResponse, + objc.ObjCBlock) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSCachedURLResponse_ffiVoidNSCachedURLResponse_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDataTask.castFromPointer(arg2, + retain: false, release: true), + NSCachedURLResponse.castFromPointer(arg3, + retain: false, release: true), + ObjCBlock_ffiVoid_NSCachedURLResponse.castFromPointer(arg4, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSCachedURLResponse_ffiVoidNSCachedURLResponse_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDataTask.castFromPointer(arg2, + retain: false, release: true), + NSCachedURLResponse.castFromPointer(arg3, + retain: false, release: true), + ObjCBlock_ffiVoid_NSCachedURLResponse.castFromPointer(arg4, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xx612k, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionDataTask, + NSCachedURLResponse, + objc.ObjCBlock)>( + wrapper, + retain: false, + release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionDataTask, NSCachedURLResponse, objc.ObjCBlock)>`. @@ -61669,6 +65536,59 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionTask)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask { @@ -61745,12 +65665,58 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask { retain: false, release: true), NSURLSessionTask.castFromPointer(arg2, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_ao4xm9(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_fjrv01(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function(ffi.Pointer, NSURLSession, NSURLSessionTask)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, NSURLSession, NSURLSessionTask)> blocking( + void Function(ffi.Pointer, NSURLSession, NSURLSessionTask) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_fjrv01, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, + NSURLSessionTask)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionTask)>`. @@ -61829,6 +65795,46 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSURLRequest_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSURLRequest_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + int arg0, + ffi.Pointer arg1) { + try { + (objc.getBlockClosure(block) as void Function( + int, ffi.Pointer))(arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, NSInteger, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSURLRequest_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + NSInteger, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSURLRequest_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, NSInteger, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSURLRequest_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + NSInteger, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSURLRequest_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSURLRequest { @@ -61894,11 +65900,50 @@ abstract final class ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSU ? null : NSURLRequest.castFromPointer(arg1, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_mn1xu3(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1otpo83(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(NSURLSessionDelayedRequestDisposition, NSURLRequest?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSURLRequest_blockingCallable + .nativeFunction + .cast(), + (int arg0, ffi.Pointer arg1) => fn( + NSURLSessionDelayedRequestDisposition.fromValue(arg0), + arg1.address == 0 + ? null + : NSURLRequest.castFromPointer(arg1, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSURLRequest_blockingListenerCallable + .nativeFunction + .cast(), + (int arg0, ffi.Pointer arg1) => fn( + NSURLSessionDelayedRequestDisposition.fromValue(arg0), + arg1.address == 0 + ? null + : NSURLRequest.castFromPointer(arg1, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1otpo83, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -62018,6 +66063,71 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLRequest_ffiVoidNSURLSessionDelayedRequestDispositionNSURLRequest_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLRequest_ffiVoidNSURLSessionDelayedRequestDispositionNSURLRequest_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3, arg4); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLRequest_ffiVoidNSURLSessionDelayedRequestDispositionNSURLRequest_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLRequest_ffiVoidNSURLSessionDelayedRequestDispositionNSURLRequest_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLRequest_ffiVoidNSURLSessionDelayedRequestDispositionNSURLRequest_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLRequest_ffiVoidNSURLSessionDelayedRequestDispositionNSURLRequest_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, NSURLRequest, objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLRequest_ffiVoidNSURLSessionDelayedRequestDispositionNSURLRequest { @@ -62124,7 +66234,7 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSU retain: false, release: true), ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSURLRequest .castFromPointer(arg4, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1f43wec(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xx612k(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -62137,6 +66247,84 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSU retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + NSURLRequest, + objc.ObjCBlock)> + blocking( + void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + NSURLRequest, + objc.ObjCBlock) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLRequest_ffiVoidNSURLSessionDelayedRequestDispositionNSURLRequest_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + NSURLRequest.castFromPointer(arg3, + retain: false, release: true), + ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSURLRequest + .castFromPointer(arg4, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLRequest_ffiVoidNSURLSessionDelayedRequestDispositionNSURLRequest_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + NSURLRequest.castFromPointer(arg3, + retain: false, release: true), + ObjCBlock_ffiVoid_NSURLSessionDelayedRequestDisposition_NSURLRequest + .castFromPointer(arg4, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xx612k, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + NSURLRequest, + objc.ObjCBlock)>( + wrapper, + retain: false, + release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, NSURLRequest, objc.ObjCBlock)>`. @@ -62185,7 +66373,7 @@ late final _sel_URLSession_taskIsWaitingForConnectivity_ = late final _class_NSHTTPURLResponse = objc.getClass("NSHTTPURLResponse"); late final _sel_initWithURL_statusCode_HTTPVersion_headerFields_ = objc.registerName("initWithURL:statusCode:HTTPVersion:headerFields:"); -final _objc_msgSend_1pmy6mh = objc.msgSendPointer +final _objc_msgSend_xw7l5 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -62207,7 +66395,7 @@ late final _sel_statusCode = objc.registerName("statusCode"); late final _sel_allHeaderFields = objc.registerName("allHeaderFields"); late final _sel_localizedStringForStatusCode_ = objc.registerName("localizedStringForStatusCode:"); -final _objc_msgSend_8o14b = objc.msgSendPointer +final _objc_msgSend_qugqlf = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -62233,7 +66421,7 @@ class NSHTTPURLResponse extends NSURLResponse { /// Returns whether [obj] is an instance of [NSHTTPURLResponse]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( obj.ref.pointer, _sel_isKindOfClass_, _class_NSHTTPURLResponse); } @@ -62251,7 +66439,7 @@ class NSHTTPURLResponse extends NSURLResponse { DartNSInteger statusCode, objc.NSString? HTTPVersion, objc.NSDictionary? headerFields) { - final _ret = _objc_msgSend_1pmy6mh( + final _ret = _objc_msgSend_xw7l5( this.ref.retainAndReturnPointer(), _sel_initWithURL_statusCode_HTTPVersion_headerFields_, url.ref.pointer, @@ -62280,7 +66468,7 @@ class NSHTTPURLResponse extends NSURLResponse { /// @result A dictionary containing all the HTTP header fields of the /// receiver. objc.NSDictionary get allHeaderFields { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_allHeaderFields); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_allHeaderFields); return objc.NSDictionary.castFromPointer(_ret, retain: true, release: true); } @@ -62294,7 +66482,7 @@ class NSHTTPURLResponse extends NSURLResponse { /// @result the value associated with the given header field, or nil if /// there is no value associated with the given header field. objc.NSString? valueForHTTPHeaderField_(objc.NSString field) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_valueForHTTPHeaderField_, field.ref.pointer); return _ret.address == 0 ? null @@ -62308,7 +66496,7 @@ class NSHTTPURLResponse extends NSURLResponse { /// @param statusCode the status code to use to produce a localized string. /// @result A localized string corresponding to the given status code. static objc.NSString localizedStringForStatusCode_(DartNSInteger statusCode) { - final _ret = _objc_msgSend_8o14b(_class_NSHTTPURLResponse, + final _ret = _objc_msgSend_qugqlf(_class_NSHTTPURLResponse, _sel_localizedStringForStatusCode_, statusCode); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -62328,7 +66516,7 @@ class NSHTTPURLResponse extends NSURLResponse { objc.NSString? MIMEType, DartNSInteger length, objc.NSString? name) { - final _ret = _objc_msgSend_13tl325( + final _ret = _objc_msgSend_l9ppnx( this.ref.retainAndReturnPointer(), _sel_initWithURL_MIMEType_expectedContentLength_textEncodingName_, URL.ref.pointer, @@ -62342,21 +66530,21 @@ class NSHTTPURLResponse extends NSURLResponse { /// init NSHTTPURLResponse init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSHTTPURLResponse.castFromPointer(_ret, retain: false, release: true); } /// new static NSHTTPURLResponse new1() { - final _ret = _objc_msgSend_1x359cv(_class_NSHTTPURLResponse, _sel_new); + final _ret = _objc_msgSend_151sglz(_class_NSHTTPURLResponse, _sel_new); return NSHTTPURLResponse.castFromPointer(_ret, retain: false, release: true); } /// allocWithZone: static NSHTTPURLResponse allocWithZone_(ffi.Pointer<_NSZone> zone) { - final _ret = _objc_msgSend_hzlb60( + final _ret = _objc_msgSend_1cwp428( _class_NSHTTPURLResponse, _sel_allocWithZone_, zone); return NSHTTPURLResponse.castFromPointer(_ret, retain: false, release: true); @@ -62364,26 +66552,26 @@ class NSHTTPURLResponse extends NSURLResponse { /// alloc static NSHTTPURLResponse alloc() { - final _ret = _objc_msgSend_1x359cv(_class_NSHTTPURLResponse, _sel_alloc); + final _ret = _objc_msgSend_151sglz(_class_NSHTTPURLResponse, _sel_alloc); return NSHTTPURLResponse.castFromPointer(_ret, retain: false, release: true); } /// self NSHTTPURLResponse self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSHTTPURLResponse.castFromPointer(_ret, retain: true, release: true); } /// retain NSHTTPURLResponse retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSHTTPURLResponse.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSHTTPURLResponse autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSHTTPURLResponse.castFromPointer(_ret, retain: true, release: true); } @@ -62395,7 +66583,7 @@ class NSHTTPURLResponse extends NSURLResponse { /// initWithCoder: NSHTTPURLResponse? initWithCoder_(objc.NSCoder coder) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithCoder_, coder.ref.pointer); return _ret.address == 0 ? null @@ -62443,6 +66631,39 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSURLRequest_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_NSURLRequest_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSURLRequest_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSURLRequest_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSURLRequest_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSURLRequest_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSURLRequest { @@ -62504,8 +66725,40 @@ abstract final class ObjCBlock_ffiVoid_NSURLRequest { ? null : NSURLRequest.castFromPointer(arg0, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1jdvcbf(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xtuoz7(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(NSURLRequest?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSURLRequest_blockingCallable.nativeFunction.cast(), + (ffi.Pointer arg0) => fn(arg0.address == 0 + ? null + : NSURLRequest.castFromPointer(arg0, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSURLRequest_blockingListenerCallable.nativeFunction + .cast(), + (ffi.Pointer arg0) => fn(arg0.address == 0 + ? null + : NSURLRequest.castFromPointer(arg0, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xtuoz7, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock(wrapper, retain: false, release: true); } @@ -62639,6 +66892,77 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_NSURLRequest_ffiVoidNSURLRequest_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_NSURLRequest_ffiVoidNSURLRequest_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4, + ffi.Pointer arg5) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3, arg4, arg5); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_NSURLRequest_ffiVoidNSURLRequest_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_NSURLRequest_ffiVoidNSURLRequest_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_NSURLRequest_ffiVoidNSURLRequest_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_NSURLRequest_ffiVoidNSURLRequest_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, NSHTTPURLResponse, NSURLRequest, objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_NSURLRequest_ffiVoidNSURLRequest { @@ -62754,8 +67078,92 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSH retain: false, release: true), ObjCBlock_ffiVoid_NSURLRequest.castFromPointer(arg5, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_13vswqm(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_l2g8ke(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + NSHTTPURLResponse, + NSURLRequest, + objc.ObjCBlock)>(wrapper, + retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + NSHTTPURLResponse, + NSURLRequest, + objc.ObjCBlock)> blocking( + void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + NSHTTPURLResponse, + NSURLRequest, + objc.ObjCBlock) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_NSURLRequest_ffiVoidNSURLRequest_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4, + ffi.Pointer arg5) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + NSHTTPURLResponse.castFromPointer(arg3, + retain: false, release: true), + NSURLRequest.castFromPointer(arg4, + retain: false, release: true), + ObjCBlock_ffiVoid_NSURLRequest.castFromPointer(arg5, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_NSURLRequest_ffiVoidNSURLRequest_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4, + ffi.Pointer arg5) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + NSHTTPURLResponse.castFromPointer(arg3, + retain: false, release: true), + NSURLRequest.castFromPointer(arg4, + retain: false, release: true), + ObjCBlock_ffiVoid_NSURLRequest.castFromPointer(arg5, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_l2g8ke, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function( ffi.Pointer, @@ -62906,6 +67314,46 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + int arg0, + ffi.Pointer arg1) { + try { + (objc.getBlockClosure(block) as void Function( + int, ffi.Pointer))(arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, NSInteger, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + NSInteger, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, NSInteger, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + NSInteger, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential { @@ -62975,8 +67423,51 @@ abstract final class ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSUR ? null : NSURLCredential.castFromPointer(arg1, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_37btrl(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_n8yd09(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock( + wrapper, + retain: false, + release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock + blocking( + void Function(NSURLSessionAuthChallengeDisposition, NSURLCredential?) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential_blockingCallable + .nativeFunction + .cast(), + (int arg0, ffi.Pointer arg1) => fn( + NSURLSessionAuthChallengeDisposition.fromValue(arg0), + arg1.address == 0 + ? null + : NSURLCredential.castFromPointer(arg1, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential_blockingListenerCallable + .nativeFunction + .cast(), + (int arg0, ffi.Pointer arg1) => fn( + NSURLSessionAuthChallengeDisposition.fromValue(arg0), + arg1.address == 0 + ? null + : NSURLCredential.castFromPointer(arg1, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_n8yd09, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock( wrapper, retain: false, @@ -63100,6 +67591,71 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3, arg4); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, NSURLAuthenticationChallenge, objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential { @@ -63206,7 +67762,7 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSU retain: false, release: true), ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential .castFromPointer(arg4, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1f43wec(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xx612k(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -63218,6 +67774,83 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSU ffi.Void Function(NSInteger, NSURLCredential?)>)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + NSURLAuthenticationChallenge, + objc.ObjCBlock< + ffi.Void Function(NSInteger, NSURLCredential?)>)> blocking( + void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + NSURLAuthenticationChallenge, + objc.ObjCBlock) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + NSURLAuthenticationChallenge.castFromPointer(arg3, + retain: false, release: true), + ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential + .castFromPointer(arg4, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + NSURLAuthenticationChallenge.castFromPointer(arg3, + retain: false, release: true), + ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential + .castFromPointer(arg4, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xx612k, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + NSURLAuthenticationChallenge, + objc.ObjCBlock< + ffi.Void Function(NSInteger, NSURLCredential?)>)>(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, NSURLAuthenticationChallenge, objc.ObjCBlock)>`. @@ -63297,6 +67930,39 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSInputStream_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_NSInputStream_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSInputStream_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSInputStream_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_NSInputStream_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSInputStream_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSInputStream { @@ -63358,8 +68024,40 @@ abstract final class ObjCBlock_ffiVoid_NSInputStream { ? null : objc.NSInputStream.castFromPointer(arg0, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1jdvcbf(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_xtuoz7(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock(wrapper, + retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock blocking( + void Function(objc.NSInputStream?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSInputStream_blockingCallable.nativeFunction.cast(), + (ffi.Pointer arg0) => fn(arg0.address == 0 + ? null + : objc.NSInputStream.castFromPointer(arg0, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSInputStream_blockingListenerCallable.nativeFunction + .cast(), + (ffi.Pointer arg0) => fn(arg0.address == 0 + ? null + : objc.NSInputStream.castFromPointer(arg0, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_xtuoz7, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock(wrapper, retain: false, release: true); } @@ -63468,6 +68166,65 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffiVoidNSInputStream_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffiVoidNSInputStream_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffiVoidNSInputStream_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffiVoidNSInputStream_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffiVoidNSInputStream_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffiVoidNSInputStream_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffiVoidNSInputStream { @@ -63558,7 +68315,7 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffi retain: false, release: true), ObjCBlock_ffiVoid_NSInputStream.castFromPointer(arg3, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_12nszru(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_bklti2(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -63570,6 +68327,68 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffi retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, + objc.ObjCBlock)> blocking( + void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, + objc.ObjCBlock) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffiVoidNSInputStream_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + ObjCBlock_ffiVoid_NSInputStream.castFromPointer(arg3, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffiVoidNSInputStream_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + ObjCBlock_ffiVoid_NSInputStream.castFromPointer(arg3, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_bklti2, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + objc.ObjCBlock)>( + wrapper, + retain: false, + release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, objc.ObjCBlock)>`. @@ -63703,6 +68522,71 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_ffiVoidNSInputStream_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_ffiVoidNSInputStream_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + ffi.Pointer arg4) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + int, + ffi.Pointer))(arg0, arg1, arg2, arg3, arg4); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_ffiVoidNSInputStream_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_ffiVoidNSInputStream_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_ffiVoidNSInputStream_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_ffiVoidNSInputStream_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, ffi.Int64, objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_ffiVoidNSInputStream { @@ -63800,7 +68684,7 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int arg3, ObjCBlock_ffiVoid_NSInputStream.castFromPointer(arg4, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_qm01og(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_jyim80(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -63813,6 +68697,77 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + ffi.Int64, + objc.ObjCBlock)> blocking( + void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, int, + objc.ObjCBlock) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_ffiVoidNSInputStream_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + ffi.Pointer arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + arg3, + ObjCBlock_ffiVoid_NSInputStream.castFromPointer(arg4, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_ffiVoidNSInputStream_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + ffi.Pointer arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + arg3, + ObjCBlock_ffiVoid_NSInputStream.castFromPointer(arg4, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_jyim80, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + ffi.Int64, + objc.ObjCBlock)>( + wrapper, + retain: false, + release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, ffi.Int64, objc.ObjCBlock)>`. @@ -63963,6 +68918,77 @@ ffi.NativeCallable< ffi.Int64)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_Int64_Int64_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_Int64_Int64_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + int arg4, + int arg5) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + int, + int, + int))(arg0, arg1, arg2, arg3, arg4, arg5); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Int64, + ffi.Int64)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_Int64_Int64_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Int64, + ffi.Int64)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_Int64_Int64_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Int64, + ffi.Int64)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_Int64_Int64_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Int64, + ffi.Int64)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_Int64_Int64_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, ffi.Int64, ffi.Int64, ffi.Int64)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_Int64_Int64 { @@ -64060,8 +69086,75 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int arg3, arg4, arg5)); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1uuez7b(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_h68abb(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionTask, + ffi.Int64, + ffi.Int64, + ffi.Int64)>(wrapper, retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, + ffi.Int64, ffi.Int64, ffi.Int64)> blocking( + void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, int, + int, int) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_Int64_Int64_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + int arg4, + int arg5) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + arg3, + arg4, + arg5)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_Int64_Int64_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + int arg4, + int arg5) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + arg3, + arg4, + arg5)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_h68abb, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function( ffi.Pointer, @@ -64192,6 +69285,65 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, NSHTTPURLResponse)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse { @@ -64275,8 +69427,64 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSH retain: false, release: true), NSHTTPURLResponse.castFromPointer(arg3, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1r3kn8f(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1tz5yf(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, + NSHTTPURLResponse)>(wrapper, retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, + NSHTTPURLResponse)> blocking( + void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, + NSHTTPURLResponse) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + NSHTTPURLResponse.castFromPointer(arg3, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + NSHTTPURLResponse.castFromPointer(arg3, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1tz5yf, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, NSHTTPURLResponse)>(wrapper, retain: false, release: true); @@ -64417,6 +69625,65 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLSessionTaskMetrics_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLSessionTaskMetrics_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLSessionTaskMetrics_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLSessionTaskMetrics_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLSessionTaskMetrics_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLSessionTaskMetrics_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, NSURLSessionTaskMetrics)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLSessionTaskMetrics { @@ -64499,12 +69766,68 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSU retain: false, release: true), NSURLSessionTaskMetrics.castFromPointer(arg3, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1r3kn8f(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1tz5yf(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, NSURLSessionTaskMetrics)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, + NSURLSessionTaskMetrics)> blocking( + void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, + NSURLSessionTaskMetrics) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLSessionTaskMetrics_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + NSURLSessionTaskMetrics.castFromPointer(arg3, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLSessionTaskMetrics_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + NSURLSessionTaskMetrics.castFromPointer(arg3, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1tz5yf, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, + NSURLSessionTaskMetrics)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, NSURLSessionTaskMetrics)>`. @@ -64622,6 +69945,65 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSError_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSError_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSError_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSError_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSError_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSError_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, objc.NSError?)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSError { @@ -64708,12 +70090,72 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSE ? null : objc.NSError.castFromPointer(arg3, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1r3kn8f(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1tz5yf(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, objc.NSError?)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, + objc.NSError?)> blocking( + void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, + objc.NSError?) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSError_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + arg3.address == 0 + ? null + : objc.NSError.castFromPointer(arg3, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSError_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionTask.castFromPointer(arg2, + retain: false, release: true), + arg3.address == 0 + ? null + : objc.NSError.castFromPointer(arg3, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1tz5yf, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, NSURLSessionTask, + objc.NSError?)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionTask, objc.NSError?)>`. @@ -64815,6 +70257,58 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError_blockingCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, objc.NSError?)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError { @@ -64889,8 +70383,58 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError { ? null : objc.NSError.castFromPointer(arg2, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_ao4xm9(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_fjrv01(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, + objc.NSError?)>(wrapper, retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, NSURLSession, objc.NSError?)> blocking( + void Function(ffi.Pointer, NSURLSession, objc.NSError?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + arg2.address == 0 + ? null + : objc.NSError.castFromPointer(arg2, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + arg2.address == 0 + ? null + : objc.NSError.castFromPointer(arg2, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_fjrv01, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function(ffi.Pointer, NSURLSession, objc.NSError?)>(wrapper, retain: false, release: true); @@ -65009,6 +70553,65 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLAuthenticationChallenge, objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential { @@ -65106,8 +70709,76 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationC retain: false, release: true), ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential .castFromPointer(arg3, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_12nszru(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_bklti2(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLAuthenticationChallenge, + objc.ObjCBlock< + ffi.Void Function(NSInteger, NSURLCredential?)>)>(wrapper, + retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLAuthenticationChallenge, + objc.ObjCBlock< + ffi.Void Function(NSInteger, NSURLCredential?)>)> blocking( + void Function( + ffi.Pointer, + NSURLSession, + NSURLAuthenticationChallenge, + objc.ObjCBlock) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLAuthenticationChallenge.castFromPointer(arg2, + retain: false, release: true), + ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential + .castFromPointer(arg3, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLAuthenticationChallenge.castFromPointer(arg2, + retain: false, release: true), + ObjCBlock_ffiVoid_NSURLSessionAuthChallengeDisposition_NSURLCredential + .castFromPointer(arg3, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_bklti2, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function( ffi.Pointer, @@ -65202,6 +70873,51 @@ ffi.NativeCallable< ffi.Pointer, ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, ffi.Pointer))(arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_blockingCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession { @@ -65265,12 +70981,45 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession { (ffi.Pointer arg0, ffi.Pointer arg1) => fn( arg0, NSURLSession.castFromPointer(arg1, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_wjovn7(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_18v1jvf(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function(ffi.Pointer, NSURLSession)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock, NSURLSession)> + blocking(void Function(ffi.Pointer, NSURLSession) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_blockingCallable.nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1) => fn( + arg0, + NSURLSession.castFromPointer(arg1, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1) => fn( + arg0, + NSURLSession.castFromPointer(arg1, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_18v1jvf, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession)>(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession)>`. @@ -65653,6 +71402,192 @@ abstract final class NSURLSessionDataDelegate { builder, URLSessionDidFinishEventsForBackgroundURLSession_); } + /// Builds an object that implements the NSURLSessionDataDelegate protocol. To implement + /// multiple protocols, use [addToBuilder] or [objc.ObjCProtocolBuilder] directly. All + /// methods that can be implemented as blocking listeners will be. + static objc.ObjCObjectBase implementAsBlocking( + {void Function(NSURLSession, NSURLSessionDataTask, NSURLResponse, objc.ObjCBlock)? + URLSession_dataTask_didReceiveResponse_completionHandler_, + void Function(NSURLSession, NSURLSessionDataTask, NSURLSessionDownloadTask)? + URLSession_dataTask_didBecomeDownloadTask_, + void Function(NSURLSession, NSURLSessionDataTask, NSURLSessionStreamTask)? + URLSession_dataTask_didBecomeStreamTask_, + void Function(NSURLSession, NSURLSessionDataTask, objc.NSData)? + URLSession_dataTask_didReceiveData_, + void Function(NSURLSession, NSURLSessionDataTask, NSCachedURLResponse, + objc.ObjCBlock)? + URLSession_dataTask_willCacheResponse_completionHandler_, + void Function(NSURLSession, NSURLSessionTask)? URLSession_didCreateTask_, + void Function(NSURLSession, NSURLSessionTask, NSURLRequest, objc.ObjCBlock)? + URLSession_task_willBeginDelayedRequest_completionHandler_, + void Function(NSURLSession, NSURLSessionTask)? + URLSession_taskIsWaitingForConnectivity_, + void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse, + NSURLRequest, objc.ObjCBlock)? + URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_, + void Function(NSURLSession, NSURLSessionTask, NSURLAuthenticationChallenge, objc.ObjCBlock)? URLSession_task_didReceiveChallenge_completionHandler_, + void Function(NSURLSession, NSURLSessionTask, objc.ObjCBlock)? URLSession_task_needNewBodyStream_, + void Function(NSURLSession, NSURLSessionTask, int, objc.ObjCBlock)? URLSession_task_needNewBodyStreamFromOffset_completionHandler_, + void Function(NSURLSession, NSURLSessionTask, int, int, int)? URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_, + void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse)? URLSession_task_didReceiveInformationalResponse_, + void Function(NSURLSession, NSURLSessionTask, NSURLSessionTaskMetrics)? URLSession_task_didFinishCollectingMetrics_, + void Function(NSURLSession, NSURLSessionTask, objc.NSError?)? URLSession_task_didCompleteWithError_, + void Function(NSURLSession, objc.NSError?)? URLSession_didBecomeInvalidWithError_, + void Function(NSURLSession, NSURLAuthenticationChallenge, objc.ObjCBlock)? URLSession_didReceiveChallenge_completionHandler_, + void Function(NSURLSession)? URLSessionDidFinishEventsForBackgroundURLSession_}) { + final builder = objc.ObjCProtocolBuilder(); + NSURLSessionDataDelegate + .URLSession_dataTask_didReceiveResponse_completionHandler_ + .implementAsBlocking( + builder, URLSession_dataTask_didReceiveResponse_completionHandler_); + NSURLSessionDataDelegate.URLSession_dataTask_didBecomeDownloadTask_ + .implementAsBlocking( + builder, URLSession_dataTask_didBecomeDownloadTask_); + NSURLSessionDataDelegate.URLSession_dataTask_didBecomeStreamTask_ + .implementAsBlocking(builder, URLSession_dataTask_didBecomeStreamTask_); + NSURLSessionDataDelegate.URLSession_dataTask_didReceiveData_ + .implementAsBlocking(builder, URLSession_dataTask_didReceiveData_); + NSURLSessionDataDelegate + .URLSession_dataTask_willCacheResponse_completionHandler_ + .implementAsBlocking( + builder, URLSession_dataTask_willCacheResponse_completionHandler_); + NSURLSessionDataDelegate.URLSession_didCreateTask_.implementAsBlocking( + builder, URLSession_didCreateTask_); + NSURLSessionDataDelegate + .URLSession_task_willBeginDelayedRequest_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_willBeginDelayedRequest_completionHandler_); + NSURLSessionDataDelegate.URLSession_taskIsWaitingForConnectivity_ + .implementAsBlocking(builder, URLSession_taskIsWaitingForConnectivity_); + NSURLSessionDataDelegate + .URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_); + NSURLSessionDataDelegate + .URLSession_task_didReceiveChallenge_completionHandler_ + .implementAsBlocking( + builder, URLSession_task_didReceiveChallenge_completionHandler_); + NSURLSessionDataDelegate.URLSession_task_needNewBodyStream_ + .implementAsBlocking(builder, URLSession_task_needNewBodyStream_); + NSURLSessionDataDelegate + .URLSession_task_needNewBodyStreamFromOffset_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_needNewBodyStreamFromOffset_completionHandler_); + NSURLSessionDataDelegate + .URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_ + .implementAsBlocking(builder, + URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_); + NSURLSessionDataDelegate.URLSession_task_didReceiveInformationalResponse_ + .implementAsBlocking( + builder, URLSession_task_didReceiveInformationalResponse_); + NSURLSessionDataDelegate.URLSession_task_didFinishCollectingMetrics_ + .implementAsBlocking( + builder, URLSession_task_didFinishCollectingMetrics_); + NSURLSessionDataDelegate.URLSession_task_didCompleteWithError_ + .implementAsBlocking(builder, URLSession_task_didCompleteWithError_); + NSURLSessionDataDelegate.URLSession_didBecomeInvalidWithError_ + .implementAsBlocking(builder, URLSession_didBecomeInvalidWithError_); + NSURLSessionDataDelegate.URLSession_didReceiveChallenge_completionHandler_ + .implementAsBlocking( + builder, URLSession_didReceiveChallenge_completionHandler_); + NSURLSessionDataDelegate.URLSessionDidFinishEventsForBackgroundURLSession_ + .implementAsBlocking( + builder, URLSessionDidFinishEventsForBackgroundURLSession_); + return builder.build(); + } + + /// Adds the implementation of the NSURLSessionDataDelegate protocol to an existing + /// [objc.ObjCProtocolBuilder]. All methods that can be implemented as blocking + /// listeners will be. + static void addToBuilderAsBlocking(objc.ObjCProtocolBuilder builder, + {void Function(NSURLSession, NSURLSessionDataTask, NSURLResponse, objc.ObjCBlock)? + URLSession_dataTask_didReceiveResponse_completionHandler_, + void Function(NSURLSession, NSURLSessionDataTask, NSURLSessionDownloadTask)? + URLSession_dataTask_didBecomeDownloadTask_, + void Function(NSURLSession, NSURLSessionDataTask, NSURLSessionStreamTask)? + URLSession_dataTask_didBecomeStreamTask_, + void Function(NSURLSession, NSURLSessionDataTask, objc.NSData)? + URLSession_dataTask_didReceiveData_, + void Function(NSURLSession, NSURLSessionDataTask, NSCachedURLResponse, + objc.ObjCBlock)? + URLSession_dataTask_willCacheResponse_completionHandler_, + void Function(NSURLSession, NSURLSessionTask)? URLSession_didCreateTask_, + void Function(NSURLSession, NSURLSessionTask, NSURLRequest, objc.ObjCBlock)? + URLSession_task_willBeginDelayedRequest_completionHandler_, + void Function(NSURLSession, NSURLSessionTask)? + URLSession_taskIsWaitingForConnectivity_, + void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse, + NSURLRequest, objc.ObjCBlock)? + URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_, + void Function(NSURLSession, NSURLSessionTask, NSURLAuthenticationChallenge, objc.ObjCBlock)? URLSession_task_didReceiveChallenge_completionHandler_, + void Function(NSURLSession, NSURLSessionTask, objc.ObjCBlock)? URLSession_task_needNewBodyStream_, + void Function(NSURLSession, NSURLSessionTask, int, objc.ObjCBlock)? URLSession_task_needNewBodyStreamFromOffset_completionHandler_, + void Function(NSURLSession, NSURLSessionTask, int, int, int)? URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_, + void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse)? URLSession_task_didReceiveInformationalResponse_, + void Function(NSURLSession, NSURLSessionTask, NSURLSessionTaskMetrics)? URLSession_task_didFinishCollectingMetrics_, + void Function(NSURLSession, NSURLSessionTask, objc.NSError?)? URLSession_task_didCompleteWithError_, + void Function(NSURLSession, objc.NSError?)? URLSession_didBecomeInvalidWithError_, + void Function(NSURLSession, NSURLAuthenticationChallenge, objc.ObjCBlock)? URLSession_didReceiveChallenge_completionHandler_, + void Function(NSURLSession)? URLSessionDidFinishEventsForBackgroundURLSession_}) { + NSURLSessionDataDelegate + .URLSession_dataTask_didReceiveResponse_completionHandler_ + .implementAsBlocking( + builder, URLSession_dataTask_didReceiveResponse_completionHandler_); + NSURLSessionDataDelegate.URLSession_dataTask_didBecomeDownloadTask_ + .implementAsBlocking( + builder, URLSession_dataTask_didBecomeDownloadTask_); + NSURLSessionDataDelegate.URLSession_dataTask_didBecomeStreamTask_ + .implementAsBlocking(builder, URLSession_dataTask_didBecomeStreamTask_); + NSURLSessionDataDelegate.URLSession_dataTask_didReceiveData_ + .implementAsBlocking(builder, URLSession_dataTask_didReceiveData_); + NSURLSessionDataDelegate + .URLSession_dataTask_willCacheResponse_completionHandler_ + .implementAsBlocking( + builder, URLSession_dataTask_willCacheResponse_completionHandler_); + NSURLSessionDataDelegate.URLSession_didCreateTask_.implementAsBlocking( + builder, URLSession_didCreateTask_); + NSURLSessionDataDelegate + .URLSession_task_willBeginDelayedRequest_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_willBeginDelayedRequest_completionHandler_); + NSURLSessionDataDelegate.URLSession_taskIsWaitingForConnectivity_ + .implementAsBlocking(builder, URLSession_taskIsWaitingForConnectivity_); + NSURLSessionDataDelegate + .URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_); + NSURLSessionDataDelegate + .URLSession_task_didReceiveChallenge_completionHandler_ + .implementAsBlocking( + builder, URLSession_task_didReceiveChallenge_completionHandler_); + NSURLSessionDataDelegate.URLSession_task_needNewBodyStream_ + .implementAsBlocking(builder, URLSession_task_needNewBodyStream_); + NSURLSessionDataDelegate + .URLSession_task_needNewBodyStreamFromOffset_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_needNewBodyStreamFromOffset_completionHandler_); + NSURLSessionDataDelegate + .URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_ + .implementAsBlocking(builder, + URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_); + NSURLSessionDataDelegate.URLSession_task_didReceiveInformationalResponse_ + .implementAsBlocking( + builder, URLSession_task_didReceiveInformationalResponse_); + NSURLSessionDataDelegate.URLSession_task_didFinishCollectingMetrics_ + .implementAsBlocking( + builder, URLSession_task_didFinishCollectingMetrics_); + NSURLSessionDataDelegate.URLSession_task_didCompleteWithError_ + .implementAsBlocking(builder, URLSession_task_didCompleteWithError_); + NSURLSessionDataDelegate.URLSession_didBecomeInvalidWithError_ + .implementAsBlocking(builder, URLSession_didBecomeInvalidWithError_); + NSURLSessionDataDelegate.URLSession_didReceiveChallenge_completionHandler_ + .implementAsBlocking( + builder, URLSession_didReceiveChallenge_completionHandler_); + NSURLSessionDataDelegate.URLSessionDidFinishEventsForBackgroundURLSession_ + .implementAsBlocking( + builder, URLSessionDidFinishEventsForBackgroundURLSession_); + } + /// The task has received a response and no further messages will be /// received until the completion block is called. The disposition /// allows you to cancel a request or to turn a data task into a @@ -65692,6 +71627,16 @@ abstract final class NSURLSessionDataDelegate { NSURLResponse arg3, objc.ObjCBlock arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionDataTask, NSURLResponse, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLResponse_ffiVoidNSURLSessionResponseDisposition + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionDataTask arg2, + NSURLResponse arg3, + objc.ObjCBlock arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Notification that a data task has become a download task. No @@ -65720,6 +71665,12 @@ abstract final class NSURLSessionDataDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionDataTask arg2, NSURLSessionDownloadTask arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionDataTask, NSURLSessionDownloadTask) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionDownloadTask + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionDataTask arg2, NSURLSessionDownloadTask arg3) => + func(arg1, arg2, arg3)), ); /// Notification that a data task has become a bidirectional stream @@ -65760,6 +71711,12 @@ abstract final class NSURLSessionDataDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionDataTask arg2, NSURLSessionStreamTask arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionDataTask, NSURLSessionStreamTask) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSURLSessionStreamTask + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionDataTask arg2, NSURLSessionStreamTask arg3) => + func(arg1, arg2, arg3)), ); /// Sent when data is available for the delegate to consume. As the @@ -65786,6 +71743,11 @@ abstract final class NSURLSessionDataDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionDataTask arg2, objc.NSData arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionDataTask, objc.NSData) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSData + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionDataTask arg2, objc.NSData arg3) => + func(arg1, arg2, arg3)), ); /// Invoke the completion routine with a valid NSCachedURLResponse to @@ -65827,6 +71789,17 @@ abstract final class NSURLSessionDataDelegate { objc.ObjCBlock arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionDataTask, NSCachedURLResponse, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDataTask_NSCachedURLResponse_ffiVoidNSCachedURLResponse + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionDataTask arg2, + NSCachedURLResponse arg3, + objc.ObjCBlock + arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Notification that a task has been created. This method is the first message @@ -65854,6 +71827,11 @@ abstract final class NSURLSessionDataDelegate { (ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2) => func(arg1, arg2)), + (void Function(NSURLSession, NSURLSessionTask) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask.blocking( + (ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2) => + func(arg1, arg2)), ); /// Sent when the system is ready to begin work for a task with a delayed start @@ -65910,6 +71888,17 @@ abstract final class NSURLSessionDataDelegate { objc.ObjCBlock arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionTask, NSURLRequest, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLRequest_ffiVoidNSURLSessionDelayedRequestDispositionNSURLRequest + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + NSURLRequest arg3, + objc.ObjCBlock + arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Sent when a task cannot start the network loading process because the current @@ -65942,6 +71931,11 @@ abstract final class NSURLSessionDataDelegate { (ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2) => func(arg1, arg2)), + (void Function(NSURLSession, NSURLSessionTask) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask.blocking( + (ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2) => + func(arg1, arg2)), ); /// An HTTP request is attempting to perform a redirection to a different @@ -65986,6 +71980,17 @@ abstract final class NSURLSessionDataDelegate { NSURLRequest arg4, objc.ObjCBlock arg5) => func(arg1, arg2, arg3, arg4, arg5)), + (void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse, + NSURLRequest, objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_NSURLRequest_ffiVoidNSURLRequest + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + NSHTTPURLResponse arg3, + NSURLRequest arg4, + objc.ObjCBlock arg5) => + func(arg1, arg2, arg3, arg4, arg5)), ); /// The task has received a request specific authentication challenge. @@ -66031,6 +72036,18 @@ abstract final class NSURLSessionDataDelegate { ffi.Void Function(NSInteger, NSURLCredential?)> arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionTask, NSURLAuthenticationChallenge, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + NSURLAuthenticationChallenge arg3, + objc.ObjCBlock< + ffi.Void Function(NSInteger, NSURLCredential?)> + arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Sent if a task requires a new, unopened body stream. This may be @@ -66068,6 +72085,16 @@ abstract final class NSURLSessionDataDelegate { objc.ObjCBlock arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionTask, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffiVoidNSInputStream + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + objc.ObjCBlock + arg3) => + func(arg1, arg2, arg3)), ); /// Tells the delegate if a task requires a new body stream starting from the given offset. This may be @@ -66111,6 +72138,17 @@ abstract final class NSURLSessionDataDelegate { objc.ObjCBlock arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionTask, int, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_ffiVoidNSInputStream + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + int arg3, + objc.ObjCBlock + arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Sent periodically to notify the delegate of upload progress. This @@ -66136,6 +72174,11 @@ abstract final class NSURLSessionDataDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2, int arg3, int arg4, int arg5) => func(arg1, arg2, arg3, arg4, arg5)), + (void Function(NSURLSession, NSURLSessionTask, int, int, int) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_Int64_Int64 + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2, int arg3, int arg4, int arg5) => + func(arg1, arg2, arg3, arg4, arg5)), ); /// Sent for each informational response received except 101 switching protocols. @@ -66160,6 +72203,11 @@ abstract final class NSURLSessionDataDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2, NSHTTPURLResponse arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2, NSHTTPURLResponse arg3) => + func(arg1, arg2, arg3)), ); /// Sent when complete statistics information has been collected for the task. @@ -66187,6 +72235,12 @@ abstract final class NSURLSessionDataDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2, NSURLSessionTaskMetrics arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionTask, NSURLSessionTaskMetrics) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLSessionTaskMetrics + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2, NSURLSessionTaskMetrics arg3) => + func(arg1, arg2, arg3)), ); /// Sent as the last message related to a specific task. Error may be @@ -66212,6 +72266,11 @@ abstract final class NSURLSessionDataDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2, objc.NSError? arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionTask, objc.NSError?) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSError + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2, objc.NSError? arg3) => + func(arg1, arg2, arg3)), ); /// The last message a session receives. A session will only become @@ -66235,6 +72294,10 @@ abstract final class NSURLSessionDataDelegate { ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError.listener( (ffi.Pointer _, NSURLSession arg1, objc.NSError? arg2) => func(arg1, arg2)), + (void Function(NSURLSession, objc.NSError?) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError.blocking( + (ffi.Pointer _, NSURLSession arg1, objc.NSError? arg2) => + func(arg1, arg2)), ); /// If implemented, when a connection level authentication challenge @@ -66279,6 +72342,17 @@ abstract final class NSURLSessionDataDelegate { ffi.Void Function(NSInteger, NSURLCredential?)> arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLAuthenticationChallenge, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLAuthenticationChallenge arg2, + objc.ObjCBlock< + ffi.Void Function(NSInteger, NSURLCredential?)> + arg3) => + func(arg1, arg2, arg3)), ); /// If an application has received an @@ -66304,6 +72378,9 @@ abstract final class NSURLSessionDataDelegate { (void Function(NSURLSession) func) => ObjCBlock_ffiVoid_ffiVoid_NSURLSession.listener( (ffi.Pointer _, NSURLSession arg1) => func(arg1)), + (void Function(NSURLSession) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession.blocking( + (ffi.Pointer _, NSURLSession arg1) => func(arg1)), ); } @@ -66398,6 +72475,65 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_NSURL_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionDownloadTask, objc.NSURL)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_NSURL { @@ -66482,7 +72618,7 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownload retain: false, release: true), objc.NSURL .castFromPointer(arg3, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1r3kn8f(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1tz5yf(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -66491,6 +72627,65 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownload NSURLSessionDownloadTask, objc.NSURL)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, + NSURLSessionDownloadTask, objc.NSURL)> blocking( + void Function(ffi.Pointer, NSURLSession, + NSURLSessionDownloadTask, objc.NSURL) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDownloadTask.castFromPointer(arg2, + retain: false, release: true), + objc.NSURL + .castFromPointer(arg3, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDownloadTask.castFromPointer(arg2, + retain: false, release: true), + objc.NSURL + .castFromPointer(arg3, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1tz5yf, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionDownloadTask, + objc.NSURL)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionDownloadTask, objc.NSURL)>`. @@ -66631,6 +72826,77 @@ ffi.NativeCallable< ffi.Int64)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_Int64_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_Int64_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + int arg4, + int arg5) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + int, + int, + int))(arg0, arg1, arg2, arg3, arg4, arg5); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Int64, + ffi.Int64)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_Int64_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Int64, + ffi.Int64)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_Int64_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Int64, + ffi.Int64)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_Int64_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Int64, + ffi.Int64)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_Int64_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionDownloadTask, ffi.Int64, ffi.Int64, ffi.Int64)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_Int64 { @@ -66728,7 +72994,7 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownload arg3, arg4, arg5)); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1uuez7b(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_h68abb(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -66739,6 +73005,73 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownload ffi.Int64, ffi.Int64)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, + NSURLSessionDownloadTask, ffi.Int64, ffi.Int64, ffi.Int64)> blocking( + void Function(ffi.Pointer, NSURLSession, + NSURLSessionDownloadTask, int, int, int) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_Int64_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + int arg4, + int arg5) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDownloadTask.castFromPointer(arg2, + retain: false, release: true), + arg3, + arg4, + arg5)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_Int64_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + int arg4, + int arg5) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDownloadTask.castFromPointer(arg2, + retain: false, release: true), + arg3, + arg4, + arg5)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_h68abb, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionDownloadTask, + ffi.Int64, + ffi.Int64, + ffi.Int64)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionDownloadTask, ffi.Int64, ffi.Int64, ffi.Int64)>`. @@ -66872,6 +73205,71 @@ ffi.NativeCallable< ffi.Int64)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + int arg4) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + int, + int))(arg0, arg1, arg2, arg3, arg4); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Int64)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Int64)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Int64)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int64, + ffi.Int64)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionDownloadTask, ffi.Int64, ffi.Int64)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64 { @@ -66953,7 +73351,7 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownload retain: false, release: true), arg3, arg4)); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_9qxjkl(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_ly2579(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -66963,6 +73361,62 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownload ffi.Int64, ffi.Int64)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, + NSURLSessionDownloadTask, ffi.Int64, ffi.Int64)> blocking( + void Function(ffi.Pointer, NSURLSession, + NSURLSessionDownloadTask, int, int) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2, int arg3, int arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDownloadTask.castFromPointer(arg2, + retain: false, release: true), + arg3, + arg4)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1, + ffi.Pointer arg2, int arg3, int arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDownloadTask.castFromPointer(arg2, + retain: false, release: true), + arg3, + arg4)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_ly2579, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionDownloadTask, + ffi.Int64, + ffi.Int64)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionDownloadTask, ffi.Int64, ffi.Int64)>`. @@ -67368,6 +73822,198 @@ abstract final class NSURLSessionDownloadDelegate { builder, URLSessionDidFinishEventsForBackgroundURLSession_); } + /// Builds an object that implements the NSURLSessionDownloadDelegate protocol. To implement + /// multiple protocols, use [addToBuilder] or [objc.ObjCProtocolBuilder] directly. All + /// methods that can be implemented as blocking listeners will be. + static objc.ObjCObjectBase implementAsBlocking( + {required void Function(NSURLSession, NSURLSessionDownloadTask, objc.NSURL) + URLSession_downloadTask_didFinishDownloadingToURL_, + void Function(NSURLSession, NSURLSessionDownloadTask, int, int, int)? + URLSession_downloadTask_didWriteData_totalBytesWritten_totalBytesExpectedToWrite_, + void Function(NSURLSession, NSURLSessionDownloadTask, int, int)? + URLSession_downloadTask_didResumeAtOffset_expectedTotalBytes_, + void Function(NSURLSession, NSURLSessionTask)? URLSession_didCreateTask_, + void Function(NSURLSession, NSURLSessionTask, NSURLRequest, + objc.ObjCBlock)? + URLSession_task_willBeginDelayedRequest_completionHandler_, + void Function(NSURLSession, NSURLSessionTask)? + URLSession_taskIsWaitingForConnectivity_, + void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse, + NSURLRequest, objc.ObjCBlock)? + URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_, + void Function( + NSURLSession, + NSURLSessionTask, + NSURLAuthenticationChallenge, + objc.ObjCBlock)? + URLSession_task_didReceiveChallenge_completionHandler_, + void Function(NSURLSession, NSURLSessionTask, + objc.ObjCBlock)? + URLSession_task_needNewBodyStream_, + void Function(NSURLSession, NSURLSessionTask, int, objc.ObjCBlock)? URLSession_task_needNewBodyStreamFromOffset_completionHandler_, + void Function(NSURLSession, NSURLSessionTask, int, int, int)? URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_, + void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse)? URLSession_task_didReceiveInformationalResponse_, + void Function(NSURLSession, NSURLSessionTask, NSURLSessionTaskMetrics)? URLSession_task_didFinishCollectingMetrics_, + void Function(NSURLSession, NSURLSessionTask, objc.NSError?)? URLSession_task_didCompleteWithError_, + void Function(NSURLSession, objc.NSError?)? URLSession_didBecomeInvalidWithError_, + void Function(NSURLSession, NSURLAuthenticationChallenge, objc.ObjCBlock)? URLSession_didReceiveChallenge_completionHandler_, + void Function(NSURLSession)? URLSessionDidFinishEventsForBackgroundURLSession_}) { + final builder = objc.ObjCProtocolBuilder(); + NSURLSessionDownloadDelegate + .URLSession_downloadTask_didFinishDownloadingToURL_ + .implementAsBlocking( + builder, URLSession_downloadTask_didFinishDownloadingToURL_); + NSURLSessionDownloadDelegate + .URLSession_downloadTask_didWriteData_totalBytesWritten_totalBytesExpectedToWrite_ + .implementAsBlocking(builder, + URLSession_downloadTask_didWriteData_totalBytesWritten_totalBytesExpectedToWrite_); + NSURLSessionDownloadDelegate + .URLSession_downloadTask_didResumeAtOffset_expectedTotalBytes_ + .implementAsBlocking(builder, + URLSession_downloadTask_didResumeAtOffset_expectedTotalBytes_); + NSURLSessionDownloadDelegate.URLSession_didCreateTask_.implementAsBlocking( + builder, URLSession_didCreateTask_); + NSURLSessionDownloadDelegate + .URLSession_task_willBeginDelayedRequest_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_willBeginDelayedRequest_completionHandler_); + NSURLSessionDownloadDelegate.URLSession_taskIsWaitingForConnectivity_ + .implementAsBlocking(builder, URLSession_taskIsWaitingForConnectivity_); + NSURLSessionDownloadDelegate + .URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_); + NSURLSessionDownloadDelegate + .URLSession_task_didReceiveChallenge_completionHandler_ + .implementAsBlocking( + builder, URLSession_task_didReceiveChallenge_completionHandler_); + NSURLSessionDownloadDelegate.URLSession_task_needNewBodyStream_ + .implementAsBlocking(builder, URLSession_task_needNewBodyStream_); + NSURLSessionDownloadDelegate + .URLSession_task_needNewBodyStreamFromOffset_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_needNewBodyStreamFromOffset_completionHandler_); + NSURLSessionDownloadDelegate + .URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_ + .implementAsBlocking(builder, + URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_); + NSURLSessionDownloadDelegate + .URLSession_task_didReceiveInformationalResponse_ + .implementAsBlocking( + builder, URLSession_task_didReceiveInformationalResponse_); + NSURLSessionDownloadDelegate.URLSession_task_didFinishCollectingMetrics_ + .implementAsBlocking( + builder, URLSession_task_didFinishCollectingMetrics_); + NSURLSessionDownloadDelegate.URLSession_task_didCompleteWithError_ + .implementAsBlocking(builder, URLSession_task_didCompleteWithError_); + NSURLSessionDownloadDelegate.URLSession_didBecomeInvalidWithError_ + .implementAsBlocking(builder, URLSession_didBecomeInvalidWithError_); + NSURLSessionDownloadDelegate + .URLSession_didReceiveChallenge_completionHandler_ + .implementAsBlocking( + builder, URLSession_didReceiveChallenge_completionHandler_); + NSURLSessionDownloadDelegate + .URLSessionDidFinishEventsForBackgroundURLSession_ + .implementAsBlocking( + builder, URLSessionDidFinishEventsForBackgroundURLSession_); + return builder.build(); + } + + /// Adds the implementation of the NSURLSessionDownloadDelegate protocol to an existing + /// [objc.ObjCProtocolBuilder]. All methods that can be implemented as blocking + /// listeners will be. + static void addToBuilderAsBlocking(objc.ObjCProtocolBuilder builder, + {required void Function(NSURLSession, NSURLSessionDownloadTask, objc.NSURL) + URLSession_downloadTask_didFinishDownloadingToURL_, + void Function(NSURLSession, NSURLSessionDownloadTask, int, int, int)? + URLSession_downloadTask_didWriteData_totalBytesWritten_totalBytesExpectedToWrite_, + void Function(NSURLSession, NSURLSessionDownloadTask, int, int)? + URLSession_downloadTask_didResumeAtOffset_expectedTotalBytes_, + void Function(NSURLSession, NSURLSessionTask)? URLSession_didCreateTask_, + void Function(NSURLSession, NSURLSessionTask, NSURLRequest, + objc.ObjCBlock)? + URLSession_task_willBeginDelayedRequest_completionHandler_, + void Function(NSURLSession, NSURLSessionTask)? + URLSession_taskIsWaitingForConnectivity_, + void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse, + NSURLRequest, objc.ObjCBlock)? + URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_, + void Function( + NSURLSession, + NSURLSessionTask, + NSURLAuthenticationChallenge, + objc.ObjCBlock)? + URLSession_task_didReceiveChallenge_completionHandler_, + void Function(NSURLSession, NSURLSessionTask, + objc.ObjCBlock)? + URLSession_task_needNewBodyStream_, + void Function(NSURLSession, NSURLSessionTask, int, objc.ObjCBlock)? URLSession_task_needNewBodyStreamFromOffset_completionHandler_, + void Function(NSURLSession, NSURLSessionTask, int, int, int)? URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_, + void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse)? URLSession_task_didReceiveInformationalResponse_, + void Function(NSURLSession, NSURLSessionTask, NSURLSessionTaskMetrics)? URLSession_task_didFinishCollectingMetrics_, + void Function(NSURLSession, NSURLSessionTask, objc.NSError?)? URLSession_task_didCompleteWithError_, + void Function(NSURLSession, objc.NSError?)? URLSession_didBecomeInvalidWithError_, + void Function(NSURLSession, NSURLAuthenticationChallenge, objc.ObjCBlock)? URLSession_didReceiveChallenge_completionHandler_, + void Function(NSURLSession)? URLSessionDidFinishEventsForBackgroundURLSession_}) { + NSURLSessionDownloadDelegate + .URLSession_downloadTask_didFinishDownloadingToURL_ + .implementAsBlocking( + builder, URLSession_downloadTask_didFinishDownloadingToURL_); + NSURLSessionDownloadDelegate + .URLSession_downloadTask_didWriteData_totalBytesWritten_totalBytesExpectedToWrite_ + .implementAsBlocking(builder, + URLSession_downloadTask_didWriteData_totalBytesWritten_totalBytesExpectedToWrite_); + NSURLSessionDownloadDelegate + .URLSession_downloadTask_didResumeAtOffset_expectedTotalBytes_ + .implementAsBlocking(builder, + URLSession_downloadTask_didResumeAtOffset_expectedTotalBytes_); + NSURLSessionDownloadDelegate.URLSession_didCreateTask_.implementAsBlocking( + builder, URLSession_didCreateTask_); + NSURLSessionDownloadDelegate + .URLSession_task_willBeginDelayedRequest_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_willBeginDelayedRequest_completionHandler_); + NSURLSessionDownloadDelegate.URLSession_taskIsWaitingForConnectivity_ + .implementAsBlocking(builder, URLSession_taskIsWaitingForConnectivity_); + NSURLSessionDownloadDelegate + .URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_); + NSURLSessionDownloadDelegate + .URLSession_task_didReceiveChallenge_completionHandler_ + .implementAsBlocking( + builder, URLSession_task_didReceiveChallenge_completionHandler_); + NSURLSessionDownloadDelegate.URLSession_task_needNewBodyStream_ + .implementAsBlocking(builder, URLSession_task_needNewBodyStream_); + NSURLSessionDownloadDelegate + .URLSession_task_needNewBodyStreamFromOffset_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_needNewBodyStreamFromOffset_completionHandler_); + NSURLSessionDownloadDelegate + .URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_ + .implementAsBlocking(builder, + URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_); + NSURLSessionDownloadDelegate + .URLSession_task_didReceiveInformationalResponse_ + .implementAsBlocking( + builder, URLSession_task_didReceiveInformationalResponse_); + NSURLSessionDownloadDelegate.URLSession_task_didFinishCollectingMetrics_ + .implementAsBlocking( + builder, URLSession_task_didFinishCollectingMetrics_); + NSURLSessionDownloadDelegate.URLSession_task_didCompleteWithError_ + .implementAsBlocking(builder, URLSession_task_didCompleteWithError_); + NSURLSessionDownloadDelegate.URLSession_didBecomeInvalidWithError_ + .implementAsBlocking(builder, URLSession_didBecomeInvalidWithError_); + NSURLSessionDownloadDelegate + .URLSession_didReceiveChallenge_completionHandler_ + .implementAsBlocking( + builder, URLSession_didReceiveChallenge_completionHandler_); + NSURLSessionDownloadDelegate + .URLSessionDidFinishEventsForBackgroundURLSession_ + .implementAsBlocking( + builder, URLSessionDidFinishEventsForBackgroundURLSession_); + } + /// Sent when a download task that has completed a download. The delegate should /// copy or move the file at the given location to a new location as it will be /// removed when the delegate message returns. URLSession:task:didCompleteWithError: will @@ -67393,6 +74039,11 @@ abstract final class NSURLSessionDownloadDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionDownloadTask arg2, objc.NSURL arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionDownloadTask, objc.NSURL) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_NSURL + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionDownloadTask arg2, objc.NSURL arg3) => + func(arg1, arg2, arg3)), ); /// Sent periodically to notify the delegate of download progress. @@ -67427,6 +74078,16 @@ abstract final class NSURLSessionDownloadDelegate { int arg4, int arg5) => func(arg1, arg2, arg3, arg4, arg5)), + (void Function(NSURLSession, NSURLSessionDownloadTask, int, int, int) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64_Int64 + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionDownloadTask arg2, + int arg3, + int arg4, + int arg5) => + func(arg1, arg2, arg3, arg4, arg5)), ); /// Sent when a download has been resumed. If a download failed with an @@ -67454,6 +74115,11 @@ abstract final class NSURLSessionDownloadDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionDownloadTask arg2, int arg3, int arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionDownloadTask, int, int) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionDownloadTask_Int64_Int64 + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionDownloadTask arg2, int arg3, int arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Notification that a task has been created. This method is the first message @@ -67481,6 +74147,11 @@ abstract final class NSURLSessionDownloadDelegate { (ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2) => func(arg1, arg2)), + (void Function(NSURLSession, NSURLSessionTask) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask.blocking( + (ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2) => + func(arg1, arg2)), ); /// Sent when the system is ready to begin work for a task with a delayed start @@ -67537,6 +74208,17 @@ abstract final class NSURLSessionDownloadDelegate { objc.ObjCBlock arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionTask, NSURLRequest, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLRequest_ffiVoidNSURLSessionDelayedRequestDispositionNSURLRequest + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + NSURLRequest arg3, + objc.ObjCBlock + arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Sent when a task cannot start the network loading process because the current @@ -67569,6 +74251,11 @@ abstract final class NSURLSessionDownloadDelegate { (ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2) => func(arg1, arg2)), + (void Function(NSURLSession, NSURLSessionTask) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask.blocking( + (ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2) => + func(arg1, arg2)), ); /// An HTTP request is attempting to perform a redirection to a different @@ -67613,6 +74300,17 @@ abstract final class NSURLSessionDownloadDelegate { NSURLRequest arg4, objc.ObjCBlock arg5) => func(arg1, arg2, arg3, arg4, arg5)), + (void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse, + NSURLRequest, objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_NSURLRequest_ffiVoidNSURLRequest + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + NSHTTPURLResponse arg3, + NSURLRequest arg4, + objc.ObjCBlock arg5) => + func(arg1, arg2, arg3, arg4, arg5)), ); /// The task has received a request specific authentication challenge. @@ -67658,6 +74356,18 @@ abstract final class NSURLSessionDownloadDelegate { ffi.Void Function(NSInteger, NSURLCredential?)> arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionTask, NSURLAuthenticationChallenge, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + NSURLAuthenticationChallenge arg3, + objc.ObjCBlock< + ffi.Void Function(NSInteger, NSURLCredential?)> + arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Sent if a task requires a new, unopened body stream. This may be @@ -67695,6 +74405,16 @@ abstract final class NSURLSessionDownloadDelegate { objc.ObjCBlock arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionTask, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffiVoidNSInputStream + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + objc.ObjCBlock + arg3) => + func(arg1, arg2, arg3)), ); /// Tells the delegate if a task requires a new body stream starting from the given offset. This may be @@ -67738,6 +74458,17 @@ abstract final class NSURLSessionDownloadDelegate { objc.ObjCBlock arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionTask, int, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_ffiVoidNSInputStream + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + int arg3, + objc.ObjCBlock + arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Sent periodically to notify the delegate of upload progress. This @@ -67763,6 +74494,11 @@ abstract final class NSURLSessionDownloadDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2, int arg3, int arg4, int arg5) => func(arg1, arg2, arg3, arg4, arg5)), + (void Function(NSURLSession, NSURLSessionTask, int, int, int) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_Int64_Int64 + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2, int arg3, int arg4, int arg5) => + func(arg1, arg2, arg3, arg4, arg5)), ); /// Sent for each informational response received except 101 switching protocols. @@ -67787,6 +74523,11 @@ abstract final class NSURLSessionDownloadDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2, NSHTTPURLResponse arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2, NSHTTPURLResponse arg3) => + func(arg1, arg2, arg3)), ); /// Sent when complete statistics information has been collected for the task. @@ -67814,6 +74555,12 @@ abstract final class NSURLSessionDownloadDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2, NSURLSessionTaskMetrics arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionTask, NSURLSessionTaskMetrics) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLSessionTaskMetrics + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2, NSURLSessionTaskMetrics arg3) => + func(arg1, arg2, arg3)), ); /// Sent as the last message related to a specific task. Error may be @@ -67839,6 +74586,11 @@ abstract final class NSURLSessionDownloadDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2, objc.NSError? arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionTask, objc.NSError?) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSError + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2, objc.NSError? arg3) => + func(arg1, arg2, arg3)), ); /// The last message a session receives. A session will only become @@ -67862,6 +74614,10 @@ abstract final class NSURLSessionDownloadDelegate { ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError.listener( (ffi.Pointer _, NSURLSession arg1, objc.NSError? arg2) => func(arg1, arg2)), + (void Function(NSURLSession, objc.NSError?) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError.blocking( + (ffi.Pointer _, NSURLSession arg1, objc.NSError? arg2) => + func(arg1, arg2)), ); /// If implemented, when a connection level authentication challenge @@ -67906,6 +74662,17 @@ abstract final class NSURLSessionDownloadDelegate { ffi.Void Function(NSInteger, NSURLCredential?)> arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLAuthenticationChallenge, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLAuthenticationChallenge arg2, + objc.ObjCBlock< + ffi.Void Function(NSInteger, NSURLCredential?)> + arg3) => + func(arg1, arg2, arg3)), ); /// If an application has received an @@ -67931,6 +74698,9 @@ abstract final class NSURLSessionDownloadDelegate { (void Function(NSURLSession) func) => ObjCBlock_ffiVoid_ffiVoid_NSURLSession.listener( (ffi.Pointer _, NSURLSession arg1) => func(arg1)), + (void Function(NSURLSession) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession.blocking( + (ffi.Pointer _, NSURLSession arg1) => func(arg1)), ); } @@ -68025,6 +74795,65 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSString_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSString_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSString_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSString_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSString_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSString_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionWebSocketTask, objc.NSString?)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSString { @@ -68111,8 +74940,71 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocke ? null : objc.NSString.castFromPointer(arg3, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1r3kn8f(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1tz5yf(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionWebSocketTask, + objc.NSString?)>(wrapper, retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, + NSURLSessionWebSocketTask, objc.NSString?)> blocking( + void Function(ffi.Pointer, NSURLSession, + NSURLSessionWebSocketTask, objc.NSString?) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSString_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionWebSocketTask.castFromPointer(arg2, + retain: false, release: true), + arg3.address == 0 + ? null + : objc.NSString.castFromPointer(arg3, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSString_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionWebSocketTask.castFromPointer(arg2, + retain: false, release: true), + arg3.address == 0 + ? null + : objc.NSString.castFromPointer(arg3, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1tz5yf, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function( ffi.Pointer, @@ -68249,6 +75141,71 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSURLSessionWebSocketCloseCode_NSData_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSURLSessionWebSocketCloseCode_NSData_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + ffi.Pointer arg4) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + int, + ffi.Pointer))(arg0, arg1, arg2, arg3, arg4); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSInteger, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSURLSessionWebSocketCloseCode_NSData_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSInteger, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSURLSessionWebSocketCloseCode_NSData_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSInteger, + ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSURLSessionWebSocketCloseCode_NSData_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSInteger, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSURLSessionWebSocketCloseCode_NSData_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, NSURLSession, NSURLSessionWebSocketTask, NSInteger, objc.NSData?)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSURLSessionWebSocketCloseCode_NSData { @@ -68340,7 +75297,7 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocke ? null : objc.NSData.castFromPointer(arg4, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_3lo3bb(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1lx650f(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -68350,6 +75307,74 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocke NSInteger, objc.NSData?)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, NSURLSession, + NSURLSessionWebSocketTask, NSInteger, objc.NSData?)> blocking( + void Function(ffi.Pointer, NSURLSession, + NSURLSessionWebSocketTask, DartNSInteger, objc.NSData?) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSURLSessionWebSocketCloseCode_NSData_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + ffi.Pointer arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionWebSocketTask.castFromPointer(arg2, + retain: false, release: true), + arg3, + arg4.address == 0 + ? null + : objc.NSData.castFromPointer(arg4, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSURLSessionWebSocketCloseCode_NSData_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + int arg3, + ffi.Pointer arg4) => + fn( + arg0, + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionWebSocketTask.castFromPointer(arg2, + retain: false, release: true), + arg3, + arg4.address == 0 + ? null + : objc.NSData.castFromPointer(arg4, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1lx650f, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + ffi.Pointer, + NSURLSession, + NSURLSessionWebSocketTask, + NSInteger, + objc.NSData?)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, NSURLSession, NSURLSessionWebSocketTask, NSInteger, objc.NSData?)>`. @@ -68733,6 +75758,184 @@ abstract final class NSURLSessionWebSocketDelegate { builder, URLSessionDidFinishEventsForBackgroundURLSession_); } + /// Builds an object that implements the NSURLSessionWebSocketDelegate protocol. To implement + /// multiple protocols, use [addToBuilder] or [objc.ObjCProtocolBuilder] directly. All + /// methods that can be implemented as blocking listeners will be. + static objc.ObjCObjectBase implementAsBlocking( + {void Function(NSURLSession, NSURLSessionWebSocketTask, objc.NSString?)? + URLSession_webSocketTask_didOpenWithProtocol_, + void Function(NSURLSession, NSURLSessionWebSocketTask, DartNSInteger, objc.NSData?)? + URLSession_webSocketTask_didCloseWithCode_reason_, + void Function(NSURLSession, NSURLSessionTask)? URLSession_didCreateTask_, + void Function(NSURLSession, NSURLSessionTask, NSURLRequest, + objc.ObjCBlock)? + URLSession_task_willBeginDelayedRequest_completionHandler_, + void Function(NSURLSession, NSURLSessionTask)? + URLSession_taskIsWaitingForConnectivity_, + void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse, + NSURLRequest, objc.ObjCBlock)? + URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_, + void Function( + NSURLSession, + NSURLSessionTask, + NSURLAuthenticationChallenge, + objc.ObjCBlock)? + URLSession_task_didReceiveChallenge_completionHandler_, + void Function( + NSURLSession, NSURLSessionTask, objc.ObjCBlock)? + URLSession_task_needNewBodyStream_, + void Function(NSURLSession, NSURLSessionTask, int, objc.ObjCBlock)? URLSession_task_needNewBodyStreamFromOffset_completionHandler_, + void Function(NSURLSession, NSURLSessionTask, int, int, int)? URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_, + void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse)? URLSession_task_didReceiveInformationalResponse_, + void Function(NSURLSession, NSURLSessionTask, NSURLSessionTaskMetrics)? URLSession_task_didFinishCollectingMetrics_, + void Function(NSURLSession, NSURLSessionTask, objc.NSError?)? URLSession_task_didCompleteWithError_, + void Function(NSURLSession, objc.NSError?)? URLSession_didBecomeInvalidWithError_, + void Function(NSURLSession, NSURLAuthenticationChallenge, objc.ObjCBlock)? URLSession_didReceiveChallenge_completionHandler_, + void Function(NSURLSession)? URLSessionDidFinishEventsForBackgroundURLSession_}) { + final builder = objc.ObjCProtocolBuilder(); + NSURLSessionWebSocketDelegate.URLSession_webSocketTask_didOpenWithProtocol_ + .implementAsBlocking( + builder, URLSession_webSocketTask_didOpenWithProtocol_); + NSURLSessionWebSocketDelegate + .URLSession_webSocketTask_didCloseWithCode_reason_ + .implementAsBlocking( + builder, URLSession_webSocketTask_didCloseWithCode_reason_); + NSURLSessionWebSocketDelegate.URLSession_didCreateTask_.implementAsBlocking( + builder, URLSession_didCreateTask_); + NSURLSessionWebSocketDelegate + .URLSession_task_willBeginDelayedRequest_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_willBeginDelayedRequest_completionHandler_); + NSURLSessionWebSocketDelegate.URLSession_taskIsWaitingForConnectivity_ + .implementAsBlocking(builder, URLSession_taskIsWaitingForConnectivity_); + NSURLSessionWebSocketDelegate + .URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_); + NSURLSessionWebSocketDelegate + .URLSession_task_didReceiveChallenge_completionHandler_ + .implementAsBlocking( + builder, URLSession_task_didReceiveChallenge_completionHandler_); + NSURLSessionWebSocketDelegate.URLSession_task_needNewBodyStream_ + .implementAsBlocking(builder, URLSession_task_needNewBodyStream_); + NSURLSessionWebSocketDelegate + .URLSession_task_needNewBodyStreamFromOffset_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_needNewBodyStreamFromOffset_completionHandler_); + NSURLSessionWebSocketDelegate + .URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_ + .implementAsBlocking(builder, + URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_); + NSURLSessionWebSocketDelegate + .URLSession_task_didReceiveInformationalResponse_ + .implementAsBlocking( + builder, URLSession_task_didReceiveInformationalResponse_); + NSURLSessionWebSocketDelegate.URLSession_task_didFinishCollectingMetrics_ + .implementAsBlocking( + builder, URLSession_task_didFinishCollectingMetrics_); + NSURLSessionWebSocketDelegate.URLSession_task_didCompleteWithError_ + .implementAsBlocking(builder, URLSession_task_didCompleteWithError_); + NSURLSessionWebSocketDelegate.URLSession_didBecomeInvalidWithError_ + .implementAsBlocking(builder, URLSession_didBecomeInvalidWithError_); + NSURLSessionWebSocketDelegate + .URLSession_didReceiveChallenge_completionHandler_ + .implementAsBlocking( + builder, URLSession_didReceiveChallenge_completionHandler_); + NSURLSessionWebSocketDelegate + .URLSessionDidFinishEventsForBackgroundURLSession_ + .implementAsBlocking( + builder, URLSessionDidFinishEventsForBackgroundURLSession_); + return builder.build(); + } + + /// Adds the implementation of the NSURLSessionWebSocketDelegate protocol to an existing + /// [objc.ObjCProtocolBuilder]. All methods that can be implemented as blocking + /// listeners will be. + static void addToBuilderAsBlocking(objc.ObjCProtocolBuilder builder, + {void Function(NSURLSession, NSURLSessionWebSocketTask, objc.NSString?)? + URLSession_webSocketTask_didOpenWithProtocol_, + void Function(NSURLSession, NSURLSessionWebSocketTask, DartNSInteger, objc.NSData?)? + URLSession_webSocketTask_didCloseWithCode_reason_, + void Function(NSURLSession, NSURLSessionTask)? URLSession_didCreateTask_, + void Function(NSURLSession, NSURLSessionTask, NSURLRequest, + objc.ObjCBlock)? + URLSession_task_willBeginDelayedRequest_completionHandler_, + void Function(NSURLSession, NSURLSessionTask)? + URLSession_taskIsWaitingForConnectivity_, + void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse, + NSURLRequest, objc.ObjCBlock)? + URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_, + void Function( + NSURLSession, + NSURLSessionTask, + NSURLAuthenticationChallenge, + objc.ObjCBlock)? + URLSession_task_didReceiveChallenge_completionHandler_, + void Function( + NSURLSession, NSURLSessionTask, objc.ObjCBlock)? + URLSession_task_needNewBodyStream_, + void Function(NSURLSession, NSURLSessionTask, int, objc.ObjCBlock)? URLSession_task_needNewBodyStreamFromOffset_completionHandler_, + void Function(NSURLSession, NSURLSessionTask, int, int, int)? URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_, + void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse)? URLSession_task_didReceiveInformationalResponse_, + void Function(NSURLSession, NSURLSessionTask, NSURLSessionTaskMetrics)? URLSession_task_didFinishCollectingMetrics_, + void Function(NSURLSession, NSURLSessionTask, objc.NSError?)? URLSession_task_didCompleteWithError_, + void Function(NSURLSession, objc.NSError?)? URLSession_didBecomeInvalidWithError_, + void Function(NSURLSession, NSURLAuthenticationChallenge, objc.ObjCBlock)? URLSession_didReceiveChallenge_completionHandler_, + void Function(NSURLSession)? URLSessionDidFinishEventsForBackgroundURLSession_}) { + NSURLSessionWebSocketDelegate.URLSession_webSocketTask_didOpenWithProtocol_ + .implementAsBlocking( + builder, URLSession_webSocketTask_didOpenWithProtocol_); + NSURLSessionWebSocketDelegate + .URLSession_webSocketTask_didCloseWithCode_reason_ + .implementAsBlocking( + builder, URLSession_webSocketTask_didCloseWithCode_reason_); + NSURLSessionWebSocketDelegate.URLSession_didCreateTask_.implementAsBlocking( + builder, URLSession_didCreateTask_); + NSURLSessionWebSocketDelegate + .URLSession_task_willBeginDelayedRequest_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_willBeginDelayedRequest_completionHandler_); + NSURLSessionWebSocketDelegate.URLSession_taskIsWaitingForConnectivity_ + .implementAsBlocking(builder, URLSession_taskIsWaitingForConnectivity_); + NSURLSessionWebSocketDelegate + .URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_willPerformHTTPRedirection_newRequest_completionHandler_); + NSURLSessionWebSocketDelegate + .URLSession_task_didReceiveChallenge_completionHandler_ + .implementAsBlocking( + builder, URLSession_task_didReceiveChallenge_completionHandler_); + NSURLSessionWebSocketDelegate.URLSession_task_needNewBodyStream_ + .implementAsBlocking(builder, URLSession_task_needNewBodyStream_); + NSURLSessionWebSocketDelegate + .URLSession_task_needNewBodyStreamFromOffset_completionHandler_ + .implementAsBlocking(builder, + URLSession_task_needNewBodyStreamFromOffset_completionHandler_); + NSURLSessionWebSocketDelegate + .URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_ + .implementAsBlocking(builder, + URLSession_task_didSendBodyData_totalBytesSent_totalBytesExpectedToSend_); + NSURLSessionWebSocketDelegate + .URLSession_task_didReceiveInformationalResponse_ + .implementAsBlocking( + builder, URLSession_task_didReceiveInformationalResponse_); + NSURLSessionWebSocketDelegate.URLSession_task_didFinishCollectingMetrics_ + .implementAsBlocking( + builder, URLSession_task_didFinishCollectingMetrics_); + NSURLSessionWebSocketDelegate.URLSession_task_didCompleteWithError_ + .implementAsBlocking(builder, URLSession_task_didCompleteWithError_); + NSURLSessionWebSocketDelegate.URLSession_didBecomeInvalidWithError_ + .implementAsBlocking(builder, URLSession_didBecomeInvalidWithError_); + NSURLSessionWebSocketDelegate + .URLSession_didReceiveChallenge_completionHandler_ + .implementAsBlocking( + builder, URLSession_didReceiveChallenge_completionHandler_); + NSURLSessionWebSocketDelegate + .URLSessionDidFinishEventsForBackgroundURLSession_ + .implementAsBlocking( + builder, URLSessionDidFinishEventsForBackgroundURLSession_); + } + /// Indicates that the WebSocket handshake was successful and the connection has been upgraded to webSockets. /// It will also provide the protocol that is picked in the handshake. If the handshake fails, this delegate will not be invoked. static final URLSession_webSocketTask_didOpenWithProtocol_ = @@ -68759,6 +75962,12 @@ abstract final class NSURLSessionWebSocketDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionWebSocketTask arg2, objc.NSString? arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionWebSocketTask, objc.NSString?) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSString + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionWebSocketTask arg2, objc.NSString? arg3) => + func(arg1, arg2, arg3)), ); /// Indicates that the WebSocket has received a close frame from the server endpoint. @@ -68796,6 +76005,16 @@ abstract final class NSURLSessionWebSocketDelegate { DartNSInteger arg3, objc.NSData? arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionWebSocketTask, DartNSInteger, + objc.NSData?) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionWebSocketTask_NSURLSessionWebSocketCloseCode_NSData + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionWebSocketTask arg2, + DartNSInteger arg3, + objc.NSData? arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Notification that a task has been created. This method is the first message @@ -68823,6 +76042,11 @@ abstract final class NSURLSessionWebSocketDelegate { (ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2) => func(arg1, arg2)), + (void Function(NSURLSession, NSURLSessionTask) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask.blocking( + (ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2) => + func(arg1, arg2)), ); /// Sent when the system is ready to begin work for a task with a delayed start @@ -68879,6 +76103,17 @@ abstract final class NSURLSessionWebSocketDelegate { objc.ObjCBlock arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionTask, NSURLRequest, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLRequest_ffiVoidNSURLSessionDelayedRequestDispositionNSURLRequest + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + NSURLRequest arg3, + objc.ObjCBlock + arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Sent when a task cannot start the network loading process because the current @@ -68911,6 +76146,11 @@ abstract final class NSURLSessionWebSocketDelegate { (ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2) => func(arg1, arg2)), + (void Function(NSURLSession, NSURLSessionTask) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask.blocking( + (ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2) => + func(arg1, arg2)), ); /// An HTTP request is attempting to perform a redirection to a different @@ -68955,6 +76195,17 @@ abstract final class NSURLSessionWebSocketDelegate { NSURLRequest arg4, objc.ObjCBlock arg5) => func(arg1, arg2, arg3, arg4, arg5)), + (void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse, + NSURLRequest, objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse_NSURLRequest_ffiVoidNSURLRequest + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + NSHTTPURLResponse arg3, + NSURLRequest arg4, + objc.ObjCBlock arg5) => + func(arg1, arg2, arg3, arg4, arg5)), ); /// The task has received a request specific authentication challenge. @@ -69000,6 +76251,18 @@ abstract final class NSURLSessionWebSocketDelegate { ffi.Void Function(NSInteger, NSURLCredential?)> arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionTask, NSURLAuthenticationChallenge, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + NSURLAuthenticationChallenge arg3, + objc.ObjCBlock< + ffi.Void Function(NSInteger, NSURLCredential?)> + arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Sent if a task requires a new, unopened body stream. This may be @@ -69037,6 +76300,16 @@ abstract final class NSURLSessionWebSocketDelegate { objc.ObjCBlock arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionTask, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_ffiVoidNSInputStream + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + objc.ObjCBlock + arg3) => + func(arg1, arg2, arg3)), ); /// Tells the delegate if a task requires a new body stream starting from the given offset. This may be @@ -69080,6 +76353,17 @@ abstract final class NSURLSessionWebSocketDelegate { objc.ObjCBlock arg4) => func(arg1, arg2, arg3, arg4)), + (void Function(NSURLSession, NSURLSessionTask, int, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_ffiVoidNSInputStream + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLSessionTask arg2, + int arg3, + objc.ObjCBlock + arg4) => + func(arg1, arg2, arg3, arg4)), ); /// Sent periodically to notify the delegate of upload progress. This @@ -69105,6 +76389,11 @@ abstract final class NSURLSessionWebSocketDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2, int arg3, int arg4, int arg5) => func(arg1, arg2, arg3, arg4, arg5)), + (void Function(NSURLSession, NSURLSessionTask, int, int, int) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_Int64_Int64_Int64 + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2, int arg3, int arg4, int arg5) => + func(arg1, arg2, arg3, arg4, arg5)), ); /// Sent for each informational response received except 101 switching protocols. @@ -69129,6 +76418,11 @@ abstract final class NSURLSessionWebSocketDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2, NSHTTPURLResponse arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionTask, NSHTTPURLResponse) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSHTTPURLResponse + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2, NSHTTPURLResponse arg3) => + func(arg1, arg2, arg3)), ); /// Sent when complete statistics information has been collected for the task. @@ -69156,6 +76450,12 @@ abstract final class NSURLSessionWebSocketDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2, NSURLSessionTaskMetrics arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionTask, NSURLSessionTaskMetrics) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSURLSessionTaskMetrics + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2, NSURLSessionTaskMetrics arg3) => + func(arg1, arg2, arg3)), ); /// Sent as the last message related to a specific task. Error may be @@ -69181,6 +76481,11 @@ abstract final class NSURLSessionWebSocketDelegate { .listener((ffi.Pointer _, NSURLSession arg1, NSURLSessionTask arg2, objc.NSError? arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLSessionTask, objc.NSError?) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLSessionTask_NSError + .blocking((ffi.Pointer _, NSURLSession arg1, + NSURLSessionTask arg2, objc.NSError? arg3) => + func(arg1, arg2, arg3)), ); /// The last message a session receives. A session will only become @@ -69204,6 +76509,10 @@ abstract final class NSURLSessionWebSocketDelegate { ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError.listener( (ffi.Pointer _, NSURLSession arg1, objc.NSError? arg2) => func(arg1, arg2)), + (void Function(NSURLSession, objc.NSError?) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSError.blocking( + (ffi.Pointer _, NSURLSession arg1, objc.NSError? arg2) => + func(arg1, arg2)), ); /// If implemented, when a connection level authentication challenge @@ -69248,6 +76557,17 @@ abstract final class NSURLSessionWebSocketDelegate { ffi.Void Function(NSInteger, NSURLCredential?)> arg3) => func(arg1, arg2, arg3)), + (void Function(NSURLSession, NSURLAuthenticationChallenge, + objc.ObjCBlock) + func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession_NSURLAuthenticationChallenge_ffiVoidNSURLSessionAuthChallengeDispositionNSURLCredential + .blocking((ffi.Pointer _, + NSURLSession arg1, + NSURLAuthenticationChallenge arg2, + objc.ObjCBlock< + ffi.Void Function(NSInteger, NSURLCredential?)> + arg3) => + func(arg1, arg2, arg3)), ); /// If an application has received an @@ -69273,6 +76593,9 @@ abstract final class NSURLSessionWebSocketDelegate { (void Function(NSURLSession) func) => ObjCBlock_ffiVoid_ffiVoid_NSURLSession.listener( (ffi.Pointer _, NSURLSession arg1) => func(arg1)), + (void Function(NSURLSession) func) => + ObjCBlock_ffiVoid_ffiVoid_NSURLSession.blocking( + (ffi.Pointer _, NSURLSession arg1) => func(arg1)), ); } @@ -69281,7 +76604,7 @@ typedef Dartunichar = int; late final _class_NSValue = objc.getClass("NSValue"); late final _sel_valueWithBytes_objCType_ = objc.registerName("valueWithBytes:objCType:"); -final _objc_msgSend_qtxoq7 = objc.msgSendPointer +final _objc_msgSend_e9mncn = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -69302,7 +76625,7 @@ extension NSValueCreation on objc.NSValue { /// valueWithBytes:objCType: static objc.NSValue valueWithBytes_objCType_( ffi.Pointer value, ffi.Pointer type) { - final _ret = _objc_msgSend_qtxoq7( + final _ret = _objc_msgSend_e9mncn( _class_NSValue, _sel_valueWithBytes_objCType_, value, type); return objc.NSValue.castFromPointer(_ret, retain: true, release: true); } @@ -69310,7 +76633,7 @@ extension NSValueCreation on objc.NSValue { /// value:withObjCType: static objc.NSValue value_withObjCType_( ffi.Pointer value, ffi.Pointer type) { - final _ret = _objc_msgSend_qtxoq7( + final _ret = _objc_msgSend_e9mncn( _class_NSValue, _sel_value_withObjCType_, value, type); return objc.NSValue.castFromPointer(_ret, retain: true, release: true); } @@ -69321,7 +76644,7 @@ late final _sel_valueWithNonretainedObject_ = late final _sel_nonretainedObjectValue = objc.registerName("nonretainedObjectValue"); late final _sel_valueWithPointer_ = objc.registerName("valueWithPointer:"); -final _objc_msgSend_1yesha9 = objc.msgSendPointer +final _objc_msgSend_1mbt9g9 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -69345,7 +76668,7 @@ extension NSValueExtensionMethods on objc.NSValue { /// valueWithNonretainedObject: static objc.NSValue valueWithNonretainedObject_( objc.ObjCObjectBase? anObject) { - final _ret = _objc_msgSend_62nh5j(_class_NSValue, + final _ret = _objc_msgSend_1sotr3r(_class_NSValue, _sel_valueWithNonretainedObject_, anObject?.ref.pointer ?? ffi.nullptr); return objc.NSValue.castFromPointer(_ret, retain: true, release: true); } @@ -69353,7 +76676,7 @@ extension NSValueExtensionMethods on objc.NSValue { /// nonretainedObjectValue objc.ObjCObjectBase? get nonretainedObjectValue { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_nonretainedObjectValue); + _objc_msgSend_151sglz(this.ref.pointer, _sel_nonretainedObjectValue); return _ret.address == 0 ? null : objc.ObjCObjectBase(_ret, retain: true, release: true); @@ -69362,7 +76685,7 @@ extension NSValueExtensionMethods on objc.NSValue { /// valueWithPointer: static objc.NSValue valueWithPointer_(ffi.Pointer pointer) { final _ret = - _objc_msgSend_1yesha9(_class_NSValue, _sel_valueWithPointer_, pointer); + _objc_msgSend_1mbt9g9(_class_NSValue, _sel_valueWithPointer_, pointer); return objc.NSValue.castFromPointer(_ret, retain: true, release: true); } @@ -69373,14 +76696,14 @@ extension NSValueExtensionMethods on objc.NSValue { /// isEqualToValue: bool isEqualToValue_(objc.NSValue value) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( this.ref.pointer, _sel_isEqualToValue_, value.ref.pointer); } } late final _class_NSNumber = objc.getClass("NSNumber"); late final _sel_numberWithChar_ = objc.registerName("numberWithChar:"); -final _objc_msgSend_vx1f2d = objc.msgSendPointer +final _objc_msgSend_13mclwd = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -69390,7 +76713,7 @@ final _objc_msgSend_vx1f2d = objc.msgSendPointer ffi.Pointer, int)>(); late final _sel_numberWithUnsignedChar_ = objc.registerName("numberWithUnsignedChar:"); -final _objc_msgSend_uzucl8 = objc.msgSendPointer +final _objc_msgSend_7uautw = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -69399,7 +76722,7 @@ final _objc_msgSend_uzucl8 = objc.msgSendPointer ffi.Pointer Function(ffi.Pointer, ffi.Pointer, int)>(); late final _sel_numberWithShort_ = objc.registerName("numberWithShort:"); -final _objc_msgSend_cvzqr9 = objc.msgSendPointer +final _objc_msgSend_68x6r1 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -69409,7 +76732,7 @@ final _objc_msgSend_cvzqr9 = objc.msgSendPointer ffi.Pointer, int)>(); late final _sel_numberWithUnsignedShort_ = objc.registerName("numberWithUnsignedShort:"); -final _objc_msgSend_onx6bi = objc.msgSendPointer +final _objc_msgSend_1njucl2 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -69418,7 +76741,7 @@ final _objc_msgSend_onx6bi = objc.msgSendPointer ffi.Pointer Function(ffi.Pointer, ffi.Pointer, int)>(); late final _sel_numberWithInt_ = objc.registerName("numberWithInt:"); -final _objc_msgSend_1a0iyvk = objc.msgSendPointer +final _objc_msgSend_14hvw5k = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -69428,7 +76751,7 @@ final _objc_msgSend_1a0iyvk = objc.msgSendPointer ffi.Pointer, int)>(); late final _sel_numberWithUnsignedInt_ = objc.registerName("numberWithUnsignedInt:"); -final _objc_msgSend_12mhqtk = objc.msgSendPointer +final _objc_msgSend_degb40 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -69440,7 +76763,7 @@ late final _sel_numberWithLong_ = objc.registerName("numberWithLong:"); late final _sel_numberWithUnsignedLong_ = objc.registerName("numberWithUnsignedLong:"); late final _sel_numberWithLongLong_ = objc.registerName("numberWithLongLong:"); -final _objc_msgSend_94zdgv = objc.msgSendPointer +final _objc_msgSend_16f0drb = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -69450,7 +76773,7 @@ final _objc_msgSend_94zdgv = objc.msgSendPointer ffi.Pointer, int)>(); late final _sel_numberWithUnsignedLongLong_ = objc.registerName("numberWithUnsignedLongLong:"); -final _objc_msgSend_98pnic = objc.msgSendPointer +final _objc_msgSend_1x2hskc = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -69459,7 +76782,7 @@ final _objc_msgSend_98pnic = objc.msgSendPointer ffi.Pointer Function(ffi.Pointer, ffi.Pointer, int)>(); late final _sel_numberWithFloat_ = objc.registerName("numberWithFloat:"); -final _objc_msgSend_1f4qa0h = objc.msgSendPointer +final _objc_msgSend_et8cuh = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -69469,7 +76792,7 @@ final _objc_msgSend_1f4qa0h = objc.msgSendPointer ffi.Pointer, double)>(); late final _sel_numberWithDouble_ = objc.registerName("numberWithDouble:"); late final _sel_numberWithBool_ = objc.registerName("numberWithBool:"); -final _objc_msgSend_1l3kbc1 = objc.msgSendPointer +final _objc_msgSend_1t6aok9 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -69486,13 +76809,13 @@ extension NSNumberCreation on objc.NSNumber { /// numberWithChar: static objc.NSNumber numberWithChar_(int value) { final _ret = - _objc_msgSend_vx1f2d(_class_NSNumber, _sel_numberWithChar_, value); + _objc_msgSend_13mclwd(_class_NSNumber, _sel_numberWithChar_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } /// numberWithUnsignedChar: static objc.NSNumber numberWithUnsignedChar_(int value) { - final _ret = _objc_msgSend_uzucl8( + final _ret = _objc_msgSend_7uautw( _class_NSNumber, _sel_numberWithUnsignedChar_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } @@ -69500,13 +76823,13 @@ extension NSNumberCreation on objc.NSNumber { /// numberWithShort: static objc.NSNumber numberWithShort_(int value) { final _ret = - _objc_msgSend_cvzqr9(_class_NSNumber, _sel_numberWithShort_, value); + _objc_msgSend_68x6r1(_class_NSNumber, _sel_numberWithShort_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } /// numberWithUnsignedShort: static objc.NSNumber numberWithUnsignedShort_(int value) { - final _ret = _objc_msgSend_onx6bi( + final _ret = _objc_msgSend_1njucl2( _class_NSNumber, _sel_numberWithUnsignedShort_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } @@ -69514,13 +76837,13 @@ extension NSNumberCreation on objc.NSNumber { /// numberWithInt: static objc.NSNumber numberWithInt_(int value) { final _ret = - _objc_msgSend_1a0iyvk(_class_NSNumber, _sel_numberWithInt_, value); + _objc_msgSend_14hvw5k(_class_NSNumber, _sel_numberWithInt_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } /// numberWithUnsignedInt: static objc.NSNumber numberWithUnsignedInt_(int value) { - final _ret = _objc_msgSend_12mhqtk( + final _ret = _objc_msgSend_degb40( _class_NSNumber, _sel_numberWithUnsignedInt_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } @@ -69528,13 +76851,13 @@ extension NSNumberCreation on objc.NSNumber { /// numberWithLong: static objc.NSNumber numberWithLong_(int value) { final _ret = - _objc_msgSend_8o14b(_class_NSNumber, _sel_numberWithLong_, value); + _objc_msgSend_qugqlf(_class_NSNumber, _sel_numberWithLong_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } /// numberWithUnsignedLong: static objc.NSNumber numberWithUnsignedLong_(int value) { - final _ret = _objc_msgSend_1qrcblu( + final _ret = _objc_msgSend_14hpxwa( _class_NSNumber, _sel_numberWithUnsignedLong_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } @@ -69542,13 +76865,13 @@ extension NSNumberCreation on objc.NSNumber { /// numberWithLongLong: static objc.NSNumber numberWithLongLong_(int value) { final _ret = - _objc_msgSend_94zdgv(_class_NSNumber, _sel_numberWithLongLong_, value); + _objc_msgSend_16f0drb(_class_NSNumber, _sel_numberWithLongLong_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } /// numberWithUnsignedLongLong: static objc.NSNumber numberWithUnsignedLongLong_(int value) { - final _ret = _objc_msgSend_98pnic( + final _ret = _objc_msgSend_1x2hskc( _class_NSNumber, _sel_numberWithUnsignedLongLong_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } @@ -69556,34 +76879,34 @@ extension NSNumberCreation on objc.NSNumber { /// numberWithFloat: static objc.NSNumber numberWithFloat_(double value) { final _ret = - _objc_msgSend_1f4qa0h(_class_NSNumber, _sel_numberWithFloat_, value); + _objc_msgSend_et8cuh(_class_NSNumber, _sel_numberWithFloat_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } /// numberWithDouble: static objc.NSNumber numberWithDouble_(double value) { final _ret = - _objc_msgSend_1x911p2(_class_NSNumber, _sel_numberWithDouble_, value); + _objc_msgSend_oa8mke(_class_NSNumber, _sel_numberWithDouble_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } /// numberWithBool: static objc.NSNumber numberWithBool_(bool value) { final _ret = - _objc_msgSend_1l3kbc1(_class_NSNumber, _sel_numberWithBool_, value); + _objc_msgSend_1t6aok9(_class_NSNumber, _sel_numberWithBool_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } /// numberWithInteger: static objc.NSNumber numberWithInteger_(DartNSInteger value) { final _ret = - _objc_msgSend_8o14b(_class_NSNumber, _sel_numberWithInteger_, value); + _objc_msgSend_qugqlf(_class_NSNumber, _sel_numberWithInteger_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } /// numberWithUnsignedInteger: static objc.NSNumber numberWithUnsignedInteger_(DartNSUInteger value) { - final _ret = _objc_msgSend_1qrcblu( + final _ret = _objc_msgSend_14hpxwa( _class_NSNumber, _sel_numberWithUnsignedInteger_, value); return objc.NSNumber.castFromPointer(_ret, retain: true, release: true); } @@ -69610,7 +76933,7 @@ extension NSDeprecated2 on objc.NSValue { typedef NSRange = objc.NSRange; typedef NSRangePointer = ffi.Pointer; late final _sel_valueWithRange_ = objc.registerName("valueWithRange:"); -final _objc_msgSend_83z673 = objc.msgSendPointer +final _objc_msgSend_1k1o1s7 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -69643,7 +76966,7 @@ extension NSValueRangeExtensions on objc.NSValue { /// valueWithRange: static objc.NSValue valueWithRange_(NSRange range) { final _ret = - _objc_msgSend_83z673(_class_NSValue, _sel_valueWithRange_, range); + _objc_msgSend_1k1o1s7(_class_NSValue, _sel_valueWithRange_, range); return objc.NSValue.castFromPointer(_ret, retain: true, release: true); } @@ -69686,7 +77009,7 @@ final _objc_msgSend_o16d3k = objc.msgSendPointer ffi.Pointer>, objc.NSRange)>(); late final _sel_indexOfObject_ = objc.registerName("indexOfObject:"); -final _objc_msgSend_1p4b7x4 = objc.msgSendPointer +final _objc_msgSend_1vd1c5m = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.UnsignedLong Function( @@ -69698,7 +77021,7 @@ final _objc_msgSend_1p4b7x4 = objc.msgSendPointer ffi.Pointer, ffi.Pointer)>(); late final _sel_indexOfObject_inRange_ = objc.registerName("indexOfObject:inRange:"); -final _objc_msgSend_1c913oo = objc.msgSendPointer +final _objc_msgSend_zug4wi = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.UnsignedLong Function( @@ -69724,7 +77047,7 @@ late final _sel_reverseObjectEnumerator = late final _sel_sortedArrayHint = objc.registerName("sortedArrayHint"); late final _sel_sortedArrayUsingFunction_context_ = objc.registerName("sortedArrayUsingFunction:context:"); -final _objc_msgSend_1iiv4px = objc.msgSendPointer +final _objc_msgSend_1ffoev1 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -69748,7 +77071,7 @@ final _objc_msgSend_1iiv4px = objc.msgSendPointer ffi.Pointer)>(); late final _sel_sortedArrayUsingFunction_context_hint_ = objc.registerName("sortedArrayUsingFunction:context:hint:"); -final _objc_msgSend_iqbzrn = objc.msgSendPointer +final _objc_msgSend_1i2r70j = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -69789,7 +77112,7 @@ final _objc_msgSend_1d9e4oe = objc.msgSendPointer ffi.Pointer, ffi.Pointer)>(); late final _sel_makeObjectsPerformSelector_withObject_ = objc.registerName("makeObjectsPerformSelector:withObject:"); -final _objc_msgSend_1c03bya = objc.msgSendPointer +final _objc_msgSend_1qv0eq4 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -69868,6 +77191,56 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_objcObjCObject_NSUInteger_bool_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_objcObjCObject_NSUInteger_bool_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + int arg1, + ffi.Pointer arg2) { + try { + (objc.getBlockClosure(block) as void Function(ffi.Pointer, + int, ffi.Pointer))(arg0, arg1, arg2); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSUInteger, + ffi.Pointer)> + _ObjCBlock_ffiVoid_objcObjCObject_NSUInteger_bool_blockingCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSUInteger, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_objcObjCObject_NSUInteger_bool_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSUInteger, + ffi.Pointer)> + _ObjCBlock_ffiVoid_objcObjCObject_NSUInteger_bool_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSUInteger, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_objcObjCObject_NSUInteger_bool_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, ffi.UnsignedLong, ffi.Pointer)>`. abstract final class ObjCBlock_ffiVoid_objcObjCObject_NSUInteger_bool { @@ -69938,8 +77311,47 @@ abstract final class ObjCBlock_ffiVoid_objcObjCObject_NSUInteger_bool { ffi.Pointer arg2) => fn(objc.ObjCObjectBase(arg0, retain: false, release: true), arg1, arg2)); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_16ko9u(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1p9ui4q(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, ffi.UnsignedLong, + ffi.Pointer)>(wrapper, retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, ffi.UnsignedLong, + ffi.Pointer)> blocking( + void Function(objc.ObjCObjectBase, DartNSUInteger, ffi.Pointer) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_objcObjCObject_NSUInteger_bool_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, int arg1, + ffi.Pointer arg2) => + fn(objc.ObjCObjectBase(arg0, retain: false, release: true), arg1, + arg2)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_objcObjCObject_NSUInteger_bool_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, int arg1, + ffi.Pointer arg2) => + fn(objc.ObjCObjectBase(arg0, retain: false, release: true), arg1, + arg2)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1p9ui4q, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function(ffi.Pointer, ffi.UnsignedLong, ffi.Pointer)>(wrapper, retain: false, release: true); @@ -69976,7 +77388,7 @@ late final _sel_enumerateObjectsWithOptions_usingBlock_ = objc.registerName("enumerateObjectsWithOptions:usingBlock:"); late final _sel_enumerateObjectsAtIndexes_options_usingBlock_ = objc.registerName("enumerateObjectsAtIndexes:options:usingBlock:"); -final _objc_msgSend_p1bhs = objc.msgSendPointer +final _objc_msgSend_a3wp08 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -70137,7 +77549,7 @@ final _objc_msgSend_1698hqz = objc.msgSendPointer ffi.Pointer)>(); late final _sel_indexOfObjectAtIndexes_options_passingTest_ = objc.registerName("indexOfObjectAtIndexes:options:passingTest:"); -final _objc_msgSend_viax9j = objc.msgSendPointer +final _objc_msgSend_k1x6mt = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.UnsignedLong Function( @@ -70159,7 +77571,7 @@ late final _sel_indexesOfObjectsWithOptions_passingTest_ = objc.registerName("indexesOfObjectsWithOptions:passingTest:"); late final _sel_indexesOfObjectsAtIndexes_options_passingTest_ = objc.registerName("indexesOfObjectsAtIndexes:options:passingTest:"); -final _objc_msgSend_1bj2f0k = objc.msgSendPointer +final _objc_msgSend_1i9v144 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -70181,7 +77593,7 @@ late final _sel_sortedArrayWithOptions_usingComparator_ = objc.registerName("sortedArrayWithOptions:usingComparator:"); late final _sel_indexOfObject_inSortedRange_options_usingComparator_ = objc.registerName("indexOfObject:inSortedRange:options:usingComparator:"); -final _objc_msgSend_9efhbf = objc.msgSendPointer +final _objc_msgSend_kshx9d = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.UnsignedLong Function( @@ -70204,40 +77616,40 @@ final _objc_msgSend_9efhbf = objc.msgSendPointer extension NSExtendedArray on objc.NSArray { /// arrayByAddingObject: objc.NSArray arrayByAddingObject_(objc.ObjCObjectBase anObject) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_arrayByAddingObject_, anObject.ref.pointer); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } /// arrayByAddingObjectsFromArray: objc.NSArray arrayByAddingObjectsFromArray_(objc.NSArray otherArray) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_arrayByAddingObjectsFromArray_, otherArray.ref.pointer); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } /// componentsJoinedByString: objc.NSString componentsJoinedByString_(objc.NSString separator) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_componentsJoinedByString_, separator.ref.pointer); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// containsObject: bool containsObject_(objc.ObjCObjectBase anObject) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( this.ref.pointer, _sel_containsObject_, anObject.ref.pointer); } /// description objc.NSString get description { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_description); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_description); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// descriptionWithLocale: objc.NSString descriptionWithLocale_(objc.ObjCObjectBase? locale) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_descriptionWithLocale_, locale?.ref.pointer ?? ffi.nullptr); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -70245,7 +77657,7 @@ extension NSExtendedArray on objc.NSArray { /// descriptionWithLocale:indent: objc.NSString descriptionWithLocale_indent_( objc.ObjCObjectBase? locale, DartNSUInteger level) { - final _ret = _objc_msgSend_dcd68g( + final _ret = _objc_msgSend_1k4kd9s( this.ref.pointer, _sel_descriptionWithLocale_indent_, locale?.ref.pointer ?? ffi.nullptr, @@ -70255,7 +77667,7 @@ extension NSExtendedArray on objc.NSArray { /// firstObjectCommonWithArray: objc.ObjCObjectBase? firstObjectCommonWithArray_(objc.NSArray otherArray) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_firstObjectCommonWithArray_, otherArray.ref.pointer); return _ret.address == 0 ? null @@ -70271,39 +77683,39 @@ extension NSExtendedArray on objc.NSArray { /// indexOfObject: DartNSUInteger indexOfObject_(objc.ObjCObjectBase anObject) { - return _objc_msgSend_1p4b7x4( + return _objc_msgSend_1vd1c5m( this.ref.pointer, _sel_indexOfObject_, anObject.ref.pointer); } /// indexOfObject:inRange: DartNSUInteger indexOfObject_inRange_( objc.ObjCObjectBase anObject, NSRange range) { - return _objc_msgSend_1c913oo(this.ref.pointer, _sel_indexOfObject_inRange_, + return _objc_msgSend_zug4wi(this.ref.pointer, _sel_indexOfObject_inRange_, anObject.ref.pointer, range); } /// indexOfObjectIdenticalTo: DartNSUInteger indexOfObjectIdenticalTo_(objc.ObjCObjectBase anObject) { - return _objc_msgSend_1p4b7x4( + return _objc_msgSend_1vd1c5m( this.ref.pointer, _sel_indexOfObjectIdenticalTo_, anObject.ref.pointer); } /// indexOfObjectIdenticalTo:inRange: DartNSUInteger indexOfObjectIdenticalTo_inRange_( objc.ObjCObjectBase anObject, NSRange range) { - return _objc_msgSend_1c913oo(this.ref.pointer, + return _objc_msgSend_zug4wi(this.ref.pointer, _sel_indexOfObjectIdenticalTo_inRange_, anObject.ref.pointer, range); } /// isEqualToArray: bool isEqualToArray_(objc.NSArray otherArray) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( this.ref.pointer, _sel_isEqualToArray_, otherArray.ref.pointer); } /// firstObject objc.ObjCObjectBase? get firstObject { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_firstObject); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_firstObject); return _ret.address == 0 ? null : objc.ObjCObjectBase(_ret, retain: true, release: true); @@ -70311,7 +77723,7 @@ extension NSExtendedArray on objc.NSArray { /// lastObject objc.ObjCObjectBase? get lastObject { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_lastObject); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_lastObject); return _ret.address == 0 ? null : objc.ObjCObjectBase(_ret, retain: true, release: true); @@ -70319,20 +77731,20 @@ extension NSExtendedArray on objc.NSArray { /// objectEnumerator objc.NSEnumerator objectEnumerator() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_objectEnumerator); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_objectEnumerator); return objc.NSEnumerator.castFromPointer(_ret, retain: true, release: true); } /// reverseObjectEnumerator objc.NSEnumerator reverseObjectEnumerator() { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_reverseObjectEnumerator); + _objc_msgSend_151sglz(this.ref.pointer, _sel_reverseObjectEnumerator); return objc.NSEnumerator.castFromPointer(_ret, retain: true, release: true); } /// sortedArrayHint objc.NSData get sortedArrayHint { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_sortedArrayHint); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_sortedArrayHint); return objc.NSData.castFromPointer(_ret, retain: true, release: true); } @@ -70344,7 +77756,7 @@ extension NSExtendedArray on objc.NSArray { ffi.Pointer, ffi.Pointer)>> comparator, ffi.Pointer context) { - final _ret = _objc_msgSend_1iiv4px(this.ref.pointer, + final _ret = _objc_msgSend_1ffoev1(this.ref.pointer, _sel_sortedArrayUsingFunction_context_, comparator, context); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } @@ -70358,7 +77770,7 @@ extension NSExtendedArray on objc.NSArray { comparator, ffi.Pointer context, objc.NSData? hint) { - final _ret = _objc_msgSend_iqbzrn( + final _ret = _objc_msgSend_1i2r70j( this.ref.pointer, _sel_sortedArrayUsingFunction_context_hint_, comparator, @@ -70370,7 +77782,7 @@ extension NSExtendedArray on objc.NSArray { /// sortedArrayUsingSelector: objc.NSArray sortedArrayUsingSelector_( ffi.Pointer comparator) { - final _ret = _objc_msgSend_19hbqky( + final _ret = _objc_msgSend_3ctkt6( this.ref.pointer, _sel_sortedArrayUsingSelector_, comparator); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } @@ -70378,14 +77790,14 @@ extension NSExtendedArray on objc.NSArray { /// subarrayWithRange: objc.NSArray subarrayWithRange_(NSRange range) { final _ret = - _objc_msgSend_83z673(this.ref.pointer, _sel_subarrayWithRange_, range); + _objc_msgSend_1k1o1s7(this.ref.pointer, _sel_subarrayWithRange_, range); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } /// writeToURL:error: bool writeToURL_error_( objc.NSURL url, ffi.Pointer> error) { - return _objc_msgSend_blqzg8( + return _objc_msgSend_l9p60w( this.ref.pointer, _sel_writeToURL_error_, url.ref.pointer, error); } @@ -70398,7 +77810,7 @@ extension NSExtendedArray on objc.NSArray { /// makeObjectsPerformSelector:withObject: void makeObjectsPerformSelector_withObject_( ffi.Pointer aSelector, objc.ObjCObjectBase? argument) { - _objc_msgSend_1c03bya( + _objc_msgSend_1qv0eq4( this.ref.pointer, _sel_makeObjectsPerformSelector_withObject_, aSelector, @@ -70407,14 +77819,14 @@ extension NSExtendedArray on objc.NSArray { /// objectsAtIndexes: objc.NSArray objectsAtIndexes_(objc.NSIndexSet indexes) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_objectsAtIndexes_, indexes.ref.pointer); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } /// objectAtIndexedSubscript: objc.ObjCObjectBase objectAtIndexedSubscript_(DartNSUInteger idx) { - final _ret = _objc_msgSend_1qrcblu( + final _ret = _objc_msgSend_14hpxwa( this.ref.pointer, _sel_objectAtIndexedSubscript_, idx); return objc.ObjCObjectBase(_ret, retain: true, release: true); } @@ -70451,7 +77863,7 @@ extension NSExtendedArray on objc.NSArray { ffi.Void Function(ffi.Pointer, ffi.UnsignedLong, ffi.Pointer)> block) { - _objc_msgSend_p1bhs( + _objc_msgSend_a3wp08( this.ref.pointer, _sel_enumerateObjectsAtIndexes_options_usingBlock_, s.ref.pointer, @@ -70491,7 +77903,7 @@ extension NSExtendedArray on objc.NSArray { ffi.Bool Function(ffi.Pointer, ffi.UnsignedLong, ffi.Pointer)> predicate) { - return _objc_msgSend_viax9j( + return _objc_msgSend_k1x6mt( this.ref.pointer, _sel_indexOfObjectAtIndexes_options_passingTest_, s.ref.pointer, @@ -70505,7 +77917,7 @@ extension NSExtendedArray on objc.NSArray { ffi.Bool Function(ffi.Pointer, ffi.UnsignedLong, ffi.Pointer)> predicate) { - final _ret = _objc_msgSend_cy99le(this.ref.pointer, + final _ret = _objc_msgSend_nnxkei(this.ref.pointer, _sel_indexesOfObjectsPassingTest_, predicate.ref.pointer); return objc.NSIndexSet.castFromPointer(_ret, retain: true, release: true); } @@ -70517,7 +77929,7 @@ extension NSExtendedArray on objc.NSArray { ffi.Bool Function(ffi.Pointer, ffi.UnsignedLong, ffi.Pointer)> predicate) { - final _ret = _objc_msgSend_hd4f96( + final _ret = _objc_msgSend_13x5boi( this.ref.pointer, _sel_indexesOfObjectsWithOptions_passingTest_, opts.value, @@ -70533,7 +77945,7 @@ extension NSExtendedArray on objc.NSArray { ffi.Bool Function(ffi.Pointer, ffi.UnsignedLong, ffi.Pointer)> predicate) { - final _ret = _objc_msgSend_1bj2f0k( + final _ret = _objc_msgSend_1i9v144( this.ref.pointer, _sel_indexesOfObjectsAtIndexes_options_passingTest_, s.ref.pointer, @@ -70544,7 +77956,7 @@ extension NSExtendedArray on objc.NSArray { /// sortedArrayUsingComparator: objc.NSArray sortedArrayUsingComparator_(DartNSComparator cmptr) { - final _ret = _objc_msgSend_cy99le( + final _ret = _objc_msgSend_nnxkei( this.ref.pointer, _sel_sortedArrayUsingComparator_, cmptr.ref.pointer); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } @@ -70552,7 +77964,7 @@ extension NSExtendedArray on objc.NSArray { /// sortedArrayWithOptions:usingComparator: objc.NSArray sortedArrayWithOptions_usingComparator_( objc.NSSortOptions opts, DartNSComparator cmptr) { - final _ret = _objc_msgSend_1u2b7ut( + final _ret = _objc_msgSend_1x5ew3h( this.ref.pointer, _sel_sortedArrayWithOptions_usingComparator_, opts.value, @@ -70566,7 +77978,7 @@ extension NSExtendedArray on objc.NSArray { NSRange r, objc.NSBinarySearchingOptions opts, DartNSComparator cmp) { - return _objc_msgSend_9efhbf( + return _objc_msgSend_kshx9d( this.ref.pointer, _sel_indexOfObject_inSortedRange_options_usingComparator_, obj.ref.pointer, @@ -70580,7 +77992,7 @@ late final _sel_array = objc.registerName("array"); late final _sel_arrayWithObject_ = objc.registerName("arrayWithObject:"); late final _sel_arrayWithObjects_count_ = objc.registerName("arrayWithObjects:count:"); -final _objc_msgSend_1lqqdvl = objc.msgSendPointer +final _objc_msgSend_zmbtbd = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -70607,13 +78019,13 @@ late final _sel_arrayWithContentsOfURL_error_ = extension NSArrayCreation on objc.NSArray { /// array static objc.NSArray array() { - final _ret = _objc_msgSend_1x359cv(_class_NSArray, _sel_array); + final _ret = _objc_msgSend_151sglz(_class_NSArray, _sel_array); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } /// arrayWithObject: static objc.NSArray arrayWithObject_(objc.ObjCObjectBase anObject) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSArray, _sel_arrayWithObject_, anObject.ref.pointer); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } @@ -70621,42 +78033,42 @@ extension NSArrayCreation on objc.NSArray { /// arrayWithObjects:count: static objc.NSArray arrayWithObjects_count_( ffi.Pointer> objects, DartNSUInteger cnt) { - final _ret = _objc_msgSend_1lqqdvl( + final _ret = _objc_msgSend_zmbtbd( _class_NSArray, _sel_arrayWithObjects_count_, objects, cnt); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } /// arrayWithObjects: static objc.NSArray arrayWithObjects_(objc.ObjCObjectBase firstObj) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSArray, _sel_arrayWithObjects_, firstObj.ref.pointer); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } /// arrayWithArray: static objc.NSArray arrayWithArray_(objc.NSArray array) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSArray, _sel_arrayWithArray_, array.ref.pointer); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } /// initWithObjects: objc.NSArray initWithObjects_(objc.ObjCObjectBase firstObj) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithObjects_, firstObj.ref.pointer); return objc.NSArray.castFromPointer(_ret, retain: false, release: true); } /// initWithArray: objc.NSArray initWithArray_(objc.NSArray array) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithArray_, array.ref.pointer); return objc.NSArray.castFromPointer(_ret, retain: false, release: true); } /// initWithArray:copyItems: objc.NSArray initWithArray_copyItems_(objc.NSArray array, bool flag) { - final _ret = _objc_msgSend_1bdmr5f(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_17amj0z(this.ref.retainAndReturnPointer(), _sel_initWithArray_copyItems_, array.ref.pointer, flag); return objc.NSArray.castFromPointer(_ret, retain: false, release: true); } @@ -70664,7 +78076,7 @@ extension NSArrayCreation on objc.NSArray { /// initWithContentsOfURL:error: objc.NSArray? initWithContentsOfURL_error_( objc.NSURL url, ffi.Pointer> error) { - final _ret = _objc_msgSend_1705co6(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1lhpu4m(this.ref.retainAndReturnPointer(), _sel_initWithContentsOfURL_error_, url.ref.pointer, error); return _ret.address == 0 ? null @@ -70674,7 +78086,7 @@ extension NSArrayCreation on objc.NSArray { /// arrayWithContentsOfURL:error: static objc.NSArray? arrayWithContentsOfURL_error_( objc.NSURL url, ffi.Pointer> error) { - final _ret = _objc_msgSend_1705co6(_class_NSArray, + final _ret = _objc_msgSend_1lhpu4m(_class_NSArray, _sel_arrayWithContentsOfURL_error_, url.ref.pointer, error); return _ret.address == 0 ? null @@ -70792,7 +78204,7 @@ extension ObjCBlock_bool_objcObjCObject_objcObjCObject_CallExtension late final _sel_differenceFromArray_withOptions_usingEquivalenceTest_ = objc.registerName("differenceFromArray:withOptions:usingEquivalenceTest:"); -final _objc_msgSend_1jy28v8 = objc.msgSendPointer +final _objc_msgSend_1415lvo = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -70810,7 +78222,7 @@ final _objc_msgSend_1jy28v8 = objc.msgSendPointer ffi.Pointer)>(); late final _sel_differenceFromArray_withOptions_ = objc.registerName("differenceFromArray:withOptions:"); -final _objc_msgSend_4yz83j = objc.msgSendPointer +final _objc_msgSend_1wtpmu7 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -70840,7 +78252,7 @@ extension NSArrayDiffing on objc.NSArray { ffi.Bool Function(ffi.Pointer, ffi.Pointer)> block) { - final _ret = _objc_msgSend_1jy28v8( + final _ret = _objc_msgSend_1415lvo( this.ref.pointer, _sel_differenceFromArray_withOptions_usingEquivalenceTest_, other.ref.pointer, @@ -70854,7 +78266,7 @@ extension NSArrayDiffing on objc.NSArray { objc.NSOrderedCollectionDifference differenceFromArray_withOptions_( objc.NSArray other, objc.NSOrderedCollectionDifferenceCalculationOptions options) { - final _ret = _objc_msgSend_4yz83j( + final _ret = _objc_msgSend_1wtpmu7( this.ref.pointer, _sel_differenceFromArray_withOptions_, other.ref.pointer, @@ -70865,7 +78277,7 @@ extension NSArrayDiffing on objc.NSArray { /// differenceFromArray: objc.NSOrderedCollectionDifference differenceFromArray_(objc.NSArray other) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_differenceFromArray_, other.ref.pointer); return objc.NSOrderedCollectionDifference.castFromPointer(_ret, retain: true, release: true); @@ -70874,7 +78286,7 @@ extension NSArrayDiffing on objc.NSArray { /// arrayByApplyingDifference: objc.NSArray? arrayByApplyingDifference_( objc.NSOrderedCollectionDifference difference) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_arrayByApplyingDifference_, difference.ref.pointer); return _ret.address == 0 ? null @@ -70909,7 +78321,7 @@ extension NSDeprecated3 on objc.NSArray { /// arrayWithContentsOfFile: static objc.NSArray? arrayWithContentsOfFile_(objc.NSString path) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSArray, _sel_arrayWithContentsOfFile_, path.ref.pointer); return _ret.address == 0 ? null @@ -70918,7 +78330,7 @@ extension NSDeprecated3 on objc.NSArray { /// arrayWithContentsOfURL: static objc.NSArray? arrayWithContentsOfURL_(objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSArray, _sel_arrayWithContentsOfURL_, url.ref.pointer); return _ret.address == 0 ? null @@ -70927,7 +78339,7 @@ extension NSDeprecated3 on objc.NSArray { /// initWithContentsOfFile: objc.NSArray? initWithContentsOfFile_(objc.NSString path) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithContentsOfFile_, path.ref.pointer); return _ret.address == 0 ? null @@ -70936,7 +78348,7 @@ extension NSDeprecated3 on objc.NSArray { /// initWithContentsOfURL: objc.NSArray? initWithContentsOfURL_(objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithContentsOfURL_, url.ref.pointer); return _ret.address == 0 ? null @@ -70945,13 +78357,13 @@ extension NSDeprecated3 on objc.NSArray { /// writeToFile:atomically: bool writeToFile_atomically_(objc.NSString path, bool useAuxiliaryFile) { - return _objc_msgSend_w8pbfh(this.ref.pointer, _sel_writeToFile_atomically_, + return _objc_msgSend_1iyq28l(this.ref.pointer, _sel_writeToFile_atomically_, path.ref.pointer, useAuxiliaryFile); } /// writeToURL:atomically: bool writeToURL_atomically_(objc.NSURL url, bool atomically) { - return _objc_msgSend_w8pbfh(this.ref.pointer, _sel_writeToURL_atomically_, + return _objc_msgSend_1iyq28l(this.ref.pointer, _sel_writeToURL_atomically_, url.ref.pointer, atomically); } } @@ -70974,7 +78386,7 @@ final _objc_msgSend_bfp043 = objc.msgSendPointer ffi.Pointer, int, int)>(); late final _sel_removeObject_inRange_ = objc.registerName("removeObject:inRange:"); -final _objc_msgSend_16f6m81 = objc.msgSendPointer +final _objc_msgSend_1oteutl = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -71023,7 +78435,7 @@ final _objc_msgSend_1e3pm0z = objc.msgSendPointer ffi.Pointer, objc.NSRange)>(); late final _sel_replaceObjectsInRange_withObjectsFromArray_range_ = objc.registerName("replaceObjectsInRange:withObjectsFromArray:range:"); -final _objc_msgSend_169h6dj = objc.msgSendPointer +final _objc_msgSend_15bolr3 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -71041,7 +78453,7 @@ final _objc_msgSend_169h6dj = objc.msgSendPointer objc.NSRange)>(); late final _sel_replaceObjectsInRange_withObjectsFromArray_ = objc.registerName("replaceObjectsInRange:withObjectsFromArray:"); -final _objc_msgSend_i4ny2p = objc.msgSendPointer +final _objc_msgSend_1tv4uax = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -71089,7 +78501,7 @@ late final _sel_replaceObjectsAtIndexes_withObjects_ = objc.registerName("replaceObjectsAtIndexes:withObjects:"); late final _sel_setObject_atIndexedSubscript_ = objc.registerName("setObject:atIndexedSubscript:"); -final _objc_msgSend_10i1axw = objc.msgSendPointer +final _objc_msgSend_djsa9o = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -71126,7 +78538,7 @@ final _objc_msgSend_jjgvjt = objc.msgSendPointer extension NSExtendedMutableArray on objc.NSMutableArray { /// addObjectsFromArray: void addObjectsFromArray_(objc.NSArray otherArray) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_addObjectsFromArray_, otherArray.ref.pointer); } @@ -71144,26 +78556,26 @@ extension NSExtendedMutableArray on objc.NSMutableArray { /// removeObject:inRange: void removeObject_inRange_(objc.ObjCObjectBase anObject, NSRange range) { - _objc_msgSend_16f6m81(this.ref.pointer, _sel_removeObject_inRange_, + _objc_msgSend_1oteutl(this.ref.pointer, _sel_removeObject_inRange_, anObject.ref.pointer, range); } /// removeObject: void removeObject_(objc.ObjCObjectBase anObject) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_removeObject_, anObject.ref.pointer); } /// removeObjectIdenticalTo:inRange: void removeObjectIdenticalTo_inRange_( objc.ObjCObjectBase anObject, NSRange range) { - _objc_msgSend_16f6m81(this.ref.pointer, + _objc_msgSend_1oteutl(this.ref.pointer, _sel_removeObjectIdenticalTo_inRange_, anObject.ref.pointer, range); } /// removeObjectIdenticalTo: void removeObjectIdenticalTo_(objc.ObjCObjectBase anObject) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_removeObjectIdenticalTo_, anObject.ref.pointer); } @@ -71176,7 +78588,7 @@ extension NSExtendedMutableArray on objc.NSMutableArray { /// removeObjectsInArray: void removeObjectsInArray_(objc.NSArray otherArray) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_removeObjectsInArray_, otherArray.ref.pointer); } @@ -71188,7 +78600,7 @@ extension NSExtendedMutableArray on objc.NSMutableArray { /// replaceObjectsInRange:withObjectsFromArray:range: void replaceObjectsInRange_withObjectsFromArray_range_( NSRange range, objc.NSArray otherArray, NSRange otherRange) { - _objc_msgSend_169h6dj( + _objc_msgSend_15bolr3( this.ref.pointer, _sel_replaceObjectsInRange_withObjectsFromArray_range_, range, @@ -71199,7 +78611,7 @@ extension NSExtendedMutableArray on objc.NSMutableArray { /// replaceObjectsInRange:withObjectsFromArray: void replaceObjectsInRange_withObjectsFromArray_( NSRange range, objc.NSArray otherArray) { - _objc_msgSend_i4ny2p( + _objc_msgSend_1tv4uax( this.ref.pointer, _sel_replaceObjectsInRange_withObjectsFromArray_, range, @@ -71208,7 +78620,7 @@ extension NSExtendedMutableArray on objc.NSMutableArray { /// setArray: void setArray_(objc.NSArray otherArray) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_setArray_, otherArray.ref.pointer); } @@ -71232,20 +78644,20 @@ extension NSExtendedMutableArray on objc.NSMutableArray { /// insertObjects:atIndexes: void insertObjects_atIndexes_(objc.NSArray objects, objc.NSIndexSet indexes) { - _objc_msgSend_wjvic9(this.ref.pointer, _sel_insertObjects_atIndexes_, + _objc_msgSend_pfv6jd(this.ref.pointer, _sel_insertObjects_atIndexes_, objects.ref.pointer, indexes.ref.pointer); } /// removeObjectsAtIndexes: void removeObjectsAtIndexes_(objc.NSIndexSet indexes) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_removeObjectsAtIndexes_, indexes.ref.pointer); } /// replaceObjectsAtIndexes:withObjects: void replaceObjectsAtIndexes_withObjects_( objc.NSIndexSet indexes, objc.NSArray objects) { - _objc_msgSend_wjvic9( + _objc_msgSend_pfv6jd( this.ref.pointer, _sel_replaceObjectsAtIndexes_withObjects_, indexes.ref.pointer, @@ -71255,7 +78667,7 @@ extension NSExtendedMutableArray on objc.NSMutableArray { /// setObject:atIndexedSubscript: void setObject_atIndexedSubscript_( objc.ObjCObjectBase obj, DartNSUInteger idx) { - _objc_msgSend_10i1axw(this.ref.pointer, _sel_setObject_atIndexedSubscript_, + _objc_msgSend_djsa9o(this.ref.pointer, _sel_setObject_atIndexedSubscript_, obj.ref.pointer, idx); } @@ -71279,7 +78691,7 @@ late final _sel_arrayWithCapacity_ = objc.registerName("arrayWithCapacity:"); extension NSMutableArrayCreation on objc.NSMutableArray { /// arrayWithCapacity: static objc.NSMutableArray arrayWithCapacity_(DartNSUInteger numItems) { - final _ret = _objc_msgSend_1qrcblu( + final _ret = _objc_msgSend_14hpxwa( _class_NSMutableArray, _sel_arrayWithCapacity_, numItems); return objc.NSMutableArray.castFromPointer(_ret, retain: true, release: true); @@ -71287,7 +78699,7 @@ extension NSMutableArrayCreation on objc.NSMutableArray { /// arrayWithContentsOfFile: static objc.NSMutableArray? arrayWithContentsOfFile_(objc.NSString path) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSMutableArray, _sel_arrayWithContentsOfFile_, path.ref.pointer); return _ret.address == 0 ? null @@ -71297,7 +78709,7 @@ extension NSMutableArrayCreation on objc.NSMutableArray { /// arrayWithContentsOfURL: static objc.NSMutableArray? arrayWithContentsOfURL_(objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSMutableArray, _sel_arrayWithContentsOfURL_, url.ref.pointer); return _ret.address == 0 ? null @@ -71307,7 +78719,7 @@ extension NSMutableArrayCreation on objc.NSMutableArray { /// initWithContentsOfFile: objc.NSMutableArray? initWithContentsOfFile_(objc.NSString path) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithContentsOfFile_, path.ref.pointer); return _ret.address == 0 ? null @@ -71317,7 +78729,7 @@ extension NSMutableArrayCreation on objc.NSMutableArray { /// initWithContentsOfURL: objc.NSMutableArray? initWithContentsOfURL_(objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithContentsOfURL_, url.ref.pointer); return _ret.address == 0 ? null @@ -71332,7 +78744,7 @@ late final _sel_applyDifference_ = objc.registerName("applyDifference:"); extension NSMutableArrayDiffing on objc.NSMutableArray { /// applyDifference: void applyDifference_(objc.NSOrderedCollectionDifference difference) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_applyDifference_, difference.ref.pointer); } } @@ -71392,6 +78804,51 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_objcObjCObject_NSError_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_objcObjCObject_NSError_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1) { + try { + (objc.getBlockClosure(block) as void Function(ffi.Pointer, + ffi.Pointer))(arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_objcObjCObject_NSError_blockingCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_objcObjCObject_NSError_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_objcObjCObject_NSError_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_objcObjCObject_NSError_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock?, objc.NSError)>`. abstract final class ObjCBlock_ffiVoid_objcObjCObject_NSError { @@ -71462,8 +78919,53 @@ abstract final class ObjCBlock_ffiVoid_objcObjCObject_NSError { : objc.ObjCObjectBase(arg0, retain: false, release: true), objc.NSError.castFromPointer(arg1, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_wjvic9(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_pfv6jd(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer?, + objc.NSError)>(wrapper, retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc + .ObjCBlock?, objc.NSError)> + blocking(void Function(objc.ObjCObjectBase?, objc.NSError) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_objcObjCObject_NSError_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1) => + fn( + arg0.address == 0 + ? null + : objc.ObjCObjectBase(arg0, retain: false, release: true), + objc.NSError.castFromPointer(arg1, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_objcObjCObject_NSError_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1) => + fn( + arg0.address == 0 + ? null + : objc.ObjCObjectBase(arg0, retain: false, release: true), + objc.NSError.castFromPointer(arg1, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_pfv6jd, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function(ffi.Pointer?, objc.NSError)>(wrapper, retain: false, release: true); @@ -71568,6 +79070,59 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSItemProviderCompletionHandler_objcObjCObject_NSDictionary_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_NSItemProviderCompletionHandler_objcObjCObject_NSDictionary_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + NSItemProviderCompletionHandler arg0, + ffi.Pointer arg1, + ffi.Pointer arg2) { + try { + (objc.getBlockClosure(block) as void Function( + NSItemProviderCompletionHandler, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + NSItemProviderCompletionHandler, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSItemProviderCompletionHandler_objcObjCObject_NSDictionary_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + NSItemProviderCompletionHandler, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSItemProviderCompletionHandler_objcObjCObject_NSDictionary_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + NSItemProviderCompletionHandler, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSItemProviderCompletionHandler_objcObjCObject_NSDictionary_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + NSItemProviderCompletionHandler, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSItemProviderCompletionHandler_objcObjCObject_NSDictionary_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock?, objc.NSError)>, ffi.Pointer, objc.NSDictionary)>`. abstract final class ObjCBlock_ffiVoid_NSItemProviderCompletionHandler_objcObjCObject_NSDictionary { @@ -71654,7 +79209,7 @@ abstract final class ObjCBlock_ffiVoid_NSItemProviderCompletionHandler_objcObjCO objc.ObjCObjectBase(arg1, retain: false, release: true), objc.NSDictionary.castFromPointer(arg2, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1j2nt86(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_1b3bb6a(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function( @@ -71663,6 +79218,62 @@ abstract final class ObjCBlock_ffiVoid_NSItemProviderCompletionHandler_objcObjCO ffi.Pointer, objc.NSDictionary)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function( + objc.ObjCBlock< + ffi.Void Function(ffi.Pointer?, objc.NSError)>, + ffi.Pointer, + objc.NSDictionary)> blocking( + void Function(DartNSItemProviderCompletionHandler, objc.ObjCObjectBase, + objc.NSDictionary) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSItemProviderCompletionHandler_objcObjCObject_NSDictionary_blockingCallable + .nativeFunction + .cast(), + (NSItemProviderCompletionHandler arg0, + ffi.Pointer arg1, + ffi.Pointer arg2) => + fn( + ObjCBlock_ffiVoid_objcObjCObject_NSError.castFromPointer(arg0, + retain: false, release: true), + objc.ObjCObjectBase(arg1, retain: false, release: true), + objc.NSDictionary.castFromPointer(arg2, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSItemProviderCompletionHandler_objcObjCObject_NSDictionary_blockingListenerCallable + .nativeFunction + .cast(), + (NSItemProviderCompletionHandler arg0, + ffi.Pointer arg1, + ffi.Pointer arg2) => + fn( + ObjCBlock_ffiVoid_objcObjCObject_NSError.castFromPointer(arg0, + retain: false, release: true), + objc.ObjCObjectBase(arg1, retain: false, release: true), + objc.NSDictionary.castFromPointer(arg2, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_1b3bb6a, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function( + objc.ObjCBlock< + ffi.Void Function(ffi.Pointer?, objc.NSError)>, + ffi.Pointer, + objc.NSDictionary)>(wrapper, retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock?, objc.NSError)>, ffi.Pointer, objc.NSDictionary)>`. @@ -71729,14 +79340,14 @@ extension NSPreviewSupport on objc.NSItemProvider { /// setPreviewImageHandler: set previewImageHandler(DartNSItemProviderLoadHandler? value) { - return _objc_msgSend_f167m6(this.ref.pointer, _sel_setPreviewImageHandler_, + _objc_msgSend_f167m6(this.ref.pointer, _sel_setPreviewImageHandler_, value?.ref.pointer ?? ffi.nullptr); } /// loadPreviewImageWithOptions:completionHandler: void loadPreviewImageWithOptions_completionHandler_(objc.NSDictionary options, DartNSItemProviderCompletionHandler completionHandler) { - _objc_msgSend_14pxqbs( + _objc_msgSend_o762yo( this.ref.pointer, _sel_loadPreviewImageWithOptions_completionHandler_, options.ref.pointer, @@ -71766,7 +79377,7 @@ final _objc_msgSend_898fog = objc.msgSendPointer ffi.Pointer, objc.NSRange)>(); late final _sel_compare_options_ = objc.registerName("compare:options:"); -final _objc_msgSend_16ydezh = objc.msgSendPointer +final _objc_msgSend_pg1fnv = objc.msgSendPointer .cast< ffi.NativeFunction< NSInteger Function( @@ -71782,7 +79393,7 @@ final _objc_msgSend_16ydezh = objc.msgSendPointer int)>(); late final _sel_compare_options_range_ = objc.registerName("compare:options:range:"); -final _objc_msgSend_eeuxub = objc.msgSendPointer +final _objc_msgSend_xrqic1 = objc.msgSendPointer .cast< ffi.NativeFunction< NSInteger Function( @@ -71800,7 +79411,7 @@ final _objc_msgSend_eeuxub = objc.msgSendPointer objc.NSRange)>(); late final _sel_compare_options_range_locale_ = objc.registerName("compare:options:range:locale:"); -final _objc_msgSend_i4hdht = objc.msgSendPointer +final _objc_msgSend_1895u4n = objc.msgSendPointer .cast< ffi.NativeFunction< NSInteger Function( @@ -71830,7 +79441,7 @@ late final _sel_hasPrefix_ = objc.registerName("hasPrefix:"); late final _sel_hasSuffix_ = objc.registerName("hasSuffix:"); late final _sel_commonPrefixWithString_options_ = objc.registerName("commonPrefixWithString:options:"); -final _objc_msgSend_fcs5vo = objc.msgSendPointer +final _objc_msgSend_diypgk = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -71851,7 +79462,7 @@ late final _sel_localizedStandardContainsString_ = objc.registerName("localizedStandardContainsString:"); late final _sel_localizedStandardRangeOfString_ = objc.registerName("localizedStandardRangeOfString:"); -final _objc_msgSend_x4muu7 = objc.msgSendPointer +final _objc_msgSend_182fzon = objc.msgSendPointer .cast< ffi.NativeFunction< objc.NSRange Function( @@ -71861,7 +79472,7 @@ final _objc_msgSend_x4muu7 = objc.msgSendPointer .asFunction< objc.NSRange Function(ffi.Pointer, ffi.Pointer, ffi.Pointer)>(); -final _objc_msgSend_x4muu7Stret = objc.msgSendStretPointer +final _objc_msgSend_182fzonStret = objc.msgSendStretPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -71875,7 +79486,7 @@ final _objc_msgSend_x4muu7Stret = objc.msgSendStretPointer late final _sel_rangeOfString_ = objc.registerName("rangeOfString:"); late final _sel_rangeOfString_options_ = objc.registerName("rangeOfString:options:"); -final _objc_msgSend_1kwndnw = objc.msgSendPointer +final _objc_msgSend_102xxo4 = objc.msgSendPointer .cast< ffi.NativeFunction< objc.NSRange Function( @@ -71889,7 +79500,7 @@ final _objc_msgSend_1kwndnw = objc.msgSendPointer ffi.Pointer, ffi.Pointer, int)>(); -final _objc_msgSend_1kwndnwStret = objc.msgSendStretPointer +final _objc_msgSend_102xxo4Stret = objc.msgSendStretPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -71907,7 +79518,7 @@ final _objc_msgSend_1kwndnwStret = objc.msgSendStretPointer int)>(); late final _sel_rangeOfString_options_range_ = objc.registerName("rangeOfString:options:range:"); -final _objc_msgSend_ackzik = objc.msgSendPointer +final _objc_msgSend_1nmlvqc = objc.msgSendPointer .cast< ffi.NativeFunction< objc.NSRange Function( @@ -71923,7 +79534,7 @@ final _objc_msgSend_ackzik = objc.msgSendPointer ffi.Pointer, int, objc.NSRange)>(); -final _objc_msgSend_ackzikStret = objc.msgSendStretPointer +final _objc_msgSend_1nmlvqcStret = objc.msgSendStretPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -71943,7 +79554,7 @@ final _objc_msgSend_ackzikStret = objc.msgSendStretPointer objc.NSRange)>(); late final _sel_rangeOfString_options_range_locale_ = objc.registerName("rangeOfString:options:range:locale:"); -final _objc_msgSend_198mga8 = objc.msgSendPointer +final _objc_msgSend_gg0462 = objc.msgSendPointer .cast< ffi.NativeFunction< objc.NSRange Function( @@ -71961,7 +79572,7 @@ final _objc_msgSend_198mga8 = objc.msgSendPointer int, objc.NSRange, ffi.Pointer)>(); -final _objc_msgSend_198mga8Stret = objc.msgSendStretPointer +final _objc_msgSend_gg0462Stret = objc.msgSendStretPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -72159,6 +79770,61 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSString_NSRange_NSRange_bool_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_NSString_NSRange_NSRange_bool_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + NSRange arg1, + NSRange arg2, + ffi.Pointer arg3) { + try { + (objc.getBlockClosure(block) as void Function(ffi.Pointer, + NSRange, NSRange, ffi.Pointer))(arg0, arg1, arg2, arg3); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSRange, + NSRange, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSString_NSRange_NSRange_bool_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSRange, + NSRange, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSString_NSRange_NSRange_bool_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSRange, + NSRange, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSString_NSRange_NSRange_bool_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSRange, + NSRange, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSString_NSRange_NSRange_bool_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_NSString_NSRange_NSRange_bool { @@ -72234,8 +79900,59 @@ abstract final class ObjCBlock_ffiVoid_NSString_NSRange_NSRange_bool { arg1, arg2, arg3)); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_8wbg7l(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_lmc3p5(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function(objc.NSString?, objc.NSRange, objc.NSRange, + ffi.Pointer)>(wrapper, retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(objc.NSString?, objc.NSRange, objc.NSRange, + ffi.Pointer)> blocking( + void Function(objc.NSString?, NSRange, NSRange, ffi.Pointer) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSString_NSRange_NSRange_bool_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, NSRange arg1, NSRange arg2, + ffi.Pointer arg3) => + fn( + arg0.address == 0 + ? null + : objc.NSString.castFromPointer(arg0, + retain: false, release: true), + arg1, + arg2, + arg3)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSString_NSRange_NSRange_bool_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, NSRange arg1, NSRange arg2, + ffi.Pointer arg3) => + fn( + arg0.address == 0 + ? null + : objc.NSString.castFromPointer(arg0, + retain: false, release: true), + arg1, + arg2, + arg3)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_lmc3p5, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function(objc.NSString?, objc.NSRange, objc.NSRange, ffi.Pointer)>(wrapper, retain: false, release: true); @@ -72333,6 +80050,50 @@ ffi.NativeCallable< ffi.Pointer, ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSString_bool_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_NSString_bool_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, ffi.Pointer))(arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSString_bool_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSString_bool_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSString_bool_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSString_bool_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_NSString_bool { @@ -72395,12 +80156,43 @@ abstract final class ObjCBlock_ffiVoid_NSString_bool { (ffi.Pointer arg0, ffi.Pointer arg1) => fn( objc.NSString.castFromPointer(arg0, retain: false, release: true), arg1)); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_148br51(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_t8l8el(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock< ffi.Void Function(objc.NSString, ffi.Pointer)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock)> + blocking(void Function(objc.NSString, ffi.Pointer) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSString_bool_blockingCallable.nativeFunction.cast(), + (ffi.Pointer arg0, ffi.Pointer arg1) => fn( + objc.NSString.castFromPointer(arg0, retain: false, release: true), + arg1)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSString_bool_blockingListenerCallable.nativeFunction + .cast(), + (ffi.Pointer arg0, ffi.Pointer arg1) => fn( + objc.NSString.castFromPointer(arg0, retain: false, release: true), + arg1)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_t8l8el, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function(objc.NSString, ffi.Pointer)>(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock)>`. @@ -72436,7 +80228,7 @@ late final _sel_fastestEncoding = objc.registerName("fastestEncoding"); late final _sel_smallestEncoding = objc.registerName("smallestEncoding"); late final _sel_dataUsingEncoding_allowLossyConversion_ = objc.registerName("dataUsingEncoding:allowLossyConversion:"); -final _objc_msgSend_rubz6a = objc.msgSendPointer +final _objc_msgSend_hiwitm = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -72548,7 +80340,7 @@ late final _sel_stringByTrimmingCharactersInSet_ = objc.registerName("stringByTrimmingCharactersInSet:"); late final _sel_stringByPaddingToLength_withString_startingAtIndex_ = objc.registerName("stringByPaddingToLength:withString:startingAtIndex:"); -final _objc_msgSend_exgdqb = objc.msgSendPointer +final _objc_msgSend_1tfztp = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -72566,7 +80358,7 @@ final _objc_msgSend_exgdqb = objc.msgSendPointer int)>(); late final _sel_stringByFoldingWithOptions_locale_ = objc.registerName("stringByFoldingWithOptions:locale:"); -final _objc_msgSend_146986e = objc.msgSendPointer +final _objc_msgSend_11cbyu0 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -72583,7 +80375,7 @@ final _objc_msgSend_146986e = objc.msgSendPointer late final _sel_stringByReplacingOccurrencesOfString_withString_options_range_ = objc.registerName( "stringByReplacingOccurrencesOfString:withString:options:range:"); -final _objc_msgSend_1wrs2o6 = objc.msgSendPointer +final _objc_msgSend_2u4jm6 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -72605,7 +80397,7 @@ late final _sel_stringByReplacingOccurrencesOfString_withString_ = objc.registerName("stringByReplacingOccurrencesOfString:withString:"); late final _sel_stringByReplacingCharactersInRange_withString_ = objc.registerName("stringByReplacingCharactersInRange:withString:"); -final _objc_msgSend_197wcu5 = objc.msgSendPointer +final _objc_msgSend_bstjp9 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -72625,7 +80417,7 @@ late final _sel_stringByApplyingTransform_reverse_ = objc.registerName("stringByApplyingTransform:reverse:"); late final _sel_writeToURL_atomically_encoding_error_ = objc.registerName("writeToURL:atomically:encoding:error:"); -final _objc_msgSend_1140663 = objc.msgSendPointer +final _objc_msgSend_dv3z6r = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Bool Function( @@ -72648,7 +80440,7 @@ late final _sel_writeToFile_atomically_encoding_error_ = late final _sel_hash = objc.registerName("hash"); late final _sel_initWithCharactersNoCopy_length_freeWhenDone_ = objc.registerName("initWithCharactersNoCopy:length:freeWhenDone:"); -final _objc_msgSend_zsd8q9 = objc.msgSendPointer +final _objc_msgSend_lh0jh5 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -72709,6 +80501,44 @@ ffi.NativeCallable< ffi.Pointer, NSUInteger)>.listener( _ObjCBlock_ffiVoid_unichar_NSUInteger_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_unichar_NSUInteger_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + int arg1) { + try { + (objc.getBlockClosure(block) as void Function(ffi.Pointer, int))( + arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer, NSUInteger)> + _ObjCBlock_ffiVoid_unichar_NSUInteger_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSUInteger)>.isolateLocal( + _ObjCBlock_ffiVoid_unichar_NSUInteger_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer, NSUInteger)> + _ObjCBlock_ffiVoid_unichar_NSUInteger_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSUInteger)>.listener( + _ObjCBlock_ffiVoid_unichar_NSUInteger_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, ffi.UnsignedLong)>`. abstract final class ObjCBlock_ffiVoid_unichar_NSUInteger { @@ -72773,6 +80603,36 @@ abstract final class ObjCBlock_ffiVoid_unichar_NSUInteger { ffi.Void Function(ffi.Pointer, ffi.UnsignedLong)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc + .ObjCBlock, ffi.UnsignedLong)> + blocking(void Function(ffi.Pointer, DartNSUInteger) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_unichar_NSUInteger_blockingCallable.nativeFunction + .cast(), + (ffi.Pointer arg0, int arg1) => fn(arg0, arg1)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_unichar_NSUInteger_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, int arg1) => fn(arg0, arg1)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_vhbh5h, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, ffi.UnsignedLong)>(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, ffi.UnsignedLong)>`. @@ -72791,7 +80651,7 @@ extension ObjCBlock_ffiVoid_unichar_NSUInteger_CallExtension on objc late final _sel_initWithCharactersNoCopy_length_deallocator_ = objc.registerName("initWithCharactersNoCopy:length:deallocator:"); -final _objc_msgSend_1pr13r6 = objc.msgSendPointer +final _objc_msgSend_talwei = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -72809,7 +80669,7 @@ final _objc_msgSend_1pr13r6 = objc.msgSendPointer ffi.Pointer)>(); late final _sel_initWithCharacters_length_ = objc.registerName("initWithCharacters:length:"); -final _objc_msgSend_13z9dkp = objc.msgSendPointer +final _objc_msgSend_9x4k8x = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -72824,7 +80684,7 @@ final _objc_msgSend_13z9dkp = objc.msgSendPointer ffi.Pointer, int)>(); late final _sel_initWithUTF8String_ = objc.registerName("initWithUTF8String:"); -final _objc_msgSend_rqwdif = objc.msgSendPointer +final _objc_msgSend_56zxyn = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, @@ -72837,7 +80697,7 @@ late final _sel_initWithFormat_locale_ = objc.registerName("initWithFormat:locale:"); late final _sel_initWithValidatedFormat_validFormatSpecifiers_error_ = objc.registerName("initWithValidatedFormat:validFormatSpecifiers:error:"); -final _objc_msgSend_bo6ep4 = objc.msgSendPointer +final _objc_msgSend_1pnyuds = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -72856,7 +80716,7 @@ final _objc_msgSend_bo6ep4 = objc.msgSendPointer late final _sel_initWithValidatedFormat_validFormatSpecifiers_locale_error_ = objc.registerName( "initWithValidatedFormat:validFormatSpecifiers:locale:error:"); -final _objc_msgSend_2izev6 = objc.msgSendPointer +final _objc_msgSend_1k0ezzm = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -72878,7 +80738,7 @@ late final _sel_initWithData_encoding_ = objc.registerName("initWithData:encoding:"); late final _sel_initWithBytes_length_encoding_ = objc.registerName("initWithBytes:length:encoding:"); -final _objc_msgSend_i38ton = objc.msgSendPointer +final _objc_msgSend_9b3h4v = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -72892,7 +80752,7 @@ final _objc_msgSend_i38ton = objc.msgSendPointer ffi.Pointer, ffi.Pointer, int, int)>(); late final _sel_initWithBytesNoCopy_length_encoding_freeWhenDone_ = objc.registerName("initWithBytesNoCopy:length:encoding:freeWhenDone:"); -final _objc_msgSend_o2ktnn = objc.msgSendPointer +final _objc_msgSend_k4j8m3 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -72955,6 +80815,44 @@ ffi.NativeCallable< ffi.Pointer, NSUInteger)>.listener( _ObjCBlock_ffiVoid_ffiVoid_NSUInteger_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_ffiVoid_NSUInteger_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + int arg1) { + try { + (objc.getBlockClosure(block) as void Function(ffi.Pointer, int))( + arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer, NSUInteger)> + _ObjCBlock_ffiVoid_ffiVoid_NSUInteger_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSUInteger)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_NSUInteger_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer, NSUInteger)> + _ObjCBlock_ffiVoid_ffiVoid_NSUInteger_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + NSUInteger)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_NSUInteger_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock, ffi.UnsignedLong)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid_NSUInteger { @@ -73020,6 +80918,36 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid_NSUInteger { ffi.Void Function(ffi.Pointer, ffi.UnsignedLong)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc + .ObjCBlock, ffi.UnsignedLong)> + blocking(void Function(ffi.Pointer, DartNSUInteger) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSUInteger_blockingCallable.nativeFunction + .cast(), + (ffi.Pointer arg0, int arg1) => fn(arg0, arg1)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_NSUInteger_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, int arg1) => fn(arg0, arg1)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_zuf90e, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock< + ffi.Void Function(ffi.Pointer, ffi.UnsignedLong)>(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock, ffi.UnsignedLong)>`. @@ -73038,7 +80966,7 @@ extension ObjCBlock_ffiVoid_ffiVoid_NSUInteger_CallExtension on objc late final _sel_initWithBytesNoCopy_length_encoding_deallocator_ = objc.registerName("initWithBytesNoCopy:length:encoding:deallocator:"); -final _objc_msgSend_1nnfqvg = objc.msgSendPointer +final _objc_msgSend_1lbgrac = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -73071,7 +80999,7 @@ late final _sel_localizedStringWithValidatedFormat_validFormatSpecifiers_error_ "localizedStringWithValidatedFormat:validFormatSpecifiers:error:"); late final _sel_initWithCString_encoding_ = objc.registerName("initWithCString:encoding:"); -final _objc_msgSend_a15xhc = objc.msgSendPointer +final _objc_msgSend_erqryg = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -73086,7 +81014,7 @@ late final _sel_stringWithCString_encoding_ = objc.registerName("stringWithCString:encoding:"); late final _sel_initWithContentsOfURL_encoding_error_ = objc.registerName("initWithContentsOfURL:encoding:error:"); -final _objc_msgSend_94cet5 = objc.msgSendPointer +final _objc_msgSend_1nomli1 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -73110,7 +81038,7 @@ late final _sel_stringWithContentsOfFile_encoding_error_ = objc.registerName("stringWithContentsOfFile:encoding:error:"); late final _sel_initWithContentsOfURL_usedEncoding_error_ = objc.registerName("initWithContentsOfURL:usedEncoding:error:"); -final _objc_msgSend_1gxo8gv = objc.msgSendPointer +final _objc_msgSend_1alewu7 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -73138,21 +81066,21 @@ extension NSStringExtensionMethods on objc.NSString { /// substringFromIndex: objc.NSString substringFromIndex_(DartNSUInteger from) { final _ret = - _objc_msgSend_1qrcblu(this.ref.pointer, _sel_substringFromIndex_, from); + _objc_msgSend_14hpxwa(this.ref.pointer, _sel_substringFromIndex_, from); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// substringToIndex: objc.NSString substringToIndex_(DartNSUInteger to) { final _ret = - _objc_msgSend_1qrcblu(this.ref.pointer, _sel_substringToIndex_, to); + _objc_msgSend_14hpxwa(this.ref.pointer, _sel_substringToIndex_, to); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// substringWithRange: objc.NSString substringWithRange_(NSRange range) { - final _ret = - _objc_msgSend_83z673(this.ref.pointer, _sel_substringWithRange_, range); + final _ret = _objc_msgSend_1k1o1s7( + this.ref.pointer, _sel_substringWithRange_, range); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -73164,7 +81092,7 @@ extension NSStringExtensionMethods on objc.NSString { /// compare: objc.NSComparisonResult compare_(objc.NSString string) { - final _ret = _objc_msgSend_1wpduvy( + final _ret = _objc_msgSend_1ym6zyw( this.ref.pointer, _sel_compare_, string.ref.pointer); return objc.NSComparisonResult.fromValue(_ret); } @@ -73172,7 +81100,7 @@ extension NSStringExtensionMethods on objc.NSString { /// compare:options: objc.NSComparisonResult compare_options_( objc.NSString string, objc.NSStringCompareOptions mask) { - final _ret = _objc_msgSend_16ydezh(this.ref.pointer, _sel_compare_options_, + final _ret = _objc_msgSend_pg1fnv(this.ref.pointer, _sel_compare_options_, string.ref.pointer, mask.value); return objc.NSComparisonResult.fromValue(_ret); } @@ -73180,7 +81108,7 @@ extension NSStringExtensionMethods on objc.NSString { /// compare:options:range: objc.NSComparisonResult compare_options_range_(objc.NSString string, objc.NSStringCompareOptions mask, NSRange rangeOfReceiverToCompare) { - final _ret = _objc_msgSend_eeuxub( + final _ret = _objc_msgSend_xrqic1( this.ref.pointer, _sel_compare_options_range_, string.ref.pointer, @@ -73195,7 +81123,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSStringCompareOptions mask, NSRange rangeOfReceiverToCompare, objc.ObjCObjectBase? locale) { - final _ret = _objc_msgSend_i4hdht( + final _ret = _objc_msgSend_1895u4n( this.ref.pointer, _sel_compare_options_range_locale_, string.ref.pointer, @@ -73207,14 +81135,14 @@ extension NSStringExtensionMethods on objc.NSString { /// caseInsensitiveCompare: objc.NSComparisonResult caseInsensitiveCompare_(objc.NSString string) { - final _ret = _objc_msgSend_1wpduvy( + final _ret = _objc_msgSend_1ym6zyw( this.ref.pointer, _sel_caseInsensitiveCompare_, string.ref.pointer); return objc.NSComparisonResult.fromValue(_ret); } /// localizedCompare: objc.NSComparisonResult localizedCompare_(objc.NSString string) { - final _ret = _objc_msgSend_1wpduvy( + final _ret = _objc_msgSend_1ym6zyw( this.ref.pointer, _sel_localizedCompare_, string.ref.pointer); return objc.NSComparisonResult.fromValue(_ret); } @@ -73222,59 +81150,59 @@ extension NSStringExtensionMethods on objc.NSString { /// localizedCaseInsensitiveCompare: objc.NSComparisonResult localizedCaseInsensitiveCompare_( objc.NSString string) { - final _ret = _objc_msgSend_1wpduvy(this.ref.pointer, + final _ret = _objc_msgSend_1ym6zyw(this.ref.pointer, _sel_localizedCaseInsensitiveCompare_, string.ref.pointer); return objc.NSComparisonResult.fromValue(_ret); } /// localizedStandardCompare: objc.NSComparisonResult localizedStandardCompare_(objc.NSString string) { - final _ret = _objc_msgSend_1wpduvy( + final _ret = _objc_msgSend_1ym6zyw( this.ref.pointer, _sel_localizedStandardCompare_, string.ref.pointer); return objc.NSComparisonResult.fromValue(_ret); } /// isEqualToString: bool isEqualToString_(objc.NSString aString) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( this.ref.pointer, _sel_isEqualToString_, aString.ref.pointer); } /// hasPrefix: bool hasPrefix_(objc.NSString str) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( this.ref.pointer, _sel_hasPrefix_, str.ref.pointer); } /// hasSuffix: bool hasSuffix_(objc.NSString str) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( this.ref.pointer, _sel_hasSuffix_, str.ref.pointer); } /// commonPrefixWithString:options: objc.NSString commonPrefixWithString_options_( objc.NSString str, objc.NSStringCompareOptions mask) { - final _ret = _objc_msgSend_fcs5vo(this.ref.pointer, + final _ret = _objc_msgSend_diypgk(this.ref.pointer, _sel_commonPrefixWithString_options_, str.ref.pointer, mask.value); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// containsString: bool containsString_(objc.NSString str) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( this.ref.pointer, _sel_containsString_, str.ref.pointer); } /// localizedCaseInsensitiveContainsString: bool localizedCaseInsensitiveContainsString_(objc.NSString str) { - return _objc_msgSend_69e0x1(this.ref.pointer, + return _objc_msgSend_19nvye5(this.ref.pointer, _sel_localizedCaseInsensitiveContainsString_, str.ref.pointer); } /// localizedStandardContainsString: bool localizedStandardContainsString_(objc.NSString str) { - return _objc_msgSend_69e0x1(this.ref.pointer, + return _objc_msgSend_19nvye5(this.ref.pointer, _sel_localizedStandardContainsString_, str.ref.pointer); } @@ -73282,9 +81210,9 @@ extension NSStringExtensionMethods on objc.NSString { NSRange localizedStandardRangeOfString_(objc.NSString str) { final _ptr = pkg_ffi.calloc(); objc.useMsgSendVariants - ? _objc_msgSend_x4muu7Stret(_ptr, this.ref.pointer, + ? _objc_msgSend_182fzonStret(_ptr, this.ref.pointer, _sel_localizedStandardRangeOfString_, str.ref.pointer) - : _ptr.ref = _objc_msgSend_x4muu7(this.ref.pointer, + : _ptr.ref = _objc_msgSend_182fzon(this.ref.pointer, _sel_localizedStandardRangeOfString_, str.ref.pointer); final _finalizable = _ptr.cast().asTypedList( ffi.sizeOf(), @@ -73296,9 +81224,9 @@ extension NSStringExtensionMethods on objc.NSString { NSRange rangeOfString_(objc.NSString searchString) { final _ptr = pkg_ffi.calloc(); objc.useMsgSendVariants - ? _objc_msgSend_x4muu7Stret(_ptr, this.ref.pointer, _sel_rangeOfString_, - searchString.ref.pointer) - : _ptr.ref = _objc_msgSend_x4muu7( + ? _objc_msgSend_182fzonStret(_ptr, this.ref.pointer, + _sel_rangeOfString_, searchString.ref.pointer) + : _ptr.ref = _objc_msgSend_182fzon( this.ref.pointer, _sel_rangeOfString_, searchString.ref.pointer); final _finalizable = _ptr.cast().asTypedList( ffi.sizeOf(), @@ -73311,9 +81239,9 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSString searchString, objc.NSStringCompareOptions mask) { final _ptr = pkg_ffi.calloc(); objc.useMsgSendVariants - ? _objc_msgSend_1kwndnwStret(_ptr, this.ref.pointer, + ? _objc_msgSend_102xxo4Stret(_ptr, this.ref.pointer, _sel_rangeOfString_options_, searchString.ref.pointer, mask.value) - : _ptr.ref = _objc_msgSend_1kwndnw(this.ref.pointer, + : _ptr.ref = _objc_msgSend_102xxo4(this.ref.pointer, _sel_rangeOfString_options_, searchString.ref.pointer, mask.value); final _finalizable = _ptr.cast().asTypedList( ffi.sizeOf(), @@ -73326,14 +81254,14 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSStringCompareOptions mask, NSRange rangeOfReceiverToSearch) { final _ptr = pkg_ffi.calloc(); objc.useMsgSendVariants - ? _objc_msgSend_ackzikStret( + ? _objc_msgSend_1nmlvqcStret( _ptr, this.ref.pointer, _sel_rangeOfString_options_range_, searchString.ref.pointer, mask.value, rangeOfReceiverToSearch) - : _ptr.ref = _objc_msgSend_ackzik( + : _ptr.ref = _objc_msgSend_1nmlvqc( this.ref.pointer, _sel_rangeOfString_options_range_, searchString.ref.pointer, @@ -73353,7 +81281,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSLocale? locale) { final _ptr = pkg_ffi.calloc(); objc.useMsgSendVariants - ? _objc_msgSend_198mga8Stret( + ? _objc_msgSend_gg0462Stret( _ptr, this.ref.pointer, _sel_rangeOfString_options_range_locale_, @@ -73361,7 +81289,7 @@ extension NSStringExtensionMethods on objc.NSString { mask.value, rangeOfReceiverToSearch, locale?.ref.pointer ?? ffi.nullptr) - : _ptr.ref = _objc_msgSend_198mga8( + : _ptr.ref = _objc_msgSend_gg0462( this.ref.pointer, _sel_rangeOfString_options_range_locale_, searchString.ref.pointer, @@ -73378,9 +81306,9 @@ extension NSStringExtensionMethods on objc.NSString { NSRange rangeOfCharacterFromSet_(objc.NSCharacterSet searchSet) { final _ptr = pkg_ffi.calloc(); objc.useMsgSendVariants - ? _objc_msgSend_x4muu7Stret(_ptr, this.ref.pointer, + ? _objc_msgSend_182fzonStret(_ptr, this.ref.pointer, _sel_rangeOfCharacterFromSet_, searchSet.ref.pointer) - : _ptr.ref = _objc_msgSend_x4muu7(this.ref.pointer, + : _ptr.ref = _objc_msgSend_182fzon(this.ref.pointer, _sel_rangeOfCharacterFromSet_, searchSet.ref.pointer); final _finalizable = _ptr.cast().asTypedList( ffi.sizeOf(), @@ -73393,13 +81321,13 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSCharacterSet searchSet, objc.NSStringCompareOptions mask) { final _ptr = pkg_ffi.calloc(); objc.useMsgSendVariants - ? _objc_msgSend_1kwndnwStret( + ? _objc_msgSend_102xxo4Stret( _ptr, this.ref.pointer, _sel_rangeOfCharacterFromSet_options_, searchSet.ref.pointer, mask.value) - : _ptr.ref = _objc_msgSend_1kwndnw( + : _ptr.ref = _objc_msgSend_102xxo4( this.ref.pointer, _sel_rangeOfCharacterFromSet_options_, searchSet.ref.pointer, @@ -73415,14 +81343,14 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSStringCompareOptions mask, NSRange rangeOfReceiverToSearch) { final _ptr = pkg_ffi.calloc(); objc.useMsgSendVariants - ? _objc_msgSend_ackzikStret( + ? _objc_msgSend_1nmlvqcStret( _ptr, this.ref.pointer, _sel_rangeOfCharacterFromSet_options_range_, searchSet.ref.pointer, mask.value, rangeOfReceiverToSearch) - : _ptr.ref = _objc_msgSend_ackzik( + : _ptr.ref = _objc_msgSend_1nmlvqc( this.ref.pointer, _sel_rangeOfCharacterFromSet_options_range_, searchSet.ref.pointer, @@ -73464,14 +81392,14 @@ extension NSStringExtensionMethods on objc.NSString { /// stringByAppendingString: objc.NSString stringByAppendingString_(objc.NSString aString) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_stringByAppendingString_, aString.ref.pointer); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// stringByAppendingFormat: objc.NSString stringByAppendingFormat_(objc.NSString format) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_stringByAppendingFormat_, format.ref.pointer); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -73512,61 +81440,61 @@ extension NSStringExtensionMethods on objc.NSString { /// uppercaseString objc.NSString get uppercaseString { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_uppercaseString); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_uppercaseString); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// lowercaseString objc.NSString get lowercaseString { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_lowercaseString); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_lowercaseString); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// capitalizedString objc.NSString get capitalizedString { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_capitalizedString); + _objc_msgSend_151sglz(this.ref.pointer, _sel_capitalizedString); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// localizedUppercaseString objc.NSString get localizedUppercaseString { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_localizedUppercaseString); + _objc_msgSend_151sglz(this.ref.pointer, _sel_localizedUppercaseString); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// localizedLowercaseString objc.NSString get localizedLowercaseString { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_localizedLowercaseString); + _objc_msgSend_151sglz(this.ref.pointer, _sel_localizedLowercaseString); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// localizedCapitalizedString objc.NSString get localizedCapitalizedString { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_localizedCapitalizedString); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// uppercaseStringWithLocale: objc.NSString uppercaseStringWithLocale_(objc.NSLocale? locale) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_uppercaseStringWithLocale_, locale?.ref.pointer ?? ffi.nullptr); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// lowercaseStringWithLocale: objc.NSString lowercaseStringWithLocale_(objc.NSLocale? locale) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_lowercaseStringWithLocale_, locale?.ref.pointer ?? ffi.nullptr); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// capitalizedStringWithLocale: objc.NSString capitalizedStringWithLocale_(objc.NSLocale? locale) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_capitalizedStringWithLocale_, locale?.ref.pointer ?? ffi.nullptr); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -73671,7 +81599,7 @@ extension NSStringExtensionMethods on objc.NSString { /// dataUsingEncoding:allowLossyConversion: objc.NSData? dataUsingEncoding_allowLossyConversion_( DartNSUInteger encoding, bool lossy) { - final _ret = _objc_msgSend_rubz6a(this.ref.pointer, + final _ret = _objc_msgSend_hiwitm(this.ref.pointer, _sel_dataUsingEncoding_allowLossyConversion_, encoding, lossy); return _ret.address == 0 ? null @@ -73680,7 +81608,7 @@ extension NSStringExtensionMethods on objc.NSString { /// dataUsingEncoding: objc.NSData? dataUsingEncoding_(DartNSUInteger encoding) { - final _ret = _objc_msgSend_1qrcblu( + final _ret = _objc_msgSend_14hpxwa( this.ref.pointer, _sel_dataUsingEncoding_, encoding); return _ret.address == 0 ? null @@ -73747,7 +81675,7 @@ extension NSStringExtensionMethods on objc.NSString { /// localizedNameOfStringEncoding: static objc.NSString localizedNameOfStringEncoding_(DartNSUInteger encoding) { - final _ret = _objc_msgSend_1qrcblu( + final _ret = _objc_msgSend_14hpxwa( _class_NSString, _sel_localizedNameOfStringEncoding_, encoding); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -73759,35 +81687,35 @@ extension NSStringExtensionMethods on objc.NSString { /// decomposedStringWithCanonicalMapping objc.NSString get decomposedStringWithCanonicalMapping { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_decomposedStringWithCanonicalMapping); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// precomposedStringWithCanonicalMapping objc.NSString get precomposedStringWithCanonicalMapping { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_precomposedStringWithCanonicalMapping); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// decomposedStringWithCompatibilityMapping objc.NSString get decomposedStringWithCompatibilityMapping { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_decomposedStringWithCompatibilityMapping); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// precomposedStringWithCompatibilityMapping objc.NSString get precomposedStringWithCompatibilityMapping { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_precomposedStringWithCompatibilityMapping); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// componentsSeparatedByString: objc.NSArray componentsSeparatedByString_(objc.NSString separator) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_componentsSeparatedByString_, separator.ref.pointer); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } @@ -73795,14 +81723,14 @@ extension NSStringExtensionMethods on objc.NSString { /// componentsSeparatedByCharactersInSet: objc.NSArray componentsSeparatedByCharactersInSet_( objc.NSCharacterSet separator) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_componentsSeparatedByCharactersInSet_, separator.ref.pointer); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } /// stringByTrimmingCharactersInSet: objc.NSString stringByTrimmingCharactersInSet_(objc.NSCharacterSet set) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_stringByTrimmingCharactersInSet_, set.ref.pointer); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -73812,7 +81740,7 @@ extension NSStringExtensionMethods on objc.NSString { DartNSUInteger newLength, objc.NSString padString, DartNSUInteger padIndex) { - final _ret = _objc_msgSend_exgdqb( + final _ret = _objc_msgSend_1tfztp( this.ref.pointer, _sel_stringByPaddingToLength_withString_startingAtIndex_, newLength, @@ -73824,7 +81752,7 @@ extension NSStringExtensionMethods on objc.NSString { /// stringByFoldingWithOptions:locale: objc.NSString stringByFoldingWithOptions_locale_( objc.NSStringCompareOptions options, objc.NSLocale? locale) { - final _ret = _objc_msgSend_146986e( + final _ret = _objc_msgSend_11cbyu0( this.ref.pointer, _sel_stringByFoldingWithOptions_locale_, options.value, @@ -73838,7 +81766,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSString replacement, objc.NSStringCompareOptions options, NSRange searchRange) { - final _ret = _objc_msgSend_1wrs2o6( + final _ret = _objc_msgSend_2u4jm6( this.ref.pointer, _sel_stringByReplacingOccurrencesOfString_withString_options_range_, target.ref.pointer, @@ -73851,7 +81779,7 @@ extension NSStringExtensionMethods on objc.NSString { /// stringByReplacingOccurrencesOfString:withString: objc.NSString stringByReplacingOccurrencesOfString_withString_( objc.NSString target, objc.NSString replacement) { - final _ret = _objc_msgSend_rsfdlh( + final _ret = _objc_msgSend_15qeuct( this.ref.pointer, _sel_stringByReplacingOccurrencesOfString_withString_, target.ref.pointer, @@ -73862,7 +81790,7 @@ extension NSStringExtensionMethods on objc.NSString { /// stringByReplacingCharactersInRange:withString: objc.NSString stringByReplacingCharactersInRange_withString_( NSRange range, objc.NSString replacement) { - final _ret = _objc_msgSend_197wcu5( + final _ret = _objc_msgSend_bstjp9( this.ref.pointer, _sel_stringByReplacingCharactersInRange_withString_, range, @@ -73873,7 +81801,7 @@ extension NSStringExtensionMethods on objc.NSString { /// stringByApplyingTransform:reverse: objc.NSString? stringByApplyingTransform_reverse_( DartNSStringTransform transform, bool reverse) { - final _ret = _objc_msgSend_1bdmr5f( + final _ret = _objc_msgSend_17amj0z( this.ref.pointer, _sel_stringByApplyingTransform_reverse_, transform.ref.pointer, @@ -73889,7 +81817,7 @@ extension NSStringExtensionMethods on objc.NSString { bool useAuxiliaryFile, DartNSUInteger enc, ffi.Pointer> error) { - return _objc_msgSend_1140663( + return _objc_msgSend_dv3z6r( this.ref.pointer, _sel_writeToURL_atomically_encoding_error_, url.ref.pointer, @@ -73904,7 +81832,7 @@ extension NSStringExtensionMethods on objc.NSString { bool useAuxiliaryFile, DartNSUInteger enc, ffi.Pointer> error) { - return _objc_msgSend_1140663( + return _objc_msgSend_dv3z6r( this.ref.pointer, _sel_writeToFile_atomically_encoding_error_, path.ref.pointer, @@ -73915,7 +81843,7 @@ extension NSStringExtensionMethods on objc.NSString { /// description objc.NSString get description { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_description); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_description); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -73927,7 +81855,7 @@ extension NSStringExtensionMethods on objc.NSString { /// initWithCharactersNoCopy:length:freeWhenDone: objc.NSString initWithCharactersNoCopy_length_freeWhenDone_( ffi.Pointer characters, DartNSUInteger length, bool freeBuffer) { - final _ret = _objc_msgSend_zsd8q9( + final _ret = _objc_msgSend_lh0jh5( this.ref.retainAndReturnPointer(), _sel_initWithCharactersNoCopy_length_freeWhenDone_, characters, @@ -73942,7 +81870,7 @@ extension NSStringExtensionMethods on objc.NSString { DartNSUInteger len, objc.ObjCBlock, ffi.UnsignedLong)>? deallocator) { - final _ret = _objc_msgSend_1pr13r6( + final _ret = _objc_msgSend_talwei( this.ref.retainAndReturnPointer(), _sel_initWithCharactersNoCopy_length_deallocator_, chars, @@ -73954,7 +81882,7 @@ extension NSStringExtensionMethods on objc.NSString { /// initWithCharacters:length: objc.NSString initWithCharacters_length_( ffi.Pointer characters, DartNSUInteger length) { - final _ret = _objc_msgSend_13z9dkp(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_9x4k8x(this.ref.retainAndReturnPointer(), _sel_initWithCharacters_length_, characters, length); return objc.NSString.castFromPointer(_ret, retain: false, release: true); } @@ -73962,7 +81890,7 @@ extension NSStringExtensionMethods on objc.NSString { /// initWithUTF8String: objc.NSString? initWithUTF8String_( ffi.Pointer nullTerminatedCString) { - final _ret = _objc_msgSend_rqwdif(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_56zxyn(this.ref.retainAndReturnPointer(), _sel_initWithUTF8String_, nullTerminatedCString); return _ret.address == 0 ? null @@ -73971,14 +81899,14 @@ extension NSStringExtensionMethods on objc.NSString { /// initWithString: objc.NSString initWithString_(objc.NSString aString) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithString_, aString.ref.pointer); return objc.NSString.castFromPointer(_ret, retain: false, release: true); } /// initWithFormat: objc.NSString initWithFormat_(objc.NSString format) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithFormat_, format.ref.pointer); return objc.NSString.castFromPointer(_ret, retain: false, release: true); } @@ -73986,7 +81914,7 @@ extension NSStringExtensionMethods on objc.NSString { /// initWithFormat:locale: objc.NSString initWithFormat_locale_( objc.NSString format, objc.ObjCObjectBase? locale) { - final _ret = _objc_msgSend_rsfdlh( + final _ret = _objc_msgSend_15qeuct( this.ref.retainAndReturnPointer(), _sel_initWithFormat_locale_, format.ref.pointer, @@ -73999,7 +81927,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSString format, objc.NSString validFormatSpecifiers, ffi.Pointer> error) { - final _ret = _objc_msgSend_bo6ep4( + final _ret = _objc_msgSend_1pnyuds( this.ref.retainAndReturnPointer(), _sel_initWithValidatedFormat_validFormatSpecifiers_error_, format.ref.pointer, @@ -74016,7 +81944,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSString validFormatSpecifiers, objc.ObjCObjectBase? locale, ffi.Pointer> error) { - final _ret = _objc_msgSend_2izev6( + final _ret = _objc_msgSend_1k0ezzm( this.ref.retainAndReturnPointer(), _sel_initWithValidatedFormat_validFormatSpecifiers_locale_error_, format.ref.pointer, @@ -74031,7 +81959,7 @@ extension NSStringExtensionMethods on objc.NSString { /// initWithData:encoding: objc.NSString? initWithData_encoding_( objc.NSData data, DartNSUInteger encoding) { - final _ret = _objc_msgSend_dcd68g(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1k4kd9s(this.ref.retainAndReturnPointer(), _sel_initWithData_encoding_, data.ref.pointer, encoding); return _ret.address == 0 ? null @@ -74041,7 +81969,7 @@ extension NSStringExtensionMethods on objc.NSString { /// initWithBytes:length:encoding: objc.NSString? initWithBytes_length_encoding_(ffi.Pointer bytes, DartNSUInteger len, DartNSUInteger encoding) { - final _ret = _objc_msgSend_i38ton(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_9b3h4v(this.ref.retainAndReturnPointer(), _sel_initWithBytes_length_encoding_, bytes, len, encoding); return _ret.address == 0 ? null @@ -74054,7 +81982,7 @@ extension NSStringExtensionMethods on objc.NSString { DartNSUInteger len, DartNSUInteger encoding, bool freeBuffer) { - final _ret = _objc_msgSend_o2ktnn( + final _ret = _objc_msgSend_k4j8m3( this.ref.retainAndReturnPointer(), _sel_initWithBytesNoCopy_length_encoding_freeWhenDone_, bytes, @@ -74074,7 +82002,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.ObjCBlock< ffi.Void Function(ffi.Pointer, ffi.UnsignedLong)>? deallocator) { - final _ret = _objc_msgSend_1nnfqvg( + final _ret = _objc_msgSend_1lbgrac( this.ref.retainAndReturnPointer(), _sel_initWithBytesNoCopy_length_encoding_deallocator_, bytes, @@ -74088,13 +82016,13 @@ extension NSStringExtensionMethods on objc.NSString { /// string static objc.NSString string() { - final _ret = _objc_msgSend_1x359cv(_class_NSString, _sel_string); + final _ret = _objc_msgSend_151sglz(_class_NSString, _sel_string); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// stringWithString: static objc.NSString stringWithString_(objc.NSString string) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSString, _sel_stringWithString_, string.ref.pointer); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -74102,7 +82030,7 @@ extension NSStringExtensionMethods on objc.NSString { /// stringWithCharacters:length: static objc.NSString stringWithCharacters_length_( ffi.Pointer characters, DartNSUInteger length) { - final _ret = _objc_msgSend_13z9dkp( + final _ret = _objc_msgSend_9x4k8x( _class_NSString, _sel_stringWithCharacters_length_, characters, length); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -74110,7 +82038,7 @@ extension NSStringExtensionMethods on objc.NSString { /// stringWithUTF8String: static objc.NSString? stringWithUTF8String_( ffi.Pointer nullTerminatedCString) { - final _ret = _objc_msgSend_rqwdif( + final _ret = _objc_msgSend_56zxyn( _class_NSString, _sel_stringWithUTF8String_, nullTerminatedCString); return _ret.address == 0 ? null @@ -74119,14 +82047,14 @@ extension NSStringExtensionMethods on objc.NSString { /// stringWithFormat: static objc.NSString stringWithFormat_(objc.NSString format) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSString, _sel_stringWithFormat_, format.ref.pointer); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } /// localizedStringWithFormat: static objc.NSString localizedStringWithFormat_(objc.NSString format) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSString, _sel_localizedStringWithFormat_, format.ref.pointer); return objc.NSString.castFromPointer(_ret, retain: true, release: true); } @@ -74136,7 +82064,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSString format, objc.NSString validFormatSpecifiers, ffi.Pointer> error) { - final _ret = _objc_msgSend_bo6ep4( + final _ret = _objc_msgSend_1pnyuds( _class_NSString, _sel_stringWithValidatedFormat_validFormatSpecifiers_error_, format.ref.pointer, @@ -74153,7 +82081,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSString format, objc.NSString validFormatSpecifiers, ffi.Pointer> error) { - final _ret = _objc_msgSend_bo6ep4( + final _ret = _objc_msgSend_1pnyuds( _class_NSString, _sel_localizedStringWithValidatedFormat_validFormatSpecifiers_error_, format.ref.pointer, @@ -74167,7 +82095,7 @@ extension NSStringExtensionMethods on objc.NSString { /// initWithCString:encoding: objc.NSString? initWithCString_encoding_( ffi.Pointer nullTerminatedCString, DartNSUInteger encoding) { - final _ret = _objc_msgSend_a15xhc(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_erqryg(this.ref.retainAndReturnPointer(), _sel_initWithCString_encoding_, nullTerminatedCString, encoding); return _ret.address == 0 ? null @@ -74177,7 +82105,7 @@ extension NSStringExtensionMethods on objc.NSString { /// stringWithCString:encoding: static objc.NSString? stringWithCString_encoding_( ffi.Pointer cString, DartNSUInteger enc) { - final _ret = _objc_msgSend_a15xhc( + final _ret = _objc_msgSend_erqryg( _class_NSString, _sel_stringWithCString_encoding_, cString, enc); return _ret.address == 0 ? null @@ -74187,7 +82115,7 @@ extension NSStringExtensionMethods on objc.NSString { /// initWithContentsOfURL:encoding:error: objc.NSString? initWithContentsOfURL_encoding_error_(objc.NSURL url, DartNSUInteger enc, ffi.Pointer> error) { - final _ret = _objc_msgSend_94cet5( + final _ret = _objc_msgSend_1nomli1( this.ref.retainAndReturnPointer(), _sel_initWithContentsOfURL_encoding_error_, url.ref.pointer, @@ -74201,7 +82129,7 @@ extension NSStringExtensionMethods on objc.NSString { /// initWithContentsOfFile:encoding:error: objc.NSString? initWithContentsOfFile_encoding_error_(objc.NSString path, DartNSUInteger enc, ffi.Pointer> error) { - final _ret = _objc_msgSend_94cet5( + final _ret = _objc_msgSend_1nomli1( this.ref.retainAndReturnPointer(), _sel_initWithContentsOfFile_encoding_error_, path.ref.pointer, @@ -74215,7 +82143,7 @@ extension NSStringExtensionMethods on objc.NSString { /// stringWithContentsOfURL:encoding:error: static objc.NSString? stringWithContentsOfURL_encoding_error_(objc.NSURL url, DartNSUInteger enc, ffi.Pointer> error) { - final _ret = _objc_msgSend_94cet5( + final _ret = _objc_msgSend_1nomli1( _class_NSString, _sel_stringWithContentsOfURL_encoding_error_, url.ref.pointer, @@ -74231,7 +82159,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSString path, DartNSUInteger enc, ffi.Pointer> error) { - final _ret = _objc_msgSend_94cet5( + final _ret = _objc_msgSend_1nomli1( _class_NSString, _sel_stringWithContentsOfFile_encoding_error_, path.ref.pointer, @@ -74247,7 +82175,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSURL url, ffi.Pointer enc, ffi.Pointer> error) { - final _ret = _objc_msgSend_1gxo8gv( + final _ret = _objc_msgSend_1alewu7( this.ref.retainAndReturnPointer(), _sel_initWithContentsOfURL_usedEncoding_error_, url.ref.pointer, @@ -74263,7 +82191,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSString path, ffi.Pointer enc, ffi.Pointer> error) { - final _ret = _objc_msgSend_1gxo8gv( + final _ret = _objc_msgSend_1alewu7( this.ref.retainAndReturnPointer(), _sel_initWithContentsOfFile_usedEncoding_error_, path.ref.pointer, @@ -74279,7 +82207,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSURL url, ffi.Pointer enc, ffi.Pointer> error) { - final _ret = _objc_msgSend_1gxo8gv( + final _ret = _objc_msgSend_1alewu7( _class_NSString, _sel_stringWithContentsOfURL_usedEncoding_error_, url.ref.pointer, @@ -74295,7 +82223,7 @@ extension NSStringExtensionMethods on objc.NSString { objc.NSString path, ffi.Pointer enc, ffi.Pointer> error) { - final _ret = _objc_msgSend_1gxo8gv( + final _ret = _objc_msgSend_1alewu7( _class_NSString, _sel_stringWithContentsOfFile_usedEncoding_error_, path.ref.pointer, @@ -74312,7 +82240,7 @@ typedef DartNSStringEncodingDetectionOptionsKey = objc.NSString; late final _sel_stringEncodingForData_encodingOptions_convertedString_usedLossyConversion_ = objc.registerName( "stringEncodingForData:encodingOptions:convertedString:usedLossyConversion:"); -final _objc_msgSend_pi68en = objc.msgSendPointer +final _objc_msgSend_1q2ox4r = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.UnsignedLong Function( @@ -74340,7 +82268,7 @@ extension NSStringEncodingDetection on objc.NSString { objc.NSDictionary? opts, ffi.Pointer> string, ffi.Pointer usedLossyConversion) { - return _objc_msgSend_pi68en( + return _objc_msgSend_1q2ox4r( _class_NSString, _sel_stringEncodingForData_encodingOptions_convertedString_usedLossyConversion_, data.ref.pointer, @@ -74595,7 +82523,7 @@ late final _sel_writableTypeIdentifiersForItemProvider = late final _sel_itemProviderVisibilityForRepresentationWithTypeIdentifier_ = objc.registerName( "itemProviderVisibilityForRepresentationWithTypeIdentifier:"); -final _objc_msgSend_96wwe1 = objc.msgSendPointer +final _objc_msgSend_16fy0up = objc.msgSendPointer .cast< ffi.NativeFunction< NSInteger Function( @@ -74760,6 +82688,50 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSData_NSError_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_NSData_NSError_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1) { + try { + (objc.getBlockClosure(block) as void Function(ffi.Pointer, + ffi.Pointer))(arg0, arg1); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSData_NSError_blockingCallable = ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSData_NSError_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSData_NSError_blockingListenerCallable = ffi + .NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSData_NSError_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSData_NSError { @@ -74832,13 +82804,63 @@ abstract final class ObjCBlock_ffiVoid_NSData_NSError { ? null : objc.NSError.castFromPointer(arg1, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_wjvic9(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_pfv6jd(raw); objc.objectRelease(raw.cast()); return objc.ObjCBlock( wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock + blocking(void Function(objc.NSData?, objc.NSError?) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSData_NSError_blockingCallable.nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1) => + fn( + arg0.address == 0 + ? null + : objc.NSData.castFromPointer(arg0, + retain: false, release: true), + arg1.address == 0 + ? null + : objc.NSError.castFromPointer(arg1, + retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSData_NSError_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1) => + fn( + arg0.address == 0 + ? null + : objc.NSData.castFromPointer(arg0, + retain: false, release: true), + arg1.address == 0 + ? null + : objc.NSError.castFromPointer(arg1, + retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_pfv6jd, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock( + wrapper, + retain: false, + release: true); + } } /// Call operator for `objc.ObjCBlock`. @@ -74995,7 +83017,7 @@ extension ObjCBlock_NSProgress_ffiVoid_NSString_ffiVoidNSDataNSError_CallExtensi extension NSItemProvider on objc.NSString { /// readableTypeIdentifiersForItemProvider static objc.NSArray getReadableTypeIdentifiersForItemProvider() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( _class_NSString, _sel_readableTypeIdentifiersForItemProvider); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } @@ -75005,7 +83027,7 @@ extension NSItemProvider on objc.NSString { objc.NSData data, objc.NSString typeIdentifier, ffi.Pointer> outError) { - final _ret = _objc_msgSend_bo6ep4( + final _ret = _objc_msgSend_1pnyuds( _class_NSString, _sel_objectWithItemProviderData_typeIdentifier_error_, data.ref.pointer, @@ -75018,7 +83040,7 @@ extension NSItemProvider on objc.NSString { /// writableTypeIdentifiersForItemProvider static objc.NSArray getWritableTypeIdentifiersForItemProvider() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( _class_NSString, _sel_writableTypeIdentifiersForItemProvider); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } @@ -75030,7 +83052,7 @@ extension NSItemProvider on objc.NSString { throw objc.UnimplementedOptionalMethodException( 'NSString', 'writableTypeIdentifiersForItemProvider'); } - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_writableTypeIdentifiersForItemProvider); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } @@ -75044,7 +83066,7 @@ extension NSItemProvider on objc.NSString { throw objc.UnimplementedOptionalMethodException('NSString', 'itemProviderVisibilityForRepresentationWithTypeIdentifier:'); } - final _ret = _objc_msgSend_96wwe1( + final _ret = _objc_msgSend_16fy0up( _class_NSString, _sel_itemProviderVisibilityForRepresentationWithTypeIdentifier_, typeIdentifier.ref.pointer); @@ -75060,7 +83082,7 @@ extension NSItemProvider on objc.NSString { throw objc.UnimplementedOptionalMethodException('NSString', 'itemProviderVisibilityForRepresentationWithTypeIdentifier:'); } - final _ret = _objc_msgSend_96wwe1( + final _ret = _objc_msgSend_16fy0up( this.ref.pointer, _sel_itemProviderVisibilityForRepresentationWithTypeIdentifier_, typeIdentifier.ref.pointer); @@ -75072,7 +83094,7 @@ extension NSItemProvider on objc.NSString { objc.NSString typeIdentifier, objc.ObjCBlock completionHandler) { - final _ret = _objc_msgSend_o4sqyk( + final _ret = _objc_msgSend_r0bo0s( this.ref.pointer, _sel_loadDataWithTypeIdentifier_forItemProviderCompletionHandler_, typeIdentifier.ref.pointer, @@ -75093,7 +83115,7 @@ late final _sel_appendFormat_ = objc.registerName("appendFormat:"); late final _sel_setString_ = objc.registerName("setString:"); late final _sel_replaceOccurrencesOfString_withString_options_range_ = objc.registerName("replaceOccurrencesOfString:withString:options:range:"); -final _objc_msgSend_19rhlmt = objc.msgSendPointer +final _objc_msgSend_1upeo1d = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.UnsignedLong Function( @@ -75113,7 +83135,7 @@ final _objc_msgSend_19rhlmt = objc.msgSendPointer objc.NSRange)>(); late final _sel_applyTransform_reverse_range_updatedRange_ = objc.registerName("applyTransform:reverse:range:updatedRange:"); -final _objc_msgSend_1wfeihn = objc.msgSendPointer +final _objc_msgSend_zy00wz = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Bool Function( @@ -75138,7 +83160,7 @@ late final _sel_stringWithCapacity_ = objc.registerName("stringWithCapacity:"); extension NSMutableStringExtensionMethods on objc.NSMutableString { /// insertString:atIndex: void insertString_atIndex_(objc.NSString aString, DartNSUInteger loc) { - _objc_msgSend_10i1axw( + _objc_msgSend_djsa9o( this.ref.pointer, _sel_insertString_atIndex_, aString.ref.pointer, loc); } @@ -75150,19 +83172,19 @@ extension NSMutableStringExtensionMethods on objc.NSMutableString { /// appendString: void appendString_(objc.NSString aString) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_appendString_, aString.ref.pointer); } /// appendFormat: void appendFormat_(objc.NSString format) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_appendFormat_, format.ref.pointer); } /// setString: void setString_(objc.NSString aString) { - _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_setString_, aString.ref.pointer); } @@ -75172,7 +83194,7 @@ extension NSMutableStringExtensionMethods on objc.NSMutableString { objc.NSString replacement, objc.NSStringCompareOptions options, NSRange searchRange) { - return _objc_msgSend_19rhlmt( + return _objc_msgSend_1upeo1d( this.ref.pointer, _sel_replaceOccurrencesOfString_withString_options_range_, target.ref.pointer, @@ -75187,7 +83209,7 @@ extension NSMutableStringExtensionMethods on objc.NSMutableString { bool reverse, NSRange range, NSRangePointer resultingRange) { - return _objc_msgSend_1wfeihn( + return _objc_msgSend_zy00wz( this.ref.pointer, _sel_applyTransform_reverse_range_updatedRange_, transform.ref.pointer, @@ -75198,7 +83220,7 @@ extension NSMutableStringExtensionMethods on objc.NSMutableString { /// initWithCapacity: objc.NSMutableString initWithCapacity_(DartNSUInteger capacity) { - final _ret = _objc_msgSend_1qrcblu( + final _ret = _objc_msgSend_14hpxwa( this.ref.retainAndReturnPointer(), _sel_initWithCapacity_, capacity); return objc.NSMutableString.castFromPointer(_ret, retain: false, release: true); @@ -75206,7 +83228,7 @@ extension NSMutableStringExtensionMethods on objc.NSMutableString { /// stringWithCapacity: static objc.NSMutableString stringWithCapacity_(DartNSUInteger capacity) { - final _ret = _objc_msgSend_1qrcblu( + final _ret = _objc_msgSend_14hpxwa( _class_NSMutableString, _sel_stringWithCapacity_, capacity); return objc.NSMutableString.castFromPointer(_ret, retain: true, release: true); @@ -75221,13 +83243,13 @@ late final _sel_propertyListFromStringsFileFormat = extension NSExtendedStringPropertyListParsing on objc.NSString { /// propertyList objc.ObjCObjectBase propertyList() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_propertyList); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_propertyList); return objc.ObjCObjectBase(_ret, retain: true, release: true); } /// propertyListFromStringsFileFormat objc.NSDictionary? propertyListFromStringsFileFormat() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_propertyListFromStringsFileFormat); return _ret.address == 0 ? null @@ -75286,7 +83308,7 @@ late final _sel_stringWithContentsOfURL_ = objc.registerName("stringWithContentsOfURL:"); late final _sel_initWithCStringNoCopy_length_freeWhenDone_ = objc.registerName("initWithCStringNoCopy:length:freeWhenDone:"); -final _objc_msgSend_fjj4b8 = objc.msgSendPointer +final _objc_msgSend_1ojrli4 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Pointer Function( @@ -75363,19 +83385,19 @@ extension NSStringDeprecated on objc.NSString { /// writeToFile:atomically: bool writeToFile_atomically_(objc.NSString path, bool useAuxiliaryFile) { - return _objc_msgSend_w8pbfh(this.ref.pointer, _sel_writeToFile_atomically_, + return _objc_msgSend_1iyq28l(this.ref.pointer, _sel_writeToFile_atomically_, path.ref.pointer, useAuxiliaryFile); } /// writeToURL:atomically: bool writeToURL_atomically_(objc.NSURL url, bool atomically) { - return _objc_msgSend_w8pbfh(this.ref.pointer, _sel_writeToURL_atomically_, + return _objc_msgSend_1iyq28l(this.ref.pointer, _sel_writeToURL_atomically_, url.ref.pointer, atomically); } /// initWithContentsOfFile: objc.ObjCObjectBase? initWithContentsOfFile_(objc.NSString path) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithContentsOfFile_, path.ref.pointer); return _ret.address == 0 ? null @@ -75384,7 +83406,7 @@ extension NSStringDeprecated on objc.NSString { /// initWithContentsOfURL: objc.ObjCObjectBase? initWithContentsOfURL_(objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_1sotr3r(this.ref.retainAndReturnPointer(), _sel_initWithContentsOfURL_, url.ref.pointer); return _ret.address == 0 ? null @@ -75393,7 +83415,7 @@ extension NSStringDeprecated on objc.NSString { /// stringWithContentsOfFile: static objc.ObjCObjectBase? stringWithContentsOfFile_(objc.NSString path) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSString, _sel_stringWithContentsOfFile_, path.ref.pointer); return _ret.address == 0 ? null @@ -75402,7 +83424,7 @@ extension NSStringDeprecated on objc.NSString { /// stringWithContentsOfURL: static objc.ObjCObjectBase? stringWithContentsOfURL_(objc.NSURL url) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSString, _sel_stringWithContentsOfURL_, url.ref.pointer); return _ret.address == 0 ? null @@ -75412,7 +83434,7 @@ extension NSStringDeprecated on objc.NSString { /// initWithCStringNoCopy:length:freeWhenDone: objc.ObjCObjectBase? initWithCStringNoCopy_length_freeWhenDone_( ffi.Pointer bytes, DartNSUInteger length, bool freeBuffer) { - final _ret = _objc_msgSend_fjj4b8( + final _ret = _objc_msgSend_1ojrli4( this.ref.retainAndReturnPointer(), _sel_initWithCStringNoCopy_length_freeWhenDone_, bytes, @@ -75426,7 +83448,7 @@ extension NSStringDeprecated on objc.NSString { /// initWithCString:length: objc.ObjCObjectBase? initWithCString_length_( ffi.Pointer bytes, DartNSUInteger length) { - final _ret = _objc_msgSend_a15xhc(this.ref.retainAndReturnPointer(), + final _ret = _objc_msgSend_erqryg(this.ref.retainAndReturnPointer(), _sel_initWithCString_length_, bytes, length); return _ret.address == 0 ? null @@ -75435,7 +83457,7 @@ extension NSStringDeprecated on objc.NSString { /// initWithCString: objc.ObjCObjectBase? initWithCString_(ffi.Pointer bytes) { - final _ret = _objc_msgSend_rqwdif( + final _ret = _objc_msgSend_56zxyn( this.ref.retainAndReturnPointer(), _sel_initWithCString_, bytes); return _ret.address == 0 ? null @@ -75445,7 +83467,7 @@ extension NSStringDeprecated on objc.NSString { /// stringWithCString:length: static objc.ObjCObjectBase? stringWithCString_length_( ffi.Pointer bytes, DartNSUInteger length) { - final _ret = _objc_msgSend_a15xhc( + final _ret = _objc_msgSend_erqryg( _class_NSString, _sel_stringWithCString_length_, bytes, length); return _ret.address == 0 ? null @@ -75455,7 +83477,7 @@ extension NSStringDeprecated on objc.NSString { /// stringWithCString: static objc.ObjCObjectBase? stringWithCString_(ffi.Pointer bytes) { final _ret = - _objc_msgSend_rqwdif(_class_NSString, _sel_stringWithCString_, bytes); + _objc_msgSend_56zxyn(_class_NSString, _sel_stringWithCString_, bytes); return _ret.address == 0 ? null : objc.ObjCObjectBase(_ret, retain: true, release: true); @@ -75485,7 +83507,7 @@ typedef NSURLBookmarkFileCreationOptions = NSUInteger; late final _class_NSURL = objc.getClass("NSURL"); late final _sel_getPromisedItemResourceValue_forKey_error_ = objc.registerName("getPromisedItemResourceValue:forKey:error:"); -final _objc_msgSend_7iv28v = objc.msgSendPointer +final _objc_msgSend_1j9bhml = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Bool Function( @@ -75534,7 +83556,7 @@ extension NSPromisedItems on objc.NSURL { ffi.Pointer> value, DartNSURLResourceKey key, ffi.Pointer> error) { - return _objc_msgSend_7iv28v( + return _objc_msgSend_1j9bhml( this.ref.pointer, _sel_getPromisedItemResourceValue_forKey_error_, value, @@ -75545,7 +83567,7 @@ extension NSPromisedItems on objc.NSURL { /// promisedItemResourceValuesForKeys:error: objc.NSDictionary? promisedItemResourceValuesForKeys_error_( objc.NSArray keys, ffi.Pointer> error) { - final _ret = _objc_msgSend_1705co6(this.ref.pointer, + final _ret = _objc_msgSend_1lhpu4m(this.ref.pointer, _sel_promisedItemResourceValuesForKeys_error_, keys.ref.pointer, error); return _ret.address == 0 ? null @@ -75564,7 +83586,7 @@ extension NSPromisedItems on objc.NSURL { extension NSItemProvider1 on objc.NSURL { /// readableTypeIdentifiersForItemProvider static objc.NSArray getReadableTypeIdentifiersForItemProvider() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( _class_NSURL, _sel_readableTypeIdentifiersForItemProvider); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } @@ -75574,7 +83596,7 @@ extension NSItemProvider1 on objc.NSURL { objc.NSData data, objc.NSString typeIdentifier, ffi.Pointer> outError) { - final _ret = _objc_msgSend_bo6ep4( + final _ret = _objc_msgSend_1pnyuds( _class_NSURL, _sel_objectWithItemProviderData_typeIdentifier_error_, data.ref.pointer, @@ -75587,7 +83609,7 @@ extension NSItemProvider1 on objc.NSURL { /// writableTypeIdentifiersForItemProvider static objc.NSArray getWritableTypeIdentifiersForItemProvider() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( _class_NSURL, _sel_writableTypeIdentifiersForItemProvider); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } @@ -75599,7 +83621,7 @@ extension NSItemProvider1 on objc.NSURL { throw objc.UnimplementedOptionalMethodException( 'NSURL', 'writableTypeIdentifiersForItemProvider'); } - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_writableTypeIdentifiersForItemProvider); return objc.NSArray.castFromPointer(_ret, retain: true, release: true); } @@ -75613,7 +83635,7 @@ extension NSItemProvider1 on objc.NSURL { throw objc.UnimplementedOptionalMethodException('NSURL', 'itemProviderVisibilityForRepresentationWithTypeIdentifier:'); } - final _ret = _objc_msgSend_96wwe1( + final _ret = _objc_msgSend_16fy0up( _class_NSURL, _sel_itemProviderVisibilityForRepresentationWithTypeIdentifier_, typeIdentifier.ref.pointer); @@ -75629,7 +83651,7 @@ extension NSItemProvider1 on objc.NSURL { throw objc.UnimplementedOptionalMethodException('NSURL', 'itemProviderVisibilityForRepresentationWithTypeIdentifier:'); } - final _ret = _objc_msgSend_96wwe1( + final _ret = _objc_msgSend_16fy0up( this.ref.pointer, _sel_itemProviderVisibilityForRepresentationWithTypeIdentifier_, typeIdentifier.ref.pointer); @@ -75641,7 +83663,7 @@ extension NSItemProvider1 on objc.NSURL { objc.NSString typeIdentifier, objc.ObjCBlock completionHandler) { - final _ret = _objc_msgSend_o4sqyk( + final _ret = _objc_msgSend_r0bo0s( this.ref.pointer, _sel_loadDataWithTypeIdentifier_forItemProviderCompletionHandler_, typeIdentifier.ref.pointer, @@ -75670,7 +83692,7 @@ late final _sel_URLFragmentAllowedCharacterSet = extension NSURLUtilities on objc.NSCharacterSet { /// Returns a character set containing the characters allowed in a URL's user subcomponent. static objc.NSCharacterSet getURLUserAllowedCharacterSet() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( _class_NSCharacterSet, _sel_URLUserAllowedCharacterSet); return objc.NSCharacterSet.castFromPointer(_ret, retain: true, release: true); @@ -75678,7 +83700,7 @@ extension NSURLUtilities on objc.NSCharacterSet { /// Returns a character set containing the characters allowed in a URL's password subcomponent. static objc.NSCharacterSet getURLPasswordAllowedCharacterSet() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( _class_NSCharacterSet, _sel_URLPasswordAllowedCharacterSet); return objc.NSCharacterSet.castFromPointer(_ret, retain: true, release: true); @@ -75686,7 +83708,7 @@ extension NSURLUtilities on objc.NSCharacterSet { /// Returns a character set containing the characters allowed in a URL's host subcomponent. static objc.NSCharacterSet getURLHostAllowedCharacterSet() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( _class_NSCharacterSet, _sel_URLHostAllowedCharacterSet); return objc.NSCharacterSet.castFromPointer(_ret, retain: true, release: true); @@ -75694,7 +83716,7 @@ extension NSURLUtilities on objc.NSCharacterSet { /// Returns a character set containing the characters allowed in a URL's path component. ';' is a legal path character, but it is recommended that it be percent-encoded for best compatibility with NSURL (-stringByAddingPercentEncodingWithAllowedCharacters: will percent-encode any ';' characters if you pass the URLPathAllowedCharacterSet). static objc.NSCharacterSet getURLPathAllowedCharacterSet() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( _class_NSCharacterSet, _sel_URLPathAllowedCharacterSet); return objc.NSCharacterSet.castFromPointer(_ret, retain: true, release: true); @@ -75702,7 +83724,7 @@ extension NSURLUtilities on objc.NSCharacterSet { /// Returns a character set containing the characters allowed in a URL's query component. static objc.NSCharacterSet getURLQueryAllowedCharacterSet() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( _class_NSCharacterSet, _sel_URLQueryAllowedCharacterSet); return objc.NSCharacterSet.castFromPointer(_ret, retain: true, release: true); @@ -75710,7 +83732,7 @@ extension NSURLUtilities on objc.NSCharacterSet { /// Returns a character set containing the characters allowed in a URL's fragment component. static objc.NSCharacterSet getURLFragmentAllowedCharacterSet() { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( _class_NSCharacterSet, _sel_URLFragmentAllowedCharacterSet); return objc.NSCharacterSet.castFromPointer(_ret, retain: true, release: true); @@ -75731,7 +83753,7 @@ extension NSURLUtilities1 on objc.NSString { /// Returns a new string made from the receiver by replacing all characters not in the allowedCharacters set with percent encoded characters. UTF-8 encoding is used to determine the correct percent encoded characters. Entire URL strings cannot be percent-encoded. This method is intended to percent-encode a URL component or subcomponent string, NOT the entire URL string. Any characters in allowedCharacters outside of the 7-bit ASCII range are ignored. objc.NSString? stringByAddingPercentEncodingWithAllowedCharacters_( objc.NSCharacterSet allowedCharacters) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_stringByAddingPercentEncodingWithAllowedCharacters_, allowedCharacters.ref.pointer); @@ -75742,7 +83764,7 @@ extension NSURLUtilities1 on objc.NSString { /// Returns a new string made from the receiver by replacing all percent encoded sequences with the matching UTF-8 characters. objc.NSString? get stringByRemovingPercentEncoding { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_stringByRemovingPercentEncoding); return _ret.address == 0 ? null @@ -75752,7 +83774,7 @@ extension NSURLUtilities1 on objc.NSString { /// stringByAddingPercentEscapesUsingEncoding: objc.NSString? stringByAddingPercentEscapesUsingEncoding_( DartNSUInteger enc) { - final _ret = _objc_msgSend_1qrcblu( + final _ret = _objc_msgSend_14hpxwa( this.ref.pointer, _sel_stringByAddingPercentEscapesUsingEncoding_, enc); return _ret.address == 0 ? null @@ -75762,7 +83784,7 @@ extension NSURLUtilities1 on objc.NSString { /// stringByReplacingPercentEscapesUsingEncoding: objc.NSString? stringByReplacingPercentEscapesUsingEncoding_( DartNSUInteger enc) { - final _ret = _objc_msgSend_1qrcblu(this.ref.pointer, + final _ret = _objc_msgSend_14hpxwa(this.ref.pointer, _sel_stringByReplacingPercentEscapesUsingEncoding_, enc); return _ret.address == 0 ? null @@ -75796,7 +83818,7 @@ late final _sel_URLByResolvingSymlinksInPath = extension NSURLPathUtilities on objc.NSURL { /// The following methods work on the path portion of a URL in the same manner that the NSPathUtilities methods on NSString do. static objc.NSURL? fileURLWithPathComponents_(objc.NSArray components) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( _class_NSURL, _sel_fileURLWithPathComponents_, components.ref.pointer); return _ret.address == 0 ? null @@ -75805,7 +83827,7 @@ extension NSURLPathUtilities on objc.NSURL { /// pathComponents objc.NSArray? get pathComponents { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_pathComponents); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_pathComponents); return _ret.address == 0 ? null : objc.NSArray.castFromPointer(_ret, retain: true, release: true); @@ -75814,7 +83836,7 @@ extension NSURLPathUtilities on objc.NSURL { /// lastPathComponent objc.NSString? get lastPathComponent { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_lastPathComponent); + _objc_msgSend_151sglz(this.ref.pointer, _sel_lastPathComponent); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -75822,7 +83844,7 @@ extension NSURLPathUtilities on objc.NSURL { /// pathExtension objc.NSString? get pathExtension { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_pathExtension); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_pathExtension); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -75830,7 +83852,7 @@ extension NSURLPathUtilities on objc.NSURL { /// URLByAppendingPathComponent: objc.NSURL? URLByAppendingPathComponent_(objc.NSString pathComponent) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_URLByAppendingPathComponent_, pathComponent.ref.pointer); return _ret.address == 0 ? null @@ -75840,7 +83862,7 @@ extension NSURLPathUtilities on objc.NSURL { /// URLByAppendingPathComponent:isDirectory: objc.NSURL? URLByAppendingPathComponent_isDirectory_( objc.NSString pathComponent, bool isDirectory) { - final _ret = _objc_msgSend_1bdmr5f( + final _ret = _objc_msgSend_17amj0z( this.ref.pointer, _sel_URLByAppendingPathComponent_isDirectory_, pathComponent.ref.pointer, @@ -75852,7 +83874,7 @@ extension NSURLPathUtilities on objc.NSURL { /// URLByDeletingLastPathComponent objc.NSURL? get URLByDeletingLastPathComponent { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_URLByDeletingLastPathComponent); return _ret.address == 0 ? null @@ -75861,7 +83883,7 @@ extension NSURLPathUtilities on objc.NSURL { /// URLByAppendingPathExtension: objc.NSURL? URLByAppendingPathExtension_(objc.NSString pathExtension) { - final _ret = _objc_msgSend_62nh5j(this.ref.pointer, + final _ret = _objc_msgSend_1sotr3r(this.ref.pointer, _sel_URLByAppendingPathExtension_, pathExtension.ref.pointer); return _ret.address == 0 ? null @@ -75870,7 +83892,7 @@ extension NSURLPathUtilities on objc.NSURL { /// URLByDeletingPathExtension objc.NSURL? get URLByDeletingPathExtension { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_URLByDeletingPathExtension); return _ret.address == 0 ? null @@ -75887,7 +83909,7 @@ extension NSURLPathUtilities on objc.NSURL { /// URLByStandardizingPath objc.NSURL? get URLByStandardizingPath { final _ret = - _objc_msgSend_1x359cv(this.ref.pointer, _sel_URLByStandardizingPath); + _objc_msgSend_151sglz(this.ref.pointer, _sel_URLByStandardizingPath); return _ret.address == 0 ? null : objc.NSURL.castFromPointer(_ret, retain: true, release: true); @@ -75895,7 +83917,7 @@ extension NSURLPathUtilities on objc.NSURL { /// URLByResolvingSymlinksInPath objc.NSURL? get URLByResolvingSymlinksInPath { - final _ret = _objc_msgSend_1x359cv( + final _ret = _objc_msgSend_151sglz( this.ref.pointer, _sel_URLByResolvingSymlinksInPath); return _ret.address == 0 ? null @@ -75917,7 +83939,7 @@ extension NSURLClient on objc.NSObject { /// URL:resourceDataDidBecomeAvailable: void URL_resourceDataDidBecomeAvailable_( objc.NSURL sender, objc.NSData newBytes) { - _objc_msgSend_wjvic9( + _objc_msgSend_pfv6jd( this.ref.pointer, _sel_URL_resourceDataDidBecomeAvailable_, sender.ref.pointer, @@ -75926,20 +83948,20 @@ extension NSURLClient on objc.NSObject { /// URLResourceDidFinishLoading: void URLResourceDidFinishLoading_(objc.NSURL sender) { - _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_URLResourceDidFinishLoading_, + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_URLResourceDidFinishLoading_, sender.ref.pointer); } /// URLResourceDidCancelLoading: void URLResourceDidCancelLoading_(objc.NSURL sender) { - _objc_msgSend_1jdvcbf(this.ref.pointer, _sel_URLResourceDidCancelLoading_, + _objc_msgSend_xtuoz7(this.ref.pointer, _sel_URLResourceDidCancelLoading_, sender.ref.pointer); } /// URL:resourceDidFailLoadingWithReason: void URL_resourceDidFailLoadingWithReason_( objc.NSURL sender, objc.NSString reason) { - _objc_msgSend_wjvic9( + _objc_msgSend_pfv6jd( this.ref.pointer, _sel_URL_resourceDidFailLoadingWithReason_, sender.ref.pointer, @@ -75954,7 +83976,7 @@ late final _sel_loadResourceDataNotifyingClient_usingCache_ = late final _sel_propertyForKey_ = objc.registerName("propertyForKey:"); late final _sel_setResourceData_ = objc.registerName("setResourceData:"); late final _sel_setProperty_forKey_ = objc.registerName("setProperty:forKey:"); -final _objc_msgSend_1lqxdg3 = objc.msgSendPointer +final _objc_msgSend_1lsax7n = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Bool Function( @@ -75975,7 +83997,7 @@ late final _sel_URLHandleUsingCache_ = extension NSURLLoading on objc.NSURL { /// Blocks to load the data if necessary. If shouldUseCache is YES, then if an equivalent URL has already been loaded and cached, its resource data will be returned immediately. If shouldUseCache is NO, a new load will be started objc.NSData? resourceDataUsingCache_(bool shouldUseCache) { - final _ret = _objc_msgSend_1l3kbc1( + final _ret = _objc_msgSend_1t6aok9( this.ref.pointer, _sel_resourceDataUsingCache_, shouldUseCache); return _ret.address == 0 ? null @@ -75985,7 +84007,7 @@ extension NSURLLoading on objc.NSURL { /// Starts an asynchronous load of the data, registering delegate to receive notification. Only one such background load can proceed at a time. void loadResourceDataNotifyingClient_usingCache_( objc.ObjCObjectBase client, bool shouldUseCache) { - _objc_msgSend_gk45w7( + _objc_msgSend_6p7ndb( this.ref.pointer, _sel_loadResourceDataNotifyingClient_usingCache_, client.ref.pointer, @@ -75994,7 +84016,7 @@ extension NSURLLoading on objc.NSURL { /// propertyForKey: objc.ObjCObjectBase? propertyForKey_(objc.NSString propertyKey) { - final _ret = _objc_msgSend_62nh5j( + final _ret = _objc_msgSend_1sotr3r( this.ref.pointer, _sel_propertyForKey_, propertyKey.ref.pointer); return _ret.address == 0 ? null @@ -76003,20 +84025,20 @@ extension NSURLLoading on objc.NSURL { /// These attempt to write the given arguments for the resource specified by the URL; they return success or failure bool setResourceData_(objc.NSData data) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( this.ref.pointer, _sel_setResourceData_, data.ref.pointer); } /// setProperty:forKey: bool setProperty_forKey_( objc.ObjCObjectBase property, objc.NSString propertyKey) { - return _objc_msgSend_1lqxdg3(this.ref.pointer, _sel_setProperty_forKey_, + return _objc_msgSend_1lsax7n(this.ref.pointer, _sel_setProperty_forKey_, property.ref.pointer, propertyKey.ref.pointer); } /// Sophisticated clients will want to ask for this, then message the handle directly. If shouldUseCache is NO, a newly instantiated handle is returned, even if an equivalent URL has been loaded objc.NSURLHandle? URLHandleUsingCache_(bool shouldUseCache) { - final _ret = _objc_msgSend_1l3kbc1( + final _ret = _objc_msgSend_1t6aok9( this.ref.pointer, _sel_URLHandleUsingCache_, shouldUseCache); return _ret.address == 0 ? null @@ -76065,6 +84087,35 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_ffiVoid_listenerTrampoline) ..keepIsolateAlive = false; +void _ObjCBlock_ffiVoid_ffiVoid_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0) { + try { + (objc.getBlockClosure(block) as void Function(ffi.Pointer))(arg0); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_blockingCallable = ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_ffiVoid_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)> + _ObjCBlock_ffiVoid_ffiVoid_blockingListenerCallable = ffi.NativeCallable< + ffi.Void Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_ffiVoid_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock)>`. abstract final class ObjCBlock_ffiVoid_ffiVoid { @@ -76123,6 +84174,32 @@ abstract final class ObjCBlock_ffiVoid_ffiVoid { return objc.ObjCBlock)>(wrapper, retain: false, release: true); } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock)> blocking( + void Function(ffi.Pointer) fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_blockingCallable.nativeFunction.cast(), + (ffi.Pointer arg0) => fn(arg0)); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_ffiVoid_blockingListenerCallable.nativeFunction + .cast(), + (ffi.Pointer arg0) => fn(arg0)); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_ovsamd, raw, rawListener); + objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); + return objc.ObjCBlock)>(wrapper, + retain: false, release: true); + } } /// Call operator for `objc.ObjCBlock)>`. @@ -76157,7 +84234,7 @@ class NSCondition extends objc.NSObject { /// Returns whether [obj] is an instance of [NSCondition]. static bool isInstance(objc.ObjCObjectBase obj) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( obj.ref.pointer, _sel_isKindOfClass_, _class_NSCondition); } @@ -76168,7 +84245,7 @@ class NSCondition extends objc.NSObject { /// waitUntilDate: bool waitUntilDate_(objc.NSDate limit) { - return _objc_msgSend_69e0x1( + return _objc_msgSend_19nvye5( this.ref.pointer, _sel_waitUntilDate_, limit.ref.pointer); } @@ -76184,7 +84261,7 @@ class NSCondition extends objc.NSObject { /// name objc.NSString? get name { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_name); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_name); return _ret.address == 0 ? null : objc.NSString.castFromPointer(_ret, retain: true, release: true); @@ -76192,51 +84269,51 @@ class NSCondition extends objc.NSObject { /// setName: set name(objc.NSString? value) { - return _objc_msgSend_1jdvcbf( + _objc_msgSend_xtuoz7( this.ref.pointer, _sel_setName_, value?.ref.pointer ?? ffi.nullptr); } /// init NSCondition init() { final _ret = - _objc_msgSend_1x359cv(this.ref.retainAndReturnPointer(), _sel_init); + _objc_msgSend_151sglz(this.ref.retainAndReturnPointer(), _sel_init); return NSCondition.castFromPointer(_ret, retain: false, release: true); } /// new static NSCondition new1() { - final _ret = _objc_msgSend_1x359cv(_class_NSCondition, _sel_new); + final _ret = _objc_msgSend_151sglz(_class_NSCondition, _sel_new); return NSCondition.castFromPointer(_ret, retain: false, release: true); } /// allocWithZone: static NSCondition allocWithZone_(ffi.Pointer<_NSZone> zone) { final _ret = - _objc_msgSend_hzlb60(_class_NSCondition, _sel_allocWithZone_, zone); + _objc_msgSend_1cwp428(_class_NSCondition, _sel_allocWithZone_, zone); return NSCondition.castFromPointer(_ret, retain: false, release: true); } /// alloc static NSCondition alloc() { - final _ret = _objc_msgSend_1x359cv(_class_NSCondition, _sel_alloc); + final _ret = _objc_msgSend_151sglz(_class_NSCondition, _sel_alloc); return NSCondition.castFromPointer(_ret, retain: false, release: true); } /// self NSCondition self() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_self); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_self); return NSCondition.castFromPointer(_ret, retain: true, release: true); } /// retain NSCondition retain() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_retain); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_retain); return NSCondition.castFromPointer(_ret, retain: true, release: true); } /// autorelease NSCondition autorelease() { - final _ret = _objc_msgSend_1x359cv(this.ref.pointer, _sel_autorelease); + final _ret = _objc_msgSend_151sglz(this.ref.pointer, _sel_autorelease); return NSCondition.castFromPointer(_ret, retain: true, release: true); } @@ -76290,13 +84367,712 @@ late final _sel_raise_format_ = objc.registerName("raise:format:"); extension NSExceptionRaisingConveniences on NSException { /// raise:format: static void raise_format_(DartNSExceptionName name, objc.NSString format) { - _objc_msgSend_wjvic9(_class_NSException, _sel_raise_format_, + _objc_msgSend_pfv6jd(_class_NSException, _sel_raise_format_, name.ref.pointer, format.ref.pointer); } } typedef NSUncaughtExceptionHandler = ffi .NativeFunction exception)>; +typedef os_function_tFunction1 = ffi.Void Function(ffi.Pointer); +typedef Dartos_function_tFunction1 = void Function(ffi.Pointer); +typedef os_function_t1 + = ffi.Pointer>; + +/// ! +/// @typedef os_block_t +/// +/// @abstract +/// Generic type for a block taking no arguments and returning no value. +/// +/// @discussion +/// When not building with Objective-C ARC, a block object allocated on or +/// copied to the heap must be released with a -[release] message or the +/// Block_release() function. +/// +/// The declaration of a block literal allocates storage on the stack. +/// Therefore, this is an invalid construct: +/// +/// os_block_t block; +/// if (x) { +/// block = ^{ printf("true\n"); }; +/// } else { +/// block = ^{ printf("false\n"); }; +/// } +/// block(); // unsafe!!! +/// +/// +/// What is happening behind the scenes: +/// +/// if (x) { +/// struct Block __tmp_1 = ...; // setup details +/// block = &__tmp_1; +/// } else { +/// struct Block __tmp_2 = ...; // setup details +/// block = &__tmp_2; +/// } +/// +/// +/// As the example demonstrates, the address of a stack variable is escaping the +/// scope in which it is allocated. That is a classic C bug. +/// +/// Instead, the block literal must be copied to the heap with the Block_copy() +/// function or by sending it a -[copy] message. +typedef os_block_t1 = ffi.Pointer; +typedef Dartos_block_t1 = objc.ObjCBlock; +typedef fsignatures_t1 = fsignatures; +typedef fsupplement_t1 = fsupplement; + +/// DYLD needs to check if the object is allowed to be combined +/// into the main binary. This is done between the code signature +/// is loaded and dyld is doing all the work to process the LOAD commands. +/// +/// While this could be done in F_ADDFILESIGS.* family the hook into +/// the MAC module doesn't say no when LV isn't enabled and then that +/// is cached on the vnode, and the MAC module never gets change once +/// a process that library validation enabled. +typedef fchecklv_t1 = fchecklv; + +/// fgetsigsinfo_t used by F_GETSIGSINFO command +typedef fgetsigsinfo_t1 = fgetsigsinfo; + +/// fstore_t type used by F_PREALLOCATE command +typedef fstore_t1 = fstore; + +/// fpunchhole_t used by F_PUNCHHOLE +typedef fpunchhole_t1 = fpunchhole; + +/// factive_file_trim_t used by F_TRIM_ACTIVE_FILE +typedef ftrimactivefile_t1 = ftrimactivefile; + +/// fspecread_t used by F_SPECULATIVE_READ +typedef fspecread_t1 = fspecread; +typedef fattributiontag_t1 = fattributiontag; +typedef filesec_t1 = ffi.Pointer<_filesec>; +typedef boolean_t1 = ffi.Int; +typedef Dartboolean_t1 = int; + +/// natural_t and integer_t are Mach's legacy types for machine- +/// independent integer types (unsigned, and signed, respectively). +/// Their original purpose was to define other types in a machine/ +/// compiler independent way. +/// +/// They also had an implicit "same size as pointer" characteristic +/// to them (i.e. Mach's traditional types are very ILP32 or ILP64 +/// centric). We will likely support x86 ABIs that do not follow +/// either ofthese models (specifically LP64). Therefore, we had to +/// make a choice between making these types scale with pointers or stay +/// tied to integers. Because their use is predominantly tied to +/// to the size of an integer, we are keeping that association and +/// breaking free from pointer size guarantees. +/// +/// New use of these types is discouraged. +typedef natural_t1 = __darwin_natural_t; +typedef integer_t1 = ffi.Int; +typedef Dartinteger_t1 = int; +typedef vm_offset_t1 = ffi.UintPtr; +typedef Dartvm_offset_t1 = int; +typedef vm_size_t1 = ffi.UintPtr; +typedef Dartvm_size_t1 = int; +typedef mach_vm_address_t1 = ffi.Uint64; +typedef Dartmach_vm_address_t1 = int; +typedef mach_vm_offset_t1 = ffi.Uint64; +typedef Dartmach_vm_offset_t1 = int; +typedef mach_vm_size_t1 = ffi.Uint64; +typedef Dartmach_vm_size_t1 = int; +typedef vm_map_offset_t1 = ffi.Uint64; +typedef Dartvm_map_offset_t1 = int; +typedef vm_map_address_t1 = ffi.Uint64; +typedef Dartvm_map_address_t1 = int; +typedef vm_map_size_t1 = ffi.Uint64; +typedef Dartvm_map_size_t1 = int; +typedef vm32_offset_t1 = ffi.Uint32; +typedef Dartvm32_offset_t1 = int; +typedef vm32_address_t1 = ffi.Uint32; +typedef Dartvm32_address_t1 = int; +typedef vm32_size_t1 = ffi.Uint32; +typedef Dartvm32_size_t1 = int; +typedef mach_port_context_t1 = vm_offset_t1; + +/// mach_port_name_t - the local identity for a Mach port +/// +/// The name is Mach port namespace specific. It is used to +/// identify the rights held for that port by the task whose +/// namespace is implied [or specifically provided]. +/// +/// Use of this type usually implies just a name - no rights. +/// See mach_port_t for a type that implies a "named right." +typedef mach_port_name_t1 = natural_t1; +typedef mach_port_name_array_t1 = ffi.Pointer; +typedef mach_port_t1 = __darwin_mach_port_t; +typedef mach_port_array_t1 = ffi.Pointer; + +/// These are the different rights a task may have for a port. +/// The MACH_PORT_RIGHT_* definitions are used as arguments +/// to mach_port_allocate, mach_port_get_refs, etc, to specify +/// a particular right to act upon. The mach_port_names and +/// mach_port_type calls return bitmasks using the MACH_PORT_TYPE_* +/// definitions. This is because a single name may denote +/// multiple rights. +typedef mach_port_right_t1 = natural_t1; +typedef mach_port_type_t1 = natural_t1; +typedef mach_port_type_array_t1 = ffi.Pointer; + +/// User-references for capabilities. +typedef mach_port_urefs_t1 = natural_t1; +typedef mach_port_delta_t1 = integer_t1; + +/// Attributes of ports. (See mach_port_get_receive_status.) +typedef mach_port_seqno_t1 = natural_t1; +typedef mach_port_mscount_t1 = natural_t1; +typedef mach_port_msgcount_t1 = natural_t1; +typedef mach_port_rights_t1 = natural_t1; +typedef mach_port_srights_t1 = ffi.UnsignedInt; +typedef Dartmach_port_srights_t1 = int; +typedef mach_port_status_t1 = mach_port_status; +typedef mach_port_limits_t1 = mach_port_limits; +typedef mach_port_info_ext_t1 = mach_port_info_ext; +typedef mach_port_guard_info_t1 = mach_port_guard_info; +typedef mach_port_info_t1 = ffi.Pointer; + +/// Flavors for mach_port_get/set/assert_attributes() +typedef mach_port_flavor_t1 = ffi.Int; +typedef Dartmach_port_flavor_t1 = int; + +/// Structure used to pass information about port allocation requests. +/// Must be padded to 64-bits total length. +typedef mach_port_qos_t1 = mach_port_qos; +typedef mach_service_port_info_data_t1 = mach_service_port_info; +typedef mach_service_port_info_t1 = ffi.Pointer; + +/// Structure to define optional attributes for a newly +/// constructed port. +typedef mach_port_options_t1 = mach_port_options; +typedef mach_port_options_ptr_t1 = ffi.Pointer; + +/// ! +/// @typedef os_workgroup_t +/// +/// @abstract +/// A reference counted os object representing a workload that needs to +/// be distinctly recognized and tracked by the system. The workgroup +/// tracks a collection of threads all working cooperatively. An os_workgroup +/// object - when not an instance of a specific os_workgroup_t subclass - +/// represents a generic workload and makes no assumptions about the kind of +/// work done. +/// +/// @discussion +/// Threads can explicitly join an os_workgroup_t to mark themselves as +/// participants in the workload. +typedef os_workgroup_t1 = ffi.Pointer; +typedef Dartos_workgroup_t1 = OS_os_workgroup; + +/// ! +/// @typedef os_workgroup_attr_t +/// +/// @abstract +/// Pointer to an opaque structure for describing attributes that can be +/// configured on a workgroup at creation. +typedef os_workgroup_attr_s1 = os_workgroup_attr_opaque_s; +typedef os_workgroup_attr_t1 = ffi.Pointer; + +/// ! +/// @typedef os_workgroup_join_token, os_workgroup_join_token_t +/// +/// @abstract +/// An opaque join token which the client needs to pass to os_workgroup_join +/// and os_workgroup_leave +typedef os_workgroup_join_token_s1 = os_workgroup_join_token_opaque_s; +typedef os_workgroup_join_token_t1 + = ffi.Pointer; + +/// Working Arena index of a thread in a workgroup +typedef os_workgroup_index1 = ffi.Uint32; +typedef Dartos_workgroup_index1 = int; +typedef os_workgroup_working_arena_destructor_tFunction1 = ffi.Void Function( + ffi.Pointer); +typedef Dartos_workgroup_working_arena_destructor_tFunction1 = void Function( + ffi.Pointer); + +/// Destructor for Working Arena +typedef os_workgroup_working_arena_destructor_t1 = ffi.Pointer< + ffi.NativeFunction>; + +/// ! +/// @typedef os_workgroup_max_parallel_threads_attr_t +/// +/// @abstract +/// A pointer to a structure describing the set of properties of a workgroup to +/// override with the explicitly specified values in the structure. +/// +/// See also os_workgroup_max_parallel_threads. +typedef os_workgroup_mpt_attr_s1 = os_workgroup_max_parallel_threads_attr_s; +typedef os_workgroup_mpt_attr_t1 + = ffi.Pointer; +typedef os_workgroup_interval_t1 = ffi.Pointer; +typedef Dartos_workgroup_interval_t1 = OS_os_workgroup; + +/// @typedef os_workgroup_interval_data, os_workgroup_interval_data_t +/// +/// @abstract +/// An opaque structure containing additional configuration for the workgroup +/// interval. +typedef os_workgroup_interval_data_s1 = os_workgroup_interval_data_opaque_s; +typedef os_workgroup_interval_data_t1 + = ffi.Pointer; +typedef os_workgroup_parallel_t1 = ffi.Pointer; +typedef Dartos_workgroup_parallel_t1 = OS_os_workgroup; +typedef dispatch_function_tFunction1 = ffi.Void Function(ffi.Pointer); +typedef Dartdispatch_function_tFunction1 = void Function(ffi.Pointer); +typedef dispatch_function_t1 + = ffi.Pointer>; +typedef time_value_t1 = time_value; + +/// Type definitions. +typedef alarm_type_t1 = ffi.Int; +typedef Dartalarm_type_t1 = int; +typedef sleep_type_t1 = ffi.Int; +typedef Dartsleep_type_t1 = int; +typedef clock_id_t1 = ffi.Int; +typedef Dartclock_id_t1 = int; +typedef clock_flavor_t1 = ffi.Int; +typedef Dartclock_flavor_t1 = int; +typedef clock_attr_t1 = ffi.Pointer; +typedef clock_res_t1 = ffi.Int; +typedef Dartclock_res_t1 = int; +typedef mach_timespec_t1 = mach_timespec; + +/// ! +/// @typedef dispatch_time_t +/// +/// @abstract +/// A somewhat abstract representation of time; where zero means "now" and +/// DISPATCH_TIME_FOREVER means "infinity" and every value in between is an +/// opaque encoding. +typedef dispatch_time_t1 = ffi.Uint64; +typedef Dartdispatch_time_t1 = int; + +/// By default, dispatch objects are declared as Objective-C types when building +/// with an Objective-C compiler. This allows them to participate in ARC, in RR +/// management by the Blocks runtime and in leaks checking by the static +/// analyzer, and enables them to be added to Cocoa collections. +/// See for details. +typedef dispatch_object_t1 = ffi.Pointer; +typedef Dartdispatch_object_t1 = objc.NSObject; + +/// ! +/// @typedef dispatch_block_t +/// +/// @abstract +/// The type of blocks submitted to dispatch queues, which take no arguments +/// and have no return value. +/// +/// @discussion +/// When not building with Objective-C ARC, a block object allocated on or +/// copied to the heap must be released with a -[release] message or the +/// Block_release() function. +/// +/// The declaration of a block literal allocates storage on the stack. +/// Therefore, this is an invalid construct: +/// +/// dispatch_block_t block; +/// if (x) { +/// block = ^{ printf("true\n"); }; +/// } else { +/// block = ^{ printf("false\n"); }; +/// } +/// block(); // unsafe!!! +/// +/// +/// What is happening behind the scenes: +/// +/// if (x) { +/// struct Block __tmp_1 = ...; // setup details +/// block = &__tmp_1; +/// } else { +/// struct Block __tmp_2 = ...; // setup details +/// block = &__tmp_2; +/// } +/// +/// +/// As the example demonstrates, the address of a stack variable is escaping the +/// scope in which it is allocated. That is a classic C bug. +/// +/// Instead, the block literal must be copied to the heap with the Block_copy() +/// function or by sending it a -[copy] message. +typedef dispatch_block_t1 = ffi.Pointer; +typedef Dartdispatch_block_t1 = objc.ObjCBlock; + +/// ! +/// @typedef dispatch_queue_global_t +/// +/// @abstract +/// Dispatch global concurrent queues are an abstraction around the system thread +/// pool which invokes workitems that are submitted to dispatch queues. +/// +/// @discussion +/// Dispatch global concurrent queues provide buckets of priorities on top of the +/// thread pool the system manages. The system will decide how many threads +/// to allocate to this pool depending on demand and system load. In particular, +/// the system tries to maintain a good level of concurrency for this resource, +/// and will create new threads when too many existing worker threads block in +/// system calls. +/// +/// The global concurrent queues are a shared resource and as such it is the +/// responsiblity of every user of this resource to not submit an unbounded +/// amount of work to this pool, especially work that may block, as this can +/// cause the system to spawn very large numbers of threads (aka. thread +/// explosion). +/// +/// Work items submitted to the global concurrent queues have no ordering +/// guarantee with respect to the order of submission, and workitems submitted +/// to these queues may be invoked concurrently. +/// +/// Dispatch global concurrent queues are well-known global objects that are +/// returned by dispatch_get_global_queue(). These objects cannot be modified. +/// Calls to dispatch_suspend(), dispatch_resume(), dispatch_set_context(), etc., +/// will have no effect when used with queues of this type. +typedef dispatch_queue_global_t1 = ffi.Pointer; +typedef Dartdispatch_queue_global_t1 = objc.NSObject; + +/// ! +/// @typedef dispatch_queue_serial_executor_t +/// +/// @abstract +/// An abstract class of dispatch queues which conform to the serial executor +/// protocol. +/// +/// @discussion +/// A serial executor in Swift Concurrency represents a mutual exclusion context. +/// Queues with a singular owner, which invoke only one workItem at a time +/// provide such a mutual exclusion context and are serial executors. +/// +/// Subclasses of this abstract class can be therefore be setup as Custom +/// Executors for Swift Actors. +/// +/// See dispatch_queue_serial_t and dispatch_workloop_t. +typedef dispatch_queue_serial_executor_t1 = ffi.Pointer; +typedef Dartdispatch_queue_serial_executor_t1 = objc.NSObject; + +/// ! +/// @typedef dispatch_queue_serial_t +/// +/// @abstract +/// Dispatch serial queues invoke workitems submitted to them serially in FIFO +/// order. +/// +/// @discussion +/// Dispatch serial queues are lightweight objects to which workitems may be +/// submitted to be invoked in FIFO order. A serial queue will only invoke one +/// workitem at a time, but independent serial queues may each invoke their work +/// items concurrently with respect to each other. +/// +/// Serial queues can target each other (See dispatch_set_target_queue()). The +/// serial queue at the bottom of a queue hierarchy provides an exclusion +/// context: at most one workitem submitted to any of the queues in such +/// a hiearchy will run at any given time. +/// +/// Such hierarchies provide a natural construct to organize an application +/// subsystem around. +/// +/// Serial queues are created by passing a dispatch queue attribute derived from +/// DISPATCH_QUEUE_SERIAL to dispatch_queue_create_with_target(). +typedef dispatch_queue_serial_t1 = ffi.Pointer; +typedef Dartdispatch_queue_serial_t1 = objc.NSObject; + +/// ! +/// @typedef dispatch_queue_main_t +/// +/// @abstract +/// The type of the default queue that is bound to the main thread. +/// +/// @discussion +/// The main queue is a serial queue (See dispatch_queue_serial_t) which is bound +/// to the main thread of an application. +/// +/// In order to invoke workitems submitted to the main queue, the application +/// must call dispatch_main(), NSApplicationMain(), or use a CFRunLoop on the +/// main thread. +/// +/// The main queue is a well known global object that is made automatically on +/// behalf of the main thread during process initialization and is returned by +/// dispatch_get_main_queue(). This object cannot be modified. Calls to +/// dispatch_suspend(), dispatch_resume(), dispatch_set_context(), etc., will +/// have no effect when used on the main queue. +typedef dispatch_queue_main_t1 = ffi.Pointer; +typedef Dartdispatch_queue_main_t1 = objc.NSObject; + +/// ! +/// @typedef dispatch_queue_concurrent_t +/// +/// @abstract +/// Dispatch concurrent queues invoke workitems submitted to them concurrently, +/// and admit a notion of barrier workitems. +/// +/// @discussion +/// Dispatch concurrent queues are lightweight objects to which regular and +/// barrier workitems may be submited. Barrier workitems are invoked in +/// exclusion of any other kind of workitem in FIFO order. +/// +/// Regular workitems can be invoked concurrently for the same concurrent queue, +/// in any order. However, regular workitems will not be invoked before any +/// barrier workitem submited ahead of them has been invoked. +/// +/// In other words, if a serial queue is equivalent to a mutex in the Dispatch +/// world, a concurrent queue is equivalent to a reader-writer lock, where +/// regular items are readers and barriers are writers. +/// +/// Concurrent queues are created by passing a dispatch queue attribute derived +/// from DISPATCH_QUEUE_CONCURRENT to dispatch_queue_create_with_target(). +/// +/// Caveat: +/// Dispatch concurrent queues at this time do not implement priority inversion +/// avoidance when lower priority regular workitems (readers) are being invoked +/// and are preventing a higher priority barrier (writer) from being invoked. +typedef dispatch_queue_concurrent_t1 = ffi.Pointer; +typedef Dartdispatch_queue_concurrent_t1 = objc.NSObject; +typedef dispatch_queue_priority_t1 = ffi.Long; +typedef Dartdispatch_queue_priority_t1 = int; + +/// ! +/// @typedef dispatch_queue_attr_t +/// +/// @abstract +/// Attribute for dispatch queues. +typedef dispatch_queue_attr_t1 = ffi.Pointer; +typedef Dartdispatch_queue_attr_t1 = objc.NSObject; +typedef kern_return_t1 = ffi.Int; +typedef Dartkern_return_t1 = int; + +/// The timeout mechanism uses mach_msg_timeout_t values, +/// passed by value. The timeout units are milliseconds. +/// It is controlled with the MACH_SEND_TIMEOUT +/// and MACH_RCV_TIMEOUT options. +typedef mach_msg_timeout_t1 = natural_t1; + +/// Every message starts with a message header. +/// Following the message header, if the message is complex, are a count +/// of type descriptors and the type descriptors themselves +/// (mach_msg_descriptor_t). The size of the message must be specified in +/// bytes, and includes the message header, descriptor count, descriptors, +/// and inline data. +/// +/// The msgh_remote_port field specifies the destination of the message. +/// It must specify a valid send or send-once right for a port. +/// +/// The msgh_local_port field specifies a "reply port". Normally, +/// This field carries a send-once right that the receiver will use +/// to reply to the message. It may carry the values MACH_PORT_NULL, +/// MACH_PORT_DEAD, a send-once right, or a send right. +/// +/// The msgh_voucher_port field specifies a Mach voucher port. Only +/// send rights to kernel-implemented Mach Voucher kernel objects in +/// addition to MACH_PORT_NULL or MACH_PORT_DEAD may be passed. +/// +/// The msgh_id field is uninterpreted by the message primitives. +/// It normally carries information specifying the format +/// or meaning of the message. +typedef mach_msg_bits_t1 = ffi.UnsignedInt; +typedef Dartmach_msg_bits_t1 = int; +typedef mach_msg_size_t1 = natural_t1; +typedef mach_msg_id_t1 = integer_t1; +typedef mach_msg_priority_t1 = ffi.UnsignedInt; +typedef Dartmach_msg_priority_t1 = int; +typedef mach_msg_type_name_t1 = ffi.UnsignedInt; +typedef Dartmach_msg_type_name_t1 = int; +typedef mach_msg_copy_options_t1 = ffi.UnsignedInt; +typedef Dartmach_msg_copy_options_t1 = int; +typedef mach_msg_guard_flags_t1 = ffi.UnsignedInt; +typedef Dartmach_msg_guard_flags_t1 = int; + +/// In a complex mach message, the mach_msg_header_t is followed by +/// a descriptor count, then an array of that number of descriptors +/// (mach_msg_*_descriptor_t). The type field of mach_msg_type_descriptor_t +/// (which any descriptor can be cast to) indicates the flavor of the +/// descriptor. +/// +/// Note that in LP64, the various types of descriptors are no longer all +/// the same size as mach_msg_descriptor_t, so the array cannot be indexed +/// as expected. +typedef mach_msg_descriptor_type_t1 = ffi.UnsignedInt; +typedef Dartmach_msg_descriptor_type_t1 = int; +typedef mach_msg_trailer_type_t1 = ffi.UnsignedInt; +typedef Dartmach_msg_trailer_type_t1 = int; +typedef mach_msg_trailer_size_t1 = ffi.UnsignedInt; +typedef Dartmach_msg_trailer_size_t1 = int; +typedef mach_msg_trailer_info_t1 = ffi.Pointer; +typedef mach_msg_filter_id1 = ffi.Int; +typedef Dartmach_msg_filter_id1 = int; + +/// These values can change from release to release - but clearly +/// code cannot request additional trailer elements one was not +/// compiled to understand. Therefore, it is safe to use this +/// constant when the same module specified the receive options. +/// Otherwise, you run the risk that the options requested by +/// another module may exceed the local modules notion of +/// MAX_TRAILER_SIZE. +typedef mach_msg_max_trailer_t1 = mach_msg_mac_trailer_t; + +/// Legacy requirements keep us from ever updating these defines (even +/// when the format_0 trailers gain new option data fields in the future). +/// Therefore, they shouldn't be used going forward. Instead, the sizes +/// should be compared against the specific element size requested using +/// REQUESTED_TRAILER_SIZE. +typedef mach_msg_format_0_trailer_t1 = mach_msg_security_trailer_t; +typedef mach_msg_options_t1 = integer_t1; +typedef mach_msg_type_size_t1 = natural_t1; +typedef mach_msg_type_number_t1 = natural_t1; +typedef mach_msg_option_t1 = integer_t1; + +/// Much code assumes that mach_msg_return_t == kern_return_t. +/// This definition is useful for descriptive purposes. +/// +/// See for the format of error codes. +/// IPC errors are system 4. Send errors are subsystem 0; +/// receive errors are subsystem 1. The code field is always non-zero. +/// The high bits of the code field communicate extra information +/// for some error codes. MACH_MSG_MASK masks off these special bits. +typedef mach_msg_return_t1 = kern_return_t1; + +/// ! +/// @typedef dispatch_source_t +/// +/// @abstract +/// Dispatch sources are used to automatically submit event handler blocks to +/// dispatch queues in response to external events. +typedef dispatch_source_t1 = ffi.Pointer; +typedef Dartdispatch_source_t1 = objc.NSObject; + +/// ! +/// @typedef dispatch_source_type_t +/// +/// @abstract +/// Constants of this type represent the class of low-level system object that +/// is being monitored by the dispatch source. Constants of this type are +/// passed as a parameter to dispatch_source_create() and determine how the +/// handle argument is interpreted (i.e. as a file descriptor, mach port, +/// signal number, process identifier, etc.), and how the mask argument is +/// interpreted. +typedef dispatch_source_type_t1 = ffi.Pointer; +typedef dispatch_source_mach_send_flags_t1 = ffi.UnsignedLong; +typedef Dartdispatch_source_mach_send_flags_t1 = int; + +/// ! +/// @typedef dispatch_source_mach_recv_flags_t +/// Type of dispatch_source_mach_recv flags +typedef dispatch_source_mach_recv_flags_t1 = ffi.UnsignedLong; +typedef Dartdispatch_source_mach_recv_flags_t1 = int; +typedef dispatch_source_memorypressure_flags_t1 = ffi.UnsignedLong; +typedef Dartdispatch_source_memorypressure_flags_t1 = int; +typedef dispatch_source_proc_flags_t1 = ffi.UnsignedLong; +typedef Dartdispatch_source_proc_flags_t1 = int; +typedef dispatch_source_vnode_flags_t1 = ffi.UnsignedLong; +typedef Dartdispatch_source_vnode_flags_t1 = int; +typedef dispatch_source_timer_flags_t1 = ffi.UnsignedLong; +typedef Dartdispatch_source_timer_flags_t1 = int; + +/// ! +/// @typedef dispatch_group_t +/// @abstract +/// A group of blocks submitted to queues for asynchronous invocation. +typedef dispatch_group_t1 = ffi.Pointer; +typedef Dartdispatch_group_t1 = objc.NSObject; + +/// ! +/// @typedef dispatch_semaphore_t +/// +/// @abstract +/// A counting semaphore. +typedef dispatch_semaphore_t1 = ffi.Pointer; +typedef Dartdispatch_semaphore_t1 = objc.NSObject; + +/// ! +/// @typedef dispatch_once_t +/// +/// @abstract +/// A predicate for use with dispatch_once(). It must be initialized to zero. +/// Note: static and global variables default to zero. +typedef dispatch_once_t1 = ffi.IntPtr; +typedef Dartdispatch_once_t1 = int; + +/// ! +/// @typedef dispatch_data_t +/// A dispatch object representing memory regions. +typedef dispatch_data_t1 = ffi.Pointer; +typedef Dartdispatch_data_t1 = objc.NSObject; + +/// ! +/// @typedef dispatch_data_applier_t +/// A block to be invoked for every contiguous memory region in a data object. +/// +/// @param region A data object representing the current region. +/// @param offset The logical offset of the current region to the start +/// of the data object. +/// @param buffer The location of the memory for the current region. +/// @param size The size of the memory for the current region. +/// @result A Boolean indicating whether traversal should continue. +typedef dispatch_data_applier_t1 = ffi.Pointer; +typedef Dartdispatch_data_applier_t1 = objc.ObjCBlock< + ffi.Bool Function( + objc.NSObject, ffi.Size, ffi.Pointer, ffi.Size)>; +typedef dispatch_fd_t1 = ffi.Int; +typedef Dartdispatch_fd_t1 = int; + +/// ! +/// @typedef dispatch_io_t +/// A dispatch I/O channel represents the asynchronous I/O policy applied to a +/// file descriptor. I/O channels are first class dispatch objects and may be +/// retained and released, suspended and resumed, etc. +typedef dispatch_io_t1 = ffi.Pointer; +typedef Dartdispatch_io_t1 = objc.NSObject; +typedef dispatch_io_type_t1 = ffi.UnsignedLong; +typedef Dartdispatch_io_type_t1 = int; + +/// ! +/// @typedef dispatch_io_handler_t +/// The prototype of I/O handler blocks for dispatch I/O operations. +/// +/// @param done A flag indicating whether the operation is complete. +/// @param data The data object to be handled. +/// @param error An errno condition for the operation. +typedef dispatch_io_handler_t1 = ffi.Pointer; +typedef Dartdispatch_io_handler_t1 + = objc.ObjCBlock; +typedef dispatch_io_close_flags_t1 = ffi.UnsignedLong; +typedef Dartdispatch_io_close_flags_t1 = int; +typedef dispatch_io_interval_flags_t1 = ffi.UnsignedLong; +typedef Dartdispatch_io_interval_flags_t1 = int; + +/// ! +/// @typedef dispatch_workloop_t +/// +/// @abstract +/// Dispatch workloops invoke workitems submitted to them in priority order. +/// +/// @discussion +/// A dispatch workloop is a flavor of dispatch_queue_t that is a priority +/// ordered queue (using the QOS class of the submitted workitems as the +/// ordering). Dispatch workloops are an exclusion context and it is guaranteed +/// that only one work item submitted to the dispatch workloop will be invoked at +/// a time. +/// +/// Between each workitem invocation, the workloop will evaluate whether higher +/// priority workitems have since been submitted, either directly to the +/// workloop or to any queues that target the workloop, and execute these first. +/// +/// Serial queues targeting a workloop maintain FIFO execution of their +/// workitems. However, the workloop may reorder workitems submitted to +/// independent serial queues targeting it with respect to each other, +/// based on their priorities, while preserving FIFO execution with respect to +/// each serial queue. +/// +/// A dispatch workloop is a "subclass" of dispatch_queue_t which can be passed +/// to all APIs accepting a dispatch queue, except for functions from the +/// dispatch_sync() family. dispatch_async_and_wait() must be used for workloop +/// objects. Functions from the dispatch_sync() family on queues targeting +/// a workloop are still permitted but discouraged for performance reasons. +typedef dispatch_workloop_t1 = ffi.Pointer; +typedef Dartdispatch_workloop_t1 = objc.NSObject; enum NSOperationQueuePriority { NSOperationQueuePriorityVeryLow(-8), @@ -76326,7 +85102,7 @@ typedef DartNSErrorUserInfoKey = objc.NSString; late final _sel_attemptRecoveryFromError_optionIndex_delegate_didRecoverSelector_contextInfo_ = objc.registerName( "attemptRecoveryFromError:optionIndex:delegate:didRecoverSelector:contextInfo:"); -final _objc_msgSend_3kga1r = objc.msgSendPointer +final _objc_msgSend_10txwc9 = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Void Function( @@ -76348,7 +85124,7 @@ final _objc_msgSend_3kga1r = objc.msgSendPointer ffi.Pointer)>(); late final _sel_attemptRecoveryFromError_optionIndex_ = objc.registerName("attemptRecoveryFromError:optionIndex:"); -final _objc_msgSend_1yvrem6 = objc.msgSendPointer +final _objc_msgSend_z7gxsm = objc.msgSendPointer .cast< ffi.NativeFunction< ffi.Bool Function( @@ -76377,7 +85153,7 @@ extension NSErrorRecoveryAttempting on objc.NSObject { objc.ObjCObjectBase? delegate, ffi.Pointer didRecoverSelector, ffi.Pointer contextInfo) { - _objc_msgSend_3kga1r( + _objc_msgSend_10txwc9( this.ref.pointer, _sel_attemptRecoveryFromError_optionIndex_delegate_didRecoverSelector_contextInfo_, error.ref.pointer, @@ -76390,7 +85166,7 @@ extension NSErrorRecoveryAttempting on objc.NSObject { /// Given that an error alert has been presented applicaton-modally to the user, and the user has chosen one of the error's recovery options, attempt recovery from the error, and return YES if error recovery was completely successful, NO otherwise. The recovery option index is an index into the error's array of localized recovery options. bool attemptRecoveryFromError_optionIndex_( objc.NSError error, DartNSUInteger recoveryOptionIndex) { - return _objc_msgSend_1yvrem6( + return _objc_msgSend_z7gxsm( this.ref.pointer, _sel_attemptRecoveryFromError_optionIndex_, error.ref.pointer, @@ -76504,6 +85280,65 @@ ffi.NativeCallable< ffi.Pointer)>.listener( _ObjCBlock_ffiVoid_NSCondition_NSURLSession_NSURLSessionDownloadTask_NSURL_listenerTrampoline) ..keepIsolateAlive = false; +void + _ObjCBlock_ffiVoid_NSCondition_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingTrampoline( + ffi.Pointer block, + ffi.Pointer waiter, + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) { + try { + (objc.getBlockClosure(block) as void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer))(arg0, arg1, arg2, arg3); + } catch (e) { + } finally { + objc.signalWaiter(waiter); + objc.objectRelease(block.cast()); + } +} + +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSCondition_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.isolateLocal( + _ObjCBlock_ffiVoid_NSCondition_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingTrampoline) + ..keepIsolateAlive = false; +ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)> + _ObjCBlock_ffiVoid_NSCondition_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingListenerCallable = + ffi.NativeCallable< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>.listener( + _ObjCBlock_ffiVoid_NSCondition_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingTrampoline) + ..keepIsolateAlive = false; /// Construction methods for `objc.ObjCBlock`. abstract final class ObjCBlock_ffiVoid_NSCondition_NSURLSession_NSURLSessionDownloadTask_NSURL { @@ -76588,8 +85423,64 @@ abstract final class ObjCBlock_ffiVoid_NSCondition_NSURLSession_NSURLSessionDown retain: false, release: true), objc.NSURL .castFromPointer(arg3, retain: false, release: true))); - final wrapper = _NativeCupertinoHttp_wrapListenerBlock_4ya7yd(raw); + final wrapper = _NativeCupertinoHttp_wrapListenerBlock_mlcr8l(raw); + objc.objectRelease(raw.cast()); + return objc.ObjCBlock< + ffi.Void Function(NSCondition, NSURLSession, NSURLSessionDownloadTask, + objc.NSURL)>(wrapper, retain: false, release: true); + } + + /// Creates a blocking block from a Dart function. + /// + /// This callback can be invoked from any native thread, and will block the + /// caller until the callback is handled by the Dart isolate that created + /// the block. Async functions are not supported. + /// + /// This block does not keep the owner isolate alive. If the owner isolate has + /// shut down, and the block is invoked by native code, it may block + /// indefinitely, or have other undefined behavior. + static objc.ObjCBlock< + ffi.Void Function(NSCondition, NSURLSession, NSURLSessionDownloadTask, + objc.NSURL)> blocking( + void Function( + NSCondition, NSURLSession, NSURLSessionDownloadTask, objc.NSURL) + fn) { + final raw = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSCondition_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + NSCondition.castFromPointer(arg0, retain: false, release: true), + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDownloadTask.castFromPointer(arg2, + retain: false, release: true), + objc.NSURL + .castFromPointer(arg3, retain: false, release: true))); + final rawListener = objc.newClosureBlock( + _ObjCBlock_ffiVoid_NSCondition_NSURLSession_NSURLSessionDownloadTask_NSURL_blockingListenerCallable + .nativeFunction + .cast(), + (ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3) => + fn( + NSCondition.castFromPointer(arg0, retain: false, release: true), + NSURLSession.castFromPointer(arg1, + retain: false, release: true), + NSURLSessionDownloadTask.castFromPointer(arg2, + retain: false, release: true), + objc.NSURL + .castFromPointer(arg3, retain: false, release: true))); + final wrapper = objc.wrapBlockingBlock( + _NativeCupertinoHttp_wrapBlockingBlock_mlcr8l, raw, rawListener); objc.objectRelease(raw.cast()); + objc.objectRelease(rawListener.cast()); return objc.ObjCBlock< ffi.Void Function(NSCondition, NSURLSession, NSURLSessionDownloadTask, objc.NSURL)>(wrapper, retain: false, release: true); @@ -81159,6 +90050,8 @@ const int TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA = -16330; const int TLS_PSK_WITH_CHACHA20_POLY1305_SHA256 = -13141; +const int TLS_ECDHE_PSK_WITH_CHACHA20_POLY1305_SHA256 = -13140; + const int TLS_NULL_WITH_NULL_NULL = 0; const int TLS_RSA_WITH_NULL_MD5 = 1; @@ -86251,6 +95144,8 @@ const int TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA1 = -16330; const int TLS_PSK_WITH_CHACHA20_POLY1305_SHA2561 = -13141; +const int TLS_ECDHE_PSK_WITH_CHACHA20_POLY1305_SHA2561 = -13140; + const int TLS_NULL_WITH_NULL_NULL1 = 0; const int TLS_RSA_WITH_NULL_MD51 = 1; @@ -86587,6 +95482,10 @@ const int __MAC_14_4 = 140400; const int __MAC_14_5 = 140500; +const int __MAC_15_0 = 150000; + +const int __MAC_15_1 = 150100; + const int __IPHONE_2_0 = 20000; const int __IPHONE_2_1 = 20100; @@ -86745,6 +95644,10 @@ const int __IPHONE_17_4 = 170400; const int __IPHONE_17_5 = 170500; +const int __IPHONE_18_0 = 180000; + +const int __IPHONE_18_1 = 180100; + const int __WATCHOS_1_0 = 10000; const int __WATCHOS_2_0 = 20000; @@ -86839,6 +95742,10 @@ const int __WATCHOS_10_4 = 100400; const int __WATCHOS_10_5 = 100500; +const int __WATCHOS_11_0 = 110000; + +const int __WATCHOS_11_1 = 110100; + const int __TVOS_9_0 = 90000; const int __TVOS_9_1 = 90100; @@ -86935,6 +95842,10 @@ const int __TVOS_17_4 = 170400; const int __TVOS_17_5 = 170500; +const int __TVOS_18_0 = 180000; + +const int __TVOS_18_1 = 180100; + const int __BRIDGEOS_2_0 = 20000; const int __BRIDGEOS_3_0 = 30000; @@ -86987,6 +95898,10 @@ const int __BRIDGEOS_8_4 = 80400; const int __BRIDGEOS_8_5 = 80500; +const int __BRIDGEOS_9_0 = 90000; + +const int __BRIDGEOS_9_1 = 90100; + const int __DRIVERKIT_19_0 = 190000; const int __DRIVERKIT_20_0 = 200000; @@ -87013,12 +95928,20 @@ const int __DRIVERKIT_23_4 = 230400; const int __DRIVERKIT_23_5 = 230500; +const int __DRIVERKIT_24_0 = 240000; + +const int __DRIVERKIT_24_1 = 240100; + const int __VISIONOS_1_0 = 10000; const int __VISIONOS_1_1 = 10100; const int __VISIONOS_1_2 = 10200; +const int __VISIONOS_2_0 = 20000; + +const int __VISIONOS_2_1 = 20100; + const int MAC_OS_X_VERSION_10_0 = 1000; const int MAC_OS_X_VERSION_10_1 = 1010; @@ -87141,9 +96064,13 @@ const int MAC_OS_VERSION_14_4 = 140400; const int MAC_OS_VERSION_14_5 = 140500; -const int __MAC_OS_X_VERSION_MIN_REQUIRED = 140000; +const int MAC_OS_VERSION_15_0 = 150000; -const int __MAC_OS_X_VERSION_MAX_ALLOWED = 140500; +const int MAC_OS_VERSION_15_1 = 150100; + +const int __MAC_OS_X_VERSION_MIN_REQUIRED = 150000; + +const int __MAC_OS_X_VERSION_MAX_ALLOWED = 150100; const int __ENABLE_LEGACY_MAC_AVAILABILITY = 1; @@ -87743,14 +96670,14 @@ const int __DARWIN_BIG_ENDIAN = 4321; const int __DARWIN_PDP_ENDIAN = 3412; -const int __DARWIN_BYTE_ORDER = 1234; - const int LITTLE_ENDIAN = 1234; const int BIG_ENDIAN = 4321; const int PDP_ENDIAN = 3412; +const int __DARWIN_BYTE_ORDER = 1234; + const int BYTE_ORDER = 1234; const int NULL = 0; @@ -87761,12 +96688,6 @@ const int EXIT_SUCCESS = 0; const int RAND_MAX = 2147483647; -const int MAC_OS_X_VERSION_MIN_REQUIRED = 140000; - -const int MAC_OS_X_VERSION_MAX_ALLOWED = 140000; - -const int __AVAILABILITY_MACROS_USES_AVAILABILITY = 1; - const int TARGET_OS_RTKIT = 0; const int TARGET_RT_LITTLE_ENDIAN = 1; @@ -87813,36 +96734,12 @@ const int NFDBITS = 32; const int FD_SETSIZE = 1024; -const int OBJC_API_VERSION = 2; - -const int OBJC_NO_GC = 1; - -const int NS_ENFORCE_NSOBJECT_DESIGNATED_INITIALIZER = 1; - -const int OBJC_OLD_DISPATCH_PROTOTYPES = 0; - const int __bool_true_false_are_defined = 1; const int true1 = 1; const int false1 = 0; -const int OBJC_BOOL_IS_BOOL = 1; - -const int YES = 1; - -const int NO = 0; - -const int NSIntegerMax = 9223372036854775807; - -const int NSIntegerMin = -9223372036854775808; - -const int NSUIntegerMax = -1; - -const int NSINTEGER_DEFINED = 1; - -const int __GNUC_VA_LIST = 1; - const int __DARWIN_CLK_TCK = 100; const int MB_LEN_MAX = 6; @@ -87899,184 +96796,8 @@ const int QUAD_MAX = 9223372036854775807; const int QUAD_MIN = -9223372036854775808; -const int ARG_MAX = 1048576; - -const int CHILD_MAX = 266; - -const int GID_MAX = 2147483647; - -const int LINK_MAX = 32767; - -const int MAX_CANON = 1024; - -const int MAX_INPUT = 1024; - -const int NAME_MAX = 255; - -const int NGROUPS_MAX = 16; - -const int UID_MAX = 2147483647; - -const int OPEN_MAX = 10240; - -const int PATH_MAX = 1024; - -const int PIPE_BUF = 512; - -const int BC_BASE_MAX = 99; - -const int BC_DIM_MAX = 2048; - -const int BC_SCALE_MAX = 99; - -const int BC_STRING_MAX = 1000; - -const int CHARCLASS_NAME_MAX = 14; - -const int COLL_WEIGHTS_MAX = 2; - -const int EQUIV_CLASS_MAX = 2; - -const int EXPR_NEST_MAX = 32; - -const int LINE_MAX = 2048; - -const int RE_DUP_MAX = 255; - -const int NZERO = 20; - -const int _POSIX_ARG_MAX = 4096; - -const int _POSIX_CHILD_MAX = 25; - -const int _POSIX_LINK_MAX = 8; - -const int _POSIX_MAX_CANON = 255; - -const int _POSIX_MAX_INPUT = 255; - -const int _POSIX_NAME_MAX = 14; - -const int _POSIX_NGROUPS_MAX = 8; - -const int _POSIX_OPEN_MAX = 20; - -const int _POSIX_PATH_MAX = 256; - -const int _POSIX_PIPE_BUF = 512; - -const int _POSIX_SSIZE_MAX = 32767; - -const int _POSIX_STREAM_MAX = 8; - -const int _POSIX_TZNAME_MAX = 6; - -const int _POSIX2_BC_BASE_MAX = 99; - -const int _POSIX2_BC_DIM_MAX = 2048; - -const int _POSIX2_BC_SCALE_MAX = 99; - -const int _POSIX2_BC_STRING_MAX = 1000; - -const int _POSIX2_EQUIV_CLASS_MAX = 2; - -const int _POSIX2_EXPR_NEST_MAX = 32; - -const int _POSIX2_LINE_MAX = 2048; - -const int _POSIX2_RE_DUP_MAX = 255; - -const int _POSIX_AIO_LISTIO_MAX = 2; - -const int _POSIX_AIO_MAX = 1; - -const int _POSIX_DELAYTIMER_MAX = 32; - -const int _POSIX_MQ_OPEN_MAX = 8; - -const int _POSIX_MQ_PRIO_MAX = 32; - -const int _POSIX_RTSIG_MAX = 8; - -const int _POSIX_SEM_NSEMS_MAX = 256; - -const int _POSIX_SEM_VALUE_MAX = 32767; - -const int _POSIX_SIGQUEUE_MAX = 32; - -const int _POSIX_TIMER_MAX = 32; - -const int _POSIX_CLOCKRES_MIN = 20000000; - -const int _POSIX_THREAD_DESTRUCTOR_ITERATIONS = 4; - const int _POSIX_THREAD_KEYS_MAX = 128; -const int _POSIX_THREAD_THREADS_MAX = 64; - -const int PTHREAD_DESTRUCTOR_ITERATIONS = 4; - -const int PTHREAD_KEYS_MAX = 512; - -const int PTHREAD_STACK_MIN = 16384; - -const int _POSIX_HOST_NAME_MAX = 255; - -const int _POSIX_LOGIN_NAME_MAX = 9; - -const int _POSIX_SS_REPL_MAX = 4; - -const int _POSIX_SYMLINK_MAX = 255; - -const int _POSIX_SYMLOOP_MAX = 8; - -const int _POSIX_TRACE_EVENT_NAME_MAX = 30; - -const int _POSIX_TRACE_NAME_MAX = 8; - -const int _POSIX_TRACE_SYS_MAX = 8; - -const int _POSIX_TRACE_USER_EVENT_MAX = 32; - -const int _POSIX_TTY_NAME_MAX = 9; - -const int _POSIX2_CHARCLASS_NAME_MAX = 14; - -const int _POSIX2_COLL_WEIGHTS_MAX = 2; - -const int _POSIX_RE_DUP_MAX = 255; - -const int OFF_MIN = -9223372036854775808; - -const int OFF_MAX = 9223372036854775807; - -const int PASS_MAX = 128; - -const int NL_ARGMAX = 9; - -const int NL_LANGMAX = 14; - -const int NL_MSGMAX = 32767; - -const int NL_NMAX = 1; - -const int NL_SETMAX = 255; - -const int NL_TEXTMAX = 2048; - -const int _XOPEN_IOV_MAX = 16; - -const int IOV_MAX = 1024; - -const int _XOPEN_NAME_MAX = 255; - -const int _XOPEN_PATH_MAX = 1024; - -const int NS_BLOCKS_AVAILABLE = 1; - -const int __COREFOUNDATION_CFAVAILABILITY__ = 1; - const int API_TO_BE_DEPRECATED = 100000; const int API_TO_BE_DEPRECATED_MACOS = 100000; @@ -88091,412 +96812,10 @@ const int API_TO_BE_DEPRECATED_DRIVERKIT = 100000; const int API_TO_BE_DEPRECATED_VISIONOS = 100000; -const int __CF_ENUM_FIXED_IS_AVAILABLE = 1; - -const double NSFoundationVersionNumber10_0 = 397.4; - -const double NSFoundationVersionNumber10_1 = 425.0; - -const double NSFoundationVersionNumber10_1_1 = 425.0; - -const double NSFoundationVersionNumber10_1_2 = 425.0; - -const double NSFoundationVersionNumber10_1_3 = 425.0; - -const double NSFoundationVersionNumber10_1_4 = 425.0; - -const double NSFoundationVersionNumber10_2 = 462.0; - -const double NSFoundationVersionNumber10_2_1 = 462.0; - -const double NSFoundationVersionNumber10_2_2 = 462.0; - -const double NSFoundationVersionNumber10_2_3 = 462.0; - -const double NSFoundationVersionNumber10_2_4 = 462.0; - -const double NSFoundationVersionNumber10_2_5 = 462.0; - -const double NSFoundationVersionNumber10_2_6 = 462.0; - -const double NSFoundationVersionNumber10_2_7 = 462.7; - -const double NSFoundationVersionNumber10_2_8 = 462.7; - -const double NSFoundationVersionNumber10_3 = 500.0; - -const double NSFoundationVersionNumber10_3_1 = 500.0; - -const double NSFoundationVersionNumber10_3_2 = 500.3; - -const double NSFoundationVersionNumber10_3_3 = 500.54; - -const double NSFoundationVersionNumber10_3_4 = 500.56; - -const double NSFoundationVersionNumber10_3_5 = 500.56; - -const double NSFoundationVersionNumber10_3_6 = 500.56; - -const double NSFoundationVersionNumber10_3_7 = 500.56; - -const double NSFoundationVersionNumber10_3_8 = 500.56; - -const double NSFoundationVersionNumber10_3_9 = 500.58; - -const double NSFoundationVersionNumber10_4 = 567.0; - -const double NSFoundationVersionNumber10_4_1 = 567.0; - -const double NSFoundationVersionNumber10_4_2 = 567.12; - -const double NSFoundationVersionNumber10_4_3 = 567.21; - -const double NSFoundationVersionNumber10_4_4_Intel = 567.23; - -const double NSFoundationVersionNumber10_4_4_PowerPC = 567.21; - -const double NSFoundationVersionNumber10_4_5 = 567.25; - -const double NSFoundationVersionNumber10_4_6 = 567.26; - -const double NSFoundationVersionNumber10_4_7 = 567.27; - -const double NSFoundationVersionNumber10_4_8 = 567.28; - -const double NSFoundationVersionNumber10_4_9 = 567.29; - -const double NSFoundationVersionNumber10_4_10 = 567.29; - -const double NSFoundationVersionNumber10_4_11 = 567.36; - -const double NSFoundationVersionNumber10_5 = 677.0; - -const double NSFoundationVersionNumber10_5_1 = 677.1; - -const double NSFoundationVersionNumber10_5_2 = 677.15; - -const double NSFoundationVersionNumber10_5_3 = 677.19; - -const double NSFoundationVersionNumber10_5_4 = 677.19; - -const double NSFoundationVersionNumber10_5_5 = 677.21; - -const double NSFoundationVersionNumber10_5_6 = 677.22; - -const double NSFoundationVersionNumber10_5_7 = 677.24; - -const double NSFoundationVersionNumber10_5_8 = 677.26; - -const double NSFoundationVersionNumber10_6 = 751.0; - -const double NSFoundationVersionNumber10_6_1 = 751.0; - -const double NSFoundationVersionNumber10_6_2 = 751.14; - -const double NSFoundationVersionNumber10_6_3 = 751.21; - -const double NSFoundationVersionNumber10_6_4 = 751.29; - -const double NSFoundationVersionNumber10_6_5 = 751.42; - -const double NSFoundationVersionNumber10_6_6 = 751.53; - -const double NSFoundationVersionNumber10_6_7 = 751.53; - -const double NSFoundationVersionNumber10_6_8 = 751.62; - -const double NSFoundationVersionNumber10_7 = 833.1; - -const double NSFoundationVersionNumber10_7_1 = 833.1; - -const double NSFoundationVersionNumber10_7_2 = 833.2; - -const double NSFoundationVersionNumber10_7_3 = 833.24; - -const double NSFoundationVersionNumber10_7_4 = 833.25; - -const double NSFoundationVersionNumber10_8 = 945.0; - -const double NSFoundationVersionNumber10_8_1 = 945.0; - -const double NSFoundationVersionNumber10_8_2 = 945.11; - -const double NSFoundationVersionNumber10_8_3 = 945.16; - -const double NSFoundationVersionNumber10_8_4 = 945.18; - -const int NSFoundationVersionNumber10_9 = 1056; - -const int NSFoundationVersionNumber10_9_1 = 1056; - -const double NSFoundationVersionNumber10_9_2 = 1056.13; - -const double NSFoundationVersionNumber10_10 = 1151.16; - -const double NSFoundationVersionNumber10_10_1 = 1151.16; - -const double NSFoundationVersionNumber10_10_2 = 1152.14; - -const double NSFoundationVersionNumber10_10_3 = 1153.2; - -const double NSFoundationVersionNumber10_10_4 = 1153.2; - -const int NSFoundationVersionNumber10_10_5 = 1154; - -const int NSFoundationVersionNumber10_10_Max = 1199; - -const int NSFoundationVersionNumber10_11 = 1252; - -const double NSFoundationVersionNumber10_11_1 = 1255.1; - -const double NSFoundationVersionNumber10_11_2 = 1256.1; - -const double NSFoundationVersionNumber10_11_3 = 1256.1; - -const int NSFoundationVersionNumber10_11_4 = 1258; - -const int NSFoundationVersionNumber10_11_Max = 1299; - -const int __COREFOUNDATION_CFBASE__ = 1; - -const int UNIVERSAL_INTERFACES_VERSION = 1024; - -const int PRAGMA_IMPORT = 0; - -const int PRAGMA_ONCE = 0; - -const int PRAGMA_STRUCT_PACK = 1; - -const int PRAGMA_STRUCT_PACKPUSH = 1; - -const int PRAGMA_STRUCT_ALIGN = 0; - -const int PRAGMA_ENUM_PACK = 0; - -const int PRAGMA_ENUM_ALWAYSINT = 0; - -const int PRAGMA_ENUM_OPTIONS = 0; - -const int TYPE_EXTENDED = 0; - -const int TYPE_LONGDOUBLE_IS_DOUBLE = 0; - -const int TYPE_LONGLONG = 1; - -const int FUNCTION_PASCAL = 0; - -const int FUNCTION_DECLSPEC = 0; - -const int FUNCTION_WIN32CC = 0; - -const int TARGET_API_MAC_OS8 = 0; - -const int TARGET_API_MAC_CARBON = 1; - -const int TARGET_API_MAC_OSX = 1; - -const int TARGET_CARBON = 1; - -const int OLDROUTINENAMES = 0; - -const int OPAQUE_TOOLBOX_STRUCTS = 1; - -const int OPAQUE_UPP_TYPES = 1; - -const int ACCESSOR_CALLS_ARE_FUNCTIONS = 1; - -const int CALL_NOT_IN_CARBON = 0; - -const int MIXEDMODE_CALLS_ARE_FUNCTIONS = 1; - -const int ALLOW_OBSOLETE_CARBON_MACMEMORY = 0; - -const int ALLOW_OBSOLETE_CARBON_OSUTILS = 0; - -const int kInvalidID = 0; - const int TRUE = 1; const int FALSE = 0; -const double kCFCoreFoundationVersionNumber10_0 = 196.4; - -const double kCFCoreFoundationVersionNumber10_0_3 = 196.5; - -const double kCFCoreFoundationVersionNumber10_1 = 226.0; - -const double kCFCoreFoundationVersionNumber10_1_1 = 226.0; - -const double kCFCoreFoundationVersionNumber10_1_2 = 227.2; - -const double kCFCoreFoundationVersionNumber10_1_3 = 227.2; - -const double kCFCoreFoundationVersionNumber10_1_4 = 227.3; - -const double kCFCoreFoundationVersionNumber10_2 = 263.0; - -const double kCFCoreFoundationVersionNumber10_2_1 = 263.1; - -const double kCFCoreFoundationVersionNumber10_2_2 = 263.1; - -const double kCFCoreFoundationVersionNumber10_2_3 = 263.3; - -const double kCFCoreFoundationVersionNumber10_2_4 = 263.3; - -const double kCFCoreFoundationVersionNumber10_2_5 = 263.5; - -const double kCFCoreFoundationVersionNumber10_2_6 = 263.5; - -const double kCFCoreFoundationVersionNumber10_2_7 = 263.5; - -const double kCFCoreFoundationVersionNumber10_2_8 = 263.5; - -const double kCFCoreFoundationVersionNumber10_3 = 299.0; - -const double kCFCoreFoundationVersionNumber10_3_1 = 299.0; - -const double kCFCoreFoundationVersionNumber10_3_2 = 299.0; - -const double kCFCoreFoundationVersionNumber10_3_3 = 299.3; - -const double kCFCoreFoundationVersionNumber10_3_4 = 299.31; - -const double kCFCoreFoundationVersionNumber10_3_5 = 299.31; - -const double kCFCoreFoundationVersionNumber10_3_6 = 299.32; - -const double kCFCoreFoundationVersionNumber10_3_7 = 299.33; - -const double kCFCoreFoundationVersionNumber10_3_8 = 299.33; - -const double kCFCoreFoundationVersionNumber10_3_9 = 299.35; - -const double kCFCoreFoundationVersionNumber10_4 = 368.0; - -const double kCFCoreFoundationVersionNumber10_4_1 = 368.1; - -const double kCFCoreFoundationVersionNumber10_4_2 = 368.11; - -const double kCFCoreFoundationVersionNumber10_4_3 = 368.18; - -const double kCFCoreFoundationVersionNumber10_4_4_Intel = 368.26; - -const double kCFCoreFoundationVersionNumber10_4_4_PowerPC = 368.25; - -const double kCFCoreFoundationVersionNumber10_4_5_Intel = 368.26; - -const double kCFCoreFoundationVersionNumber10_4_5_PowerPC = 368.25; - -const double kCFCoreFoundationVersionNumber10_4_6_Intel = 368.26; - -const double kCFCoreFoundationVersionNumber10_4_6_PowerPC = 368.25; - -const double kCFCoreFoundationVersionNumber10_4_7 = 368.27; - -const double kCFCoreFoundationVersionNumber10_4_8 = 368.27; - -const double kCFCoreFoundationVersionNumber10_4_9 = 368.28; - -const double kCFCoreFoundationVersionNumber10_4_10 = 368.28; - -const double kCFCoreFoundationVersionNumber10_4_11 = 368.31; - -const double kCFCoreFoundationVersionNumber10_5 = 476.0; - -const double kCFCoreFoundationVersionNumber10_5_1 = 476.0; - -const double kCFCoreFoundationVersionNumber10_5_2 = 476.1; - -const double kCFCoreFoundationVersionNumber10_5_3 = 476.13; - -const double kCFCoreFoundationVersionNumber10_5_4 = 476.14; - -const double kCFCoreFoundationVersionNumber10_5_5 = 476.15; - -const double kCFCoreFoundationVersionNumber10_5_6 = 476.17; - -const double kCFCoreFoundationVersionNumber10_5_7 = 476.18; - -const double kCFCoreFoundationVersionNumber10_5_8 = 476.19; - -const double kCFCoreFoundationVersionNumber10_6 = 550.0; - -const double kCFCoreFoundationVersionNumber10_6_1 = 550.0; - -const double kCFCoreFoundationVersionNumber10_6_2 = 550.13; - -const double kCFCoreFoundationVersionNumber10_6_3 = 550.19; - -const double kCFCoreFoundationVersionNumber10_6_4 = 550.29; - -const double kCFCoreFoundationVersionNumber10_6_5 = 550.42; - -const double kCFCoreFoundationVersionNumber10_6_6 = 550.42; - -const double kCFCoreFoundationVersionNumber10_6_7 = 550.42; - -const double kCFCoreFoundationVersionNumber10_6_8 = 550.43; - -const double kCFCoreFoundationVersionNumber10_7 = 635.0; - -const double kCFCoreFoundationVersionNumber10_7_1 = 635.0; - -const double kCFCoreFoundationVersionNumber10_7_2 = 635.15; - -const double kCFCoreFoundationVersionNumber10_7_3 = 635.19; - -const double kCFCoreFoundationVersionNumber10_7_4 = 635.21; - -const double kCFCoreFoundationVersionNumber10_7_5 = 635.21; - -const double kCFCoreFoundationVersionNumber10_8 = 744.0; - -const double kCFCoreFoundationVersionNumber10_8_1 = 744.0; - -const double kCFCoreFoundationVersionNumber10_8_2 = 744.12; - -const double kCFCoreFoundationVersionNumber10_8_3 = 744.18; - -const double kCFCoreFoundationVersionNumber10_8_4 = 744.19; - -const double kCFCoreFoundationVersionNumber10_9 = 855.11; - -const double kCFCoreFoundationVersionNumber10_9_1 = 855.11; - -const double kCFCoreFoundationVersionNumber10_9_2 = 855.14; - -const double kCFCoreFoundationVersionNumber10_10 = 1151.16; - -const double kCFCoreFoundationVersionNumber10_10_1 = 1151.16; - -const int kCFCoreFoundationVersionNumber10_10_2 = 1152; - -const double kCFCoreFoundationVersionNumber10_10_3 = 1153.18; - -const double kCFCoreFoundationVersionNumber10_10_4 = 1153.18; - -const double kCFCoreFoundationVersionNumber10_10_5 = 1153.18; - -const int kCFCoreFoundationVersionNumber10_10_Max = 1199; - -const int kCFCoreFoundationVersionNumber10_11 = 1253; - -const double kCFCoreFoundationVersionNumber10_11_1 = 1255.1; - -const double kCFCoreFoundationVersionNumber10_11_2 = 1256.14; - -const double kCFCoreFoundationVersionNumber10_11_3 = 1256.14; - -const double kCFCoreFoundationVersionNumber10_11_4 = 1258.1; - -const int kCFCoreFoundationVersionNumber10_11_Max = 1299; - -const int ISA_PTRAUTH_DISCRIMINATOR = 27361; - -const double NSTimeIntervalSince1970 = 978307200.0; - -const int __COREFOUNDATION_CFARRAY__ = 1; - const int OS_OBJECT_HAVE_OBJC_SUPPORT = 0; const int OS_OBJECT_USE_OBJC = 0; @@ -88505,472 +96824,6 @@ const int OS_OBJECT_SWIFT3 = 0; const int OS_OBJECT_USE_OBJC_RETAIN_RELEASE = 0; -const int SEC_OS_IPHONE = 0; - -const int SEC_OS_OSX = 1; - -const int SEC_OS_OSX_INCLUDES = 1; - -const int SECURITY_TYPE_UNIFICATION = 1; - -const int __COREFOUNDATION_COREFOUNDATION__ = 1; - -const int __COREFOUNDATION__ = 1; - -const String __ASSERT_FILE_NAME = 'temp_for_macros.hpp'; - -const int _CACHED_RUNES = 256; - -const int _CRMASK = -256; - -const String _RUNE_MAGIC_A = 'RuneMagA'; - -const int _CTYPE_A = 256; - -const int _CTYPE_C = 512; - -const int _CTYPE_D = 1024; - -const int _CTYPE_G = 2048; - -const int _CTYPE_L = 4096; - -const int _CTYPE_P = 8192; - -const int _CTYPE_S = 16384; - -const int _CTYPE_U = 32768; - -const int _CTYPE_X = 65536; - -const int _CTYPE_B = 131072; - -const int _CTYPE_R = 262144; - -const int _CTYPE_I = 524288; - -const int _CTYPE_T = 1048576; - -const int _CTYPE_Q = 2097152; - -const int _CTYPE_SW0 = 536870912; - -const int _CTYPE_SW1 = 1073741824; - -const int _CTYPE_SW2 = 2147483648; - -const int _CTYPE_SW3 = 3221225472; - -const int _CTYPE_SWM = 3758096384; - -const int _CTYPE_SWS = 30; - -const int EPERM = 1; - -const int ENOENT = 2; - -const int ESRCH = 3; - -const int EINTR = 4; - -const int EIO = 5; - -const int ENXIO = 6; - -const int E2BIG = 7; - -const int ENOEXEC = 8; - -const int EBADF = 9; - -const int ECHILD = 10; - -const int EDEADLK = 11; - -const int ENOMEM = 12; - -const int EACCES = 13; - -const int EFAULT = 14; - -const int ENOTBLK = 15; - -const int EBUSY = 16; - -const int EEXIST = 17; - -const int EXDEV = 18; - -const int ENODEV = 19; - -const int ENOTDIR = 20; - -const int EISDIR = 21; - -const int EINVAL = 22; - -const int ENFILE = 23; - -const int EMFILE = 24; - -const int ENOTTY = 25; - -const int ETXTBSY = 26; - -const int EFBIG = 27; - -const int ENOSPC = 28; - -const int ESPIPE = 29; - -const int EROFS = 30; - -const int EMLINK = 31; - -const int EPIPE = 32; - -const int EDOM = 33; - -const int ERANGE = 34; - -const int EAGAIN = 35; - -const int EWOULDBLOCK = 35; - -const int EINPROGRESS = 36; - -const int EALREADY = 37; - -const int ENOTSOCK = 38; - -const int EDESTADDRREQ = 39; - -const int EMSGSIZE = 40; - -const int EPROTOTYPE = 41; - -const int ENOPROTOOPT = 42; - -const int EPROTONOSUPPORT = 43; - -const int ESOCKTNOSUPPORT = 44; - -const int ENOTSUP = 45; - -const int EPFNOSUPPORT = 46; - -const int EAFNOSUPPORT = 47; - -const int EADDRINUSE = 48; - -const int EADDRNOTAVAIL = 49; - -const int ENETDOWN = 50; - -const int ENETUNREACH = 51; - -const int ENETRESET = 52; - -const int ECONNABORTED = 53; - -const int ECONNRESET = 54; - -const int ENOBUFS = 55; - -const int EISCONN = 56; - -const int ENOTCONN = 57; - -const int ESHUTDOWN = 58; - -const int ETOOMANYREFS = 59; - -const int ETIMEDOUT = 60; - -const int ECONNREFUSED = 61; - -const int ELOOP = 62; - -const int ENAMETOOLONG = 63; - -const int EHOSTDOWN = 64; - -const int EHOSTUNREACH = 65; - -const int ENOTEMPTY = 66; - -const int EPROCLIM = 67; - -const int EUSERS = 68; - -const int EDQUOT = 69; - -const int ESTALE = 70; - -const int EREMOTE = 71; - -const int EBADRPC = 72; - -const int ERPCMISMATCH = 73; - -const int EPROGUNAVAIL = 74; - -const int EPROGMISMATCH = 75; - -const int EPROCUNAVAIL = 76; - -const int ENOLCK = 77; - -const int ENOSYS = 78; - -const int EFTYPE = 79; - -const int EAUTH = 80; - -const int ENEEDAUTH = 81; - -const int EPWROFF = 82; - -const int EDEVERR = 83; - -const int EOVERFLOW = 84; - -const int EBADEXEC = 85; - -const int EBADARCH = 86; - -const int ESHLIBVERS = 87; - -const int EBADMACHO = 88; - -const int ECANCELED = 89; - -const int EIDRM = 90; - -const int ENOMSG = 91; - -const int EILSEQ = 92; - -const int ENOATTR = 93; - -const int EBADMSG = 94; - -const int EMULTIHOP = 95; - -const int ENODATA = 96; - -const int ENOLINK = 97; - -const int ENOSR = 98; - -const int ENOSTR = 99; - -const int EPROTO = 100; - -const int ETIME = 101; - -const int EOPNOTSUPP = 102; - -const int ENOPOLICY = 103; - -const int ENOTRECOVERABLE = 104; - -const int EOWNERDEAD = 105; - -const int EQFULL = 106; - -const int ELAST = 106; - -const int FLT_EVAL_METHOD = 0; - -const int FLT_RADIX = 2; - -const int FLT_MANT_DIG = 24; - -const int DBL_MANT_DIG = 53; - -const int LDBL_MANT_DIG = 53; - -const int FLT_DIG = 6; - -const int DBL_DIG = 15; - -const int LDBL_DIG = 15; - -const int FLT_MIN_EXP = -125; - -const int DBL_MIN_EXP = -1021; - -const int LDBL_MIN_EXP = -1021; - -const int FLT_MIN_10_EXP = -37; - -const int DBL_MIN_10_EXP = -307; - -const int LDBL_MIN_10_EXP = -307; - -const int FLT_MAX_EXP = 128; - -const int DBL_MAX_EXP = 1024; - -const int LDBL_MAX_EXP = 1024; - -const int FLT_MAX_10_EXP = 38; - -const int DBL_MAX_10_EXP = 308; - -const int LDBL_MAX_10_EXP = 308; - -const double FLT_MAX = 3.4028234663852886e+38; - -const double DBL_MAX = 1.7976931348623157e+308; - -const double LDBL_MAX = 1.7976931348623157e+308; - -const double FLT_EPSILON = 1.1920928955078125e-7; - -const double DBL_EPSILON = 2.220446049250313e-16; - -const double LDBL_EPSILON = 2.220446049250313e-16; - -const double FLT_MIN = 1.1754943508222875e-38; - -const double DBL_MIN = 2.2250738585072014e-308; - -const double LDBL_MIN = 2.2250738585072014e-308; - -const int DECIMAL_DIG = 17; - -const int FLT_HAS_SUBNORM = 1; - -const int DBL_HAS_SUBNORM = 1; - -const int LDBL_HAS_SUBNORM = 1; - -const double FLT_TRUE_MIN = 1.401298464324817e-45; - -const double DBL_TRUE_MIN = 5e-324; - -const double LDBL_TRUE_MIN = 5e-324; - -const int FLT_DECIMAL_DIG = 9; - -const int DBL_DECIMAL_DIG = 17; - -const int LDBL_DECIMAL_DIG = 17; - -const int LC_ALL = 0; - -const int LC_COLLATE = 1; - -const int LC_CTYPE = 2; - -const int LC_MONETARY = 3; - -const int LC_NUMERIC = 4; - -const int LC_TIME = 5; - -const int LC_MESSAGES = 6; - -const int _LC_LAST = 7; - -const double HUGE_VAL = double.infinity; - -const double HUGE_VALF = double.infinity; - -const double HUGE_VALL = double.infinity; - -const double NAN = double.nan; - -const double INFINITY = double.infinity; - -const int FP_NAN = 1; - -const int FP_INFINITE = 2; - -const int FP_ZERO = 3; - -const int FP_NORMAL = 4; - -const int FP_SUBNORMAL = 5; - -const int FP_SUPERNORMAL = 6; - -const int FP_FAST_FMA = 1; - -const int FP_FAST_FMAF = 1; - -const int FP_FAST_FMAL = 1; - -const int FP_ILOGB0 = -2147483648; - -const int FP_ILOGBNAN = -2147483648; - -const int MATH_ERRNO = 1; - -const int MATH_ERREXCEPT = 2; - -const double M_E = 2.718281828459045; - -const double M_LOG2E = 1.4426950408889634; - -const double M_LOG10E = 0.4342944819032518; - -const double M_LN2 = 0.6931471805599453; - -const double M_LN10 = 2.302585092994046; - -const double M_PI = 3.141592653589793; - -const double M_PI_2 = 1.5707963267948966; - -const double M_PI_4 = 0.7853981633974483; - -const double M_1_PI = 0.3183098861837907; - -const double M_2_PI = 0.6366197723675814; - -const double M_2_SQRTPI = 1.1283791670955126; - -const double M_SQRT2 = 1.4142135623730951; - -const double M_SQRT1_2 = 0.7071067811865476; - -const double MAXFLOAT = 3.4028234663852886e+38; - -const int FP_SNAN = 1; - -const int FP_QNAN = 1; - -const double HUGE = 3.4028234663852886e+38; - -const double X_TLOSS = 14148475504056880.0; - -const int DOMAIN = 1; - -const int SING = 2; - -const int OVERFLOW = 3; - -const int UNDERFLOW = 4; - -const int TLOSS = 5; - -const int PLOSS = 6; - -const int _JBLEN = 48; - -const int RENAME_SECLUDE = 1; - -const int RENAME_SWAP = 2; - -const int RENAME_EXCL = 4; - -const int RENAME_RESERVED1 = 8; - -const int RENAME_NOFOLLOW_ANY = 16; - const int SEEK_SET = 0; const int SEEK_CUR = 1; @@ -88981,144 +96834,6 @@ const int SEEK_HOLE = 3; const int SEEK_DATA = 4; -const int __SLBF = 1; - -const int __SNBF = 2; - -const int __SRD = 4; - -const int __SWR = 8; - -const int __SRW = 16; - -const int __SEOF = 32; - -const int __SERR = 64; - -const int __SMBF = 128; - -const int __SAPP = 256; - -const int __SSTR = 512; - -const int __SOPT = 1024; - -const int __SNPT = 2048; - -const int __SOFF = 4096; - -const int __SMOD = 8192; - -const int __SALC = 16384; - -const int __SIGN = 32768; - -const int _IOFBF = 0; - -const int _IOLBF = 1; - -const int _IONBF = 2; - -const int BUFSIZ = 1024; - -const int EOF = -1; - -const int FOPEN_MAX = 20; - -const int FILENAME_MAX = 1024; - -const String P_tmpdir = '/var/tmp/'; - -const int L_tmpnam = 1024; - -const int TMP_MAX = 308915776; - -const int L_ctermid = 1024; - -const int CLOCKS_PER_SEC = 1000000; - -const int CLOCK_REALTIME = 0; - -const int CLOCK_MONOTONIC = 6; - -const int CLOCK_MONOTONIC_RAW = 4; - -const int CLOCK_MONOTONIC_RAW_APPROX = 5; - -const int CLOCK_UPTIME_RAW = 8; - -const int CLOCK_UPTIME_RAW_APPROX = 9; - -const int CLOCK_PROCESS_CPUTIME_ID = 12; - -const int CLOCK_THREAD_CPUTIME_ID = 16; - -const int TIME_UTC = 1; - -const int __COREFOUNDATION_CFBAG__ = 1; - -const int __COREFOUNDATION_CFBINARYHEAP__ = 1; - -const int __COREFOUNDATION_CFBITVECTOR__ = 1; - -const int __COREFOUNDATION_CFBYTEORDER__ = 1; - -const int CF_USE_OSBYTEORDER_H = 1; - -const int __COREFOUNDATION_CFCALENDAR__ = 1; - -const int __COREFOUNDATION_CFLOCALE__ = 1; - -const int __COREFOUNDATION_CFDICTIONARY__ = 1; - -const int __COREFOUNDATION_CFNOTIFICATIONCENTER__ = 1; - -const int __COREFOUNDATION_CFDATE__ = 1; - -const int __COREFOUNDATION_CFTIMEZONE__ = 1; - -const int __COREFOUNDATION_CFDATA__ = 1; - -const int __COREFOUNDATION_CFSTRING__ = 1; - -const int __COREFOUNDATION_CFCHARACTERSET__ = 1; - -const int __COREFOUNDATION_CFERROR__ = 1; - -const int kCFStringEncodingInvalidId = 4294967295; - -const int __kCFStringInlineBufferLength = 64; - -const int __COREFOUNDATION_CFCGTYPES__ = 1; - -const int CGFLOAT_IS_DOUBLE = 1; - -const double CGFLOAT_MIN = 2.2250738585072014e-308; - -const double CGFLOAT_MAX = 1.7976931348623157e+308; - -const double CGFLOAT_EPSILON = 2.220446049250313e-16; - -const int CGFLOAT_DEFINED = 1; - -const int CGVECTOR_DEFINED = 1; - -const int __COREFOUNDATION_CFDATEFORMATTER__ = 1; - -const int __COREFOUNDATION_CFNUMBER__ = 1; - -const int __COREFOUNDATION_CFNUMBERFORMATTER__ = 1; - -const int __COREFOUNDATION_CFPREFERENCES__ = 1; - -const int __COREFOUNDATION_CFPROPERTYLIST__ = 1; - -const int __COREFOUNDATION_CFSTREAM__ = 1; - -const int __COREFOUNDATION_CFURL__ = 1; - -const int __COREFOUNDATION_CFRUNLOOP__ = 1; - const int MACH_PORT_NULL = 0; const int MACH_PORT_DEAD = 4294967295; @@ -89151,6 +96866,12 @@ const int MACH_PORT_TYPE_DEAD_NAME = 1048576; const int MACH_PORT_TYPE_LABELH = 2097152; +const int MACH_PORT_TYPE_DNREQUEST = 2147483648; + +const int MACH_PORT_TYPE_SPREQUEST = 1073741824; + +const int MACH_PORT_TYPE_SPREQUEST_DELAYED = 536870912; + const int MACH_PORT_TYPE_SEND_RECEIVE = 196608; const int MACH_PORT_TYPE_SEND_RIGHTS = 327680; @@ -89161,12 +96882,6 @@ const int MACH_PORT_TYPE_PORT_OR_DEAD = 1507328; const int MACH_PORT_TYPE_ALL_RIGHTS = 2031616; -const int MACH_PORT_TYPE_DNREQUEST = 2147483648; - -const int MACH_PORT_TYPE_SPREQUEST = 1073741824; - -const int MACH_PORT_TYPE_SPREQUEST_DELAYED = 536870912; - const int MACH_PORT_SRIGHTS_NONE = 0; const int MACH_PORT_SRIGHTS_PRESENT = 1; @@ -89267,7 +96982,7 @@ const int MPO_ENFORCE_REPLY_PORT_SEMANTICS = 8192; const int MPO_PROVISIONAL_REPLY_PORT = 16384; -const int MPO_PROVISIONAL_ID_PROT_OPTOUT = 32768; +const int MPO_EXCEPTION_PORT = 32768; const int GUARD_TYPE_MACH_PORT = 1; @@ -89301,8 +97016,6 @@ const int MPG_STRICT = 1; const int MPG_IMMOVABLE_RECEIVE = 2; -const int __COREFOUNDATION_CFSOCKET__ = 1; - const int _POSIX_VERSION = 200112; const int _POSIX2_VERSION = 200112; @@ -90149,6 +97862,8 @@ const int F_TRANSFEREXTENTS = 110; const int F_ATTRIBUTION_TAG = 111; +const int F_ADDSIGS_MAIN_BINARY = 113; + const int FCNTL_FS_SPECIFIC_BASE = 65536; const int F_DUPFD_CLOEXEC = 67; @@ -90763,924 +98478,4 @@ const int DISPATCH_IO_STOP = 1; const int DISPATCH_IO_STRICT_INTERVAL = 1; -const int __COREFOUNDATION_CFSET__ = 1; - -const int __COREFOUNDATION_CFSTRINGENCODINGEXT__ = 1; - -const int __COREFOUNDATION_CFTREE__ = 1; - -const int __COREFOUNDATION_CFURLACCESS__ = 1; - -const int __COREFOUNDATION_CFUUID__ = 1; - -const int __COREFOUNDATION_CFUTILITIES__ = 1; - -const int __COREFOUNDATION_CFBUNDLE__ = 1; - -const int CPU_STATE_MAX = 4; - -const int CPU_STATE_USER = 0; - -const int CPU_STATE_SYSTEM = 1; - -const int CPU_STATE_IDLE = 2; - -const int CPU_STATE_NICE = 3; - -const int CPU_ARCH_MASK = 4278190080; - -const int CPU_ARCH_ABI64 = 16777216; - -const int CPU_ARCH_ABI64_32 = 33554432; - -const int CPU_TYPE_ANY = -1; - -const int CPU_TYPE_VAX = 1; - -const int CPU_TYPE_MC680x0 = 6; - -const int CPU_TYPE_X86 = 7; - -const int CPU_TYPE_I386 = 7; - -const int CPU_TYPE_X86_64 = 16777223; - -const int CPU_TYPE_MC98000 = 10; - -const int CPU_TYPE_HPPA = 11; - -const int CPU_TYPE_ARM = 12; - -const int CPU_TYPE_ARM64 = 16777228; - -const int CPU_TYPE_ARM64_32 = 33554444; - -const int CPU_TYPE_MC88000 = 13; - -const int CPU_TYPE_SPARC = 14; - -const int CPU_TYPE_I860 = 15; - -const int CPU_TYPE_POWERPC = 18; - -const int CPU_TYPE_POWERPC64 = 16777234; - -const int CPU_SUBTYPE_MASK = 4278190080; - -const int CPU_SUBTYPE_LIB64 = 2147483648; - -const int CPU_SUBTYPE_PTRAUTH_ABI = 2147483648; - -const int CPU_SUBTYPE_ANY = -1; - -const int CPU_SUBTYPE_MULTIPLE = -1; - -const int CPU_SUBTYPE_LITTLE_ENDIAN = 0; - -const int CPU_SUBTYPE_BIG_ENDIAN = 1; - -const int CPU_THREADTYPE_NONE = 0; - -const int CPU_SUBTYPE_VAX_ALL = 0; - -const int CPU_SUBTYPE_VAX780 = 1; - -const int CPU_SUBTYPE_VAX785 = 2; - -const int CPU_SUBTYPE_VAX750 = 3; - -const int CPU_SUBTYPE_VAX730 = 4; - -const int CPU_SUBTYPE_UVAXI = 5; - -const int CPU_SUBTYPE_UVAXII = 6; - -const int CPU_SUBTYPE_VAX8200 = 7; - -const int CPU_SUBTYPE_VAX8500 = 8; - -const int CPU_SUBTYPE_VAX8600 = 9; - -const int CPU_SUBTYPE_VAX8650 = 10; - -const int CPU_SUBTYPE_VAX8800 = 11; - -const int CPU_SUBTYPE_UVAXIII = 12; - -const int CPU_SUBTYPE_MC680x0_ALL = 1; - -const int CPU_SUBTYPE_MC68030 = 1; - -const int CPU_SUBTYPE_MC68040 = 2; - -const int CPU_SUBTYPE_MC68030_ONLY = 3; - -const int CPU_SUBTYPE_I386_ALL = 3; - -const int CPU_SUBTYPE_386 = 3; - -const int CPU_SUBTYPE_486 = 4; - -const int CPU_SUBTYPE_486SX = 132; - -const int CPU_SUBTYPE_586 = 5; - -const int CPU_SUBTYPE_PENT = 5; - -const int CPU_SUBTYPE_PENTPRO = 22; - -const int CPU_SUBTYPE_PENTII_M3 = 54; - -const int CPU_SUBTYPE_PENTII_M5 = 86; - -const int CPU_SUBTYPE_CELERON = 103; - -const int CPU_SUBTYPE_CELERON_MOBILE = 119; - -const int CPU_SUBTYPE_PENTIUM_3 = 8; - -const int CPU_SUBTYPE_PENTIUM_3_M = 24; - -const int CPU_SUBTYPE_PENTIUM_3_XEON = 40; - -const int CPU_SUBTYPE_PENTIUM_M = 9; - -const int CPU_SUBTYPE_PENTIUM_4 = 10; - -const int CPU_SUBTYPE_PENTIUM_4_M = 26; - -const int CPU_SUBTYPE_ITANIUM = 11; - -const int CPU_SUBTYPE_ITANIUM_2 = 27; - -const int CPU_SUBTYPE_XEON = 12; - -const int CPU_SUBTYPE_XEON_MP = 28; - -const int CPU_SUBTYPE_INTEL_FAMILY_MAX = 15; - -const int CPU_SUBTYPE_INTEL_MODEL_ALL = 0; - -const int CPU_SUBTYPE_X86_ALL = 3; - -const int CPU_SUBTYPE_X86_64_ALL = 3; - -const int CPU_SUBTYPE_X86_ARCH1 = 4; - -const int CPU_SUBTYPE_X86_64_H = 8; - -const int CPU_THREADTYPE_INTEL_HTT = 1; - -const int CPU_SUBTYPE_MIPS_ALL = 0; - -const int CPU_SUBTYPE_MIPS_R2300 = 1; - -const int CPU_SUBTYPE_MIPS_R2600 = 2; - -const int CPU_SUBTYPE_MIPS_R2800 = 3; - -const int CPU_SUBTYPE_MIPS_R2000a = 4; - -const int CPU_SUBTYPE_MIPS_R2000 = 5; - -const int CPU_SUBTYPE_MIPS_R3000a = 6; - -const int CPU_SUBTYPE_MIPS_R3000 = 7; - -const int CPU_SUBTYPE_MC98000_ALL = 0; - -const int CPU_SUBTYPE_MC98601 = 1; - -const int CPU_SUBTYPE_HPPA_ALL = 0; - -const int CPU_SUBTYPE_HPPA_7100 = 0; - -const int CPU_SUBTYPE_HPPA_7100LC = 1; - -const int CPU_SUBTYPE_MC88000_ALL = 0; - -const int CPU_SUBTYPE_MC88100 = 1; - -const int CPU_SUBTYPE_MC88110 = 2; - -const int CPU_SUBTYPE_SPARC_ALL = 0; - -const int CPU_SUBTYPE_I860_ALL = 0; - -const int CPU_SUBTYPE_I860_860 = 1; - -const int CPU_SUBTYPE_POWERPC_ALL = 0; - -const int CPU_SUBTYPE_POWERPC_601 = 1; - -const int CPU_SUBTYPE_POWERPC_602 = 2; - -const int CPU_SUBTYPE_POWERPC_603 = 3; - -const int CPU_SUBTYPE_POWERPC_603e = 4; - -const int CPU_SUBTYPE_POWERPC_603ev = 5; - -const int CPU_SUBTYPE_POWERPC_604 = 6; - -const int CPU_SUBTYPE_POWERPC_604e = 7; - -const int CPU_SUBTYPE_POWERPC_620 = 8; - -const int CPU_SUBTYPE_POWERPC_750 = 9; - -const int CPU_SUBTYPE_POWERPC_7400 = 10; - -const int CPU_SUBTYPE_POWERPC_7450 = 11; - -const int CPU_SUBTYPE_POWERPC_970 = 100; - -const int CPU_SUBTYPE_ARM_ALL = 0; - -const int CPU_SUBTYPE_ARM_V4T = 5; - -const int CPU_SUBTYPE_ARM_V6 = 6; - -const int CPU_SUBTYPE_ARM_V5TEJ = 7; - -const int CPU_SUBTYPE_ARM_XSCALE = 8; - -const int CPU_SUBTYPE_ARM_V7 = 9; - -const int CPU_SUBTYPE_ARM_V7F = 10; - -const int CPU_SUBTYPE_ARM_V7S = 11; - -const int CPU_SUBTYPE_ARM_V7K = 12; - -const int CPU_SUBTYPE_ARM_V8 = 13; - -const int CPU_SUBTYPE_ARM_V6M = 14; - -const int CPU_SUBTYPE_ARM_V7M = 15; - -const int CPU_SUBTYPE_ARM_V7EM = 16; - -const int CPU_SUBTYPE_ARM_V8M = 17; - -const int CPU_SUBTYPE_ARM64_ALL = 0; - -const int CPU_SUBTYPE_ARM64_V8 = 1; - -const int CPU_SUBTYPE_ARM64E = 2; - -const int CPU_SUBTYPE_ARM64_PTR_AUTH_MASK = 251658240; - -const int CPU_SUBTYPE_ARM64_32_ALL = 0; - -const int CPU_SUBTYPE_ARM64_32_V8 = 1; - -const int CPUFAMILY_UNKNOWN = 0; - -const int CPUFAMILY_POWERPC_G3 = 3471054153; - -const int CPUFAMILY_POWERPC_G4 = 2009171118; - -const int CPUFAMILY_POWERPC_G5 = 3983988906; - -const int CPUFAMILY_INTEL_6_13 = 2855483691; - -const int CPUFAMILY_INTEL_PENRYN = 2028621756; - -const int CPUFAMILY_INTEL_NEHALEM = 1801080018; - -const int CPUFAMILY_INTEL_WESTMERE = 1463508716; - -const int CPUFAMILY_INTEL_SANDYBRIDGE = 1418770316; - -const int CPUFAMILY_INTEL_IVYBRIDGE = 526772277; - -const int CPUFAMILY_INTEL_HASWELL = 280134364; - -const int CPUFAMILY_INTEL_BROADWELL = 1479463068; - -const int CPUFAMILY_INTEL_SKYLAKE = 939270559; - -const int CPUFAMILY_INTEL_KABYLAKE = 260141638; - -const int CPUFAMILY_INTEL_ICELAKE = 943936839; - -const int CPUFAMILY_INTEL_COMETLAKE = 486055998; - -const int CPUFAMILY_ARM_9 = 3878847406; - -const int CPUFAMILY_ARM_11 = 2415272152; - -const int CPUFAMILY_ARM_XSCALE = 1404044789; - -const int CPUFAMILY_ARM_12 = 3172666089; - -const int CPUFAMILY_ARM_13 = 214503012; - -const int CPUFAMILY_ARM_14 = 2517073649; - -const int CPUFAMILY_ARM_15 = 2823887818; - -const int CPUFAMILY_ARM_SWIFT = 506291073; - -const int CPUFAMILY_ARM_CYCLONE = 933271106; - -const int CPUFAMILY_ARM_TYPHOON = 747742334; - -const int CPUFAMILY_ARM_TWISTER = 2465937352; - -const int CPUFAMILY_ARM_HURRICANE = 1741614739; - -const int CPUFAMILY_ARM_MONSOON_MISTRAL = 3894312694; - -const int CPUFAMILY_ARM_VORTEX_TEMPEST = 131287967; - -const int CPUFAMILY_ARM_LIGHTNING_THUNDER = 1176831186; - -const int CPUFAMILY_ARM_FIRESTORM_ICESTORM = 458787763; - -const int CPUFAMILY_ARM_BLIZZARD_AVALANCHE = 3660830781; - -const int CPUFAMILY_ARM_EVEREST_SAWTOOTH = 2271604202; - -const int CPUFAMILY_ARM_IBIZA = 4197663070; - -const int CPUFAMILY_ARM_PALMA = 1912690738; - -const int CPUFAMILY_ARM_COLL = 678884789; - -const int CPUFAMILY_ARM_LOBOS = 1598941843; - -const int CPUFAMILY_ARM_DONAN = 1867590060; - -const int CPUSUBFAMILY_UNKNOWN = 0; - -const int CPUSUBFAMILY_ARM_HP = 1; - -const int CPUSUBFAMILY_ARM_HG = 2; - -const int CPUSUBFAMILY_ARM_M = 3; - -const int CPUSUBFAMILY_ARM_HS = 4; - -const int CPUSUBFAMILY_ARM_HC_HD = 5; - -const int CPUSUBFAMILY_ARM_HA = 6; - -const int CPUFAMILY_INTEL_6_23 = 2028621756; - -const int CPUFAMILY_INTEL_6_26 = 1801080018; - -const int __COREFOUNDATION_CFMESSAGEPORT__ = 1; - -const int __COREFOUNDATION_CFPLUGIN__ = 1; - -const int COREFOUNDATION_CFPLUGINCOM_SEPARATE = 1; - -const int __COREFOUNDATION_CFMACHPORT__ = 1; - -const int __COREFOUNDATION_CFATTRIBUTEDSTRING__ = 1; - -const int __COREFOUNDATION_CFURLENUMERATOR__ = 1; - -const int __COREFOUNDATION_CFFILESECURITY__ = 1; - -const int KAUTH_GUID_SIZE = 16; - -const int KAUTH_UID_NONE = 4294967195; - -const int KAUTH_GID_NONE = 4294967195; - -const int KAUTH_NTSID_MAX_AUTHORITIES = 16; - -const int KAUTH_NTSID_HDRSIZE = 8; - -const int KAUTH_EXTLOOKUP_SUCCESS = 0; - -const int KAUTH_EXTLOOKUP_BADRQ = 1; - -const int KAUTH_EXTLOOKUP_FAILURE = 2; - -const int KAUTH_EXTLOOKUP_FATAL = 3; - -const int KAUTH_EXTLOOKUP_INPROG = 100; - -const int KAUTH_EXTLOOKUP_VALID_UID = 1; - -const int KAUTH_EXTLOOKUP_VALID_UGUID = 2; - -const int KAUTH_EXTLOOKUP_VALID_USID = 4; - -const int KAUTH_EXTLOOKUP_VALID_GID = 8; - -const int KAUTH_EXTLOOKUP_VALID_GGUID = 16; - -const int KAUTH_EXTLOOKUP_VALID_GSID = 32; - -const int KAUTH_EXTLOOKUP_WANT_UID = 64; - -const int KAUTH_EXTLOOKUP_WANT_UGUID = 128; - -const int KAUTH_EXTLOOKUP_WANT_USID = 256; - -const int KAUTH_EXTLOOKUP_WANT_GID = 512; - -const int KAUTH_EXTLOOKUP_WANT_GGUID = 1024; - -const int KAUTH_EXTLOOKUP_WANT_GSID = 2048; - -const int KAUTH_EXTLOOKUP_WANT_MEMBERSHIP = 4096; - -const int KAUTH_EXTLOOKUP_VALID_MEMBERSHIP = 8192; - -const int KAUTH_EXTLOOKUP_ISMEMBER = 16384; - -const int KAUTH_EXTLOOKUP_VALID_PWNAM = 32768; - -const int KAUTH_EXTLOOKUP_WANT_PWNAM = 65536; - -const int KAUTH_EXTLOOKUP_VALID_GRNAM = 131072; - -const int KAUTH_EXTLOOKUP_WANT_GRNAM = 262144; - -const int KAUTH_EXTLOOKUP_VALID_SUPGRPS = 524288; - -const int KAUTH_EXTLOOKUP_WANT_SUPGRPS = 1048576; - -const int KAUTH_EXTLOOKUP_REGISTER = 0; - -const int KAUTH_EXTLOOKUP_RESULT = 1; - -const int KAUTH_EXTLOOKUP_WORKER = 2; - -const int KAUTH_EXTLOOKUP_DEREGISTER = 4; - -const int KAUTH_GET_CACHE_SIZES = 8; - -const int KAUTH_SET_CACHE_SIZES = 16; - -const int KAUTH_CLEAR_CACHES = 32; - -const String IDENTITYSVC_ENTITLEMENT = 'com.apple.private.identitysvc'; - -const int KAUTH_ACE_KINDMASK = 15; - -const int KAUTH_ACE_PERMIT = 1; - -const int KAUTH_ACE_DENY = 2; - -const int KAUTH_ACE_AUDIT = 3; - -const int KAUTH_ACE_ALARM = 4; - -const int KAUTH_ACE_INHERITED = 16; - -const int KAUTH_ACE_FILE_INHERIT = 32; - -const int KAUTH_ACE_DIRECTORY_INHERIT = 64; - -const int KAUTH_ACE_LIMIT_INHERIT = 128; - -const int KAUTH_ACE_ONLY_INHERIT = 256; - -const int KAUTH_ACE_SUCCESS = 512; - -const int KAUTH_ACE_FAILURE = 1024; - -const int KAUTH_ACE_INHERIT_CONTROL_FLAGS = 480; - -const int KAUTH_ACE_GENERIC_ALL = 2097152; - -const int KAUTH_ACE_GENERIC_EXECUTE = 4194304; - -const int KAUTH_ACE_GENERIC_WRITE = 8388608; - -const int KAUTH_ACE_GENERIC_READ = 16777216; - -const int KAUTH_ACL_MAX_ENTRIES = 128; - -const int KAUTH_ACL_FLAGS_PRIVATE = 65535; - -const int KAUTH_ACL_DEFER_INHERIT = 65536; - -const int KAUTH_ACL_NO_INHERIT = 131072; - -const int KAUTH_FILESEC_NOACL = 4294967295; - -const int KAUTH_FILESEC_MAGIC = 19710317; - -const int KAUTH_FILESEC_FLAGS_PRIVATE = 65535; - -const int KAUTH_FILESEC_DEFER_INHERIT = 65536; - -const int KAUTH_FILESEC_NO_INHERIT = 131072; - -const String KAUTH_FILESEC_XATTR = 'com.apple.system.Security'; - -const int KAUTH_ENDIAN_HOST = 1; - -const int KAUTH_ENDIAN_DISK = 2; - -const int KAUTH_VNODE_READ_DATA = 2; - -const int KAUTH_VNODE_LIST_DIRECTORY = 2; - -const int KAUTH_VNODE_WRITE_DATA = 4; - -const int KAUTH_VNODE_ADD_FILE = 4; - -const int KAUTH_VNODE_EXECUTE = 8; - -const int KAUTH_VNODE_SEARCH = 8; - -const int KAUTH_VNODE_DELETE = 16; - -const int KAUTH_VNODE_APPEND_DATA = 32; - -const int KAUTH_VNODE_ADD_SUBDIRECTORY = 32; - -const int KAUTH_VNODE_DELETE_CHILD = 64; - -const int KAUTH_VNODE_READ_ATTRIBUTES = 128; - -const int KAUTH_VNODE_WRITE_ATTRIBUTES = 256; - -const int KAUTH_VNODE_READ_EXTATTRIBUTES = 512; - -const int KAUTH_VNODE_WRITE_EXTATTRIBUTES = 1024; - -const int KAUTH_VNODE_READ_SECURITY = 2048; - -const int KAUTH_VNODE_WRITE_SECURITY = 4096; - -const int KAUTH_VNODE_TAKE_OWNERSHIP = 8192; - -const int KAUTH_VNODE_CHANGE_OWNER = 8192; - -const int KAUTH_VNODE_SYNCHRONIZE = 1048576; - -const int KAUTH_VNODE_LINKTARGET = 33554432; - -const int KAUTH_VNODE_CHECKIMMUTABLE = 67108864; - -const int KAUTH_VNODE_ACCESS = 2147483648; - -const int KAUTH_VNODE_NOIMMUTABLE = 1073741824; - -const int KAUTH_VNODE_SEARCHBYANYONE = 536870912; - -const int KAUTH_VNODE_GENERIC_READ_BITS = 2690; - -const int KAUTH_VNODE_GENERIC_WRITE_BITS = 5492; - -const int KAUTH_VNODE_GENERIC_EXECUTE_BITS = 8; - -const int KAUTH_VNODE_GENERIC_ALL_BITS = 8190; - -const int KAUTH_VNODE_WRITE_RIGHTS = 100676980; - -const int __DARWIN_ACL_READ_DATA = 2; - -const int __DARWIN_ACL_LIST_DIRECTORY = 2; - -const int __DARWIN_ACL_WRITE_DATA = 4; - -const int __DARWIN_ACL_ADD_FILE = 4; - -const int __DARWIN_ACL_EXECUTE = 8; - -const int __DARWIN_ACL_SEARCH = 8; - -const int __DARWIN_ACL_DELETE = 16; - -const int __DARWIN_ACL_APPEND_DATA = 32; - -const int __DARWIN_ACL_ADD_SUBDIRECTORY = 32; - -const int __DARWIN_ACL_DELETE_CHILD = 64; - -const int __DARWIN_ACL_READ_ATTRIBUTES = 128; - -const int __DARWIN_ACL_WRITE_ATTRIBUTES = 256; - -const int __DARWIN_ACL_READ_EXTATTRIBUTES = 512; - -const int __DARWIN_ACL_WRITE_EXTATTRIBUTES = 1024; - -const int __DARWIN_ACL_READ_SECURITY = 2048; - -const int __DARWIN_ACL_WRITE_SECURITY = 4096; - -const int __DARWIN_ACL_CHANGE_OWNER = 8192; - -const int __DARWIN_ACL_SYNCHRONIZE = 1048576; - -const int __DARWIN_ACL_EXTENDED_ALLOW = 1; - -const int __DARWIN_ACL_EXTENDED_DENY = 2; - -const int __DARWIN_ACL_ENTRY_INHERITED = 16; - -const int __DARWIN_ACL_ENTRY_FILE_INHERIT = 32; - -const int __DARWIN_ACL_ENTRY_DIRECTORY_INHERIT = 64; - -const int __DARWIN_ACL_ENTRY_LIMIT_INHERIT = 128; - -const int __DARWIN_ACL_ENTRY_ONLY_INHERIT = 256; - -const int __DARWIN_ACL_FLAG_NO_INHERIT = 131072; - -const int ACL_MAX_ENTRIES = 128; - -const int ACL_UNDEFINED_ID = 0; - -const int __COREFOUNDATION_CFSTRINGTOKENIZER__ = 1; - -const int __COREFOUNDATION_CFFILEDESCRIPTOR__ = 1; - -const int __COREFOUNDATION_CFUSERNOTIFICATION__ = 1; - -const int __COREFOUNDATION_CFXMLNODE__ = 1; - -const int __COREFOUNDATION_CFXMLPARSER__ = 1; - -const int _CSSMTYPE_H_ = 1; - -const int _CSSMCONFIG_H_ = 1; - -const int SEC_ASN1_TAG_MASK = 255; - -const int SEC_ASN1_TAGNUM_MASK = 31; - -const int SEC_ASN1_BOOLEAN = 1; - -const int SEC_ASN1_INTEGER = 2; - -const int SEC_ASN1_BIT_STRING = 3; - -const int SEC_ASN1_OCTET_STRING = 4; - -const int SEC_ASN1_NULL = 5; - -const int SEC_ASN1_OBJECT_ID = 6; - -const int SEC_ASN1_OBJECT_DESCRIPTOR = 7; - -const int SEC_ASN1_REAL = 9; - -const int SEC_ASN1_ENUMERATED = 10; - -const int SEC_ASN1_EMBEDDED_PDV = 11; - -const int SEC_ASN1_UTF8_STRING = 12; - -const int SEC_ASN1_SEQUENCE = 16; - -const int SEC_ASN1_SET = 17; - -const int SEC_ASN1_NUMERIC_STRING = 18; - -const int SEC_ASN1_PRINTABLE_STRING = 19; - -const int SEC_ASN1_T61_STRING = 20; - -const int SEC_ASN1_VIDEOTEX_STRING = 21; - -const int SEC_ASN1_IA5_STRING = 22; - -const int SEC_ASN1_UTC_TIME = 23; - -const int SEC_ASN1_GENERALIZED_TIME = 24; - -const int SEC_ASN1_GRAPHIC_STRING = 25; - -const int SEC_ASN1_VISIBLE_STRING = 26; - -const int SEC_ASN1_GENERAL_STRING = 27; - -const int SEC_ASN1_UNIVERSAL_STRING = 28; - -const int SEC_ASN1_BMP_STRING = 30; - -const int SEC_ASN1_HIGH_TAG_NUMBER = 31; - -const int SEC_ASN1_TELETEX_STRING = 20; - -const int SEC_ASN1_METHOD_MASK = 32; - -const int SEC_ASN1_PRIMITIVE = 0; - -const int SEC_ASN1_CONSTRUCTED = 32; - -const int SEC_ASN1_CLASS_MASK = 192; - -const int SEC_ASN1_UNIVERSAL = 0; - -const int SEC_ASN1_APPLICATION = 64; - -const int SEC_ASN1_CONTEXT_SPECIFIC = 128; - -const int SEC_ASN1_PRIVATE = 192; - -const int SEC_ASN1_OPTIONAL = 256; - -const int SEC_ASN1_EXPLICIT = 512; - -const int SEC_ASN1_ANY = 1024; - -const int SEC_ASN1_INLINE = 2048; - -const int SEC_ASN1_POINTER = 4096; - -const int SEC_ASN1_GROUP = 8192; - -const int SEC_ASN1_DYNAMIC = 16384; - -const int SEC_ASN1_SKIP = 32768; - -const int SEC_ASN1_INNER = 65536; - -const int SEC_ASN1_SAVE = 131072; - -const int SEC_ASN1_SKIP_REST = 524288; - -const int SEC_ASN1_CHOICE = 1048576; - -const int SEC_ASN1_SIGNED_INT = 8388608; - -const int SEC_ASN1_SEQUENCE_OF = 8208; - -const int SEC_ASN1_SET_OF = 8209; - -const int SEC_ASN1_ANY_CONTENTS = 66560; - -const int _CSSMAPPLE_H_ = 1; - -const int _CSSMERR_H_ = 1; - -const int _X509DEFS_H_ = 1; - -const int BER_TAG_UNKNOWN = 0; - -const int BER_TAG_BOOLEAN = 1; - -const int BER_TAG_INTEGER = 2; - -const int BER_TAG_BIT_STRING = 3; - -const int BER_TAG_OCTET_STRING = 4; - -const int BER_TAG_NULL = 5; - -const int BER_TAG_OID = 6; - -const int BER_TAG_OBJECT_DESCRIPTOR = 7; - -const int BER_TAG_EXTERNAL = 8; - -const int BER_TAG_REAL = 9; - -const int BER_TAG_ENUMERATED = 10; - -const int BER_TAG_PKIX_UTF8_STRING = 12; - -const int BER_TAG_SEQUENCE = 16; - -const int BER_TAG_SET = 17; - -const int BER_TAG_NUMERIC_STRING = 18; - -const int BER_TAG_PRINTABLE_STRING = 19; - -const int BER_TAG_T61_STRING = 20; - -const int BER_TAG_TELETEX_STRING = 20; - -const int BER_TAG_VIDEOTEX_STRING = 21; - -const int BER_TAG_IA5_STRING = 22; - -const int BER_TAG_UTC_TIME = 23; - -const int BER_TAG_GENERALIZED_TIME = 24; - -const int BER_TAG_GRAPHIC_STRING = 25; - -const int BER_TAG_ISO646_STRING = 26; - -const int BER_TAG_GENERAL_STRING = 27; - -const int BER_TAG_VISIBLE_STRING = 26; - -const int BER_TAG_PKIX_UNIVERSAL_STRING = 28; - -const int BER_TAG_PKIX_BMP_STRING = 30; - -const int CSSM_X509_OPTION_PRESENT = 1; - -const int CSSM_X509_OPTION_NOT_PRESENT = 0; - -const int CE_KU_DigitalSignature = 32768; - -const int CE_KU_NonRepudiation = 16384; - -const int CE_KU_KeyEncipherment = 8192; - -const int CE_KU_DataEncipherment = 4096; - -const int CE_KU_KeyAgreement = 2048; - -const int CE_KU_KeyCertSign = 1024; - -const int CE_KU_CRLSign = 512; - -const int CE_KU_EncipherOnly = 256; - -const int CE_KU_DecipherOnly = 128; - -const int CE_CR_Unspecified = 0; - -const int CE_CR_KeyCompromise = 1; - -const int CE_CR_CACompromise = 2; - -const int CE_CR_AffiliationChanged = 3; - -const int CE_CR_Superseded = 4; - -const int CE_CR_CessationOfOperation = 5; - -const int CE_CR_CertificateHold = 6; - -const int CE_CR_RemoveFromCRL = 8; - -const int CE_CD_Unspecified = 128; - -const int CE_CD_KeyCompromise = 64; - -const int CE_CD_CACompromise = 32; - -const int CE_CD_AffiliationChanged = 16; - -const int CE_CD_Superseded = 8; - -const int CE_CD_CessationOfOperation = 4; - -const int CE_CD_CertificateHold = 2; - -const int CSSM_APPLE_TP_SSL_OPTS_VERSION = 1; - -const int CSSM_APPLE_TP_SSL_CLIENT = 1; - -const int CSSM_APPLE_TP_CRL_OPTS_VERSION = 0; - -const int CSSM_APPLE_TP_SMIME_OPTS_VERSION = 0; - -const int CSSM_APPLE_TP_ACTION_VERSION = 0; - -const int CSSM_TP_APPLE_EVIDENCE_VERSION = 0; - -const int CSSM_EVIDENCE_FORM_APPLE_CUSTOM = 2147483648; - -const String CSSM_APPLE_CRL_END_OF_TIME = '99991231235959'; - -const String kKeychainSuffix = '.keychain'; - -const String kKeychainDbSuffix = '.keychain-db'; - -const String kSystemKeychainName = 'System.keychain'; - -const String kSystemKeychainDir = '/Library/Keychains/'; - -const String kSystemUnlockFile = '/var/db/SystemKey'; - -const String kSystemKeychainPath = '/Library/Keychains/System.keychain'; - -const String CSSM_APPLE_ACL_TAG_PARTITION_ID = '___PARTITION___'; - -const String CSSM_APPLE_ACL_TAG_INTEGRITY = '___INTEGRITY___'; - -const int errSecErrnoBase = 100000; - -const int errSecErrnoLimit = 100255; - -const int errSSLServerAuthCompleted = -9841; - -const int errSSLClientAuthCompleted = -9841; - -const int errSSLLast = -9849; - -const int NSMaximumStringLength = 2147483646; - -const int NS_UNICHAR_IS_EIGHT_BIT = 0; - const int NSURLResponseUnknownLength = -1; - -const int NSOperationQualityOfServiceUserInteractive = 33; - -const int NSOperationQualityOfServiceUserInitiated = 25; - -const int NSOperationQualityOfServiceUtility = 17; - -const int NSOperationQualityOfServiceBackground = 9; diff --git a/pkgs/cupertino_http/pubspec.yaml b/pkgs/cupertino_http/pubspec.yaml index a463092423..b0eb6ae178 100644 --- a/pkgs/cupertino_http/pubspec.yaml +++ b/pkgs/cupertino_http/pubspec.yaml @@ -16,12 +16,12 @@ dependencies: sdk: flutter http: ^1.2.0 http_profile: ^0.1.0 - objective_c: ^4.0.0 + objective_c: ^4.1.0 web_socket: ^0.1.0 dev_dependencies: dart_flutter_team_lints: ^3.0.0 - ffigen: ^16.0.0 + ffigen: ^16.1.0 flutter: plugin: