| Flutter iOS Embedder |

Class Methods | List of all members
FlutterCallbackCache Class Reference

`#import <FlutterCallbackCache.h>`

Inheritance diagram for FlutterCallbackCache:

## Class Methods
(FlutterCallbackInformation *) | + lookupCallbackInformation:
(void) | + setCachePath:`[implementation]`

## Detailed Description

The cache containing callback information for spawning a `FlutterHeadlessDartRunner`.

Definition at line 37 of file FlutterCallbackCache.h.

## Method Documentation

## ◆ lookupCallbackInformation:

+ (FlutterCallbackInformation *) lookupCallbackInformation: |  | (int64_t) | handle |

Returns the callback information for the given callback handle. This callback information can be used when spawning a `FlutterHeadlessDartRunner`.

Parameters

  handle | The handle for a callback, provided by the Dart method `PluginUtilities.getCallbackHandle`.

Returns
  A `FlutterCallbackInformation` object which contains the name of the callback, the name of the class in which the callback is defined, and the path of the library which contains the callback. If the provided handle is invalid, nil is returned.

Definition at line 23 of file FlutterCallbackCache.mm.

23 :(int64_t)handle {
24 auto info = flutter::DartCallbackCache::GetCallbackInformation(handle);
25 if (info == nullptr) {
26 return nil;
27 }
28 FlutterCallbackInformation* new_info = [[[FlutterCallbackInformation alloc] init] autorelease];
29 new_info.callbackName = [NSString stringWithUTF8String:info->name.c_str()];
30 new_info.callbackClassName = [NSString stringWithUTF8String:info->class_name.c_str()];
31 new_info.callbackLibraryPath = [NSString stringWithUTF8String:info->library_path.c_str()];
32 return new_info;
33 }

References FlutterCallbackInformation::callbackClassName, FlutterCallbackInformation::callbackLibraryPath, and FlutterCallbackInformation::callbackName.

## ◆ setCachePath:

+ (void) setCachePath: |  | (NSString *) | path |
| implementation

The documentation for this class was generated from the following files:

- shell/platform/darwin/ios/framework/Headers/FlutterCallbackCache.h
- shell/platform/darwin/ios/framework/Source/FlutterCallbackCache.mm

FlutterCallbackInformation::callbackLibraryPath
NSString * callbackLibraryPath
Definition: FlutterCallbackCache.h:29
FlutterCallbackInformation::callbackName
NSString * callbackName
Definition: FlutterCallbackCache.h:21
FlutterCallbackInformation::callbackClassName
NSString * callbackClassName
Definition: FlutterCallbackCache.h:25
FlutterCallbackInformation
Definition: FlutterCallbackCache.h:17