public class TimeStampExtractor extends Object
Allows to extract time information from file names.
Usage:
extractTimeStamps(String) to receive the start and stop time of the respective filenameLimitations:
| Modifier and Type | Class and Description |
|---|---|
static class |
TimeStampExtractor.DateInterpretationPatternValidator |
static class |
TimeStampExtractor.FilenameInterpretationPatternValidator |
| Constructor and Description |
|---|
TimeStampExtractor(String dateInterpretationPattern,
String filenameInterpretationPattern)
Creates a new instance with the given date and file interpretation patterns.
|
| Modifier and Type | Method and Description |
|---|---|
ProductData.UTC[] |
extractTimeStamps(String fileName)
Provides the start and stop time of the respective filename.
|
public TimeStampExtractor(String dateInterpretationPattern, String filenameInterpretationPattern)
dateInterpretationPattern - the date interpretation pattern; see class documentation for specification.filenameInterpretationPattern - the filename interpretation pattern; see class documentation for specification.IllegalStateException - if the filename interpretation pattern contains neither ${startDate} nor
${endDate}.public ProductData.UTC[] extractTimeStamps(String fileName) throws ValidationException
fileName - The filename to extract time information from.null.ValidationException - if the given filename does not match the given date pattern.Copyright © 2014–2017 European Space Agency (ESA). All rights reserved.