Tabnine Logo
ImmutableLHashSeparateKVShortByteMapGO$ImmutableEntry.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
net.openhft.koloboke.collect.impl.hash.ImmutableLHashSeparateKVShortByteMapGO$ImmutableEntry
constructor

Best Java code snippets using net.openhft.koloboke.collect.impl.hash.ImmutableLHashSeparateKVShortByteMapGO$ImmutableEntry.<init> (Showing top 20 results out of 315)

origin: net.openhft/koloboke-impl-jdk8

@Override
public void forEachRemaining(@Nonnull Consumer<? super Map.Entry<Short, Byte>> action) {
  if (action == null)
    throw new java.lang.NullPointerException();
  short[] keys = this.keys;
  byte[] vals = this.vals;
  short free = this.free;
  int nextI = nextIndex;
  for (int i = nextI; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      action.accept(new ImmutableEntry(key, vals[i]));
    }
  }
  if (nextI != nextIndex) {
    throw new java.util.ConcurrentModificationException();
  }
  nextIndex = -1;
}
origin: net.openhft/koloboke-impl-jdk8

@Override
public void forEachForward(Consumer<? super Map.Entry<Short, Byte>> action) {
  if (action == null)
    throw new java.lang.NullPointerException();
  short[] keys = this.keys;
  byte[] vals = this.vals;
  short free = this.free;
  int index = this.index;
  for (int i = index - 1; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      action.accept(new ImmutableEntry(key, vals[i]));
    }
  }
  if (index != this.index) {
    throw new java.util.ConcurrentModificationException();
  }
  this.index = -1;
  curKey = free;
}
origin: net.openhft/koloboke-impl-jdk6-7

@Override
public void forEachRemaining(@Nonnull Consumer<? super Map.Entry<Short, Byte>> action) {
  if (action == null)
    throw new java.lang.NullPointerException();
  short[] keys = this.keys;
  byte[] vals = this.vals;
  short free = this.free;
  int nextI = nextIndex;
  for (int i = nextI; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      action.accept(new ImmutableEntry(key, vals[i]));
    }
  }
  if (nextI != nextIndex) {
    throw new java.util.ConcurrentModificationException();
  }
  nextIndex = -1;
}
origin: net.openhft/koloboke-impl-jdk6-7

@Override
@SuppressWarnings("unchecked")
@Nonnull
public final <T> T[] toArray(@Nonnull T[] a) {
  int size = size();
  if (a.length < size) {
    Class<?> elementType = a.getClass().getComponentType();
    a = (T[]) java.lang.reflect.Array.newInstance(elementType, size);
  }
  if (size == 0) {
    if (a.length > 0)
      a[0] = null;
    return a;
  }
  int resultIndex = 0;
  short free = freeValue;
  short[] keys = set;
  byte[] vals = values;
  for (int i = keys.length - 1; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      a[resultIndex++] = (T) new ImmutableEntry(key, vals[i]);
    }
  }
  if (a.length > resultIndex)
    a[resultIndex] = null;
  return a;
}
origin: net.openhft/koloboke-impl-jdk8

@Override
@SuppressWarnings("unchecked")
@Nonnull
public final <T> T[] toArray(@Nonnull T[] a) {
  int size = size();
  if (a.length < size) {
    Class<?> elementType = a.getClass().getComponentType();
    a = (T[]) java.lang.reflect.Array.newInstance(elementType, size);
  }
  if (size == 0) {
    if (a.length > 0)
      a[0] = null;
    return a;
  }
  int resultIndex = 0;
  short free = freeValue;
  short[] keys = set;
  byte[] vals = values;
  for (int i = keys.length - 1; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      a[resultIndex++] = (T) new ImmutableEntry(key, vals[i]);
    }
  }
  if (a.length > resultIndex)
    a[resultIndex] = null;
  return a;
}
origin: net.openhft/koloboke-impl-jdk8

@Override
public boolean forEachWhile(@Nonnull  Predicate<? super Map.Entry<Short, Byte>> predicate) {
  if (predicate == null)
    throw new java.lang.NullPointerException();
  if (isEmpty())
    return true;
  boolean terminated = false;
  short free = freeValue;
  short[] keys = set;
  byte[] vals = values;
  for (int i = keys.length - 1; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      if (!predicate.test(new ImmutableEntry(key, vals[i]))) {
        terminated = true;
        break;
      }
    }
  }
  return !terminated;
}
origin: net.openhft/koloboke-impl-jdk6-7

@Override
public boolean forEachWhile(@Nonnull  Predicate<? super Map.Entry<Short, Byte>> predicate) {
  if (predicate == null)
    throw new java.lang.NullPointerException();
  if (isEmpty())
    return true;
  boolean terminated = false;
  short free = freeValue;
  short[] keys = set;
  byte[] vals = values;
  for (int i = keys.length - 1; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      if (!predicate.test(new ImmutableEntry(key, vals[i]))) {
        terminated = true;
        break;
      }
    }
  }
  return !terminated;
}
origin: net.openhft/koloboke-impl-jdk8

@Override
@Nonnull
public final Object[] toArray() {
  int size = size();
  Object[] result = new Object[size];
  if (size == 0)
    return result;
  int resultIndex = 0;
  short free = freeValue;
  short[] keys = set;
  byte[] vals = values;
  for (int i = keys.length - 1; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      result[resultIndex++] = new ImmutableEntry(key, vals[i]);
    }
  }
  return result;
}
origin: net.openhft/koloboke-impl-jdk6-7

@Override
public void forEachForward(Consumer<? super Map.Entry<Short, Byte>> action) {
  if (action == null)
    throw new java.lang.NullPointerException();
  short[] keys = this.keys;
  byte[] vals = this.vals;
  short free = this.free;
  int index = this.index;
  for (int i = index - 1; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      action.accept(new ImmutableEntry(key, vals[i]));
    }
  }
  if (index != this.index) {
    throw new java.util.ConcurrentModificationException();
  }
  this.index = -1;
  curKey = free;
}
origin: net.openhft/koloboke-impl-jdk6-7

@Override
public Map.Entry<Short, Byte> next() {
  int nextI;
  if ((nextI = nextIndex) >= 0) {
    short[] keys = this.keys;
    short free = this.free;
    ImmutableEntry prev = next;
    while (--nextI >= 0) {
      short key;
      if ((key = keys[nextI]) != free) {
        next = new ImmutableEntry(key, vals[nextI]);
        break;
      }
    }
    nextIndex = nextI;
    return prev;
  } else {
    throw new java.util.NoSuchElementException();
  }
}
origin: net.openhft/koloboke-impl-jdk8

@Override
public Map.Entry<Short, Byte> next() {
  int nextI;
  if ((nextI = nextIndex) >= 0) {
    short[] keys = this.keys;
    short free = this.free;
    ImmutableEntry prev = next;
    while (--nextI >= 0) {
      short key;
      if ((key = keys[nextI]) != free) {
        next = new ImmutableEntry(key, vals[nextI]);
        break;
      }
    }
    nextIndex = nextI;
    return prev;
  } else {
    throw new java.util.NoSuchElementException();
  }
}
origin: net.openhft/koloboke-impl-jdk6-7

@Override
@Nonnull
public final Object[] toArray() {
  int size = size();
  Object[] result = new Object[size];
  if (size == 0)
    return result;
  int resultIndex = 0;
  short free = freeValue;
  short[] keys = set;
  byte[] vals = values;
  for (int i = keys.length - 1; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      result[resultIndex++] = new ImmutableEntry(key, vals[i]);
    }
  }
  return result;
}
origin: net.openhft/koloboke-impl-jdk6-7

@Override
public final boolean reverseAddAllTo(ObjCollection<? super Map.Entry<Short, Byte>> c) {
  if (isEmpty())
    return false;
  boolean changed = false;
  short free = freeValue;
  short[] keys = set;
  byte[] vals = values;
  for (int i = keys.length - 1; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      changed |= c.add(new ImmutableEntry(key, vals[i]));
    }
  }
  return changed;
}
origin: net.openhft/koloboke-impl-jdk8

