Examples of compare()


Examples of org.openstreetmap.osmosis.core.sort.v0_6.EntityContainerComparator.compare()

        if (change == null) {
          change = changePostbox.getNext();
        }
       
        // Compare the two sources.
        comparisonResult = comparator.compare(base, change.getEntityContainer());
       
        if (comparisonResult < 0) {
          processBaseOnlyEntity(base);
          base = null;
         
View Full Code Here

Examples of org.optaplanner.benchmark.impl.ranking.SingleBenchmarkRankingComparator.compare()

        int ranking = 0;
        SingleBenchmarkResult previousSingleBenchmarkResult = null;
        int previousSameRankingCount = 0;
        for (SingleBenchmarkResult singleBenchmarkResult : rankedSingleBenchmarkResultList) {
            if (previousSingleBenchmarkResult != null
                    && singleBenchmarkRankingComparator.compare(previousSingleBenchmarkResult, singleBenchmarkResult) != 0) {
                ranking += previousSameRankingCount;
                previousSameRankingCount = 0;
            }
            singleBenchmarkResult.setRanking(ranking);
            previousSingleBenchmarkResult = singleBenchmarkResult;
View Full Code Here

Examples of org.pdf4j.saxon.sort.GlobalOrderComparer.compare()

            if (item instanceof NodeInfo) {
                NodeInfo node = (NodeInfo)item;
                if (first==null) {
                    first = node;
                } else {
                    if (comparer.compare(node, first) < 0) {
                        first = node;
                    }
                }
            } else {
                XPathException e = new XPathException("Operand of leading() contains an item that is not a node");
View Full Code Here

Examples of org.pdf4j.saxon.sort.LocalOrderComparer.compare()

                    // not ideal for performance, but it's very unusual to have more than
                    // one key definition for a key.
                    LocalOrderComparer comparer = LocalOrderComparer.getInstance();
                    boolean found = false;
                    for (int i=0; i<nodes.size(); i++) {
                        int d = comparer.compare(curr, (NodeInfo)nodes.get(i));
                        if (d<=0) {
                            if (d==0) {
                                // node already in list; do nothing
                            } else {
                                // add the node at this position
View Full Code Here

Examples of org.pentaho.platform.engine.services.solution.SolutionCompare.compare()

    startTest();

    SolutionCompare compare = new SolutionCompare();
    String path1 = PentahoSystem.getApplicationContext().getSolutionPath( "test/platform" ); //$NON-NLS-1$
    String path2 = PentahoSystem.getApplicationContext().getSolutionPath( "test/dashboard" ); //$NON-NLS-1$
    compare.compare( path1, path2 );

    assertTrue( true );
    finishTest();
  }
View Full Code Here

Examples of org.pentaho.reporting.libraries.formula.typing.ExtendedComparator.compare()

    {
      throw EvaluationException.getInstance(LibFormulaErrorValue.ERROR_NA_VALUE);
    }

    final ExtendedComparator comparator = typeRegistry.getComparator(type1, type2);
    final int result = comparator.compare (type1, value1Raw, type2, value2Raw);
    if (evaluate(result))
    {
      return RETURN_TRUE;
    }
    return RETURN_FALSE;
View Full Code Here

Examples of org.pomizer.comparator.RawClassInfoComparator.compare()

        JavaUtils.printToConsole("Calculating index information ...");
        int classListLength = classNames.size();
        for (int i = 0; i < classListLength; i++) {
            RawClassInfo classInfo = classNames.get(i);
            int j = i + 1;
            while ((j < classListLength) && (0 == rawClassInfoComparator.compare(classInfo, classNames.get(j)))) {
                RawClassInfo classInfoToMerge = classNames.get(j);
                for (int k = 0; k < classInfoToMerge.jarInfoList.size(); k++) {
                    if (-1 == classInfo.jarInfoList.indexOf(classInfoToMerge.jarInfoList.get(k))) {
                        classInfo.jarInfoList.add(classInfoToMerge.jarInfoList.get(k));
                    }
View Full Code Here

Examples of org.python.pydev.parser.visitors.comparator.SimpleNodeComparator.compare()

    }

    private void makeCompare(File f, SimpleNode original, SimpleNode node) throws Exception {
        SimpleNodeComparator comparator = new SimpleNodeComparator();
        try {
            comparator.compare(original, node);
        } catch (DifferException e) {
            System.out.println("Compare did not suceed:" + f);
        }
    }
View Full Code Here

Examples of org.rhq.core.domain.drift.DriftDefinitionComparator.compare()

            final HashMap<String, DriftDefinitionTemplate> templatesMap = new HashMap<String, DriftDefinitionTemplate>(
                templates.size());
            DriftDefinitionComparator ddc = new DriftDefinitionComparator(CompareMode.ONLY_DIRECTORY_SPECIFICATIONS);
            for (DriftDefinitionTemplate template : templates) {

                if (0 == ddc.compare(template.getTemplateDefinition(), wizard.getSnapshotDriftDef())) {
                    templatesMap.put(template.getName(), template);
                }
            }

            Set<String> templatesMapKeySet = templatesMap.keySet();
View Full Code Here

Examples of org.rhq.core.domain.util.OSGiVersionComparator.compare()

            OSGiVersionComparator c = new OSGiVersionComparator();

            if (v1 != null && v2 != null) {
                try {
                    return c.compare(v1, v2);
                } catch (IllegalArgumentException e) {
                    //well, this can happen.. not all packages have OSGi type versions.
                }
            }
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.