Example usage for org.apache.commons.digester RegexRules RegexRules

List of usage examples for org.apache.commons.digester RegexRules RegexRules

Introduction

In this page you can find the example usage for org.apache.commons.digester RegexRules RegexRules.

Prototype

public RegexRules(RegexMatcher matcher) 

Source Link

Document

Construct sets the Regex matching strategy.

Usage

From source file:org.bedework.dumprestore.restore.Restore.java

/**
 * @param info - to track status/*from w w w  .j  a  v  a 2 s  . c om*/
 * @throws Throwable
 */
public void doRestore(final InfoLines info) throws Throwable {
    if (newSystem) {
        createNewSystem();

        return;
    }

    globals.info = info;
    globals.digester = new Digester();

    RegexMatcher m = new SimpleRegexMatcher();
    globals.digester.setRules(new RegexRules(m));

    globals.digester.addRuleSet(new RestoreRuleSet(globals));
    globals.digester.parse(new InputStreamReader(new FileInputStream(filename), "UTF-8"));
}