@Override
public final boolean reverseAddAllTo(ObjCollection<? super Map.Entry<Short, Byte>> c) {
  if (isEmpty())
    return false;
  boolean changed = false;
  short free = freeValue;
  short[] keys = set;
  byte[] vals = values;
  for (int i = keys.length - 1; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      changed |= c.add(new ImmutableEntry(key, vals[i]));
    }
  }
  return changed;
}
origin: net.openhft/koloboke-impl-jdk6-7

@Override
public final void forEach(@Nonnull Consumer<? super Map.Entry<Short, Byte>> action) {
  if (action == null)
    throw new java.lang.NullPointerException();
  if (isEmpty())
    return;
  short free = freeValue;
  short[] keys = set;
  byte[] vals = values;
  for (int i = keys.length - 1; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      action.accept(new ImmutableEntry(key, vals[i]));
    }
  }
}
origin: net.openhft/koloboke-impl-jdk8

@Override
public final void forEach(@Nonnull Consumer<? super Map.Entry<Short, Byte>> action) {
  if (action == null)
    throw new java.lang.NullPointerException();
  if (isEmpty())
    return;
  short free = freeValue;
  short[] keys = set;
  byte[] vals = values;
  for (int i = keys.length - 1; i >= 0; i--) {
    short key;
    if ((key = keys[i]) != free) {
      action.accept(new ImmutableEntry(key, vals[i]));
    }
  }
}
origin: net.openhft/koloboke-impl-jdk6-7

NoRemovedEntryIterator() {
  short[] keys = this.keys = set;
  byte[] vals = this.vals = values;
  short free = this.free = freeValue;
  int nextI = keys.length;
  while (--nextI >= 0) {
    short key;
    if ((key = keys[nextI]) != free) {
      next = new ImmutableEntry(key, vals[nextI]);
      break;
    }
  }
  nextIndex = nextI;
}
origin: net.openhft/koloboke-impl-jdk8

NoRemovedEntryIterator() {
  short[] keys = this.keys = set;
  byte[] vals = this.vals = values;
  short free = this.free = freeValue;
  int nextI = keys.length;
  while (--nextI >= 0) {
    short key;
    if ((key = keys[nextI]) != free) {
      next = new ImmutableEntry(key, vals[nextI]);
      break;
    }
  }
  nextIndex = nextI;
}
origin: net.openhft/koloboke-impl-jdk6-7

@Override
public Map.Entry<Short, Byte> elem() {
  short curKey;
  if ((curKey = this.curKey) != free) {
    return new ImmutableEntry(curKey, curValue);
  } else {
    throw new java.lang.IllegalStateException();
  }
}
origin: net.openhft/koloboke-impl-jdk8

@Override
public Map.Entry<Short, Byte> elem() {
  short curKey;
  if ((curKey = this.curKey) != free) {
    return new ImmutableEntry(curKey, curValue);
  } else {
    throw new java.lang.IllegalStateException();
  }
}
net.openhft.koloboke.collect.impl.hashImmutableLHashSeparateKVShortByteMapGO$ImmutableEntry<init>

Popular methods of ImmutableLHashSeparateKVShortByteMapGO$ImmutableEntry

    Popular in Java

    • Making http requests using okhttp
    • getOriginalFilename (MultipartFile)
      Return the original filename in the client's filesystem.This may contain path information depending
    • getApplicationContext (Context)
    • orElseThrow (Optional)
      Return the contained value, if present, otherwise throw an exception to be created by the provided s
    • Socket (java.net)
      Provides a client-side TCP socket.
    • Deque (java.util)
      A linear collection that supports element insertion and removal at both ends. The name deque is shor
    • SortedSet (java.util)
      SortedSet is a Set which iterates over its elements in a sorted order. The order is determined eithe
    • Notification (javax.management)
    • Runner (org.openjdk.jmh.runner)
    • Option (scala)
    • Top 12 Jupyter Notebook extensions
    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