1 2class FormatString { 3 4 formatAMPM(dateTime) { 5 6 var startTimeRex = dateTime.replace(/T|\:\d{1,2}Z/g,' '); 7 var startTimeFormat = new Date(startTimeRex); 8 9 var hours = startTimeFormat.getHours(); 10 var minutes = startTimeFormat.getMinutes(); 11 var ampm = hours >= 12 ? 'pm' : 'am'; 12 13 hours = hours % 12; 14 hours = hours ? hours : 12; 15 minutes = minutes < 10 ? '0'+minutes : minutes; 16 var completedTime = hours + ':' + minutes + ampm; 17 18 return completedTime; 19 20 } 21 22 formatDate(dateTime) { 23 24 var startTimeRex = dateTime.replace(/T|\:\d{1,2}Z/g,' '); 25 var startTimeFormat = new Date(startTimeRex); 26 27 var dd = startTimeFormat.getDate(); 28 var mm = startTimeFormat.getMonth() + 1; 29 var yyyy = startTimeFormat.getFullYear(); 30 31 var completedDate = mm + '/' + dd + '/' + yyyy; 32 33 return completedDate; 34 35 } 36 37} 38
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.