Crawler crawler = createCrawler(aCrawlerConfig, client, transformer);
InputStream programConfigFile = new FileInputStream(new File(
aProgramConfig));
- ProgramConfigurationParser parser = new ProgramConfigurationParser(
- transformer);
+ ProgramConfigurationParser parser = new ProgramConfigurationParser();
parser.parse(programConfigFile);
List<ProgramFilter> programFilters = parser.getFilters();
import org.wamblee.conditions.Condition;
import org.wamblee.conditions.PropertyRegexCondition;
import org.wamblee.crawler.kiss.guide.Program;
-import org.wamblee.xml.XslTransformer;
/**
* Parse the configuration of desired programs.
*/
class ProgramConfigurationParser {
- private static final int DEFAULT_SMTP_PORT = 25;
-
private static final int DEFAULT_PRIORITY = 1;
- // Formatting configuration.
- private static final String ELEM_FORMAT = "format";
-
- private static final String ELEM_TEXT = "text";
-
- private static final String ELEM_HTML = "html";
-
// Configuration of interesting programs.
private static final String ELEM_PROGRAM = "program";
private static final String ACTION_NOTIFY = "notify";
private List<ProgramFilter> _filters;
-
- private XslTransformer _transformer;
- ProgramConfigurationParser(XslTransformer aTransformer) {
+ ProgramConfigurationParser() {
_filters = null;
- _transformer = aTransformer;
}
/**