Examples of matches()


Examples of com.volantis.styling.impl.engine.matchers.DefaultNamespaceMatcher.matches()

        MatcherResult result;

        // CDM namespace should match.
        matcherContextMock.expects.getNamespace()
                .returns(XDIMESchemata.CDM_NAMESPACE);
        result = matcher.matches(matcherContextMock);
        assertEquals(result, MatcherResult.MATCHED);

        // XHTML 2 namespace should match.
        matcherContextMock.expects.getNamespace()
                .returns(XDIMESchemata.XHTML2_NAMESPACE);

Examples of com.volantis.styling.impl.engine.matchers.LocalNameMatcher.matches()

        // =====================================================================
        //   Test Expectations
        // =====================================================================

        Matcher matcher = new LocalNameMatcher("xyz");
        MatcherResult actual = matcher.matches(matcherContextMock);
        assertEquals("Wrong result", MatcherResult.MATCHED, actual);
    }

    /**
     * Test that it matches the current elements local name.

Examples of com.volantis.styling.impl.engine.matchers.Matcher.matches()

        // =====================================================================
        //   Test Expectations
        // =====================================================================

        Matcher matcher = new AttributeMatcher(null, "local", constraintMock);
        MatcherResult actual = matcher.matches(matcherContextMock);
        assertEquals("Wrong result", MatcherResult.MATCHED, actual);
    }

    /**
     * Test that it invokes the constraintMock properly and returns the correct

Examples of com.volantis.styling.impl.engine.matchers.NamespaceMatcher.matches()

        // =====================================================================
        //   Test Expectations
        // =====================================================================

        Matcher matcher = new NamespaceMatcher("xyz");
        MatcherResult actual = matcher.matches(matcherContextMock);
        assertEquals("Wrong result", MatcherResult.MATCHED, actual);
    }

    /**
     * Test that it matches the current elements local name.

Examples of com.volantis.styling.impl.engine.matchers.NthChildMatcher.matches()

                // =====================================================================
                //   Test Expectations
                // =====================================================================

                Matcher matcher = new NthChildMatcher(a, b);
                MatcherResult actual = matcher.matches(matcherContextMock);
                assertEquals("Wrong result for position " + p +
                             " within sequence " + sequence + " with " +
                             a + "n + " + b,
                             sequence.expectedResult, actual);
            }

Examples of com.volantis.testtools.mock.value.ExpectedValue.matches()

        // Assume that all the actual value matched.
        boolean matched = true;
        for (int i = 0; i < expectedValues.length; i++) {
            ExpectedValue expectedValue = expectedValues[i];
            Object actualValue = actualValues[i];
            if (!expectedValue.matches(actualValue)) {
                matched = false;
            }
        }

        if (!matched) {

Examples of com.xmultra.util.Strings.matches()

    String dbUtilsConfigDocString =
        fileUtils.readFile(new File(configDocString));
    String dbUtilsConfigDTDFile = fileUtils.addRoot("defs/db_utils_cfg.dtd");

    // Add the DTD with root to the config file.
    if (strings.matches(" SYSTEM\\s+\".+\"\\s*>",
                        dbUtilsConfigDocString)) {
      dbUtilsConfigDocString = strings.getPreMatch() + " SYSTEM \"" +
          dbUtilsConfigDTDFile + "\">" + strings.getPostMatch();
    }

Examples of de.danielbechler.diff.path.NodePath.matches()

  }

  public void node(final DiffNode node, final Visit visit)
  {
    final NodePath differencePath = node.getPath();
    if (differencePath.matches(nodePath) || differencePath.isParentOf(nodePath))
    {
      if (differencePath.matches(nodePath))
      {
        this.node = node;
        visit.stop();

Examples of de.desy.tine.stringUtils.WildcardMatch.matches()

          {
            if ((dev=deviceList.getDevice(i)) == null) continue;
            if (dev.isOffline()) continue;
            if (mask > 0 && !dev.isMaskSet(mask)) continue;
            dn = dev.getName();
            if (!wc.matches(dn)) continue;
            nl.add(dn);
            n++;
          }
          namlst = nl.toArray(new String[n]);
        }

Examples of de.susebox.jtopas.impl.PatternMatcher.matches()

      PatternHandler.Result bestResult   = null;
     
      // only get the string if pattern are available
      for (int index = 0; index < _patterns.size(); ++index) {
        PatternMatcher        data = (PatternMatcher)_patterns.get(index);
        PatternHandler.Result result = data.matches(dataProvider);

        if (result != null) {
          if (bestResult == null || bestResult.getLengthOfMatch() < result.getLengthOfMatch()) {
            bestResult = result;
          }
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.