import { InAppPurchase2 } from '@ionic-native/in-app-purchase-2' ; export interface IAPProductOptions { id : string ; alias : string ; type : string ; } export declare type IAPProducts = Array < IAPProduct > & { /**
     * Get product by ID
     */ byId : { [ id ] : IAPProduct ; } ; /**
     * Get product by alias
     */ byAlias : { [ alias ] : IAPProduct ; } ; /**
     * Remove all products (for testing only).
     */ reset : ( ) => { } ; } ; export declare type IAPQueryCallback = ( ( product : IAPProduct ) => void ) | ( ( error : IAPError ) => void ) ; export interface IAPProduct { id : string ; alias : string ; type : string ; state : string ; title : string ; description : string ; priceMicros : string ; price : string ; currency : string ; loaded : boolean ; valid : boolean ; canPurchase : boolean ; owned : boolean ; downloading : boolean ; downloaded : boolean ; additionalData : any ; transaction : any ; finish ( ) : void ; verify ( ) : any ; set ( key , value ) : void ; stateChanged ( ) : void ; on ( event , callback ) : void ; once ( event , callback ) : void ; off ( callback ) : void ; trigger ( action , args ) : void ; } export interface IAPProductEvents { loaded : ( callback : IAPQueryCallback ) => void ; updated : ( callback : IAPQueryCallback ) => void ; error : ( callback : IAPQueryCallback ) => void ; approved : ( callback : IAPQueryCallback ) => void ; owned : ( callback : IAPQueryCallback ) => void ; cancelled : ( callback : IAPQueryCallback ) => void ; refunded : ( callback : IAPQueryCallback ) => void ; registered : ( callback : IAPQueryCallback ) => void ; valid : ( callback : IAPQueryCallback ) => void ; invalid : ( callback : IAPQueryCallback ) => void ; requested : ( callback : IAPQueryCallback ) => void ; initiated : ( callback : IAPQueryCallback ) => void ; finished : ( callback : IAPQueryCallback ) => void ; verified : ( callback : IAPQueryCallback ) => void ; unverified : ( callback : IAPQueryCallback ) => void ; expired : ( callback : IAPQueryCallback ) => void ; downloading : ( product : IAPProduct , progress : any , time_remaining : any ) => void ; downloaded : ( callback : IAPQueryCallback ) => void ; } hidden export declare class IAPError { code : number ; message : string ; } export class InAppPurchase2Mock extends InAppPurchase2 { QUIET : number ; ERROR : number ; WARNING : number ; INFO : number ; DEBUG : number ; /**
     * Debug level. Use QUIET, ERROR, WARNING, INFO or DEBUG constants
     */ verbosity : number ; /**
     * Set to true to invoke the platform purchase sandbox. (Windows only)
     */ sandbox : boolean ; FREE_SUBSCRIPTION : string ; PAID_SUBSCRIPTION : string ; NON_RENEWING_SUBSCRIPTION : string ; CONSUMABLE : string ; NON_CONSUMABLE : string ; ERR_SETUP : number ; ERR_LOAD : number ; ERR_PURCHASE : number ; ERR_LOAD_RECEIPTS : number ; ERR_CLIENT_INVALID : number ; ERR_PAYMENT_CANCELLED : number ; ERR_PAYMENT_INVALID : number ; ERR_PAYMENT_NOT_ALLOWED : number ; ERR_UNKNOWN : number ; ERR_REFRESH_RECEIPTS : number ; ERR_INVALID_PRODUCT_ID : number ; ERR_FINISH : number ; ERR_COMMUNICATION : number ; ERR_SUBSCRIPTIONS_NOT_AVAILABLE : number ; ERR_MISSING_TOKEN : number ; ERR_VERIFICATION_FAILED : number ; ERR_BAD_RESPONSE : number ; ERR_REFRESH : number ; ERR_PAYMENT_EXPIRED : number ; ERR_DOWNLOAD : number ; ERR_SUBSCRIPTION_UPDATE_NOT_AVAILABLE : number ; REGISTERED : string ; INVALID : string ; VALID : string ; REQUESTED : string ; INITIATED : string ; APPROVED : string ; FINISHED : string ; OWNED : string ; DOWNLOADING : string ; DOWNLOADED : string ; INVALID_PAYLOAD : number ; CONNECTION_FAILED : number ; PURCHASE_EXPIRED : number ; products : IAPProducts ; validator : string | ( ( product : string | IAPProduct , callback : Function ) => void ) ; log : { error : ( message : string ) => void ; warn : ( message : string ) => void ; info : ( message : string ) => void ; debug : ( message : string ) => void ; } ; param idOrAlias get ( idOrAlias ) { let response ; return response ; } ; param onError { Function } error ( onError ) { } ; param product { IAPProductOptions } register ( product ) { } ; param query param event param callback return { IAPProductEvents } when ( query , event ? , callback ? ) { let response ; return response ; } ; param query { string | IAPProduct } param event { event } param callback { IAPQueryCallback } return { IAPProductEvents } once ( query , event ? , callback ? ) { let response ; return response ; } ; param callback { Function } off ( callback ) { } ; order ( product , additionalData ? ) { return ; } return { Promise < any > } ready ( ) { return new Promise ( ( resolve , reject ) => { resolve ( ) ; } ) ; } ; refresh ( ) { } ; }