* Creates a JavaScript UTC Date corresponding to the given JavaScript Date. * @param {Date} oDate JavaScript date object. Time related information is cut. * @returns {Date} JavaScript date created from the date object, but this time considered as UTC date information.
(oDate: UI5Date | Date)
| 205 | * @returns {Date} JavaScript date created from the date object, but this time considered as UTC date information. |
| 206 | */ |
| 207 | function createUTCDate(oDate: UI5Date | Date) { |
| 208 | const oUTCDate = new Date(Date.UTC(0, 0, 1)); // no need to replace with UI5Date as we are creating a new UTC date object |
| 209 | |
| 210 | oUTCDate.setUTCFullYear(oDate.getFullYear(), oDate.getMonth(), oDate.getDate()); |
| 211 | |
| 212 | return oUTCDate; |
| 213 | } |
| 214 | |
| 215 | function checkCalendarDate(oCalendarDate: CalendarDate) { |
| 216 | if (!(oCalendarDate instanceof CalendarDate)) { |
no test coverage detected
searching dependent graphs…