public static void Initialize( Activity activity, Bundle savedInstanceState, CrossFirebaseSettings settings, FirebaseOptions firebaseOptions = null, string name = null) { if (firebaseOptions == null) { FirebaseApp.InitializeApp(activity); } else if (name == null) { FirebaseApp.InitializeApp(activity, firebaseOptions); } else { FirebaseApp.InitializeApp(activity, firebaseOptions, name); } if (settings.IsAnalyticsEnabled) { FirebaseAnalyticsImplementation.Initialize(activity); } if (settings.IsAuthEnabled) { FirebaseAuthImplementation.Initialize(activity, savedInstanceState, settings.GoogleRequestIdToken ?? "123-abc"); } Console.WriteLine($"Plugin.Firebase initialized with the following settings:\n{settings}"); }
protected override void OnCreate(Bundle savedInstanceState) { Platform.Init(this, savedInstanceState); FirebaseApp.InitializeApp(this); FirebaseAnalyticsImplementation.Initialize(this); FirebaseAuthImplementation.Initialize(this, savedInstanceState, "316652897245-lbddc4dc4v87nv3n19thi032n3dvrcvu.apps.googleusercontent.com"); // tests can be inside the main assembly AddTestAssembly(Assembly.GetExecutingAssembly()); AddExecutionAssembly(typeof(ExtensibilityPointFactory).Assembly); // or in any reference assemblies //AddTestAssembly(typeof(PortableTests).Assembly); // or in any assembly that you load (since JIT is available) AddTestAssembly(typeof(MustPassFixture).Assembly); #if false // you can use the default or set your own custom writer (e.g. save to web site and tweet it ;-) Writer = new TcpTextWriter("10.0.1.2", 16384); // start running the test suites as soon as the application is loaded AutoStart = true; // crash the application (to ensure it's ended) and return to springboard TerminateAfterExecution = true; #endif // you cannot add more assemblies once calling base base.OnCreate(savedInstanceState); }
public static void Initialize( UIApplication app, NSDictionary options, CrossFirebaseSettings settings, Options firebaseOptions = null, string name = null) { if (firebaseOptions == null) { App.Configure(); } else if (name == null) { App.Configure(firebaseOptions); } else { App.Configure(name, firebaseOptions); } if (settings.IsAnalyticsEnabled) { FirebaseAnalyticsImplementation.Initialize(); } if (settings.IsAuthEnabled) { FirebaseAuthImplementation.Initialize(app, options, settings.FacebookId, settings.FacebookAppName); } if (settings.IsCloudMessagingEnabled) { FirebaseCloudMessagingImplementation.Initialize(); } Console.WriteLine($"Plugin.Firebase initialized with the following settings:\n{settings}"); }