mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-02-22 01:19:36 +08:00
docs(broadcaster): fix jsdocs
This commit is contained in:
parent
e095eecf5b
commit
7ed6ab894b
@ -1,5 +1,5 @@
|
|||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { Plugin, Cordova, IonicNativePlugin } from '@ionic-native/core';
|
import { Cordova, IonicNativePlugin, Plugin } from '@ionic-native/core';
|
||||||
import { Observable } from 'rxjs/Observable';
|
import { Observable } from 'rxjs/Observable';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -32,10 +32,9 @@ import { Observable } from 'rxjs/Observable';
|
|||||||
})
|
})
|
||||||
@Injectable()
|
@Injectable()
|
||||||
export class Broadcaster extends IonicNativePlugin {
|
export class Broadcaster extends IonicNativePlugin {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This function listen to an event sent from the native code
|
* This function listen to an event sent from the native code
|
||||||
* @param eventName {string}
|
* @param {string} eventName
|
||||||
* @return {Observable<any>} Returns an observable to watch when an event is received
|
* @return {Observable<any>} Returns an observable to watch when an event is received
|
||||||
*/
|
*/
|
||||||
@Cordova({
|
@Cordova({
|
||||||
@ -43,15 +42,18 @@ export class Broadcaster extends IonicNativePlugin {
|
|||||||
clearFunction: 'removeEventListener',
|
clearFunction: 'removeEventListener',
|
||||||
clearWithArgs: true
|
clearWithArgs: true
|
||||||
})
|
})
|
||||||
addEventListener(eventName: string): Observable<any> { return; }
|
addEventListener(eventName: string): Observable<any> {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This function sends data to the native code
|
* This function sends data to the native code
|
||||||
* @param eventName {string}
|
* @param {string} eventName
|
||||||
* @param eventData {any}
|
* @param {any} eventData
|
||||||
* @return {Promise<any>} Returns a promise that resolves when an event is successfully fired
|
* @return {Promise<any>} Returns a promise that resolves when an event is successfully fired
|
||||||
*/
|
*/
|
||||||
@Cordova()
|
@Cordova()
|
||||||
fireNativeEvent(eventName: string, eventData: any): Promise<any> { return; }
|
fireNativeEvent(eventName: string, eventData: any): Promise<any> {
|
||||||
|
return;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user