Examples of accept()


Examples of cleo.search.connection.RandomConnectionFilter.accept()

   
    boolean rejected = false;
    boolean accepted = false;
   
    while(!rejected) {
      rejected = !connFilter.accept(conn);
    }
   
    while(!accepted) {
      accepted = connFilter.accept(conn);
    }
View Full Code Here

Examples of cleo.search.connection.SourcePartitionConnectionFilter.accept()

    int count = rand.nextInt(10000) + 100;
    Range sourceRange = new Range(start, count);
    ConnectionFilter connFilter = new SourcePartitionConnectionFilter(sourceRange);
   
    Connection conn = new SimpleConnection(0, rand.nextInt(), true);
    assertEquals(false, connFilter.accept(conn));
   
    conn = new SimpleConnection(rand.nextInt(start), rand.nextInt(), true);
    assertEquals(false, connFilter.accept(conn));
   
    conn = new SimpleConnection(start + rand.nextInt(count), rand.nextInt(), true);
View Full Code Here

Examples of cleo.search.connection.TargetPartitionConnectionFilter.accept()

    int count = rand.nextInt(10000) + 100;
    Range targetRange = new Range(start, count);
    ConnectionFilter connFilter = new TargetPartitionConnectionFilter(targetRange);
   
    Connection conn = new SimpleConnection(rand.nextInt(), 0, true);
    assertEquals(false, connFilter.accept(conn));
   
    conn = new SimpleConnection(rand.nextInt(), rand.nextInt(start), true);
    assertEquals(false, connFilter.accept(conn));
   
    conn = new SimpleConnection(rand.nextInt(), start + rand.nextInt(count), true);
View Full Code Here

Examples of cleo.search.connection.TransitivePartitionConnectionFilter.accept()

    ConnectionFilter connFilter = new TransitivePartitionConnectionFilter(range);
    Connection conn;
   
    // Source in range
    conn = new SimpleConnection(3100, 1, true);
    assertEquals(true, connFilter.accept(conn));
   
    conn = new SimpleConnection(3100, 3200, true);
    assertEquals(true, connFilter.accept(conn));

    conn = new SimpleConnection(3100, 5000, true);
View Full Code Here

Examples of com.alibaba.citrus.asm.ClassReader.accept()

            ConstantPool cp = new ConstantPool();
            ClassReader cr = new ClassReader(new FileInputStream(f));
            ClassWriter cw = new ClassWriter(0);
            ClassConstantsCollector ccc = new ClassConstantsCollector(cw, cp);
            ClassOptimizer co = new ClassOptimizer(ccc, remapper);
            cr.accept(co, ClassReader.SKIP_DEBUG);

            Set constants = new TreeSet(new ConstantComparator());
            constants.addAll(cp.values());

            cr = new ClassReader(cw.toByteArray());
View Full Code Here

Examples of com.alibaba.citrus.asm.signature.SignatureReader.accept()

        SignatureWriter w = new SignatureWriter();
        SignatureVisitor a = createRemappingSignatureAdapter(w);
        if (typeSignature) {
            r.acceptType(a);
        } else {
            r.accept(a);
        }
        return w.toString();
    }

    protected SignatureVisitor createRemappingSignatureAdapter(SignatureVisitor v) {
View Full Code Here

Examples of com.alibaba.citrus.springext.util.DomUtil.ElementSelector.accept()

            else if (resourceAliasSelector.accept(subElement)) {
                resourceMappings.add(parseAlias(subElement, parserContext));
            }

            // <resource-filters>
            else if (resourceFiltersSelector.accept(subElement)) {
                filterMappings.add(parseFilters(subElement, parserContext));
            }
        }

        builder.addPropertyValue("resourceMappings", resourceMappings);
View Full Code Here

Examples of com.alibaba.citrus.util.templatelite.Template.accept()

        } else {
            Template tpl = new Template(resource);
            PrintWriter out = request.getWriter(contentType);

            // 对于模板文件中,${url:relativeUrl}将被转换成完整的URL
            tpl.accept(new TextWriter<PrintWriter>(out) {
                @SuppressWarnings("unused")
                public void visitUrl(String relativeUrl) {
                    out().print(request.getResourceURL(relativeUrl));
                }
            });
View Full Code Here

Examples of com.alibaba.druid.sql.ast.SQLCommentHint.accept()

        print("SELECT ");

        for (int i = 0, size = x.getHintsSize(); i < size; ++i) {
            SQLCommentHint hint = x.getHints().get(i);
            hint.accept(this);
            print(' ');
        }

        if (SQLSetQuantifier.ALL == x.getDistionOption()) {
            print("ALL ");
View Full Code Here

Examples of com.alibaba.druid.sql.ast.SQLExpr.accept()

            print("(");
            printAndAccept(x.getParameters(), ", ");
            SQLExpr from = (SQLExpr) x.getAttribute("FROM");
            if (from != null) {
                print(" FROM ");
                from.accept(this);
            }

            SQLExpr _for = (SQLExpr) x.getAttribute("FOR");
            if (_for != null) {
                print(" FOR ");
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.