| Package | Description |
|---|---|
| com.google.common.base |
Basic utility libraries and interfaces.
|
| com.google.common.cache |
This package contains caching utilities.
|
| com.google.common.collect |
This package contains generic collection interfaces and implementations, and
other utilities for working with collections.
|
| com.google.common.io |
This package contains utility methods and classes for working with Java I/O;
for example input streams, output streams, readers, writers, and files.
|
| com.google.common.math |
Arithmetic functions operating on primitive values and
BigInteger instances. |
| com.google.common.primitives |
Static utilities for working with the eight primitive types and
void,
and value types for treating them as unsigned. |
| Modifier and Type | Class and Description |
|---|---|
private static class |
CharMatcher.BitSetMatcher |
private static class |
Predicates.AssignableFromPredicate |
private static class |
Predicates.ContainsPatternFromStringPredicate |
private static class |
Predicates.ContainsPatternPredicate |
private static class |
Predicates.InstanceOfPredicate |
(package private) class |
SmallCharMatcher
An immutable version of CharMatcher for smallish sets of characters that uses a hash table
with linear probing to check for matches.
|
class |
StandardSystemProperty
Represents a standard system property.
|
| Modifier and Type | Field and Description |
|---|---|
private static java.util.Map<java.lang.Class<? extends java.lang.Enum<?>>,java.util.Map<java.lang.String,java.lang.ref.WeakReference<? extends java.lang.Enum<?>>>> |
Enums.enumConstantCache |
static java.nio.charset.Charset |
Charsets.ISO_8859_1
ISO-8859-1: ISO Latin Alphabet Number 1 (ISO-LATIN-1).
|
static java.nio.charset.Charset |
Charsets.US_ASCII
US-ASCII: seven-bit ASCII, the Basic Latin block of the Unicode character set (ISO646-US).
|
static java.nio.charset.Charset |
Charsets.UTF_16
UTF-16: sixteen-bit UCS Transformation Format, byte order identified by an optional byte-order
mark.
|
static java.nio.charset.Charset |
Charsets.UTF_16BE
UTF-16BE: sixteen-bit UCS Transformation Format, big-endian byte order.
|
static java.nio.charset.Charset |
Charsets.UTF_16LE
UTF-16LE: sixteen-bit UCS Transformation Format, little-endian byte order.
|
| Modifier and Type | Method and Description |
|---|---|
static Predicate<java.lang.Class<?>> |
Predicates.assignableFrom(java.lang.Class<?> clazz)
Returns a predicate that evaluates to
true if the class being
tested is assignable from the given class. |
static Predicate<java.lang.CharSequence> |
Predicates.contains(java.util.regex.Pattern pattern)
Returns a predicate that evaluates to
true if the
CharSequence being tested contains any match for the given
regular expression pattern. |
static Predicate<java.lang.CharSequence> |
Predicates.containsPattern(java.lang.String pattern)
Returns a predicate that evaluates to
true if the
CharSequence being tested contains any match for the given
regular expression pattern. |
(package private) static <T extends java.lang.Enum<T>> |
Enums.getEnumConstants(java.lang.Class<T> enumClass) |
static java.lang.reflect.Field |
Enums.getField(java.lang.Enum<?> enumValue)
Returns the
Field in which enumValue is defined. |
static Predicate<java.lang.Object> |
Predicates.instanceOf(java.lang.Class<?> clazz)
Returns a predicate that evaluates to
true if the object being
tested is an instance of the given class. |
private static boolean |
CharMatcher.isSmall(int totalCharacters,
int tableLength) |
static Splitter |
Splitter.on(java.util.regex.Pattern separatorPattern)
Returns a splitter that considers any subsequence matching
pattern to be a separator. |
static Splitter |
Splitter.onPattern(java.lang.String separatorPattern)
Returns a splitter that considers any subsequence matching a given
pattern (regular expression) to be a separator.
|
private static <T extends java.lang.Enum<T>> |
Enums.populateCache(java.lang.Class<T> enumClass) |
(package private) CharMatcher |
CharMatcher.precomputedInternal()
This is the actual implementation of
CharMatcher.precomputed(), but we bounce calls through a
method on Platform so that we can have different behavior in GWT. |
private static CharMatcher |
CharMatcher.precomputedPositive(int totalCharacters,
java.util.BitSet table,
java.lang.String description)
Helper method for
CharMatcher.precomputedInternal() that doesn't test if the negation is cheaper. |
(package private) void |
CharMatcher.setBits(java.util.BitSet table)
Sets bits in
table matched by this matcher. |
(package private) void |
CharMatcher.NegatedMatcher.setBits(java.util.BitSet table) |
(package private) void |
CharMatcher.And.setBits(java.util.BitSet table) |
(package private) void |
CharMatcher.Or.setBits(java.util.BitSet table) |
java.lang.String |
Stopwatch.toString()
Returns a string representation of the current elapsed time.
|
| Modifier and Type | Method and Description |
|---|---|
static <K,V> CacheLoader<K,V> |
CacheLoader.asyncReloading(CacheLoader<K,V> loader,
java.util.concurrent.Executor executor)
Returns a
CacheLoader which wraps loader, executing calls to
CacheLoader.reload(K, V) using executor. |
java.util.Set<java.util.Map.Entry<K,V>> |
LocalCache.entrySet() |
static CacheBuilder<java.lang.Object,java.lang.Object> |
CacheBuilder.from(CacheBuilderSpec spec)
Constructs a new
CacheBuilder instance with the settings specified in spec. |
static CacheBuilder<java.lang.Object,java.lang.Object> |
CacheBuilder.from(java.lang.String spec)
Constructs a new
CacheBuilder instance with the settings specified in spec. |
(package private) CacheBuilder<K,V> |
CacheBuilder.keyEquivalence(Equivalence<java.lang.Object> equivalence)
Sets a custom
Equivalence strategy for comparing keys. |
(package private) CacheBuilder<K,V> |
CacheBuilder.lenientParsing()
Enables lenient parsing.
|
CacheBuilder<K,V> |
CacheBuilder.maximumWeight(long weight)
Specifies the maximum weight of entries the cache may contain.
|
CacheBuilder<K,V> |
CacheBuilder.refreshAfterWrite(long duration,
java.util.concurrent.TimeUnit unit)
Specifies that active entries are eligible for automatic refresh once a fixed duration has
elapsed after the entry's creation, or the most recent replacement of its value.
|
ListenableFuture<V> |
CacheLoader.reload(K key,
V oldValue)
Computes or retrieves a replacement value corresponding to an already-cached
key. |
CacheBuilder<K,V> |
CacheBuilder.softValues()
Specifies that each value (not key) stored in the cache should be wrapped in a
SoftReference (by default, strong references are used). |
(package private) CacheBuilder<K,V> |
CacheBuilder.valueEquivalence(Equivalence<java.lang.Object> equivalence)
Sets a custom
Equivalence strategy for comparing values. |
CacheBuilder<K,V> |
CacheBuilder.weakKeys()
Specifies that each key (not value) stored in the cache should be wrapped in a
WeakReference (by default, strong references are used). |
CacheBuilder<K,V> |
CacheBuilder.weakValues()
Specifies that each value (not key) stored in the cache should be wrapped in a
WeakReference (by default, strong references are used). |
<K1 extends K,V1 extends V> |
CacheBuilder.weigher(Weigher<? super K1,? super V1> weigher)
Specifies the weigher to use in determining the weight of entries.
|
| Modifier and Type | Class and Description |
|---|---|
(package private) class |
AbstractMapBasedMultimap.NavigableAsMap |
(package private) class |
AbstractMapBasedMultimap.NavigableKeySet |
(package private) class |
AbstractMapBasedMultimap.WrappedNavigableSet |
private static class |
EmptyContiguousSet.SerializedForm<C extends java.lang.Comparable> |
class |
EvictingQueue<E>
A non-blocking queue which automatically evicts elements from the head of the queue when
attempting to add new elements onto the queue and it is full.
|
(package private) static class |
GenericMapMaker.NullListener
Deprecated.
|
(package private) static class |
ImmutableAsList.SerializedForm
Serialized form that leads to the same performance as the original list.
|
(package private) class |
ImmutableMapEntry<K,V>
Implementation of
Map.Entry for ImmutableMap that adds extra methods to traverse
hash buckets for the key and the value. |
private static class |
ImmutableMapEntrySet.EntrySetSerializedForm<K,V> |
private static class |
ImmutableMapKeySet.KeySetSerializedForm<K> |
private static class |
ImmutableMapValues.SerializedForm<V> |
(package private) static class |
ImmutableMultimap.FieldSettersHolder |
class |
ImmutableRangeMap<K extends java.lang.Comparable<?>,V>
An immutable implementation of
RangeMap, supporting all query operations efficiently. |
class |
ImmutableSortedMultiset<E>
An immutable
SortedMultiset that stores its elements in a sorted array. |
(package private) static class |
Maps.DescendingMap<K,V> |
private static class |
Maps.FilteredEntryNavigableMap<K,V> |
private static class |
Maps.NavigableAsMapView<K,V> |
(package private) static class |
Maps.NavigableKeySet<K,V> |
private static class |
Maps.TransformedEntriesNavigableMap<K,V1,V2> |
(package private) static class |
Maps.UnmodifiableNavigableMap<K,V> |
private static class |
RegularContiguousSet.SerializedForm<C extends java.lang.Comparable> |
(package private) static class |
Sets.DescendingSet<E> |
private static class |
Sets.FilteredNavigableSet<E> |
(package private) static class |
Sets.UnmodifiableNavigableSet<E> |
(package private) static class |
SortedMultisets.NavigableElementSet<E>
A skeleton navigable implementation for
SortedMultiset.elementSet(). |
private static class |
Synchronized.SynchronizedDeque<E> |
private static class |
Synchronized.SynchronizedEntry<K,V> |
(package private) static class |
Synchronized.SynchronizedNavigableMap<K,V> |
(package private) static class |
Synchronized.SynchronizedNavigableSet<E> |
class |
TreeRangeMap<K extends java.lang.Comparable,V>
An implementation of
RangeMap based on a TreeMap, supporting
all optional operations. |
class |
TreeRangeSet<C extends java.lang.Comparable<?>>
An implementation of
RangeSet backed by a TreeMap. |
| Modifier and Type | Field and Description |
|---|---|
(package private) ImmutableSortedSet<E> |
ImmutableSortedSet.descendingSet |
(package private) MapMaker.RemovalListener<K0,V0> |
GenericMapMaker.removalListener
Deprecated.
|
private static long |
AbstractBiMap.serialVersionUID |
private static long |
AbstractBiMap.Inverse.serialVersionUID |
private static long |
AbstractMapBasedMultiset.serialVersionUID |
private static long |
ArrayListMultimap.serialVersionUID |
private static long |
EnumBiMap.serialVersionUID |
private static long |
EnumHashBiMap.serialVersionUID |
private static long |
EnumMultiset.serialVersionUID |
private static long |
HashBiMap.serialVersionUID |
private static long |
HashMultimap.serialVersionUID |
private static long |
HashMultiset.serialVersionUID |
private static long |
ImmutableListMultimap.serialVersionUID |
private static long |
ImmutableSetMultimap.serialVersionUID |
private static long |
LinkedHashMultimap.serialVersionUID |
private static long |
LinkedHashMultiset.serialVersionUID |
private static long |
LinkedListMultimap.serialVersionUID |
private static long |
Multimaps.CustomMultimap.serialVersionUID |
private static long |
Multimaps.CustomListMultimap.serialVersionUID |
private static long |
Multimaps.CustomSetMultimap.serialVersionUID |
private static long |
Multimaps.CustomSortedSetMultimap.serialVersionUID |
private static long |
Synchronized.SynchronizedObject.serialVersionUID |
private static long |
TreeMultimap.serialVersionUID |
private static long |
TreeMultiset.serialVersionUID |
| Modifier and Type | Method and Description |
|---|---|
java.util.NavigableMap<K,java.util.Collection<V>> |
TreeMultimap.asMap()
Returns a map view that associates each key with the corresponding values
in the multimap.
|
static <K,V> java.util.NavigableMap<K,V> |
Maps.asMap(java.util.NavigableSet<K> set,
Function<? super K,V> function)
Returns a view of the navigable set as a map, mapping keys from the set
according to the specified function.
|
(package private) java.util.NavigableMap<K,java.util.Collection<V>> |
TreeMultimap.backingMap() |
E |
ImmutableSortedSet.ceiling(E e) |
static <T> T[] |
ObjectArrays.concat(T[] first,
T[] second,
java.lang.Class<T> type)
Returns a new array that contains the concatenated contents of two arrays.
|
(package private) int |
ImmutableMultimap.Values.copyIntoArray(java.lang.Object[] dst,
int offset) |
(package private) int |
ImmutableMultiset.copyIntoArray(java.lang.Object[] dst,
int offset) |
(package private) int |
RegularImmutableAsList.copyIntoArray(java.lang.Object[] dst,
int offset) |
(package private) java.util.NavigableMap<K,java.util.Collection<V>> |
TreeMultimap.createAsMap() |
(package private) ImmutableSortedSet<E> |
DescendingImmutableSortedSet.createDescendingSet() |
(package private) ImmutableSortedSet<C> |
EmptyContiguousSet.createDescendingSet() |
(package private) ImmutableSortedSet<E> |
ImmutableSortedSet.createDescendingSet() |
(package private) java.util.NavigableSet<K> |
TreeMultimap.createKeySet() |
(package private) static <E> java.util.Deque<E> |
Synchronized.deque(java.util.Deque<E> deque,
java.lang.Object mutex) |
UnmodifiableIterator<E> |
DescendingImmutableSortedSet.descendingIterator() |
UnmodifiableIterator<C> |
EmptyContiguousSet.descendingIterator() |
UnmodifiableIterator<E> |
EmptyImmutableSortedSet.descendingIterator() |
UnmodifiableIterator<C> |
ImmutableRangeSet.AsSet.descendingIterator() |
abstract UnmodifiableIterator<E> |
ImmutableSortedSet.descendingIterator() |
UnmodifiableIterator<C> |
RegularContiguousSet.descendingIterator() |
UnmodifiableIterator<E> |
RegularImmutableSortedSet.descendingIterator() |
ImmutableSortedSet<E> |
DescendingImmutableSortedSet.descendingSet() |
ImmutableSortedSet<E> |
ImmutableSortedSet.descendingSet() |
(package private) abstract GenericMapMaker<K0,V0> |
GenericMapMaker.expireAfterAccess(long duration,
java.util.concurrent.TimeUnit unit)
Deprecated.
|
(package private) MapMaker |
MapMaker.expireAfterAccess(long duration,
java.util.concurrent.TimeUnit unit)
Deprecated.
Caching functionality in
MapMaker has been moved to
CacheBuilder, with MapMaker.expireAfterAccess(long, java.util.concurrent.TimeUnit) being
replaced by CacheBuilder.expireAfterAccess(long, java.util.concurrent.TimeUnit). Note that
CacheBuilder is simply an enhanced API for an implementation which was branched
from MapMaker. |
<T> FluentIterable<T> |
FluentIterable.filter(java.lang.Class<T> type)
Returns the elements from this fluent iterable that are instances of class
type. |
static <T> java.lang.Iterable<T> |
Iterables.filter(java.lang.Iterable<?> unfiltered,
java.lang.Class<T> type)
Returns all instances of class
type in unfiltered. |
static <T> UnmodifiableIterator<T> |
Iterators.filter(java.util.Iterator<?> unfiltered,
java.lang.Class<T> type)
Returns all instances of class
type in unfiltered. |
static <E> java.util.NavigableSet<E> |
Sets.filter(java.util.NavigableSet<E> unfiltered,
Predicate<? super E> predicate)
Returns the elements of a
NavigableSet, unfiltered, that
satisfy a predicate. |
static <K,V> java.util.NavigableMap<K,V> |
Maps.filterEntries(java.util.NavigableMap<K,V> unfiltered,
Predicate<? super java.util.Map.Entry<K,V>> entryPredicate)
Returns a sorted map containing the mappings in
unfiltered that
satisfy a predicate. |
private static <K,V> java.util.NavigableMap<K,V> |
Maps.filterFiltered(Maps.FilteredEntryNavigableMap<K,V> map,
Predicate<? super java.util.Map.Entry<K,V>> entryPredicate)
Support
clear(), removeAll(), and retainAll() when
filtering a filtered navigable map. |
static <K,V> java.util.NavigableMap<K,V> |
Maps.filterKeys(java.util.NavigableMap<K,V> unfiltered,
Predicate<? super K> keyPredicate)
Returns a navigable map containing the mappings in
unfiltered whose
keys satisfy a predicate. |
static <K,V> java.util.NavigableMap<K,V> |
Maps.filterValues(java.util.NavigableMap<K,V> unfiltered,
Predicate<? super V> valuePredicate)
Returns a navigable map containing the mappings in
unfiltered whose
values satisfy a predicate. |
E |
ImmutableSortedSet.floor(E e) |
static ImmutableMap<java.lang.String,java.lang.String> |
Maps.fromProperties(java.util.Properties properties)
Creates an
ImmutableMap<String, String> from a Properties
instance. |
java.util.NavigableSet<V> |
TreeMultimap.get(K key) |
(package private) <K extends K0,V extends V0> |
GenericMapMaker.getRemovalListener()
Deprecated.
|
ContiguousSet<C> |
ContiguousSet.headSet(C toElement,
boolean inclusive) |
ImmutableSortedSet<E> |
ImmutableSortedSet.headSet(E toElement,
boolean inclusive) |
E |
ImmutableSortedSet.higher(E e) |
(package private) int |
EmptyContiguousSet.indexOf(java.lang.Object target) |
int |
ImmutableSortedAsList.indexOf(java.lang.Object target) |
(package private) int |
RegularContiguousSet.indexOf(java.lang.Object target) |
(package private) abstract GenericMapMaker<K0,V0> |
GenericMapMaker.keyEquivalence(Equivalence<java.lang.Object> equivalence)
Deprecated.
|
(package private) MapMaker |
MapMaker.keyEquivalence(Equivalence<java.lang.Object> equivalence)
Sets a custom
Equivalence strategy for comparing keys. |
java.util.NavigableSet<K> |
TreeMultimap.keySet()
Returns a view collection of all distinct keys contained in this
multimap.
|
int |
ImmutableSortedAsList.lastIndexOf(java.lang.Object target) |
E |
ImmutableSortedSet.lower(E e) |
(package private) abstract <K,V> MapMakerInternalMap<K,V> |
GenericMapMaker.makeCustomMap()
Deprecated.
|
(package private) <K,V> MapMakerInternalMap<K,V> |
MapMaker.makeCustomMap()
Returns a MapMakerInternalMap for the benefit of internal callers that use features of
that class not exposed through ConcurrentMap.
|
(package private) static <K,V> java.util.NavigableMap<K,V> |
Synchronized.navigableMap(java.util.NavigableMap<K,V> navigableMap) |
(package private) static <K,V> java.util.NavigableMap<K,V> |
Synchronized.navigableMap(java.util.NavigableMap<K,V> navigableMap,
java.lang.Object mutex) |
(package private) static <E> java.util.NavigableSet<E> |
Synchronized.navigableSet(java.util.NavigableSet<E> navigableSet) |
(package private) static <E> java.util.NavigableSet<E> |
Synchronized.navigableSet(java.util.NavigableSet<E> navigableSet,
java.lang.Object mutex) |
static <T> T[] |
ObjectArrays.newArray(java.lang.Class<T> type,
int length)
Returns a new array of the given length with the specified component type.
|
static <E> java.util.concurrent.CopyOnWriteArrayList<E> |
Lists.newCopyOnWriteArrayList()
Creates an empty
CopyOnWriteArrayList instance. |
static <E> java.util.concurrent.CopyOnWriteArrayList<E> |
Lists.newCopyOnWriteArrayList(java.lang.Iterable<? extends E> elements)
Creates a
CopyOnWriteArrayList instance containing the given elements. |
static <E> java.util.concurrent.CopyOnWriteArraySet<E> |
Sets.newCopyOnWriteArraySet()
Creates an empty
CopyOnWriteArraySet instance. |
static <E> java.util.concurrent.CopyOnWriteArraySet<E> |
Sets.newCopyOnWriteArraySet(java.lang.Iterable<? extends E> elements)
Creates a
CopyOnWriteArraySet instance containing the given elements. |
static <E> Interner<E> |
Interners.newWeakInterner()
Returns a new thread-safe interner which retains a weak reference to each instance it has
interned, and so does not prevent these instances from being garbage-collected.
|
private static <K,V> java.util.Map.Entry<K,V> |
Synchronized.nullableSynchronizedEntry(java.util.Map.Entry<K,V> entry,
java.lang.Object mutex) |
E |
ImmutableSortedSet.pollFirst()
Deprecated.
Unsupported operation.
|
E |
ImmutableSortedSet.pollLast()
Deprecated.
Unsupported operation.
|
private void |
AbstractBiMap.Inverse.readObject(java.io.ObjectInputStream stream) |
private void |
ArrayListMultimap.readObject(java.io.ObjectInputStream stream) |
private void |
EnumBiMap.readObject(java.io.ObjectInputStream stream) |
private void |
EnumHashBiMap.readObject(java.io.ObjectInputStream stream) |
private void |
EnumMultiset.readObject(java.io.ObjectInputStream stream) |
private void |
HashBiMap.readObject(java.io.ObjectInputStream stream) |
private void |
HashMultimap.readObject(java.io.ObjectInputStream stream) |
private void |
HashMultiset.readObject(java.io.ObjectInputStream stream) |
private void |
ImmutableAsList.readObject(java.io.ObjectInputStream stream) |
private void |
ImmutableListMultimap.readObject(java.io.ObjectInputStream stream) |
private void |
ImmutableSetMultimap.readObject(java.io.ObjectInputStream stream) |
private void |
LinkedHashMultimap.readObject(java.io.ObjectInputStream stream) |
private void |
LinkedHashMultiset.readObject(java.io.ObjectInputStream stream) |
private void |
LinkedListMultimap.readObject(java.io.ObjectInputStream stream) |
private void |
Multimaps.CustomMultimap.readObject(java.io.ObjectInputStream stream) |
private void |
Multimaps.CustomListMultimap.readObject(java.io.ObjectInputStream stream) |
private void |
Multimaps.CustomSetMultimap.readObject(java.io.ObjectInputStream stream) |
private void |
Multimaps.CustomSortedSetMultimap.readObject(java.io.ObjectInputStream stream) |
private void |
TreeMultimap.readObject(java.io.ObjectInputStream stream) |
private void |
TreeMultiset.readObject(java.io.ObjectInputStream stream) |
private void |
AbstractMapBasedMultiset.readObjectNoData() |
(package private) java.lang.Object |
AbstractBiMap.Inverse.readResolve() |
(package private) <K,V> GenericMapMaker<K,V> |
MapMaker.removalListener(MapMaker.RemovalListener<K,V> listener)
Deprecated.
Caching functionality in
MapMaker has been moved to
CacheBuilder, with MapMaker.removalListener(com.google.common.collect.MapMaker.RemovalListener<K, V>) being
replaced by CacheBuilder.removalListener. Note that CacheBuilder is simply an enhanced API for an implementation which was branched from
MapMaker. |
private static <E> java.util.NavigableSet<E> |
Maps.removeOnlyNavigableSet(java.util.NavigableSet<E> set) |
abstract GenericMapMaker<K0,V0> |
GenericMapMaker.softValues()
Deprecated.
Caching functionality in
MapMaker has been moved to CacheBuilder, with GenericMapMaker.softValues() being replaced by CacheBuilder.softValues(). Note that CacheBuilder is simply
an enhanced API for an implementation which was branched from MapMaker. This
method is scheduled for removal in March 2015. |
MapMaker |
MapMaker.softValues()
Deprecated.
Caching functionality in
MapMaker has been moved to CacheBuilder, with MapMaker.softValues() being replaced by CacheBuilder.softValues(). Note that CacheBuilder is simply
an enhanced API for an implementation which was branched from MapMaker. This
method is scheduled for removal in March 2015. |
(package private) ImmutableList<E> |
ImmutableSortedAsList.subListUnchecked(int fromIndex,
int toIndex) |
ContiguousSet<C> |
ContiguousSet.subSet(C fromElement,
boolean fromInclusive,
C toElement,
boolean toInclusive) |
ImmutableSortedSet<E> |
ImmutableSortedSet.subSet(E fromElement,
boolean fromInclusive,
E toElement,
boolean toInclusive) |
static <K,V> java.util.NavigableMap<K,V> |
Maps.synchronizedNavigableMap(java.util.NavigableMap<K,V> navigableMap)
Returns a synchronized (thread-safe) navigable map backed by the specified
navigable map.
|
static <E> java.util.NavigableSet<E> |
Sets.synchronizedNavigableSet(java.util.NavigableSet<E> navigableSet)
Returns a synchronized (thread-safe) navigable set backed by the specified
navigable set.
|
ContiguousSet<C> |
ContiguousSet.tailSet(C fromElement,
boolean inclusive) |
ImmutableSortedSet<E> |
ImmutableSortedSet.tailSet(E fromElement,
boolean inclusive) |
E[] |
FluentIterable.toArray(java.lang.Class<E> type)
Returns an array containing all of the elements from this fluent iterable in iteration order.
|
V[][] |
ArrayTable.toArray(java.lang.Class<V> valueClass)
Returns a two-dimensional array with the table contents.
|
static <T> T[] |
Iterables.toArray(java.lang.Iterable<? extends T> iterable,
java.lang.Class<T> type)
Copies an iterable's elements into an array.
|
static <T> T[] |
Iterators.toArray(java.util.Iterator<? extends T> iterator,
java.lang.Class<T> type)
Copies an iterator's elements into an array.
|
static <K,V1,V2> java.util.NavigableMap<K,V2> |
Maps.transformEntries(java.util.NavigableMap<K,V1> fromMap,
Maps.EntryTransformer<? super K,? super V1,V2> transformer)
Returns a view of a navigable map whose values are derived from the
original navigable map's entries.
|
static <K,V1,V2> java.util.NavigableMap<K,V2> |
Maps.transformValues(java.util.NavigableMap<K,V1> fromMap,
Function<? super V1,V2> function)
Returns a view of a navigable map where each value is transformed by a
function.
|
(package private) java.util.Collection<V> |
TreeMultimap.unmodifiableCollectionSubclass(java.util.Collection<V> collection) |
static <K,V> java.util.NavigableMap<K,V> |
Maps.unmodifiableNavigableMap(java.util.NavigableMap<K,V> map)
Returns an unmodifiable view of the specified navigable map.
|
static <E> java.util.NavigableSet<E> |
Sets.unmodifiableNavigableSet(java.util.NavigableSet<E> set)
Returns an unmodifiable view of the specified navigable set.
|
abstract GenericMapMaker<K0,V0> |
GenericMapMaker.weakKeys()
Deprecated.
See
MapMaker.weakKeys(). |
MapMaker |
MapMaker.weakKeys()
Specifies that each key (not value) stored in the map should be wrapped in a
WeakReference (by default, strong references are used). |
abstract GenericMapMaker<K0,V0> |
GenericMapMaker.weakValues()
Deprecated.
|
MapMaker |
MapMaker.weakValues()
Specifies that each value (not key) stored in the map should be wrapped in a
WeakReference (by default, strong references are used). |
(package private) java.util.Collection<V> |
TreeMultimap.wrapCollection(K key,
java.util.Collection<V> collection) |
private void |
AbstractBiMap.Inverse.writeObject(java.io.ObjectOutputStream stream) |
private void |
ArrayListMultimap.writeObject(java.io.ObjectOutputStream stream) |
private void |
EnumBiMap.writeObject(java.io.ObjectOutputStream stream) |
private void |
EnumHashBiMap.writeObject(java.io.ObjectOutputStream stream) |
private void |
EnumMultiset.writeObject(java.io.ObjectOutputStream stream) |
private void |
HashBiMap.writeObject(java.io.ObjectOutputStream stream) |
private void |
HashMultimap.writeObject(java.io.ObjectOutputStream stream) |
private void |
HashMultiset.writeObject(java.io.ObjectOutputStream stream) |
private void |
ImmutableListMultimap.writeObject(java.io.ObjectOutputStream stream) |
private void |
ImmutableSetMultimap.writeObject(java.io.ObjectOutputStream stream) |
private void |
LinkedHashMultimap.writeObject(java.io.ObjectOutputStream stream) |
private void |
LinkedHashMultiset.writeObject(java.io.ObjectOutputStream stream) |
private void |
LinkedListMultimap.writeObject(java.io.ObjectOutputStream stream) |
private void |
Multimaps.CustomMultimap.writeObject(java.io.ObjectOutputStream stream) |
private void |
Multimaps.CustomListMultimap.writeObject(java.io.ObjectOutputStream stream) |
private void |
Multimaps.CustomSetMultimap.writeObject(java.io.ObjectOutputStream stream) |
private void |
Multimaps.CustomSortedSetMultimap.writeObject(java.io.ObjectOutputStream stream) |
private void |
Synchronized.SynchronizedObject.writeObject(java.io.ObjectOutputStream stream) |
private void |
TreeMultimap.writeObject(java.io.ObjectOutputStream stream) |
private void |
TreeMultiset.writeObject(java.io.ObjectOutputStream stream) |
(package private) java.lang.Object |
EmptyContiguousSet.writeReplace() |
(package private) java.lang.Object |
ImmutableAsList.writeReplace() |
(package private) java.lang.Object |
ImmutableMapEntrySet.writeReplace() |
(package private) java.lang.Object |
ImmutableMapKeySet.writeReplace() |
(package private) java.lang.Object |
ImmutableMapValues.writeReplace() |
(package private) java.lang.Object |
RegularContiguousSet.writeReplace() |
| Modifier and Type | Method and Description |
|---|---|
(package private) static GwtWorkarounds.CharInput |
GwtWorkarounds.asCharInput(java.io.Reader reader)
Views a
Reader as a CharInput. |
(package private) static GwtWorkarounds.CharOutput |
GwtWorkarounds.asCharOutput(java.io.Writer writer)
Views a
Writer as a CharOutput. |
(package private) static java.io.InputStream |
GwtWorkarounds.asInputStream(GwtWorkarounds.ByteInput input)
Views a
ByteInput as an InputStream. |
(package private) static java.io.OutputStream |
GwtWorkarounds.asOutputStream(GwtWorkarounds.ByteOutput output)
Views a
ByteOutput as an OutputStream. |
ByteSource |
BaseEncoding.decodingSource(CharSource encodedSource)
Returns a
ByteSource that reads base-encoded bytes from the specified
CharSource. |
java.io.InputStream |
BaseEncoding.decodingStream(java.io.Reader reader)
Returns an
InputStream that decodes base-encoded input from the specified
Reader. |
ByteSink |
BaseEncoding.encodingSink(CharSink encodedSink)
Returns a
ByteSink that writes base-encoded bytes to the specified CharSink. |
java.io.OutputStream |
BaseEncoding.encodingStream(java.io.Writer writer)
Returns an
OutputStream that encodes bytes using this encoding into the specified
Writer. |
| Modifier and Type | Class and Description |
|---|---|
private static class |
DoubleMath.MeanAccumulator |
| Modifier and Type | Field and Description |
|---|---|
(package private) static long[] |
LongMath.halfPowersOf10 |
(package private) static long[] |
LongMath.powersOf10 |
| Modifier and Type | Method and Description |
|---|---|
static int |
IntMath.binomial(int n,
int k)
Returns
n choose k, also known as the binomial coefficient of n and
k, or Integer.MAX_VALUE if the result does not fit in an int. |
static long |
LongMath.checkedAdd(long a,
long b)
Returns the sum of
a and b, provided it does not overflow. |
static long |
LongMath.checkedMultiply(long a,
long b)
Returns the product of
a and b, provided it does not overflow. |
static long |
LongMath.checkedPow(long b,
int k)
Returns the
b to the kth power, provided it does not overflow. |
static long |
LongMath.checkedSubtract(long a,
long b)
Returns the difference of
a and b, provided it does not overflow. |
static java.math.BigInteger |
BigIntegerMath.divide(java.math.BigInteger p,
java.math.BigInteger q,
java.math.RoundingMode mode)
Returns the result of dividing
p by q, rounding using the specified
RoundingMode. |
static long |
LongMath.divide(long p,
long q,
java.math.RoundingMode mode)
Returns the result of dividing
p by q, rounding using the specified
RoundingMode. |
static long |
LongMath.factorial(int n)
Returns
n!, that is, the product of the first n positive
integers, 1 if n == 0, or Long.MAX_VALUE if the
result does not fit in a long. |
(package private) static boolean |
BigIntegerMath.fitsInLong(java.math.BigInteger x) |
static boolean |
DoubleMath.isMathematicalInteger(double x)
Returns
true if x represents a mathematical integer. |
static boolean |
DoubleMath.isPowerOfTwo(double x)
Returns
true if x is exactly equal to 2^k for some finite integer
k. |
static int |
BigIntegerMath.log10(java.math.BigInteger x,
java.math.RoundingMode mode)
Returns the base-10 logarithm of
x, rounded according to the specified rounding mode. |
static int |
IntMath.log10(int x,
java.math.RoundingMode mode)
Returns the base-10 logarithm of
x, rounded according to the specified rounding mode. |
static int |
LongMath.log10(long x,
java.math.RoundingMode mode)
Returns the base-10 logarithm of
x, rounded according to the specified rounding mode. |
(package private) static int |
LongMath.log10Floor(long x) |
static int |
DoubleMath.log2(double x,
java.math.RoundingMode mode)
Returns the base 2 logarithm of a double value, rounded with the specified rounding mode to an
int. |
static double |
DoubleMath.mean(double... values)
Returns the arithmetic mean of the values.
|
static double |
DoubleMath.mean(int... values)
Returns the arithmetic mean of the values.
|
static double |
DoubleMath.mean(java.lang.Iterable<? extends java.lang.Number> values)
Returns the arithmetic mean of the values.
|
static double |
DoubleMath.mean(java.util.Iterator<? extends java.lang.Number> values)
Returns the arithmetic mean of the values.
|
static double |
DoubleMath.mean(long... values)
Returns the arithmetic mean of the values.
|
static int |
LongMath.mod(long x,
int m)
Returns
x mod m, a non-negative value less than m. |
static long |
LongMath.mod(long x,
long m)
Returns
x mod m, a non-negative value less than m. |
static int |
IntMath.pow(int b,
int k)
Returns
b to the kth power. |
static long |
LongMath.pow(long b,
int k)
Returns
b to the kth power. |
(package private) static double |
DoubleMath.roundIntermediate(double x,
java.math.RoundingMode mode) |
static java.math.BigInteger |
DoubleMath.roundToBigInteger(double x,
java.math.RoundingMode mode)
Returns the
BigInteger value that is equal to x rounded with the specified
rounding mode, if possible. |
static int |
DoubleMath.roundToInt(double x,
java.math.RoundingMode mode)
Returns the
int value that is equal to x rounded with the specified rounding
mode, if possible. |
static long |
DoubleMath.roundToLong(double x,
java.math.RoundingMode mode)
Returns the
long value that is equal to x rounded with the specified rounding
mode, if possible. |
static java.math.BigInteger |
BigIntegerMath.sqrt(java.math.BigInteger x,
java.math.RoundingMode mode)
Returns the square root of
x, rounded with the specified rounding mode. |
static int |
IntMath.sqrt(int x,
java.math.RoundingMode mode)
Returns the square root of
x, rounded with the specified rounding mode. |
static long |
LongMath.sqrt(long x,
java.math.RoundingMode mode)
Returns the square root of
x, rounded with the specified rounding mode. |
private static java.math.BigInteger |
BigIntegerMath.sqrtApproxWithDoubles(java.math.BigInteger x) |
private static java.math.BigInteger |
BigIntegerMath.sqrtFloor(java.math.BigInteger x) |
| Modifier and Type | Field and Description |
|---|---|
(package private) static java.util.regex.Pattern |
Doubles.FLOATING_POINT_PATTERN
This is adapted from the regex suggested by
Double.valueOf(String)
for prevalidating inputs. |
| Modifier and Type | Method and Description |
|---|---|
private static java.util.regex.Pattern |
Doubles.fpPattern() |
static char |
Chars.fromByteArray(byte[] bytes)
Returns the
char value whose big-endian representation is
stored in the first 2 bytes of bytes; equivalent to ByteBuffer.wrap(bytes).getChar(). |
static int |
Ints.fromByteArray(byte[] bytes)
Returns the
int value whose big-endian representation is stored in
the first 4 bytes of bytes; equivalent to ByteBuffer.wrap(bytes).getInt(). |
static short |
Shorts.fromByteArray(byte[] bytes)
Returns the
short value whose big-endian representation is
stored in the first 2 bytes of bytes; equivalent to ByteBuffer.wrap(bytes).getShort(). |
static char |
Chars.fromBytes(byte b1,
byte b2)
Returns the
char value whose byte representation is the given 2
bytes, in big-endian order; equivalent to Chars.fromByteArray(new
byte[] {b1, b2}). |
static short |
Shorts.fromBytes(byte b1,
byte b2)
Returns the
short value whose byte representation is the given 2
bytes, in big-endian order; equivalent to Shorts.fromByteArray(new
byte[] {b1, b2}). |
static int |
Ints.fromBytes(byte b1,
byte b2,
byte b3,
byte b4)
Returns the
int value whose byte representation is the given 4
bytes, in big-endian order; equivalent to Ints.fromByteArray(new
byte[] {b1, b2, b3, b4}). |
UnsignedInteger |
UnsignedInteger.times(UnsignedInteger val)
Returns the result of multiplying this and
val. |
static byte[] |
Chars.toByteArray(char value)
Returns a big-endian representation of
value in a 2-element byte
array; equivalent to ByteBuffer.allocate(2).putChar(value).array(). |
static byte[] |
Ints.toByteArray(int value)
Returns a big-endian representation of
value in a 4-element byte
array; equivalent to ByteBuffer.allocate(4).putInt(value).array(). |
static byte[] |
Shorts.toByteArray(short value)
Returns a big-endian representation of
value in a 2-element byte
array; equivalent to ByteBuffer.allocate(2).putShort(value).array(). |
static java.lang.Double |
Doubles.tryParse(java.lang.String string)
Parses the specified string as a double-precision floating point value.
|
static java.lang.Float |
Floats.tryParse(java.lang.String string)
Parses the specified string as a single-precision floating point value.
|