Skip to content

Commit

Permalink
feat(firebase): add new functions
Browse files Browse the repository at this point in the history
  • Loading branch information
danielsogl authored Apr 15, 2018
1 parent d4c9836 commit 36450e1
Showing 1 changed file with 40 additions and 12 deletions.
52 changes: 40 additions & 12 deletions src/@ionic-native/plugins/firebase/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ import { Observable } from 'rxjs/Observable';
export class Firebase extends IonicNativePlugin {
/**
* Get the device token
* @return {Promise<any>}
* @return {Promise<null | string>} Note that token will be null if it has not been established yet
*/
@Cordova()
getToken(): Promise<any> {
getToken(): Promise<null | string> {
return;
}

Expand Down Expand Up @@ -269,6 +269,44 @@ export class Firebase extends IonicNativePlugin {
return;
}

/**
* Start a trace.
* @param trace Trace name
*/
@Cordova()
startTrace(trace: string): Promise<any> {
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<any> {
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<any>}
*/
@Cordova()
setAnalyticsCollectionEnabled(enabled: boolean): Promise<any> {
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
Expand Down Expand Up @@ -298,14 +336,4 @@ export class Firebase extends IonicNativePlugin {
): Promise<any> {
return;
}

/**
* Allows the user to enable/disable analytics collection
* @param {boolean} enabled value to set collection
* @returns {Promise<any>}
*/
@Cordova()
setAnalyticsCollectionEnabled(enabled: boolean): Promise<any> {
return;
}
}

0 comments on commit 36450e1

Please sign in to comment.