Examples of addRule()


Examples of net.opentsdb.tree.Tree.addRule()

  }
 
  @Test
  public void addRule() throws Exception {
    final Tree tree = new Tree();
    tree.addRule(new TreeRule());
    assertNotNull(tree.getRules());
    assertEquals(1, tree.getRules().size());
  }
 
  @Test
View Full Code Here

Examples of net.sf.saxon.trans.Mode.addRule()

            pat.setLineNumber(getLineNumber());
            NodeTest nt;
            if (s.equals("*")) {
                nt = AnyNodeTest.getInstance();
                pat.setNodeTest(nt);
                stripperRules.addRule(
                            pat,
                            preserve,
                            getPrecedence(),
                            -0.5, true);

View Full Code Here

Examples of net.sourceforge.segment.srx.LanguageRule.addRule()

        } else {
          after = "";
        }

        Rule rule = new Rule(breakRule, before, after);
        languageRule.addRule(rule);
      }
      languageRuleMap.put(languageRule.getName(), languageRule);
    }

    for (Languagemap lm : body.getMaprules().getLanguagemap()) {
View Full Code Here

Examples of org.apache.catalina.util.CatalinaDigester.addRule()

                            "org.apache.catalina.LifecycleListener");

        digester.addObjectCreate("Server/Service/Connector",
                                 "org.apache.coyote.tomcat5.CoyoteConnector",
                                 "className");
        digester.addRule("Server/Service/Connector",
                         new SetAllPropertiesRule());
        digester.addSetNext("Server/Service/Connector",
                            "addConnector",
                            "org.apache.catalina.Connector");
View Full Code Here

Examples of org.apache.catalina.util.xml.XmlMapper.addRule()

                       mapper.methodSetter("setSmallIcon", 0));
        mapper.addRule("web-app/filter/init-param",
                       mapper.methodSetter("addInitParameter", 2));
        mapper.addRule("web-app/filter/init-param/param-name",
                       mapper.methodParam(0));
        mapper.addRule("web-app/filter/init-param/param-value",
                       mapper.methodParam(1));

        mapper.addRule("web-app/filter-mapping",
                  mapper.objectCreate("org.apache.catalina.deploy.FilterMap"));
        mapper.addRule("web-app/filter-mapping",
View Full Code Here

Examples of org.apache.cocoon.maven.deployer.monolithic.RuleBasedZipExtractor.addRule()

            File lib = (File) entry.getValue();
            try {
                log.debug("Scanning " + id);
                RuleBasedZipExtractor zipExtractor = new RuleBasedZipExtractor(basedir, log);
                // add the matching/execution rules
                zipExtractor.addRule("META-INF/cocoon/xpatch/*.xweb", xwebPatcher);
                // extract all configurations files
                zipExtractor.extract(lib);
            } catch (IOException e) {
                throw new DeploymentException("Can't deploy '" + lib.getAbsolutePath() + "'.", e);
            }
View Full Code Here

Examples of org.apache.commons.betwixt.io.BeanReader.addRule()

       
        TestRule ruleOne = new TestRule();
        TestRule ruleTwo = new TestRule();
       
        // add a test rule before the bean rules
        reader.addRule("!*/ListOfNames/names/name", ruleOne);
        reader.registerBeanClass(ListOfNames.class);
        // add a test rule after the bean rules
        reader.addRule("!*/ListOfNames/names/name", ruleTwo);
       
        ListOfNames newListOfNames = (ListOfNames) reader.parse(new StringReader(xml));
View Full Code Here

Examples of org.apache.commons.digester.Digester.addRule()

        digester.addRuleSet(new ContextRuleSet("Server/Service/Engine/Host/Default"));
        digester.addRuleSet(new NamingRuleSet("Server/Service/Engine/Host/DefaultContext/"));
        digester.addRuleSet(new ContextRuleSet("Server/Service/Engine/Host/"));
        digester.addRuleSet(new NamingRuleSet("Server/Service/Engine/Host/Context/"));

        digester.addRule("Server/Service/Engine",
                         new SetParentClassLoaderRule(digester,
                                                      parentClassLoader));


        return (digester);
View Full Code Here

Examples of org.apache.commons.digester3.Digester.addRule()

        digester.setSubstitutor( new VariableSubstitutor( expander ) );

        int useRootObj = -1;
        Class<?>[] callerArgTypes = new Class[] { String.class, String.class };
        CallMethodRule caller = new CallMethodRule( useRootObj, "addProperty", callerArgTypes.length, callerArgTypes );
        digester.addRule( "root/property", caller );
        digester.addCallParam( "root/property", 0, "name" );
        digester.addCallParam( "root/property", 1, "value" );

        digester.addObjectCreate( "root/bean", SimpleTestBean.class );
        digester.addSetProperties( "root/bean" );
View Full Code Here

Examples of org.apache.hadoop.gateway.filter.rewrite.api.UrlRewriteRulesDescriptor.addRule()

    @Override
    public void end( String namespace, String name ) throws Exception {
      Digester digester = getDigester();
      UrlRewriteRuleDescriptor rule = digester.pop();
      UrlRewriteRulesDescriptor rules = digester.peek();
      rules.addRule( rule );
    }
  }

  private class StepFactory extends FactoryRule {
    @Override
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.