List of usage examples for org.apache.commons.digester3 FactoryCreateRule FactoryCreateRule
public FactoryCreateRule(ObjectCreationFactory<?> creationFactory)
Construct a factory create rule using the given, already instantiated, ObjectCreationFactory .
From source file:org.apache.hadoop.gateway.descriptor.xml.XmlGatewayDescriptorRules.java
@Override protected void configure() { forPattern(GATEWAY).addRule(new FactoryCreateRule(XmlGatewayDescriptorFactory.class)); forPattern(GATEWAY + "/" + RESOURCE).addRule(new AddNextRule("addResource")); forPattern(GATEWAY + "/" + RESOURCE + "/" + RESOURCE_ROLE).callMethod("role").usingElementBodyAsArgument(); forPattern(GATEWAY + "/" + RESOURCE + "/" + RESOURCE_PATTERN).callMethod("pattern") .usingElementBodyAsArgument(); forPattern(GATEWAY + "/" + RESOURCE + "/" + FILTER).addRule(new AddNextRule("addFilter")); forPattern(GATEWAY + "/" + RESOURCE + "/" + FILTER + "/" + FILTER_ROLE).callMethod("name") .usingElementBodyAsArgument(); forPattern(GATEWAY + "/" + RESOURCE + "/" + FILTER + "/" + FILTER_ROLE).callMethod("role") .usingElementBodyAsArgument(); forPattern(GATEWAY + "/" + RESOURCE + "/" + FILTER + "/" + FILTER_IMPL).callMethod("impl") .usingElementBodyAsArgument(); forPattern(GATEWAY + "/" + RESOURCE + "/" + FILTER + "/" + FILTER_PARAM).addRule(new AddNextRule("param")); forPattern(GATEWAY + "/" + RESOURCE + "/" + FILTER + "/" + FILTER_PARAM + "/" + FILTER_PARAM_NAME) .callMethod("name").usingElementBodyAsArgument(); forPattern(GATEWAY + "/" + RESOURCE + "/" + FILTER + "/" + FILTER_PARAM + "/" + FILTER_PARAM_VALUE) .callMethod("value").usingElementBodyAsArgument(); }