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

How to use
ForwardingNavigableMap
in
com.google.common.collect

Best Java code snippets using com.google.common.collect.ForwardingNavigableMap (Showing top 20 results out of 315)

origin: google/guava

/**
 * A sensible definition of {@link #ceilingKey} in terms of {@code ceilingEntry}. If you override
 * {@code ceilingEntry}, you may wish to override {@code ceilingKey} to forward to this
 * implementation.
 */
protected K standardCeilingKey(K key) {
 return keyOrNull(ceilingEntry(key));
}
origin: google/guava

@Override
public K lowerKey(K key) {
 return delegate().lowerKey(key);
}
origin: google/guava

/**
 * A sensible definition of {@link #lastEntry} in terms of the {@code iterator()} of the {@link
 * #entrySet} of {@link #descendingMap}. If you override {@code descendingMap}, you may wish to
 * override {@code lastEntry} to forward to this implementation.
 */
protected Entry<K, V> standardLastEntry() {
 return Iterables.getFirst(descendingMap().entrySet(), null);
}
origin: google/guava

/**
 * A sensible definition of {@link #lowerKey} in terms of {@code lowerEntry}. If you override
 * {@link #lowerEntry}, you may wish to override {@code lowerKey} to forward to this
 * implementation.
 */
protected K standardLowerKey(K key) {
 return keyOrNull(lowerEntry(key));
}
origin: google/guava

/**
 * A sensible definition of {@link #higherKey} in terms of {@code higherEntry}. If you override
 * {@code higherEntry}, you may wish to override {@code higherKey} to forward to this
 * implementation.
 */
protected K standardHigherKey(K key) {
 return keyOrNull(higherEntry(key));
}
origin: google/guava

/**
 * A sensible definition of {@link #floorKey} in terms of {@code floorEntry}. If you override
 * {@code floorEntry}, you may wish to override {@code floorKey} to forward to this
 * implementation.
 */
protected K standardFloorKey(K key) {
 return keyOrNull(floorEntry(key));
}
origin: google/guava

/**
 * A sensible definition of {@link #firstEntry} in terms of the {@code iterator()} of {@link
 * #entrySet}. If you override {@code entrySet}, you may wish to override {@code firstEntry} to
 * forward to this implementation.
 */
protected Entry<K, V> standardFirstEntry() {
 return Iterables.getFirst(entrySet(), null);
}
origin: google/guava

/**
 * A sensible definition of {@link #headMap(Object)} in terms of {@link #headMap(Object,
 * boolean)}. If you override {@code headMap(K, boolean)}, you may wish to override {@code
 * headMap} to forward to this implementation.
 */
protected SortedMap<K, V> standardHeadMap(K toKey) {
 return headMap(toKey, false);
}
origin: google/guava

/**
 * A sensible definition of {@link #lastKey} in terms of {@code lastEntry}. If you override {@code
 * lastEntry}, you may wish to override {@code lastKey} to forward to this implementation.
 */
protected K standardLastKey() {
 Entry<K, V> entry = lastEntry();
 if (entry == null) {
  throw new NoSuchElementException();
 } else {
  return entry.getKey();
 }
}
origin: google/guava

/**
 * A sensible definition of {@link #firstKey} in terms of {@code firstEntry}. If you override
 * {@code firstEntry}, you may wish to override {@code firstKey} to forward to this
 * implementation.
 */
protected K standardFirstKey() {
 Entry<K, V> entry = firstEntry();
 if (entry == null) {
  throw new NoSuchElementException();
 } else {
  return entry.getKey();
 }
}
origin: google/j2objc

/**
 * A sensible definition of {@link #lowerKey} in terms of {@code lowerEntry}. If you override
 * {@link #lowerEntry}, you may wish to override {@code lowerKey} to forward to this
 * implementation.
 */
protected K standardLowerKey(K key) {
 return keyOrNull(lowerEntry(key));
}
origin: google/j2objc

/**
 * A sensible definition of {@link #higherKey} in terms of {@code higherEntry}. If you override
 * {@code higherEntry}, you may wish to override {@code higherKey} to forward to this
 * implementation.
 */
protected K standardHigherKey(K key) {
 return keyOrNull(higherEntry(key));
}
origin: google/j2objc

/**
 * A sensible definition of {@link #floorKey} in terms of {@code floorEntry}. If you override
 * {@code floorEntry}, you may wish to override {@code floorKey} to forward to this
 * implementation.
 */
protected K standardFloorKey(K key) {
 return keyOrNull(floorEntry(key));
}
origin: google/j2objc

/**
 * A sensible definition of {@link #firstEntry} in terms of the {@code iterator()} of {@link
 * #entrySet}. If you override {@code entrySet}, you may wish to override {@code firstEntry} to
 * forward to this implementation.
 */
