From 36450e13cf9affc68ed63a25595418985f5df418 Mon Sep 17 00:00:00 2001 From: Daniel Sogl Date: Sun, 15 Apr 2018 10:43:13 +0200 Subject: [PATCH] feat(firebase): add new functions --- src/@ionic-native/plugins/firebase/index.ts | 52 ++++++++++++++++----- 1 file changed, 40 insertions(+), 12 deletions(-) diff --git a/src/@ionic-native/plugins/firebase/index.ts b/src/@ionic-native/plugins/firebase/index.ts index 721e81f9..302cb754 100644 --- a/src/@ionic-native/plugins/firebase/index.ts +++ b/src/@ionic-native/plugins/firebase/index.ts @@ -35,10 +35,10 @@ import { Observable } from 'rxjs/Observable'; export class Firebase extends IonicNativePlugin { /** * Get the device token - * @return {Promise} + * @return {Promise} Note that token will be null if it has not been established yet */ @Cordova() - getToken(): Promise { + getToken(): Promise { return; } @@ -269,6 +269,44 @@ export class Firebase extends IonicNativePlugin { return; } + /** + * Start a trace. + * @param trace Trace name + */ + @Cordova() + startTrace(trace: string): Promise { + return; + } + + /** + * To count the performance-related events that occur in your app (such as cache hits or retries), add a line of code + * similar to the following whenever the event occurs, using a string other than retry to name that event if you are + * counting a different type of event: + * @param trace Trace name + * @param counter Counter + */ + @Cordova() + incrementCounter(trace: string, counter: string): Promise { + return; + } + + /** + * Stop the trace + * @param trace Trace name + */ + @Cordova() + stopTrace(trace: string): void {} + + /** + * Allows the user to enable/disable analytics collection + * @param {boolean} enabled value to set collection + * @returns {Promise} + */ + @Cordova() + setAnalyticsCollectionEnabled(enabled: boolean): Promise { + return; + } + /** * Sends an SMS to the user with the SMS verification code and returns the Verification ID required to sign in using phone authentication * @param {string} phoneNumber @@ -298,14 +336,4 @@ export class Firebase extends IonicNativePlugin { ): Promise { return; } - - /** - * Allows the user to enable/disable analytics collection - * @param {boolean} enabled value to set collection - * @returns {Promise} - */ - @Cordova() - setAnalyticsCollectionEnabled(enabled: boolean): Promise { - return; - } }