mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
console module naming changed to "-"
This commit is contained in:
22
console/console-helper.android.ts
Normal file
22
console/console-helper.android.ts
Normal file
@@ -0,0 +1,22 @@
|
||||
var TAG = 'JS';
|
||||
|
||||
export var helper_log = function (message: string) {
|
||||
android.util.Log.v(TAG, message);
|
||||
}
|
||||
|
||||
export var info = function (message: string) {
|
||||
android.util.Log.i(TAG, message);
|
||||
}
|
||||
|
||||
export var error = function (message: string) {
|
||||
android.util.Log.e(TAG, message);
|
||||
}
|
||||
|
||||
export var warn = function (message: string) {
|
||||
android.util.Log.w(TAG, message);
|
||||
}
|
||||
|
||||
export var timeMillis = function (): number {
|
||||
// NOTE: we might need to use currentTimeMillis if we have troubles with the long size
|
||||
return java.lang.System.nanoTime() / 1000000; // 1 ms = 1000000 ns
|
||||
}
|
||||
Reference in New Issue
Block a user