@Test public void testExtractTimeStamps_8() throws ParseException, ValidationException { final TimeStampExtractor extractor = new TimeStampExtractor("yyyyMMdd_hhmmss", "*${endDate}*"); ProductData.UTC[] dateRange = extractor.extractTimeStamps( "MER_RR__2CNACR20070123_101652_000000072055_00008_25613_0000.nc"); assertEquals(2, dateRange.length); assertEquals(ProductData.UTC.parse("2007-01-23:10:16:52", "yyyy-MM-dd:HH:mm:ss").getAsDate().getTime(), dateRange[0].getAsDate().getTime()); assertEquals(dateRange[0].getAsDate().getTime(), dateRange[1].getAsDate().getTime()); }
public ProductData.UTC[] extractTimeStamps(String fileName) throws ValidationException { final ProductData.UTC startTime = timeStampAccess.getStartTime(fileName); final ProductData.UTC stopTime = timeStampAccess.getStopTime(fileName); return new ProductData.UTC[]{startTime, stopTime}; }
TimeStampExtractor { public ProductData.UTC[] extractTimeStamps(String fileName) throws ValidationException { final ProductData.UTC startTime = timeStampAccess.getStartTime(fileName); final ProductData.UTC stopTime = timeStampAccess.getStopTime(fileName); return new ProductData.UTC[]{startTime, stopTime}; } }
TimeStampExtractor { public ProductData.UTC[] extractTimeStamps(String fileName) throws ValidationException { final ProductData.UTC startTime = timeStampAccess.getStartTime(fileName); final ProductData.UTC stopTime = timeStampAccess.getStopTime(fileName); return new ProductData.UTC[]{startTime, stopTime}; } TimeStampExtractor(String dateInterpretationPattern, String filenameInterpretationPattern); }
TimeStampExtractor { public ProductData.UTC[] extractTimeStamps(String fileName) throws ValidationException { final ProductData.UTC startTime = timeStampAccess.getStartTime(fileName); final ProductData.UTC stopTime = timeStampAccess.getStopTime(fileName); return new ProductData.UTC[]{startTime, stopTime}; } TimeStampExtractor(String dateInterpretationPattern, String filenameInterpretationPattern); ProductData.UTC[] extractTimeStamps(String fileName); }
TimeStampExtractor { public ProductData.UTC[] extractTimeStamps(String fileName) throws ValidationException { final ProductData.UTC startTime = timeStampAccess.getStartTime(fileName); final ProductData.UTC stopTime = timeStampAccess.getStopTime(fileName); return new ProductData.UTC[]{startTime, stopTime}; } TimeStampExtractor(String dateInterpretationPattern, String filenameInterpretationPattern); ProductData.UTC[] extractTimeStamps(String fileName);  }