Examples of evaluate()


Examples of org.hibernate.validator.constraints.impl.scriptassert.ScriptEvaluator.evaluate()

  public boolean isValid(Object value, ConstraintValidatorContext constraintValidatorContext) {

    ScriptEvaluator scriptEvaluator = ScriptEvaluatorFactory.getInstance()
        .getScriptEvaluatorByLanguageName( languageName );

    return scriptEvaluator.evaluate( script, value, alias );
  }

  private void validateParameters(ScriptAssert constraintAnnotation) {

    if ( constraintAnnotation.script().isEmpty() ) {

Examples of org.hibernate.validator.internal.util.scriptengine.ScriptEvaluator.evaluate()

        catch ( ScriptException e ) {
            throw new ConstraintDeclarationException( e );
        }

        try {
            evaluationResult = scriptEvaluator.evaluate( script, value, alias );
        }
        catch ( ScriptException e ) {
            throw log.getErrorDuringScriptExecutionException( script, e );
        }

Examples of org.hibernate.validator.util.scriptengine.ScriptEvaluator.evaluate()

    catch ( ScriptException e ) {
      throw new ConstraintDeclarationException( e );
    }

    try {
      evaluationResult = scriptEvaluator.evaluate( script, value, alias );
    }
    catch ( ScriptException e ) {
      throw new ConstraintDeclarationException(
          "Error during execution of script \"" + script + "\" occurred.", e
      );

Examples of org.htmlparser.scanners.AppletScanner.evaluate()

    }

    public void testEvaluate()
    {
        AppletScanner scanner = new AppletScanner("-a");
        boolean retVal = scanner.evaluate("   Applet ", null);
        assertEquals(
            "Evaluation of APPLET tag",
            new Boolean(true),
            new Boolean(retVal));
    }

Examples of org.htmlparser.scanners.FormScanner.evaluate()

        String line2 =
            "FORM method=\"post\" onsubmit=\"return implementsearch()\" name=frmsearch id=form";
        String line3 =
            "Form method=\"post\" onsubmit=\"return implementsearch()\" name=frmsearch id=form";
        FormScanner formScanner = new FormScanner("", Parser.createParser(""));
        assertTrue("Line 1", formScanner.evaluate(line1, null));
        assertTrue("Line 2", formScanner.evaluate(line2, null));
        assertTrue("Line 3", formScanner.evaluate(line3, null));
    }

    public void assertTypeNameSize(

Examples of org.htmlparser.scanners.FrameSetScanner.evaluate()

        String line2 =
            "FRAMESET rows=\"115,*\" frameborder=\"NO\" border=\"0\" framespacing=\"0\"";
        String line3 =
            "Frameset rows=\"115,*\" frameborder=\"NO\" border=\"0\" framespacing=\"0\"";
        FrameSetScanner frameSetScanner = new FrameSetScanner("");
        assertTrue("Line 1", frameSetScanner.evaluate(line1, null));
        assertTrue("Line 2", frameSetScanner.evaluate(line2, null));
        assertTrue("Line 3", frameSetScanner.evaluate(line3, null));
    }

    public void testScan() throws ParserException

Examples of org.htmlparser.scanners.ImageScanner.evaluate()

    }

    public void testEvaluate()
    {
        ImageScanner scanner = new ImageScanner("-i", new LinkProcessor());
        boolean retVal = scanner.evaluate("   img ", null);
        assertEquals(
            "Evaluation of IMG tag",
            new Boolean(true),
            new Boolean(retVal));
    }

Examples of org.htmlparser.scanners.LinkScanner.evaluate()

    }

    public void testEvaluate()
    {
        LinkScanner scanner = new LinkScanner("-l");
        boolean retVal = scanner.evaluate("   a href ", null);
        assertEquals(
            "Evaluation of the Link tag",
            new Boolean(true),
            new Boolean(retVal));
    }

Examples of org.htmlparser.scanners.ScriptScanner.evaluate()

    }

    public void testEvaluate()
    {
        ScriptScanner scanner = new ScriptScanner("-s");
        boolean retVal = scanner.evaluate("   script ", null);
        assertEquals(
            "Evaluation of SCRIPT tag",
            new Boolean(true),
            new Boolean(retVal));
    }

Examples of org.htmlparser.scanners.StyleScanner.evaluate()

    }

    public void testEvaluate()
    {
        StyleScanner scanner = new StyleScanner("-s");
        boolean retVal = scanner.evaluate("style ", null);
        assertEquals(
            "Evaluation of STYLE tag",
            new Boolean(true),
            new Boolean(retVal));
    }
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.