UNPKG

@nativescript/core

Version:

A JavaScript library providing an easy to use api for interacting with iOS and Android platform APIs.

80 lines (79 loc) 3.45 kB
export declare function dataDeserialize(nativeData?: any): any; export declare function dataSerialize(data: any, wrapPrimitives?: boolean): any; declare function getCurrentAppPath(): string; declare function joinPaths(...paths: string[]): string; export declare function getter<T>(_this: any, property: T | { (): T; }): T; declare namespace collections { function jsArrayToNSArray<T>(str: T[]): NSArray<T>; function nsArrayToJSArray<T>(a: NSArray<T>): Array<T>; } declare function getRootViewController(): UIViewController; export declare function getWindow(): UIWindow; declare function getMainScreen(): UIScreen; declare function setWindowBackgroundColor(value: string): void; declare function isLandscape(): boolean; export declare function openFile(filePath: string): boolean; declare function getVisibleViewController(rootViewController: UIViewController): UIViewController; declare function applyRotateTransform(transform: CATransform3D, x: number, y: number, z: number): CATransform3D; declare function createUIDocumentInteractionControllerDelegate(): NSObject; export declare function isRealDevice(): boolean; declare function printCGRect(rect: CGRect): string; declare function snapshotView(view: UIView, scale: number): UIImage; declare function copyLayerProperties(view: UIView, toView: UIView, customProperties?: { view?: Array<keyof UIView>; layer?: Array<keyof CALayer>; }): void; declare function animateWithSpring(options?: { tension?: number; friction?: number; mass?: number; delay?: number; velocity?: number; animateOptions?: UIViewAnimationOptions; animations?: () => void; completion?: (finished?: boolean) => void; }): void; export declare const ad: {}; export declare const android: {}; export declare const ios: { collections: typeof collections; createUIDocumentInteractionControllerDelegate: typeof createUIDocumentInteractionControllerDelegate; getCurrentAppPath: typeof getCurrentAppPath; getRootViewController: typeof getRootViewController; getVisibleViewController: typeof getVisibleViewController; getWindow: typeof getWindow; getMainScreen: typeof getMainScreen; setWindowBackgroundColor: typeof setWindowBackgroundColor; isLandscape: typeof isLandscape; applyRotateTransform: typeof applyRotateTransform; snapshotView: typeof snapshotView; joinPaths: typeof joinPaths; printCGRect: typeof printCGRect; copyLayerProperties: typeof copyLayerProperties; animateWithSpring: typeof animateWithSpring; MajorVersion: number; }; /** * @deprecated Use `Utils.ios` instead. */ export declare const iOSNativeHelper: { collections: typeof collections; createUIDocumentInteractionControllerDelegate: typeof createUIDocumentInteractionControllerDelegate; getCurrentAppPath: typeof getCurrentAppPath; getRootViewController: typeof getRootViewController; getVisibleViewController: typeof getVisibleViewController; getWindow: typeof getWindow; getMainScreen: typeof getMainScreen; setWindowBackgroundColor: typeof setWindowBackgroundColor; isLandscape: typeof isLandscape; applyRotateTransform: typeof applyRotateTransform; snapshotView: typeof snapshotView; joinPaths: typeof joinPaths; printCGRect: typeof printCGRect; copyLayerProperties: typeof copyLayerProperties; animateWithSpring: typeof animateWithSpring; MajorVersion: number; }; export {};