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.escape |
Interfaces, utilities, and simple implementations of escapers and encoders.
|
com.google.common.eventbus |
The EventBus allows publish-subscribe-style communication between components without requiring
the components to explicitly register with one another (and thus be aware of each other).
|
com.google.common.hash |
Hash functions and related structures.
|
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. |
com.google.common.reflect |
This package contains utilities to work with Java reflection.
|
com.google.common.testing |
This package contains testing utilities.
|
com.google.common.util.concurrent |
Concurrency utilities.
|
Modifier and Type | Class and Description |
---|---|
(package private) static class |
CharMatcher.Whitespace
Implementation of
CharMatcher.whitespace() . |
(package private) static class |
Suppliers.ExpiringMemoizingSupplier<T> |
(package private) static class |
Suppliers.MemoizingSupplier<T> |
Modifier and Type | Field and Description |
---|---|
(package private) static boolean |
FinalizableReferenceQueue.SystemLoader.disabled |
(package private) static java.lang.String |
Throwables.SHARED_SECRETS_CLASSNAME
SharedSecrets class name to load using reflection
|
Modifier and Type | Method and Description |
---|---|
(package private) static int |
SmallCharMatcher.chooseTableSize(int setSize)
Returns an array size suitable for the backing array of a hash table that uses open addressing
with linear probing in its implementation.
|
(package private) static boolean |
Strings.validSurrogatePairAt(java.lang.CharSequence string,
int index)
True when a valid surrogate pair starts at the given
index in the given string . |
Modifier and Type | Field and Description |
---|---|
(package private) long |
CacheBuilderSpec.accessExpirationDuration |
(package private) java.util.concurrent.TimeUnit |
CacheBuilderSpec.accessExpirationTimeUnit |
(package private) java.lang.Integer |
CacheBuilderSpec.concurrencyLevel |
(package private) java.lang.Integer |
CacheBuilderSpec.initialCapacity |
(package private) LocalCache.Strength |
CacheBuilderSpec.keyStrength |
(package private) java.lang.Long |
CacheBuilderSpec.maximumSize |
(package private) java.lang.Long |
CacheBuilderSpec.maximumWeight |
(package private) java.lang.Boolean |
CacheBuilderSpec.recordStats |
(package private) long |
CacheBuilderSpec.refreshDuration |
(package private) java.util.concurrent.TimeUnit |
CacheBuilderSpec.refreshTimeUnit |
(package private) LocalCache.Strength |
CacheBuilderSpec.valueStrength |
(package private) long |
CacheBuilderSpec.writeExpirationDuration |
(package private) java.util.concurrent.TimeUnit |
CacheBuilderSpec.writeExpirationTimeUnit |
Modifier and Type | Method and Description |
---|---|
(package private) boolean |
LocalCache.Segment.containsValue(java.lang.Object value)
This method is a convenience for testing.
|
(package private) LocalCache.ReferenceEntry<K,V> |
LocalCache.copyEntry(LocalCache.ReferenceEntry<K,V> original,
LocalCache.ReferenceEntry<K,V> newNext)
This method is a convenience for testing.
|
(package private) boolean |
LocalCache.isLive(LocalCache.ReferenceEntry<K,V> entry,
long now)
This method is a convenience for testing.
|
(package private) LocalCache.ReferenceEntry<K,V> |
LocalCache.newEntry(K key,
int hash,
LocalCache.ReferenceEntry<K,V> next)
This method is a convenience for testing.
|
(package private) LocalCache.ValueReference<K,V> |
LocalCache.newValueReference(LocalCache.ReferenceEntry<K,V> entry,
V value,
int weight)
This method is a convenience for testing.
|
(package private) boolean |
LocalCache.Segment.removeEntry(LocalCache.ReferenceEntry<K,V> entry,
int hash,
RemovalCause cause) |
Modifier and Type | Class and Description |
---|---|
(package private) static class |
LinkedHashMultimap.ValueEntry<K,V>
LinkedHashMultimap entries are in no less than three coexisting linked lists:
a bucket in the hash table for a Set
|
(package private) class |
LinkedHashMultimap.ValueSet |
(package private) static class |
Ordering.ArbitraryOrdering |
(package private) static class |
Ordering.IncomparableValueException
Exception thrown by a
Ordering.explicit(List) or Ordering.explicit(Object, Object[]) comparator when comparing a value
outside the set of values it can compare. |
(package private) static class |
Synchronized.SynchronizedBiMap<K,V> |
(package private) static class |
Synchronized.SynchronizedCollection<E> |
(package private) static class |
Synchronized.SynchronizedNavigableMap<K,V> |
(package private) static class |
Synchronized.SynchronizedNavigableSet<E> |
(package private) static class |
TreeRangeSet.RangesByUpperBound<C extends java.lang.Comparable<?>> |
Modifier and Type | Field and Description |
---|---|
(package private) int |
ArrayListMultimap.expectedValuesPerKey |
(package private) int |
HashMultimap.expectedValuesPerKey |
(package private) LinkedHashMultimap.ValueEntry<K,V>[] |
LinkedHashMultimap.ValueSet.hashTable |
(package private) int |
MinMaxPriorityQueue.maximumSize |
(package private) int |
EvictingQueue.maxSize |
(package private) java.util.NavigableMap<Cut<C>,Range<C>> |
TreeRangeSet.rangesByLowerBound |
(package private) java.lang.Object[] |
RegularImmutableSet.table |
(package private) static double |
LinkedHashMultimap.VALUE_SET_LOAD_FACTOR |
(package private) int |
LinkedHashMultimap.valueSetCapacity |
Modifier and Type | Method and Description |
---|---|
(package private) int |
MinMaxPriorityQueue.capacity() |
(package private) static int |
ImmutableSet.chooseTableSize(int setSize)
Returns an array size suitable for the backing array of a hash table that
uses open addressing with linear probing in its implementation.
|
(package private) static int |
Lists.computeArrayListCapacity(int arraySize) |
(package private) boolean |
MapMakerInternalMap.Segment.containsValue(java.lang.Object value)
This method is a convenience for testing.
|
(package private) E |
MapMakerInternalMap.copyEntry(E original,
E newNext)
This method is a convenience for testing.
|
(package private) static int |
MinMaxPriorityQueue.initialQueueSize(int configuredExpectedSize,
int maximumSize,
java.lang.Iterable<?> initialContents) |
(package private) static boolean |
MinMaxPriorityQueue.isEvenLevel(int index) |
(package private) boolean |
MinMaxPriorityQueue.isIntact()
Returns
true if the MinMax heap structure holds. |
(package private) boolean |
MapMakerInternalMap.isLiveForTesting(MapMakerInternalMap.InternalEntry<K,V,?> entry)
This method is a convenience for testing.
|
(package private) MapMakerInternalMap.Strength |
MapMakerInternalMap.keyStrength() |
(package private) static <K,V> java.util.Map<K,V> |
Synchronized.map(java.util.Map<K,V> map,
java.lang.Object mutex) |
(package private) MinMaxPriorityQueue.MoveDesc<E> |
MinMaxPriorityQueue.removeAt(int index)
Removes the element at position
index . |
(package private) static <E> java.util.Set<E> |
Synchronized.set(java.util.Set<E> set,
java.lang.Object mutex) |
(package private) Equivalence<java.lang.Object> |
MapMakerInternalMap.valueEquivalence() |
(package private) MapMakerInternalMap.Strength |
MapMakerInternalMap.valueStrength() |
Constructor and Description |
---|
ConcurrentHashMultiset(java.util.concurrent.ConcurrentMap<E,java.util.concurrent.atomic.AtomicInteger> countMap) |
Modifier and Type | Method and Description |
---|---|
(package private) static char[][] |
ArrayBasedEscaperMap.createReplacementArray(java.util.Map<java.lang.Character,java.lang.String> map) |
Modifier and Type | Class and Description |
---|---|
(package private) static class |
Subscriber.SynchronizedSubscriber
Subscriber that synchronizes invocations of a method to ensure that only one thread may enter
the method at a time.
|
Modifier and Type | Field and Description |
---|---|
(package private) java.lang.Object |
Subscriber.target
The object with the subscriber method.
|
Modifier and Type | Method and Description |
---|---|
(package private) static ImmutableSet<java.lang.Class<?>> |
SubscriberRegistry.flattenHierarchy(java.lang.Class<?> concreteClass)
Flattens a class's type hierarchy into a set of
Class objects including all
superclasses (transitively) and all interfaces implemented by these superclasses. |
(package private) java.util.Set<Subscriber> |
SubscriberRegistry.getSubscribersForTesting(java.lang.Class<?> eventType) |
(package private) void |
Subscriber.invokeSubscriberMethod(java.lang.Object event)
Invokes the subscriber method.
|
Modifier and Type | Method and Description |
---|---|
(package private) long |
BloomFilter.bitSize()
Returns the number of bits in the underlying bit array.
|
(package private) static <T> BloomFilter<T> |
BloomFilter.create(Funnel<? super T> funnel,
long expectedInsertions,
double fpp,
BloomFilter.Strategy strategy) |
(package private) static long |
FarmHashFingerprint64.fingerprint(byte[] bytes,
int offset,
int length) |
(package private) static long |
BloomFilter.optimalNumOfBits(long n,
double p)
Computes m (total bits of Bloom filter) which is expected to achieve, for the specified
expected insertions, the required false positive probability.
|
(package private) static int |
BloomFilter.optimalNumOfHashFunctions(long n,
long m)
Computes the optimal k (number of hashes per element inserted in Bloom filter), given the
expected insertions and total number of bits in the Bloom filter.
|
Modifier and Type | Class and Description |
---|---|
(package private) static class |
Closer.LoggingSuppressor
Suppresses exceptions by logging them.
|
(package private) static class |
Closer.SuppressingSuppressor
Suppresses exceptions by adding them to the exception that will be thrown using JDK7's
addSuppressed(Throwable) mechanism.
|
(package private) static interface |
Closer.Suppressor
Suppression strategy interface.
|
Modifier and Type | Field and Description |
---|---|
(package private) static java.util.logging.Logger |
Closeables.logger |
(package private) Closer.Suppressor |
Closer.suppressor |
Modifier and Type | Method and Description |
---|---|
(package private) java.io.File |
FileBackedOutputStream.getFile()
Returns the file holding the data (possibly null).
|
Constructor and Description |
---|
Closer(Closer.Suppressor suppressor) |
Modifier and Type | Field and Description |
---|---|
(package private) static int[] |
IntMath.biggestBinomials |
(package private) static int[] |
LongMath.biggestSimpleBinomials |
(package private) static double[] |
DoubleMath.everySixteenthFactorial |
(package private) static int |
IntMath.FLOOR_SQRT_MAX_INT |
(package private) static long |
LongMath.FLOOR_SQRT_MAX_LONG |
(package private) static long[] |
LongMath.halfPowersOf10 |
(package private) static int[] |
IntMath.halfPowersOf10 |
(package private) static int |
DoubleMath.MAX_FACTORIAL |
(package private) static long |
LongMath.MAX_POWER_OF_SQRT2_UNSIGNED
The biggest half power of two that fits into an unsigned long
|
(package private) static int |
IntMath.MAX_POWER_OF_SQRT2_UNSIGNED
The biggest half power of two that can fit in an unsigned int.
|
(package private) static long |
LongMath.MAX_SIGNED_POWER_OF_TWO |
(package private) static int |
IntMath.MAX_SIGNED_POWER_OF_TWO |
(package private) static byte[] |
LongMath.maxLog10ForLeadingZeros |
(package private) static byte[] |
IntMath.maxLog10ForLeadingZeros |
(package private) static long[] |
LongMath.powersOf10 |
(package private) static int[] |
IntMath.powersOf10 |
(package private) static int |
BigIntegerMath.SQRT2_PRECOMPUTE_THRESHOLD |
(package private) static java.math.BigInteger |
BigIntegerMath.SQRT2_PRECOMPUTED_BITS |
Modifier and Type | Method and Description |
---|---|
(package private) static int |
IntMath.lessThanBranchFree(int x,
int y)
Returns 1 if
x < y as unsigned integers, and 0 otherwise. |
(package private) static int |
LongMath.lessThanBranchFree(long x,
long y)
Returns 1 if
x < y as unsigned longs, and 0 otherwise. |
Modifier and Type | Class and Description |
---|---|
(package private) static class |
UnsignedBytes.LexicographicalComparatorHolder
Provides a lexicographical comparator implementation; either a Java implementation or a faster
implementation based on
Unsafe . |
(package private) static class |
UnsignedBytes.LexicographicalComparatorHolder.UnsafeComparator |
Modifier and Type | Method and Description |
---|---|
(package private) static java.util.Comparator<byte[]> |
UnsignedBytes.lexicographicalComparatorJavaImpl() |
Modifier and Type | Class and Description |
---|---|
(package private) static class |
ClassPath.DefaultScanner |
Modifier and Type | Method and Description |
---|---|
(package private) static java.lang.String |
ClassPath.getClassName(java.lang.String filename) |
(package private) static ImmutableMap<java.io.File,java.lang.ClassLoader> |
ClassPath.Scanner.getClassPathEntries(java.lang.ClassLoader classloader) |
(package private) static java.net.URL |
ClassPath.Scanner.getClassPathEntry(java.io.File jarFile,
java.lang.String path)
Returns the absolute uri of the Class-Path entry value as specified in
JAR File Specification.
|
(package private) static ImmutableSet<java.io.File> |
ClassPath.Scanner.getClassPathFromManifest(java.io.File jarFile,
java.util.jar.Manifest manifest)
Returns the class path URIs specified by the
Class-Path manifest attribute, according
to
JAR File Specification. |
(package private) void |
ClassPath.Scanner.scan(java.io.File file,
java.lang.ClassLoader classloader) |
(package private) static java.lang.reflect.WildcardType |
Types.subtypeOf(java.lang.reflect.Type upperBound)
Returns a new
WildcardType with upperBound . |
(package private) static java.lang.reflect.WildcardType |
Types.supertypeOf(java.lang.reflect.Type lowerBound)
Returns a new
WildcardType with lowerBound . |
(package private) static <T> TypeToken<? extends T> |
TypeToken.toGenericType(java.lang.Class<T> cls)
Returns the type token representing the generic type declaration of
cls . |
Modifier and Type | Class and Description |
---|---|
(package private) static class |
ClassSanityTester.FactoryMethodReturnsNullException
Thrown if the test tries to invoke a static factory method to test instance methods but the
factory returned null.
|
(package private) static class |
ClassSanityTester.ParameterHasNoDistinctValueException
Thrown if the test fails to generate two distinct non-null values of a constructor or factory
parameter in order to test
Object.equals(java.lang.Object) and Object.hashCode() of the declaring
class. |
(package private) static class |
ClassSanityTester.ParameterNotInstantiableException
Thrown if the test tries to invoke a constructor or static factory method but failed because
the dummy value of a constructor or method parameter is unknown.
|
Modifier and Type | Method and Description |
---|---|
(package private) java.util.List<java.lang.Class<?>> |
AbstractPackageSanityTests.findClassesToTest(java.lang.Iterable<? extends java.lang.Class<?>> classes,
java.lang.Iterable<java.lang.String> explicitTestNames)
Finds the classes not ending with a test suffix and not covered by an explicit test
whose name is
explicitTestName . |
Modifier and Type | Interface and Description |
---|---|
(package private) static interface |
FuturesGetChecked.GetCheckedTypeValidator |
(package private) static class |
FuturesGetChecked.GetCheckedTypeValidatorHolder
Provides a check of whether an exception type is valid for use with
FuturesGetChecked.getChecked(Future, Class) , possibly using caching. |
(package private) static class |
MoreExecutors.Application
Represents the current application to register shutdown hooks.
|
(package private) static class |
Striped.LargeLazyStriped<L>
Implementation of Striped where up to 2^k stripes can be represented, using a ConcurrentMap
where the key domain is [0..2^k).
|
(package private) static class |
Striped.SmallLazyStriped<L>
Implementation of Striped where up to 2^k stripes can be represented, using an
AtomicReferenceArray of size 2^k.
|
(package private) static class |
UncaughtExceptionHandlers.Exiter |
Modifier and Type | Method and Description |
---|---|
(package private) void |
MoreExecutors.Application.addShutdownHook(java.lang.Thread hook) |
(package private) static void |
FuturesGetChecked.checkExceptionClassValidity(java.lang.Class<? extends java.lang.Exception> exceptionClass) |
(package private) static FuturesGetChecked.GetCheckedTypeValidator |
FuturesGetChecked.classValueValidator() |
(package private) static RateLimiter |
RateLimiter.create(RateLimiter.SleepingStopwatch stopwatch,
double permitsPerSecond) |
(package private) static RateLimiter |
RateLimiter.create(RateLimiter.SleepingStopwatch stopwatch,
double permitsPerSecond,
long warmupPeriod,
java.util.concurrent.TimeUnit unit,
double coldFactor) |
(package private) static <E extends java.lang.Enum<E>> |
CycleDetectingLockFactory.createNodes(java.lang.Class<E> clazz)
For a given Enum type, creates an immutable map from each of the Enum's values to a
corresponding LockGraphNode, with the
allowedPriorLocks and
disallowedPriorLocks prepopulated with nodes according to the natural ordering of the
associated Enum values. |
(package private) static <V,X extends java.lang.Exception> |
FuturesGetChecked.getChecked(FuturesGetChecked.GetCheckedTypeValidator validator,
java.util.concurrent.Future<V> future,
java.lang.Class<X> exceptionClass)
Implementation of
Futures.getChecked(Future, Class) . |
(package private) static boolean |
FuturesGetChecked.isCheckedException(java.lang.Class<? extends java.lang.Exception> type) |
(package private) static FuturesGetChecked.GetCheckedTypeValidator |
FuturesGetChecked.weakSetValidator() |
Constructor and Description |
---|
WithExplicitOrdering(CycleDetectingLockFactory.Policy policy,
java.util.Map<E,CycleDetectingLockFactory.LockGraphNode> lockGraphNodes) |