You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

115 lines
3.4 KiB

  1. /*
  2. * Copyright 2017 Google
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License");
  5. * you may not use this file except in compliance with the License.
  6. * You may obtain a copy of the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS,
  12. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. * See the License for the specific language governing permissions and
  14. * limitations under the License.
  15. */
  16. #import <FirebaseCore/FIROptions.h>
  17. /**
  18. * Keys for the strings in the plist file.
  19. */
  20. extern NSString *const kFIRAPIKey;
  21. extern NSString *const kFIRTrackingID;
  22. extern NSString *const kFIRGoogleAppID;
  23. extern NSString *const kFIRClientID;
  24. extern NSString *const kFIRGCMSenderID;
  25. extern NSString *const kFIRAndroidClientID;
  26. extern NSString *const kFIRDatabaseURL;
  27. extern NSString *const kFIRStorageBucket;
  28. extern NSString *const kFIRBundleID;
  29. extern NSString *const kFIRProjectID;
  30. /**
  31. * Keys for the plist file name
  32. */
  33. extern NSString *const kServiceInfoFileName;
  34. extern NSString *const kServiceInfoFileType;
  35. /**
  36. * This header file exposes the initialization of FIROptions to internal use.
  37. */
  38. @interface FIROptions ()
  39. /**
  40. * resetDefaultOptions and initInternalWithOptionsDictionary: are exposed only for unit tests.
  41. */
  42. + (void)resetDefaultOptions;
  43. /**
  44. * Initializes the options with dictionary. The above strings are the keys of the dictionary.
  45. * This is the designated initializer.
  46. */
  47. - (instancetype)initInternalWithOptionsDictionary:(NSDictionary *)serviceInfoDictionary
  48. NS_DESIGNATED_INITIALIZER;
  49. /**
  50. * defaultOptions and defaultOptionsDictionary are exposed in order to be used in FIRApp and
  51. * other first party services.
  52. */
  53. + (FIROptions *)defaultOptions;
  54. + (NSDictionary *)defaultOptionsDictionary;
  55. /**
  56. * Indicates whether or not Analytics collection was explicitly enabled via a plist flag or at
  57. * runtime.
  58. */
  59. @property(nonatomic, readonly) BOOL isAnalyticsCollectionExplicitlySet;
  60. /**
  61. * Whether or not Analytics Collection was enabled. Analytics Collection is enabled unless
  62. * explicitly disabled in GoogleService-Info.plist.
  63. */
  64. @property(nonatomic, readonly) BOOL isAnalyticsCollectionEnabled;
  65. /**
  66. * Whether or not Analytics Collection was completely disabled. If YES, then
  67. * isAnalyticsCollectionEnabled will be NO.
  68. */
  69. @property(nonatomic, readonly) BOOL isAnalyticsCollectionDeactivated;
  70. /**
  71. * The version ID of the client library, e.g. @"1100000".
  72. */
  73. @property(nonatomic, readonly, copy) NSString *libraryVersionID;
  74. /**
  75. * The flag indicating whether this object was constructed with the values in the default plist
  76. * file.
  77. */
  78. @property(nonatomic) BOOL usingOptionsFromDefaultPlist;
  79. /**
  80. * Whether or not Measurement was enabled. Measurement is enabled unless explicitly disabled in
  81. * GoogleService-Info.plist.
  82. */
  83. @property(nonatomic, readonly) BOOL isMeasurementEnabled;
  84. /**
  85. * Whether or not Analytics was enabled in the developer console.
  86. */
  87. @property(nonatomic, readonly) BOOL isAnalyticsEnabled;
  88. /**
  89. * Whether or not SignIn was enabled in the developer console.
  90. */
  91. @property(nonatomic, readonly) BOOL isSignInEnabled;
  92. /**
  93. * Whether or not editing is locked. This should occur after FIROptions has been set on a FIRApp.
  94. */
  95. @property(nonatomic, getter=isEditingLocked) BOOL editingLocked;
  96. @end