| Flutter iOS Embedder |

Instance Methods | Class Methods | Properties | List of all members
FlutterRestorationPlugin Class Reference

`#import <FlutterRestorationPlugin.h>`

Inheritance diagram for FlutterRestorationPlugin:

## Instance Methods
(instancetype) | - NS_UNAVAILABLE
(instancetype) | - initWithChannel:restorationEnabled:
(void) | - markRestorationComplete
(void) | - reset

## Class Methods
(instancetype) | + NS_UNAVAILABLE

## Properties
NSData * | restorationData

## Detailed Description

Definition at line 12 of file FlutterRestorationPlugin.h.

## Method Documentation

## ◆ initWithChannel:restorationEnabled:

- (instancetype) initWithChannel: |  | (FlutterMethodChannel*) | channel
restorationEnabled: |  | (BOOL) | NS_DESIGNATED_INITIALIZER

Definition at line 20 of file FlutterRestorationPlugin.mm.

23 :(FlutterMethodChannel*)channel
24 restorationEnabled:(BOOL)restorationEnabled {
25 FML_DCHECK(channel) << "channel must be set";
26 self = [super init];
27 if (self) {
28 [channel setMethodCallHandler:^(FlutterMethodCall* call, FlutterResult result) {
29 [self handleMethodCall:call result:result];
30 }];
31 _restorationEnabled = restorationEnabled;
32 _waitForData = restorationEnabled;
33 }
34 return self;
35 }
_restorationEnabled
BOOL _restorationEnabled
Definition: FlutterRestorationPlugin.mm:18
FlutterMethodChannel
Definition: FlutterChannels.h:221
-[FlutterMethodChannel setMethodCallHandler:]
void setMethodCallHandler:(FlutterMethodCallHandler _Nullable handler)

## ◆ markRestorationComplete

- (void) markRestorationComplete |  |  |

Definition at line 20 of file FlutterRestorationPlugin.mm.

66 {
67 _waitForData = NO;
68 if (self.pendingRequest != nil) {
69 NSAssert(_restorationEnabled, @"No request can be pending when restoration is disabled.");
70 self.pendingRequest([self dataForFramework]);
71 self.pendingRequest = nil;
72 }
73 }

## ◆ NS_UNAVAILABLE [1/2]

+ (instancetype) NS_UNAVAILABLE |  |  |

## ◆ NS_UNAVAILABLE [2/2]

- (instancetype) NS_UNAVAILABLE |  |  |

## ◆ reset

- (void) reset |  |  |

Reset the state restoration plugin to prepare for a hot restart.

This clears the restoration data and drops any pending requests.

Definition at line 20 of file FlutterRestorationPlugin.mm.

75 {
76 self.pendingRequest = nil;
77 self.restorationData = nil;
78 }

## Property Documentation

## ◆ restorationData

- (NSData*) restorationData
| readwritenonatomiccopy

Definition at line 18 of file FlutterRestorationPlugin.h.

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

- shell/platform/darwin/ios/framework/Source/FlutterRestorationPlugin.h
- shell/platform/darwin/ios/framework/Source/FlutterRestorationPlugin.mm