#import <FlutterDartVMServicePublisher.h>
◆ initWithEnableVMServicePublication:
- (instancetype) initWithEnableVMServicePublication: |
|
(BOOL) |
NS_DESIGNATED_INITIALIZER |
|
Definition at line 166 of file FlutterDartVMServicePublisher.mm.
166 :(BOOL)enableVMServicePublication {
168 NSAssert(
self,
@"Super must not return null on init.");
171 _enableVMServicePublication = enableVMServicePublication;
172 _weakFactory = std::make_unique<fml::WeakPtrFactory<FlutterDartVMServicePublisher>>(
self);
174 fml::MessageLoop::EnsureInitializedForCurrentThread();
176 _callbackHandle = flutter::DartServiceIsolate::AddServerStatusCallback(
178 runner = fml::MessageLoop::GetCurrent().GetTaskRunner()](
const std::string& uri) {
180 runner->PostTask([weak, uri]() {
184 NSURL* url = [[[NSURL alloc]
185 initWithString:[NSString stringWithUTF8String:uri.c_str()]] autorelease];
186 weak.get().url = url;
187 if (weak.get().enableVMServicePublication) {
188 [[weak.get() delegate] publishServiceProtocolPort:url];
References _weakFactory.
◆ NS_UNAVAILABLE [1/2]
+ (instancetype) NS_UNAVAILABLE |
|
|
|
◆ NS_UNAVAILABLE [2/2]
- (instancetype) NS_UNAVAILABLE |
|
|
|
◆ url
The documentation for this class was generated from the following files: