react-native-firebase/ios/RNFirebase/RNFirebaseMessaging.h

31 lines
987 B
C
Raw Normal View History

2017-03-09 15:26:28 +00:00
#ifndef RNFirebaseMessaging_h
#define RNFirebaseMessaging_h
#endif
#import <UIKit/UIKit.h>
2017-03-09 15:26:28 +00:00
#import "Firebase.h"
#import <FirebaseMessaging/FirebaseMessaging.h>
#import <React/RCTEventEmitter.h>
#import <React/RCTBridgeModule.h>
#import <React/RCTUtils.h>
2017-03-09 15:26:28 +00:00
@import UserNotifications;
2017-03-09 15:26:28 +00:00
@interface RNFirebaseMessaging : RCTEventEmitter<RCTBridgeModule, FIRMessagingDelegate>
2017-03-09 15:26:28 +00:00
typedef void (^RCTRemoteNotificationCallback)(UIBackgroundFetchResult result);
typedef void (^RCTWillPresentNotificationCallback)(UNNotificationPresentationOptions result);
typedef void (^RCTNotificationResponseCallback)();
2017-03-09 15:26:28 +00:00
@property (nonatomic, assign) bool connectedToFCM;
2017-03-09 15:26:28 +00:00
#if !TARGET_OS_TV
+ (void)didReceiveRemoteNotification:(nonnull NSDictionary *)userInfo;
+ (void)didReceiveRemoteNotification:(nonnull NSDictionary *)userInfo fetchCompletionHandler:(nonnull RCTRemoteNotificationCallback)completionHandler;
+ (void)didReceiveLocalNotification:(nonnull UILocalNotification *)notification;
2017-03-09 15:26:28 +00:00
#endif
@end