@ema/js-base-library
Version:
This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 7.2.0.
33 lines (32 loc) • 1.03 kB
TypeScript
export declare class Util {
static arrayRemoveValue(arr: any[], value: any): any[];
static arraySetUnique(arr: any): any[];
static castToType(o: any): any;
static copy(obj: any): any;
static fetchJson(url: string): Promise<any>;
static tryParseJSON(jsonString: any): any;
/**
* Returns the global object of the environment the application is running in (browser, node, web worker, or frame)
*/
static getGlobal(): any;
/**
* Returns the current date as milliseconds since midnight Jan 1, 1970.
*/
static getTimeStamp(date?: any): number;
/**
* Returns the current date as seconds since midnight Jan 1, 1970.
*/
static getUnixTimeStamp(date?: any): number;
/**
* Returns a UUID.
*/
static getUUID(): string;
/**
* Checks if the application is running in a browser.
*/
static isBrowser(): boolean;
/**
* Checks if the application is running in a browser and online.
*/
static isOnline(): boolean;
}