#include <FlutterEngine_Internal.h>
Private interface declaration for FlutterEngine.
Definition at line 110 of file FlutterEngine.mm.
◆ addSceneLifeCycleDelegate:
◆ addViewController:
Attach a view controller to the engine as its default controller.
Since FlutterEngine can only handle the implicit view for now, the given controller will always be assigned to the implicit view, if there isn't an implicit view yet. If the engine already has an implicit view, this call throws an assertion.
The engine holds a weak reference to the attached view controller.
If the given view controller is already attached to an engine, this call throws an assertion.
◆ announceAccessibilityMessage:withPriority:
| - (void) announceAccessibilityMessage: |
|
(NSString *) |
message |
| withPriority: |
|
(NSAccessibilityPriorityLevel) |
priority |
|
|
| |
Announces accessibility messages.
◆ attachView [1/2]
◆ attachView [2/2]
◆ createShell:libraryURI:initialRoute: [1/2]
| - (BOOL) createShell: |
|
(NSString *) |
entrypoint |
| libraryURI: |
|
(NSString *) |
libraryURI |
| initialRoute: |
|
(NSString *) |
initialRoute |
|
|
| |
◆ createShell:libraryURI:initialRoute: [2/2]
| - (BOOL) createShell: |
|
(nullable NSString *) |
entrypoint |
| libraryURI: |
|
(nullable NSString *) |
libraryOrNil |
| initialRoute: |
|
(nullable NSString *) |
initialRoute |
|
|
| |
◆ deregisterViewControllerForIdentifier:
An internal method that removes the view controller with the given ID.
This method clears the ID of the controller, removes the controller from the map. This is an no-op if the view ID is not associated with any view controllers.
◆ dispatchPointerDataPacket: [1/2]
◆ dispatchPointerDataPacket: [2/2]
◆ dispatchSemanticsAction:toTarget:withData:
Dispatches semantics action back to the framework. The semantics must be enabled by calling the updateSemanticsEnabled before dispatching semantics actions.
◆ enableMultiView
Enables multi-view support.
Called by [FlutterWindowController] before the first view is added. This affects the behavior when adding view controllers:
- When multiview is disabled, the engine will only assign views to the implicit view ID. The implicit view ID can be reused if and only if the implicit view ID is unassigned.
- When multiview is enabled, the engine will assign views to a self-incrementing ID.
Calling enableMultiView when multiview is already enabled is a noop.
◆ enableSemantics:withFlags:
| - (void) enableSemantics: |
|
(BOOL) |
enabled |
| withFlags: |
|
(int64_t) |
flags |
|
|
| |
◆ engineCallbackOnPlatformMessage:
Handles a platform message from the engine.
◆ engineCallbackOnPreEngineRestart
| - (void) engineCallbackOnPreEngineRestart |
|
|
|
Invoked right before the engine is restarted.
This should reset states to as if the application has just started. It usually indicates a hot restart (Shift-R in Flutter CLI.)
◆ engineForIdentifier: [1/2]
| + (nullable FlutterEngine *) engineForIdentifier: |
|
(int64_t) |
identifier |
|
Returns engine for the identifier. The identifier must be valid for an engine that is currently running, otherwise the behavior is undefined.
The identifier can be obtained in Dart code through PlatformDispatcher.instance.engineId.
This function must be called on the main thread.
◆ engineForIdentifier: [2/2]
| + (nullable FlutterEngine *) engineForIdentifier: |
|
(int64_t) |
identifier |
|
Returns engine for the identifier. The identifier must be valid for an engine that is currently running, otherwise the behavior is undefined.
The identifier can be obtained in Dart code through PlatformDispatcher.instance.engineId.
This function must be called on the main thread.
◆ engineIdentifier
| - (int64_t) engineIdentifier |
|
|
|
◆ handleAccessibilityEvent:
| - (void) handleAccessibilityEvent: |
|
(NSDictionary< NSString *, id > *) |
annotatedEvent |
|
Handles accessibility events.
◆ handleMethodCall:result:
Handles messages received from the Flutter engine on the _*Channel channels.
◆ installFirstFrameCallback:
| - (void) installFirstFrameCallback: |
|
(void(^)(void)) |
block |
|
◆ launchEngine:libraryURI:entrypointArgs:
| - (void) launchEngine: |
|
(nullable NSString *) |
entrypoint |
| libraryURI: |
|
(nullable NSString *) |
libraryOrNil |
| entrypointArgs: |
|
(nullable NSArray< NSString * > *) |
entrypointArgs |
|
|
| |
◆ loadAOTData:
| - (void) loadAOTData: |
|
(NSString *) |
assetsDir |
|
Loads the AOT snapshots and instructions from the elf bundle (app_elf_snapshot.so) into _aotData, if it is present in the assets directory.
◆ markTextureFrameAvailable:
| - (BOOL) markTextureFrameAvailable: |
|
(int64_t) |
textureID |
|
Marks texture with the given id as available. Returns YES on success.
◆ notifyLowMemory
◆ notifyViewCreated
| - (void) notifyViewCreated |
|
|
|
◆ notifyViewDestroyed
| - (void) notifyViewDestroyed |
|
|
|
◆ performImplicitEngineCallback
| - (BOOL) performImplicitEngineCallback |
|
|
|
◆ platformPlugin
◆ platformTaskRunner
◆ platformViewController
◆ postMainThreadTask:targetTimeInNanoseconds:
| - (void) postMainThreadTask: |
|
(FlutterTask) |
task |
| targetTimeInNanoseconds: |
|
(uint64_t) |
targetTime |
|
|
| |
Requests that the task be posted back the to the Flutter engine at the target time. The target time is in the clock used by the Flutter engine.
◆ rasterTaskRunner
◆ registerTextureWithID:
| - (BOOL) registerTextureWithID: |
|
(int64_t) |
textureId |
|
Registers an external texture with the given id. Returns YES on success.
◆ registerViewController:forIdentifier:
An internal method that adds the view controller with the given ID.
This method assigns the controller with the ID, puts the controller into the map, and does assertions related to the implicit view ID.
◆ registrarForApplication:
◆ removeViewController:
Dissociate the given view controller from this engine.
If the view controller is not associated with this engine, this call throws an assertion.
◆ restorationPlugin
◆ sceneLifeCycleDelegate
◆ screens
| - (NSArray< NSScreen * > *) screens |
|
|
|
Returns an array of screen objects representing all of the screens available on the system.
◆ screenshot:base64Encode:
◆ sendDeepLinkToFramework:completionHandler:
| - (void) sendDeepLinkToFramework: |
|
(NSURL *) |
url |
| completionHandler: |
|
(void(^)(BOOL success)) |
completion |
|
|
| |
◆ sendKeyEvent:callback:userData:
Dispatches the given key event data to the framework through the engine. The callback is called once the response from the framework is received.
Reimplemented from <FlutterKeyboardManagerDelegate>.
◆ sendPointerEvent:
Dispatches the given pointer event data to engine.
◆ sendUserLocales
Sends the list of user-preferred locales to the Flutter engine.
◆ setApplicationState:
Handles changes to the application state, sending them to the framework.
- Parameters
-
| state | One of the lifecycle constants in app_lifecycle_state.h, corresponding to the Dart enum AppLifecycleState. |
◆ setUpAccessibilityChannel
| - (void) setUpAccessibilityChannel |
|
|
|
Creates an accessibility channel and sets up the message handler.
◆ setUpPlatformViewChannel
| - (void) setUpPlatformViewChannel |
|
|
|
Creates a platform view channel and sets up the method handler.
◆ shutDownIfNeeded
| - (void) shutDownIfNeeded |
|
|
|
Shuts down the engine if view requirement is not met, and headless execution is not allowed.
◆ spawnWithEntrypoint:libraryURI:initialRoute:entrypointArgs:
| - (FlutterEngine *) spawnWithEntrypoint: |
|
(nullable NSString *) |
entrypoint |
| libraryURI: |
|
(nullable NSString *) |
libraryURI |
| initialRoute: |
|
(nullable NSString *) |
initialRoute |
| entrypointArgs: |
|
(nullable NSArray< NSString * > *) |
entrypointArgs |
|
|
| |
Creates one running FlutterEngine from another, sharing components between them.
This results in a faster creation time and a smaller memory footprint engine. This should only be called on a FlutterEngine that is running.
◆ textInputPlugin [1/2]
◆ textInputPlugin [2/2]
◆ uiTaskRunner
◆ unregisterTextureWithID:
| - (BOOL) unregisterTextureWithID: |
|
(int64_t) |
textureID |
|
Unregisters an external texture with the given id. Returns YES on success.
◆ updateViewportMetrics: [1/2]
◆ updateViewportMetrics: [2/2]
◆ updateWindowMetricsForViewController:
Informs the engine that the specified view controller's window metrics have changed.
◆ viewControllerForIdentifier: [1/2]
◆ viewControllerForIdentifier: [2/2]
◆ viewControllerViewDidLoad:
Notify the engine that a view for the given view controller has been loaded.
◆ waitForFirstFrame:callback:
| - (void) waitForFirstFrame: |
|
(NSTimeInterval) |
timeout |
| callback: |
|
(void(^)(BOOL didTimeout)) |
callback |
|
|
| |
Asynchronously waits until the first frame is presented or the timeout is exceeded, then invokes callback.
◆ waitForFirstFrameSync:callback:
| - (void) waitForFirstFrameSync: |
|
(NSTimeInterval) |
timeout |
| callback: |
|
(NS_NOESCAPE void(^)(BOOL didTimeout)) |
callback |
|
|
| |
Blocks until the first frame is presented or the timeout is exceeded, then invokes callback.
◆ windowDidBecomeKey:
Notifies the engine that window with the given identifier has been made key.
◆ windowDidResignKey:
Notifies the engine that window with the given identifier has resigned being key.
◆ allowHeadlessExecution
| - (BOOL) allowHeadlessExecution |
|
readnonatomicassign |
◆ connections
| - (FlutterConnectionCollection*) connections |
|
readwritenonatomicstrong |
◆ dartProject
◆ embedderAPI
◆ enableEmbedderAPI
| - (BOOL) enableEmbedderAPI |
|
readwritenonatomicassign |
◆ executableName
| - (NSString*) executableName |
|
readnonatomicassign |
◆ flutterViewControllerWillDeallocObserver
| - (id<NSObject>) flutterViewControllerWillDeallocObserver |
|
readwritenonatomicstrong |
◆ initialRoute
| - (NSString*) initialRoute |
|
readwritenonatomiccopy |
◆ isolateId
◆ isResponseValid
| - (NSMutableArray<NSNumber*>*) isResponseValid |
|
readwritenonatomicstrong |
A mutable array that holds one bool value that determines if responses to platform messages are clear to execute. This value should be read or written only inside of a synchronized block and will return NO after the FlutterEngine has been dealloc'd.
Definition at line 105 of file FlutterEngine.mm.
◆ keyboardManager
◆ keyEventChannel
◆ labelPrefix
| - (NSString*) labelPrefix |
|
readnonatomiccopy |
◆ lifecycleChannel
◆ localizationChannel
◆ manuallyRegisteredToScene
| - (BOOL) manuallyRegisteredToScene |
|
readwritenonatomicassign |
◆ navigationChannel
◆ nextTextureId
| - (int64_t) nextTextureId |
|
readwritenonatomicassign |
◆ pasteboard
◆ platformChannel
◆ platformPlugin
◆ platformViewsChannel
◆ platformViewsController
◆ pluginAppDelegates
| - (NSPointerArray*) pluginAppDelegates |
|
readwritenonatomicstrong |
All delegates added via plugin calls to addApplicationDelegate.
Definition at line 110 of file FlutterEngine.mm.
◆ pluginPublications
| - (NSMutableDictionary*) pluginPublications |
|
readnonatomicassign |
◆ pluginRegistrars
All registrars returned from registrarForPlugin:
Definition at line 116 of file FlutterEngine.mm.
◆ project
◆ publisher
◆ registrars
◆ renderer
Provides the renderer config needed to initialize the engine and also handles external texture management.
Definition at line 94 of file FlutterEngine_Internal.h.
◆ restorationChannel
◆ restorationEnabled
| - (BOOL) restorationEnabled |
|
readnonatomicassign |
◆ restorationPlugin
◆ running
◆ sceneLifeCycleDelegate
◆ screenshotChannel
◆ scribbleChannel
◆ semanticsEnabled
| - (BOOL) semanticsEnabled |
|
readwritenonatomicassign |
True if the semantics is enabled. The Flutter framework starts sending semantics update through the embedder as soon as it is set to YES.
Definition at line 105 of file FlutterEngine_Internal.h.
◆ settingsChannel
◆ spellCheckChannel
◆ spellCheckPlugin
◆ switches
◆ systemChannel
◆ terminationHandler
◆ textInputChannel
◆ textInputPlugin
◆ undoManagerChannel
◆ undoManagerPlugin
◆ windowController
The documentation for this category was generated from the following files: