congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
ObjectArraySet.findKey
Code IndexAdd Tabnine to your IDE (free)

How to use
findKey
method
in
it.unimi.dsi.fastutil.objects.ObjectArraySet

Best Java code snippets using it.unimi.dsi.fastutil.objects.ObjectArraySet.findKey (Showing top 3 results out of 315)

origin: it.unimi.dsi/fastutil

@Override
public boolean contains(final Object k) {
  return findKey(k) != -1;
}
@Override
origin: it.unimi.dsi/fastutil

@Override
public boolean remove(final Object k) {
  final int pos = findKey(k);
  if (pos == -1)
    return false;
  final int tail = size - pos - 1;
  for (int i = 0; i < tail; i++)
    a[pos + i] = a[pos + i + 1];
  size--;
  a[size] = null;
  return true;
}
@Override
origin: it.unimi.dsi/fastutil

@Override
public boolean add(final K k) {
  final int pos = findKey(k);
  if (pos != -1)
    return false;
  if (size == a.length) {
    final Object[] b = new Object[size == 0 ? 2 : size * 2];
    for (int i = size; i-- != 0;)
      b[i] = a[i];
    a = b;
  }
  a[size++] = k;
  return true;
}
@Override
it.unimi.dsi.fastutil.objectsObjectArraySetfindKey

Popular methods of ObjectArraySet

  • <init>
    Creates a new array set using the given backing array and the given number of elements of the array.
  • add
  • addAll

Popular in Java

  • Making http post requests using okhttp
  • findViewById (Activity)
  • onRequestPermissionsResult (Fragment)
  • getSharedPreferences (Context)
  • VirtualMachine (com.sun.tools.attach)
    A Java virtual machine. A VirtualMachine represents a Java virtual machine to which this Java vir
  • Permission (java.security)
    Legacy security code; do not use.
  • Locale (java.util)
    Locale represents a language/country/variant combination. Locales are used to alter the presentatio
  • Pattern (java.util.regex)
    Patterns are compiled regular expressions. In many cases, convenience methods such as String#matches
  • ZipFile (java.util.zip)
    This class provides random read access to a zip file. You pay more to read the zip file's central di
  • JButton (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