congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
IntArray.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
org.h2.util.IntArray
constructor

Best Java code snippets using org.h2.util.IntArray.<init> (Showing top 20 results out of 315)

origin: apache/ignite

/**
 *
 * @param partsMap Partitions map.
 * @param parts Partitions.
 * @return Result.
 */
private static Map<ClusterNode, IntArray> narrowForQuery(Map<ClusterNode, IntArray> partsMap, int[] parts) {
  if (parts == null)
    return partsMap;
  Map<ClusterNode, IntArray> cp = U.newHashMap(partsMap.size());
  for (Map.Entry<ClusterNode, IntArray> entry : partsMap.entrySet()) {
    IntArray filtered = new IntArray(parts.length);
    IntArray orig = entry.getValue();
    for (int i = 0; i < orig.size(); i++) {
      int p = orig.get(i);
      if (Arrays.binarySearch(parts, p) >= 0)
        filtered.add(p);
    }
    if (filtered.size() > 0)
      cp.put(entry.getKey(), filtered);
  }
  return cp.isEmpty() ? null : cp;
}
origin: com.h2database/h2

/**
 * Free up all reserved pages.
 */
void freeReserved() {
  if (reservedPages.size() > 0) {
    int[] array = new int[reservedPages.size()];
    reservedPages.toArray(array);
    reservedPages = new IntArray();
    reserved = 0;
    for (int p : array) {
      store.free(p, false);
    }
  }
}
origin: apache/ignite

partIds = new IntArray();
origin: com.h2database/h2

IntArray paramColumnIndex = new IntArray();
int indexColumnCount = 0;
for (int i = 0; i < masks.length; i++) {
origin: com.h2database/h2

IntArray list = new IntArray();
list.add(t.getPos());
for (int i = 0;; i++) {
origin: apache/ignite

res.put(n, parts = new IntArray());
origin: com.h2database/com.springsource.org.h2

public void truncate(Session session) throws SQLException {
  freeList = new IntArray();
  recordCount = 0;
  file.truncateStorage(session, this, pages);
}
origin: org.apache.ignite/ignite-indexing

/** */
private Map<ClusterNode, IntArray> narrowForQuery(Map<ClusterNode, IntArray> partsMap, int[] parts) {
  if (parts == null)
    return partsMap;
  Map<ClusterNode, IntArray> cp = U.newHashMap(partsMap.size());
  for (Map.Entry<ClusterNode, IntArray> entry : partsMap.entrySet()) {
    IntArray filtered = new IntArray(parts.length);
    IntArray orig = entry.getValue();
    for (int i = 0; i < orig.size(); i++) {
      int p = orig.get(i);
      if (Arrays.binarySearch(parts, p) >= 0)
        filtered.add(p);
    }
    if (filtered.size() > 0)
      cp.put(entry.getKey(), filtered);
  }
  return cp.isEmpty() ? null : cp;
}
origin: com.h2database/com.springsource.org.h2

BtreeNode(BtreeIndex index, DataPage s) throws SQLException {
  super(index);
  int len = s.readInt();
  int[] array = new int[len];
  for (int i = 0; i < array.length; i++) {
    array[i] = s.readInt();
  }
  pageChildren = new IntArray(array);
  pageData = index.readRowArray(s);
}
origin: com.h2database/com.springsource.org.h2

private void reset() {
  used = new BitField();
  deleted = new BitField();
  pageOwners = new IntArray();
  // init pageOwners
  setBlockCount(fileBlockCount);
  redoBuffer = new ObjectArray();
  potentiallyFreePages = new HashSet();
}
origin: com.eventsourcing/h2

/**
 * Free up all reserved pages.
 */
void freeReserved() {
  if (reservedPages.size() > 0) {
    int[] array = new int[reservedPages.size()];
    reservedPages.toArray(array);
    reservedPages = new IntArray();
    reserved = 0;
    for (int p : array) {
      store.free(p, false);
    }
  }
}
origin: org.wowtools/h2

/**
 * Free up all reserved pages.
 */
void freeReserved() {
  if (reservedPages.size() > 0) {
    int[] array = new int[reservedPages.size()];
    reservedPages.toArray(array);
    reservedPages = new IntArray();
    reserved = 0;
    for (int p : array) {
      store.free(p, false);
    }
  }
}
origin: org.apache.ignite/ignite-indexing

partIds = new IntArray();
origin: com.h2database/com.springsource.org.h2

BtreeNode(BtreeIndex index, BtreePage left, SearchRow pivot, BtreePage right) {
  super(index);
  pageChildren = new IntArray();
  pageChildren.add(left.getPos());
  pageChildren.add(right.getPos());
  pageData = new ObjectArray();
  pageData.add(pivot);
}
origin: com.h2database/com.springsource.org.h2

public PlanItem getBestPlanItem(Session session, int[] masks) throws SQLException {
  PlanItem item = new PlanItem();
  item.cost = index.getCost(session, masks);
  IntArray masksArray = new IntArray(masks == null ? new int[0] : masks);
  ViewIndex i2 = (ViewIndex) indexCache.get(masksArray);
  if (i2 == null || i2.getSession() != session) {
    i2 = new ViewIndex(this, index, session, masks);
    indexCache.put(masksArray, i2);
  }
  item.setIndex(i2);
  return item;
}
origin: com.h2database/com.springsource.org.h2

public double getCost(Session session, int[] masks) throws SQLException {
  IntArray masksArray = new IntArray(masks == null ? new int[0] : masks);
  CostElement cachedCost = (CostElement) costCache.get(masksArray);
  if (cachedCost != null) {
    columns = new Column[0];
  } else {
    IntArray paramIndex = new IntArray();
    for (int i = 0; i < masks.length; i++) {
      int mask = masks[i];
origin: org.wowtools/h2

IntArray list = new IntArray();
list.add(t.getPos());
for (int i = 0;; i++) {
origin: com.eventsourcing/h2

IntArray list = new IntArray();
list.add(t.getPos());
for (int i = 0;; i++) {
origin: com.h2database/com.springsource.org.h2

IntArray paramIndex = new IntArray();
for (int i = 0; i < masks.length; i++) {
  int mask = masks[i];
origin: com.h2database/com.springsource.org.h2

public BtreePage split(Session session, int splitPoint) throws SQLException {
  ObjectArray data = new ObjectArray();
  IntArray children = new IntArray();
  splitPoint++;
  int max = pageData.size();
  if (SysProperties.CHECK && index.getDatabase().getLogIndexChanges() && !getDeleted()) {
    // page must have been deleted already before calling
    // getSplitPoint()
    throw Message.getInternalError();
  }
  for (int i = splitPoint; i < max; i++) {
    data.add(getData(splitPoint));
    children.add(getChild(splitPoint));
    pageData.remove(splitPoint);
    pageChildren.remove(splitPoint);
  }
  children.add(getChild(splitPoint));
  pageData.remove(splitPoint - 1);
  pageChildren.remove(splitPoint);
  BtreeNode n2 = new BtreeNode(index, children, data);
  index.updatePage(session, this);
  index.addPage(session, n2);
  return n2;
}
org.h2.utilIntArray<init>

Javadoc

Create an int array with the default initial capacity.

Popular methods of IntArray

  • add
  • get
    Get the value at the given index.
  • size
    Get the size of the list.
  • toArray
    Convert this list to an array. The target array must be big enough.
  • hashCode
  • remove
    Remove the value at the given index.
  • ensureCapacity
    Ensure the the underlying array is large enough for the given number of entries.
  • removeRange
    Remove a number of elements.
  • addValueSorted
  • checkCapacity
  • findNextValueIndex
  • removeValue
  • findNextValueIndex,
  • removeValue,
  • set

Popular in Java

  • Parsing JSON documents to java classes using gson
  • findViewById (Activity)
  • getSharedPreferences (Context)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • Kernel (java.awt.image)
  • Thread (java.lang)
    A thread is a thread of execution in a program. The Java Virtual Machine allows an application to ha
  • KeyStore (java.security)
    KeyStore is responsible for maintaining cryptographic keys and their owners. The type of the syste
  • Permission (java.security)
    Legacy security code; do not use.
  • ResourceBundle (java.util)
    ResourceBundle is an abstract class which is the superclass of classes which provide Locale-specifi
  • JTextField (javax.swing)
  • Top PhpStorm plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

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