}
public void executeStatistics(String cfgdata, Map<Tokens, String> layerUpdateProperties, String destFileName) throws JAXBException, IOException {
LOGGER.debug("Statistics input properties"+layerUpdateProperties.toString());
StatisticConfiguration cfg = (StatisticConfiguration) unmarshaller.unmarshal(new StringReader(cfgdata));
TokenResolver<StatisticConfiguration, Tokens> resolver =
new TokenResolver(cfg, StatisticConfiguration.class);
resolver.putAll(layerUpdateProperties);
cfg = (StatisticConfiguration)resolver.resolve();
// initialize the file when saving statistics
cfg.getOutput().setFile(destFileName);
StatsRunner runner = new StatsRunner(cfg);
runner.run();
}