설명 없음

FIRInstanceIDCheckinPreferences+Internal.h 2.2KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. /*
  2. * Copyright 2019 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 <FirebaseInstanceID/FIRInstanceIDCheckinPreferences.h>
  17. @interface FIRInstanceIDCheckinPreferences (Internal)
  18. /**
  19. * Parse the checkin auth credentials saved in the Keychain to initialize checkin
  20. * preferences.
  21. *
  22. * @param keychainContent The checkin auth credentials saved in the Keychain.
  23. *
  24. * @return A valid checkin preferences object if the checkin auth credentials in the
  25. * keychain can be parsed successfully else nil.
  26. */
  27. + (FIRInstanceIDCheckinPreferences *)preferencesFromKeychainContents:(NSString *)keychainContent;
  28. /**
  29. * Default initializer for InstanceID checkin preferences.
  30. *
  31. * @param deviceID The deviceID for the app.
  32. * @param secretToken The secret token the app uses to authenticate with the server.
  33. *
  34. * @return A checkin preferences object with given deviceID and secretToken.
  35. */
  36. - (instancetype)initWithDeviceID:(NSString *)deviceID secretToken:(NSString *)secretToken;
  37. /**
  38. * Update checkin preferences from the preferences dict persisted as a plist. The dict contains
  39. * all the checkin preferences retrieved from the server except the deviceID and secret which
  40. * are stored in the Keychain.
  41. *
  42. * @param checkinPlistContent The checkin preferences saved in a plist on the disk.
  43. */
  44. - (void)updateWithCheckinPlistContents:(NSDictionary *)checkinPlistContent;
  45. /**
  46. * Reset the current checkin preferences object.
  47. */
  48. - (void)reset;
  49. /**
  50. * The string that contains the checkin auth credentials i.e. deviceID and secret. This
  51. * needs to be stored in the Keychain.
  52. *
  53. * @return The checkin auth credential string containing the deviceID and secret.
  54. */
  55. - (NSString *)checkinKeychainContent;
  56. @end