Tabnine Logo
SortOrder.compare
Code IndexAdd Tabnine to your IDE (free)

How to use
compare
method
in
org.h2.result.SortOrder

Best Java code snippets using org.h2.result.SortOrder.compare (Showing top 7 results out of 315)

origin: com.h2database/h2

  @Override
  public int compare(Value v1, Value v2) {
    Value[] a1 = ((ValueArray) v1).getList();
    Value[] a2 = ((ValueArray) v2).getList();
    return sortOrder.compare(a1, a2);
  }
});
origin: com.h2database/h2

  @Override
  public int compare(Value v1, Value v2) {
    Value[] a1 = ((ValueArray) v1).getList();
    Value[] a2 = ((ValueArray) v2).getList();
    return sortOrder.compare(a1, a2);
  }
});
origin: com.eventsourcing/h2

  @Override
  public int compare(Value v1, Value v2) {
    Value[] a1 = ((ValueArray) v1).getList();
    Value[] a2 = ((ValueArray) v2).getList();
    return sortOrder.compare(a1, a2);
  }
});
origin: org.wowtools/h2

  @Override
  public int compare(Value v1, Value v2) {
    Value[] a1 = ((ValueArray) v1).getList();
    Value[] a2 = ((ValueArray) v2).getList();
    return sortOrder.compare(a1, a2);
  }
});
origin: com.h2database/com.springsource.org.h2

private int compareTapes(ResultDiskTape a, ResultDiskTape b) throws SQLException {
  Value[] va = (Value[]) a.buffer.get(0);
  Value[] vb = (Value[]) b.buffer.get(0);
  return sort.compare(va, vb);
}
origin: com.h2database/com.springsource.org.h2

  public int compare(Object o1, Object o2) {
    try {
      Value[] a1 = ((ValueArray) o1).getList();
      Value[] a2 = ((ValueArray) o2).getList();
      return sort.compare(a1, a2);
    } catch (SQLException e) {
      throw Message.convertToInternal(e);
    }
  }
});
origin: com.h2database/com.springsource.org.h2

if (compare((Value[]) rows.get(l), (Value[]) rows.get(r)) > 0) {
  swap(rows, l, r);
if (compare((Value[]) rows.get(i), (Value[]) rows.get(l)) < 0) {
  swap(rows, l, i);
} else if (compare((Value[]) rows.get(i), (Value[]) rows.get(r)) > 0) {
  swap(rows, i, r);
  do {
    ++i;
  } while (compare((Value[]) rows.get(i), p) < 0);
  do {
    --j;
  } while (compare((Value[]) rows.get(j), p) > 0);
  if (i >= j) {
    break;
for (j = i - 1; j >= l && (compare((Value[]) rows.get(j), t) > 0); j--) {
  rows.set(j + 1, rows.get(j));
org.h2.resultSortOrdercompare

Javadoc

Compare two expression lists.

Popular methods of SortOrder

  • getSortTypes
    Get the sort order bit masks.
  • <init>
    Construct a new sort order object.
  • compareNull
  • getQueryColumnIndexes
    Get the column index list. This is the column indexes of the order by expressions within the query.
  • getSQL
    Create the SQL snippet that describes this sort order. This is the SQL snippet that usually appears
  • sort
  • getColumn
    Get the column for the given table filter, if the sort column is for this filter.
  • addExplicitNullPosition
    Returns a sort type bit mask with #NULLS_FIRST or #NULLS_LASTexplicitly set, depending on SysPropert
  • getIndexes
  • getSortTypesWithNullPosition
    Returns sort order bit masks with #NULLS_FIRST or #NULLS_LASTexplicitly set, depending on SysPropert
  • swap
  • swap

Popular in Java

  • Creating JSON documents from java classes using gson
  • getResourceAsStream (ClassLoader)
  • compareTo (BigDecimal)
  • setContentView (Activity)
  • Point (java.awt)
    A point representing a location in (x,y) coordinate space, specified in integer precision.
  • BigDecimal (java.math)
    An immutable arbitrary-precision signed decimal.A value is represented by an arbitrary-precision "un
  • Queue (java.util)
    A collection designed for holding elements prior to processing. Besides basic java.util.Collection o
  • Callable (java.util.concurrent)
    A task that returns a result and may throw an exception. Implementors define a single method with no
  • ExecutorService (java.util.concurrent)
    An Executor that provides methods to manage termination and methods that can produce a Future for tr
  • HttpServlet (javax.servlet.http)
    Provides an abstract class to be subclassed to create an HTTP servlet suitable for a Web site. A sub
  • 21 Best IntelliJ Plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now