MCPcopy
hub / github.com/google/guava / newTreeMap

Method newTreeMap

guava/src/com/google/common/collect/Maps.java:363–369  ·  view source on GitHub ↗

Creates a <i>mutable</i>, empty {@code TreeMap} instance using the natural ordering of its elements. <p><b>Note:</b> if mutability is not required, use {@link ImmutableSortedMap#of()} instead. <p><b>Note:</b> this method is now unnecessary and should be treated as deprecated. Instead, use the {@co

()

Source from the content-addressed store, hash-verified

361 * @return a new, empty {@code TreeMap}
362 */
363 @SuppressWarnings({
364 "rawtypes", // https://github.com/google/guava/issues/989
365 "NonApiType", // acts as a direct substitute for a constructor call
366 })
367 public static <K extends Comparable, V extends @Nullable Object> TreeMap<K, V> newTreeMap() {
368 return new TreeMap<>();
369 }
370
371 /**
372 * Creates a <i>mutable</i> {@code TreeMap} instance with the same mappings as the specified map

Callers 15

differenceMethod · 0.95
copyOfMethod · 0.95
TreeRangeMapMethod · 0.95
createMapMethod · 0.95
createMethod · 0.95
testTransformEqualsMethod · 0.95
makeEmptyMapMethod · 0.95
makePopulatedMapMethod · 0.95
testTreeMapMethod · 0.95
testTreeMapDerivedMethod · 0.95
testTreeMapNonGenericMethod · 0.95

Calls

no outgoing calls

Tested by 15

createMethod · 0.76
testTransformEqualsMethod · 0.76
makeEmptyMapMethod · 0.76
makePopulatedMapMethod · 0.76
testTreeMapMethod · 0.76
testTreeMapDerivedMethod · 0.76
testTreeMapNonGenericMethod · 0.76
createMethod · 0.76