mirror of
https://github.com/shaka-project/shaka-player.git
synced 2026-06-16 16:16:40 +03:00
4f62ce8b24
Ensure generated bundles contain a single license header instead of repeating the same notice across bundled modules. Normalize all copyright years to 2016 and remove duplicate license headers from generated bundles. This reduces the final bundle size while preserving license information in the distributed artifacts.
22 lines
444 B
JavaScript
22 lines
444 B
JavaScript
/*! @license
|
|
* Shaka Player
|
|
* Copyright 2016 Google LLC
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*/
|
|
|
|
goog.provide('shaka.util.TimeUtils');
|
|
|
|
|
|
shaka.util.TimeUtils = class {
|
|
/**
|
|
* Convert Ntp ntpTimeStamp to UTC Time
|
|
*
|
|
* @param {number} ntpTimeStamp
|
|
* @return {number} utcTime
|
|
*/
|
|
static convertNtp(ntpTimeStamp) {
|
|
const start = Date.UTC(1900, 0, 1, 0, 0, 0, 0);
|
|
return new Date(start + ntpTimeStamp).getTime();
|
|
}
|
|
};
|