summaryrefslogtreecommitdiff
path: root/StoneIsland/platforms/ios/Pods/GoogleCloudMessaging/Headers/Public/GCMConfig.h
blob: 4e65fb87355bffea22d2a5c6bf0449d33c2c8e72 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
@protocol GCMReceiverDelegate;

typedef NS_ENUM(int8_t, GCMLogLevel) {
  kGCMLogLevelDebug,
  kGCMLogLevelInfo,
  kGCMLogLevelError,
  kGCMLogLevelAssert,
};

/**
 *  Config used to set different options in Google Cloud Messaging.
 */
@interface GCMConfig : NSObject

/**
 *  Set the `GCMReceiverDelegate` to receive callbacks on upstream messages.
 *
 *  @see GCMReceiverDelegate
 */
@property(nonatomic, readwrite, weak) id<GCMReceiverDelegate> receiverDelegate;

/**
 * The log level for the GCM library. Valid values are `kGCMLogLevelDebug`,
 *   `kGCMLogLevelInfo`, `kGCMLogLevelError`, and `kGCMLogLevelAssert`.
 */
@property(nonatomic, readwrite, assign) GCMLogLevel logLevel;

/**
 *  Specify which remote notification callback to invoke when a GCM message is
 *  received.
 *
 *  If set to "YES" GCM uses the new remote notification callback i.e.
 *  application:didReceiveRemoteNotification:fetchCompletionHandler:.
 *  If set to "NO" GCM invokes application:didReceiveRemoteNotification: callback.
 *
 *  Defaults to "NO".
 */
@property(nonatomic, readwrite, assign) BOOL useNewRemoteNotificationCallback;

/**
 *  Get default configuration for GCM. The default config has logLevel set to
 *  `kGCMLogLevelError` and `receiverDelegate` is set to nil.
 *
 *  @return GCMConfig sharedInstance.
 */
+ (instancetype)defaultConfig;

@end