refactoring

This commit is contained in:
Max Lynch
2015-11-29 19:54:45 -06:00
parent 9d54bfcd0b
commit dfef6dcfe8
42 changed files with 719 additions and 185 deletions
+13 -1
View File
@@ -3,6 +3,18 @@ export declare const isInstalled: (pluginRef: string) => boolean;
export declare const pluginWarn: (pluginName: string, method: string, plugin: string) => void;
export declare const cordovaWarn: (pluginName: string, method: string) => void;
export declare const wrap: (pluginObj: any, methodName: any, opts?: any) => (...args: any[]) => any;
/**
* Class decorator specifying Plugin metadata. Required for all plugins.
*/
export declare function Plugin(config: any): (cls: any) => any;
export declare function Cordova(opts?: any): (obj: any, methodName: any) => void;
/**
* Wrap a stub function in a call to a Cordova plugin, checking if both Cordova
* and the required plugin are installed.
*/
export declare function Cordova(opts?: any): (target: Object, methodName: string, descriptor: TypedPropertyDescriptor<any>) => {
value: (...args: any[]) => any;
};
/**
* Before calling the original method, ensure Cordova and the plugin are installed.
*/
export declare function RequiresPlugin(target: Function, key: string, descriptor: TypedPropertyDescriptor<any>): TypedPropertyDescriptor<any>;