@hazelcast/services
Advanced tools
Comparing version 1.3.2-next.99 to 1.3.2-next.100
@@ -1,2 +0,2 @@ | ||
declare type LogLevel = 'log' | 'warn' | 'error'; | ||
type LogLevel = 'log' | 'warn' | 'error'; | ||
declare class Logger { | ||
@@ -3,0 +3,0 @@ private readonly whiteListedMessages; |
export declare class TimeService { | ||
static DEFAULT_FORMAT: string; | ||
static currentTimestamp(): number; | ||
static format(source: Date): string; | ||
static formatTime(source: Date): string; | ||
static formatDate(source: Date): string; | ||
} |
@@ -6,3 +6,13 @@ // Useful to override current time for our code in tests, leaving third-party code untouched. | ||
} | ||
static format(source) { | ||
return `${TimeService.formatDate(source)} ${TimeService.formatTime(source)}`; | ||
} | ||
static formatTime(source) { | ||
return `${('0' + source.getHours().toString()).slice(-2)}:${('0' + source.getMinutes().toString()).slice(-2)}:${('0' + source.getSeconds().toString()).slice(-2)}`; | ||
} | ||
static formatDate(source) { | ||
return `${source.getFullYear()}-${('0' + (source.getMonth() + 1).toString()).slice(-2)}-${('0' + source.getDate().toString()).slice(-2)}`; | ||
} | ||
} | ||
TimeService.DEFAULT_FORMAT = 'YYYY-MM-DD hh:mm:ss'; | ||
//# sourceMappingURL=time.js.map |
{ | ||
"name": "@hazelcast/services", | ||
"version": "1.3.2-next.99+ec89674", | ||
"version": "1.3.2-next.100+d1cfa9e", | ||
"description": "Hazelcast shared services", | ||
@@ -29,3 +29,3 @@ "author": "", | ||
"lint": "eslint --ext .ts,.tsx .", | ||
"lint:fix": "npm run lint -- --fix" | ||
"lint:fix": "pnpm run lint -- --fix" | ||
}, | ||
@@ -38,3 +38,6 @@ "bugs": { | ||
}, | ||
"gitHead": "ec8967400f73f91161b788c1422f9ca86f587310" | ||
"devDependencies": { | ||
"@types/node": "^16.18.13" | ||
}, | ||
"gitHead": "d1cfa9ec3c53ca5601139078dd301c038b6057b9" | ||
} |
Sorry, the diff of this file is not supported yet
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
20142
125
1