protected Entry<K, V> standardFirstEntry() {
 return Iterables.getFirst(entrySet(), null);
}
origin: google/j2objc

/**
 * A sensible definition of {@link #headMap(Object)} in terms of {@link #headMap(Object,
 * boolean)}. If you override {@code headMap(K, boolean)}, you may wish to override {@code
 * headMap} to forward to this implementation.
 */
protected SortedMap<K, V> standardHeadMap(K toKey) {
 return headMap(toKey, false);
}
origin: google/j2objc

/**
 * A sensible definition of {@link #lastKey} in terms of {@code lastEntry}. If you override {@code
 * lastEntry}, you may wish to override {@code lastKey} to forward to this implementation.
 */
protected K standardLastKey() {
 Entry<K, V> entry = lastEntry();
 if (entry == null) {
  throw new NoSuchElementException();
 } else {
  return entry.getKey();
 }
}
origin: google/j2objc

/**
 * A sensible definition of {@link #firstKey} in terms of {@code firstEntry}. If you override
 * {@code firstEntry}, you may wish to override {@code firstKey} to forward to this
 * implementation.
 */
protected K standardFirstKey() {
 Entry<K, V> entry = firstEntry();
 if (entry == null) {
  throw new NoSuchElementException();
 } else {
  return entry.getKey();
 }
}
origin: google/guava

/**
 * A sensible definition of {@link #pollFirstEntry} in terms of the {@code iterator} of the {@code
 * entrySet} of {@code descendingMap}. If you override {@code descendingMap}, you may wish to
 * override {@code pollFirstEntry} to forward to this implementation.
 */
protected Entry<K, V> standardPollLastEntry() {
 return Iterators.pollNext(descendingMap().entrySet().iterator());
}
origin: google/j2objc

/**
 * A sensible definition of {@link #ceilingKey} in terms of {@code ceilingEntry}. If you override
 * {@code ceilingEntry}, you may wish to override {@code ceilingKey} to forward to this
 * implementation.
 */
protected K standardCeilingKey(K key) {
 return keyOrNull(ceilingEntry(key));
}
origin: wildfly/wildfly

/**
 * A sensible definition of {@link #lowerKey} in terms of {@code lowerEntry}. If you override
 * {@link #lowerEntry}, you may wish to override {@code lowerKey} to forward to this
 * implementation.
 */
protected K standardLowerKey(K key) {
 return keyOrNull(lowerEntry(key));
}
com.google.common.collectForwardingNavigableMap

Javadoc

A navigable map which forwards all its method calls to another navigable map. Subclasses should override one or more methods to modify the behavior of the backing map as desired per the decorator pattern.

Warning: The methods of ForwardingNavigableMap forward indiscriminately to the methods of the delegate. For example, overriding #put alone will not change the behavior of #putAll, which can lead to unexpected behavior. In this case, you should override putAll as well, either providing your own implementation, or delegating to the provided standardPutAll method.

default method warning: This class does not forward calls to default methods. Instead, it inherits their default implementations. When those implementations invoke methods, they invoke methods on the ForwardingNavigableMap.

Each of the standard methods uses the map's comparator (or the natural ordering of the elements, if there is no comparator) to test element equality. As a result, if the comparator is not consistent with equals, some of the standard implementations may violate the Mapcontract.

The standard methods and the collection views they return are not guaranteed to be thread-safe, even when all of the methods that they depend on are thread-safe.

Most used methods

  • ceilingEntry
  • delegate
  • descendingMap
  • entrySet
  • firstEntry
  • floorEntry
  • headMap
  • higherEntry
  • lastEntry
  • lowerEntry
  • subMap
  • tailMap
  • subMap,
  • tailMap,
  • put,
  • putAll

Popular in Java

  • Finding current android device location
  • onCreateOptionsMenu (Activity)
  • getSupportFragmentManager (FragmentActivity)
  • runOnUiThread (Activity)
  • FlowLayout (java.awt)
    A flow layout arranges components in a left-to-right flow, much like lines of text in a paragraph. F
  • BufferedImage (java.awt.image)
    The BufferedImage subclass describes an java.awt.Image with an accessible buffer of image data. All
  • Format (java.text)
    The base class for all formats. This is an abstract base class which specifies the protocol for clas
  • Scanner (java.util)
    A parser that parses a text string of primitive types and strings with the help of regular expressio
  • TreeMap (java.util)
    Walk the nodes of the tree left-to-right or right-to-left. Note that in descending iterations, next
  • ExecutorService (java.util.concurrent)
    An Executor that provides methods to manage termination and methods that can produce a Future for tr
  • Github Copilot alternatives
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