|
||||||||||
PREV NEXT | FRAMES NO FRAMES |
Optional
instance with no contained reference.
Cache
interface to minimize the
effort required to implement this interface.AbstractCache.StatsCounter
implementation for use by Cache
implementors.Cache
for presentation by Cache.stats()
.ListenableFuture
that adds support for
the AbstractCheckedFuture.checkedGet()
and AbstractCheckedFuture.checkedGet(long, TimeUnit)
methods.AbstractCheckedFuture
that wraps a delegate.
AbstractExecutionThreadService.startUp()
, AbstractExecutionThreadService.run()
and
AbstractExecutionThreadService.shutDown()
methods.ListenableFuture
interface.Iterator
interface, to make this interface easier to implement for certain types of
data sources.Iterator
interface for sequences whose next element can always be derived from the
previous element.firstOrNull
is null, creates a new empty iterator.
AbstractFuture
. This class is scheduled for deletion from Guava in
Guava release 11.0.AbstractService.doStart()
and
AbstractService.doStop()
requests, responding to them with AbstractService.notifyStarted()
and AbstractService.notifyStopped()
callbacks.name=value
format.
element
to the ImmutableCollection
being built.
elements
to the ImmutableCollection
being built.
element
to the ImmutableList
.
elements
to the ImmutableList
.
element
to the ImmutableMultiset
.
elements
to the ImmutableMultiset
.
element
to the ImmutableSet
.
elements
to the ImmutableSet
,
ignoring duplicate elements (only the first duplicate element is added).
element
to the ImmutableSortedSet
.
elements
to the ImmutableSortedSet
,
ignoring duplicate elements (only the first duplicate element is added).
Runnable
and accompanying Executor
to the list of
listeners to execute.
elements
to the ImmutableCollection
being built.
elements
to the ImmutableCollection
being built.
elements
to the ImmutableList
.
elements
to the ImmutableList
.
elements
to the ImmutableMultiset
.
elements
to the ImmutableMultiset
.
elements
to the ImmutableSet
,
ignoring duplicate elements (only the first duplicate element is added).
elements
to the ImmutableSet
,
ignoring duplicate elements (only the first duplicate element is added).
elements
to the ImmutableSortedSet
,
ignoring duplicate elements (only the first duplicate element is added).
elements
to the ImmutableSortedSet
,
ignoring duplicate elements (only the first duplicate element is added).
iterable
to collection
.
iterator
to collection
.
Future
's computation is complete or, if the computation is already complete, immediately.
Future
's computation is complete or, if the computation is already complete, immediately.
ImmutableMultiset
.
service
.
value
format.
true
if every element in iterable
satisfies the
predicate.
true
if every element returned by iterator
satisfies the given predicate.
C
.
ListenableFuture
whose value is a list containing the
values of all its input futures, if all succeed.
ListenableFuture
whose value is a list containing the
values of all its input futures, if all succeed.
void
).
Void
).
false
.
true
.
other
.
true
if each of its
components evaluates to true
.
true
if each of its
components evaluates to true
.
true
if both of its
components evaluate to true
.
true
if one or more elements in iterable
satisfy
the predicate.
true
if one or more elements returned by iterator
satisfy the given predicate.
char
matcher that matches any character present in the given character
sequence.
parts
, using the previously configured
separator between each, to appendable
.
parts
, using the previously configured
separator between each, to appendable
.
appendable
the string representation of each of the remaining arguments.
parts
, using the previously configured
separator between each, to builder
.
parts
, using the previously configured
separator between each, to builder
.
builder
the string representation of each of the remaining arguments.
map
, using the previously
configured separator and key-value separator, to appendable
.
map
, using the previously
configured separator and key-value separator, to builder
.
entries
, using the previously
configured separator and key-value separator, to appendable
.
entries
, using the previously
configured separator and key-value separator, to builder
.
true
if this matcher matches the given character.
input
.
input
.
Range.contains(C)
; provided only to satisfy the Predicate
interface.
compare(a,
b) == 0
implies a == b
(identity equality).
true
if there are no differences between the two maps;
that is, if the maps are equal.
Multimap
that uses an ArrayList
to store
the values for a given key.Table
implementation backed by a two-dimensional array.0x00
through 0x7F
), and to strings containing such
characters.Iterator
to the Enumeration
interface.
Interner.intern(E)
method of the given interner.
Arrays.asList(Object[])
.
Arrays.asList(Object[])
.
Arrays.asList(Object[])
.
Arrays.asList(Object[])
.
Arrays.asList(Object[])
.
Arrays.asList(Object[])
.
Arrays.asList(Object[])
.
Arrays.asList(Object[])
.
ImmutableSortedSet
containing the same values in the
given domain contained by this range.
true
if the class being
tested is assignable from the given class.
Appendable
target.
EventBus
that takes the Executor of your choice and uses it to
dispatch events, allowing dispatch to occur asynchronously.executor
to dispatch
events.
executor
to dispatch
events.
RemovalListener
which processes all
eviction notifications asynchronously, using executor
.
MapMaker
is being moved to
CacheBuilder
. Functionality similar to
EvictionListeners#asynchronous
is provided by
RemovalListeners.asynchronous(com.google.common.cache.RemovalListener, java.util.concurrent.Executor)
.
This method is scheduled for deletion from Guava in Guava release 11.0.
endpoint
.
endpoint
.
java.util.concurrent.atomic
package.latch.
await()
uninterruptibly.
latch.
await(timeout, unit)
uninterruptibly.
Searches
sortedList
for key
using the binary search algorithm.
boolean
primitives, that are not
already found in either Boolean
or Arrays
.CacheLoader
.
ImmutableCollection
of the appropriate
type, containing the elements provided to this builder.
ImmutableList
based on the contents of
the Builder
.
ImmutableMultiset
based on the contents
of the Builder
.
ImmutableSet
based on the contents of
the Builder
.
ImmutableSortedSet
based on the contents
of the Builder
and its comparator.
ImmutableSetMultimap.Builder
.
DataInput
for reading from in-memory byte arrays; its
methods offer identical functionality but do not throw IOException
.DataOutput
for writing to in-memory byte arrays; its
methods offer identical functionality but do not throw IOException
.byte
primitives, that are not
already found in either Byte
or Arrays
, and interpret
bytes as neither signed nor unsigned.char
value.
double
value.
float
value.
int
value.
long
value.
short
value.
Cache
instances having any combination of the following features:
least-recently-used eviction when a maximum size is exceeded
time-based expiration of entries, measured since last access or last write
keys automatically wrapped in weak references
values automatically wrapped in weak or
soft references
notification of evicted (or otherwise removed) entries
Cache
.Cache
.CacheStats
instance.
Callable
interface.AbstractFuture.cancel(boolean)
and not need to call this method
at all. Those that are not can delegate to super.cancel(mayInterruptIfRunning)
or, to get behavior exactly equivalent
to this method, super.cancel(false)
. This method will be removed
from Guava in Guava release 11.0.
ListenableFuture
whose result is asynchronously
derived from the result of the given Future
.
ListenableFuture
whose result is asynchronously
derived from the result of the given Future
.
Character
values.
CharSequence
as a List<Character>
, viewing sequence
as a sequence of Unicode code
units.
char
value, just as Predicate
does
for any Object
.char
primitives, that are not
already found in either Character
or Arrays
.Charset
instances, which are
guaranteed to be supported by all Java platform implementations.char
value that is equal to value
, if possible.
int
value that is equal to value
, if possible.
short
value that is equal to value
, if
possible.
byte
value that is equal to value
, if possible.
byte
value that, when treated as unsigned, is equal to
value
, if possible.
CheckedFuture
is a ListenableFuture
that includes versions
of the get
methods that can throw a checked exception.Future.get()
that will translate
InterruptedException
, CancellationException
and
ExecutionException
into application-specific exceptions.
Future.get(long, TimeUnit)
that will
translate InterruptedException
, CancellationException
and
ExecutionException
into application-specific exceptions.
Future.get()
that will translate
InterruptedException
, CancellationException
and
ExecutionException
into application-specific exceptions.
Future.get(long, TimeUnit)
that will
translate InterruptedException
, CancellationException
and
ExecutionException
into application-specific exceptions.
RuntimeException
if the specified element is
illegal.
index
specifies a valid element in an array,
list or string of size size
.
index
specifies a valid element in an array,
list or string of size size
.
RuntimeException
if the specified key or value is
illegal.
index
specifies a valid position in an array,
list or string of size size
.
index
specifies a valid position in an array,
list or string of size size
.
start
and end
specify a valid positions
in an array, list or string of size size
, and are in order.
InternetDomainName
by prepending the
argument and a dot to the current name.
ArrayTable.eraseAll()
Closeable
, with control over whether an
IOException
may be thrown.
Closeable
objects.lower
and less than or equal to upper
.
lower
and strictly less than upper
.
close(closeable, true)
, but with no
IOException in the signature.
Collection
instances.void
.Ordering.natural()
when the natural ordering of the keys is used.
Ordering.natural()
when the natural ordering of the
elements is used.
Comparable.compareTo(T)
, if the result of this comparison chain
has not already been determined.
int
values as specified by Ints.compare(int, int)
,
if the result of this comparison chain has not already been
determined.
long
values as specified by Longs.compare(long, long)
,
if the result of this comparison chain has not already been
determined.
float
values as specified by Float.compare(float, float)
, if the result of this comparison chain has not
already been determined.
double
values as specified by Double.compare(double, double)
, if the result of this comparison chain has not
already been determined.
boolean
values as specified by Booleans.compare(boolean, boolean)
, if the result of this comparison chain has not
already been determined.
boolean
values in the standard way
(false
is considered less than true
).
char
values.
double
values.
float
values using Float.compare(float, float)
.
int
values.
long
values.
short
values.
byte
values.
byte
values, treating them as unsigned
values between 0 and 255 inclusive.
long
values, treating them as unsigned values between
0
and 2^64 - 1
inclusive.
EnumSet
consisting of all enum values that are not in
the specified collection.
EnumSet
consisting of all enum values that are not in
the specified collection.
this
, but which
in the event of a "tie", then delegates to secondaryComparator
.
previous
, or returns null
if no elements remain.
element
to array
.
element
to array
.
MapMaker.concurrencyLevel
.
Multiset
operations (exceptions where noted).value
for any input.
Constraint
interface.Iterator
through Iterators.consumingIterator(Iterator)
.
iterator
that removes each element
from the supplied iterator
as it is returned.
true
if the
CharSequence
being tested contains any match for the given
regular expression pattern.
true
if the provided keys are among the keys provided when
the table was constructed.
true
if iterable
contains element
; that is,
any object for which equals(element)
is true.
true
if iterator
contains element
.
true
if value
is within the bounds of this
range.
true
if the table contains a mapping with the specified
row and column keys.
true
if target
is present as an element anywhere in
array
.
true
if target
is present as an element anywhere in
array
.
true
if target
is present as an element anywhere in
array
.
true
if target
is present as an element anywhere in
array
.
true
if target
is present as an element anywhere in
array
.
true
if target
is present as an element anywhere in
array
.
true
if target
is present as an element anywhere in
array
.
true
if target
is present as an element anywhere in
array
.
true
if this multiset contains at least one occurrence of
each element in the specified collection.
true
if every element in values
is contained in this range.
true
if the provided column key is among the column keys
provided when the table was constructed.
true
if the table contains a mapping with the specified
column.
true
if the multimap contains the specified key-value pair.
true
if the multimap contains any values for the specified
key.
true
if subMultiset.count(o) <=
superMultiset.count(o)
for all o
.
true
if the
CharSequence
being tested contains any match for the given
regular expression pattern.
true
if the provided row key is among the row keys
provided when the table was constructed.
true
if the table contains a mapping with the specified
row key.
true
if the multimap contains the specified value for any
key.
true
if the table contains a mapping with the specified
value.
DiscreteDomain
.Readable
and Appendable
objects from the
given factories, copies all characters between the two, and closes
them.
Readable
object from the supplier, copies all characters
to the Appendable
object, and closes the input.
Readable
and Appendable
objects.
InputStream
supplied by a
factory.
OutputStream
supplied by
a factory.
Readable
and
Closeable
object supplied by a factory, using the given
character set.
Appendable
&
Closeable
object supplied by a factory, using the given
character set.
map
.
map
.
multimap
.
map
.
multimap
.
multimap
.
map
, sorted
by the natural ordering of the keys.
map
, with
keys sorted by the provided comparator.
Comparator
.
Comparator
.
Comparator
.
Comparator
.
element
in this multiset.
InputStream
that counts the number of bytes read.ArrayListMultimap
with the default initial
capacities.
ArrayListMultimap
with enough capacity to hold
the specified numbers of keys and values without resizing.
ArrayListMultimap
with the same mappings as the
specified multimap.
ArrayTable
.
ArrayTable
with the mappings in the provided table.
ArrayTable
with the same mappings, allowed keys, and
iteration ordering as the provided ArrayTable
.
ConcurrentHashMultiset
using the default
initial capacity, load factor, and concurrency settings.
ConcurrentHashMultiset
containing the specified
elements, using the default initial capacity, load factor, and concurrency
settings.
ConcurrentHashMultiset
using mapMaker
to construct the internal backing map.
EnumBiMap
using the specified key and value
types.
EnumHashBiMap
using the specified key type.
EnumMultiset
.
EnumMultiset
containing the specified elements.
HashBasedTable
.
HashBasedTable
with the specified map sizes.
HashBasedTable
with the same mappings as the specified
table.
HashBiMap
with the default initial capacity
(16).
map
.
HashMultimap
with the default initial
capacities.
HashMultimap
with enough capacity to hold the
specified numbers of keys and values without rehashing.
HashMultimap
with the same mappings as the specified
multimap.
HashMultiset
using the default initial
capacity.
HashMultiset
with the specified expected
number of distinct elements.
HashMultiset
containing the specified elements.
LinkedHashMultimap
with the default initial
capacities.
LinkedHashMultimap
with enough capacity to hold
the specified numbers of keys and values without rehashing.
LinkedHashMultimap
with the same mappings as the
specified multimap.
LinkedHashMultiset
using the default initial
capacity.
LinkedHashMultiset
with the specified expected
number of distinct elements.
LinkedHashMultiset
containing the specified elements.
LinkedListMultimap
with the default initial
capacity.
LinkedListMultimap
with enough capacity to hold
the specified number of keys without rehashing.
LinkedListMultimap
with the same mappings as the
specified Multimap
.
MutableClassToInstanceMap
instance backed by a HashMap
using the default initial capacity and load factor.
MutableClassToInstanceMap
instance backed by a given
empty backingMap
.
TreeBasedTable
that uses the natural orderings
of both row and column keys.
TreeBasedTable
that is ordered by the specified
comparators.
TreeBasedTable
with the same mappings and sort order
as the specified TreeBasedTable
.
TreeMultimap
ordered by the natural ordering of
its keys and values.
TreeMultimap
instance using explicit comparators.
TreeMultimap
, ordered by the natural ordering of its
keys and values, with the same mappings as the specified multimap.
ListenableFutureTask
that will upon running, execute the
given Callable
.
ListenableFutureTask
that will upon running, execute the
given Runnable
, and arrange that get
will return the
given result on successful completion.
SettableFuture
in the default state.
java.io.tmpdir
system
property), and returns its name.
iterable
.
iterable
.
type
as defined by JLS --- 0
for numbers, false
for boolean
and '\0'
for char
.
Ordering.natural()
if the left map uses the
natural ordering of its elements.
Comparable
domain such as all
Integer
s.DiscreteDomain
instances.AsyncEventBus.executor
to dispatch event
to handler
.
event
to the handler in wrapper
.
events
in the order they were posted, regardless of
the posting thread.
DiscreteDomain.next(C)
(if positive) or DiscreteDomain.previous(C)
(if negative) are needed to reach
end
starting from start
.
true
if a
and b
are considered equivalent.
t
.
AbstractService.start()
to initiate service startup.
double
primitives, that are not
already found in either Double
or Arrays
.null
otherwise.
true
if the bounds of other
do not extend outside
the bounds of this range.
AbstractIterator.computeNext()
must invoke this method when
there are no elements left in the iteration.
event
for dispatch during
EventBus.dispatchQueuedEvents()
.
array
, but
guaranteed to be of a specified minimum length.
array
, but
guaranteed to be of a specified minimum length.
array
, but
guaranteed to be of a specified minimum length.
array
, but
guaranteed to be of a specified minimum length.
array
, but
guaranteed to be of a specified minimum length.
array
, but
guaranteed to be of a specified minimum length.
array
, but
guaranteed to be of a specified minimum length.
array
, but
guaranteed to be of a specified minimum length.
Multiset.Entry
instances, each providing an element of the multiset and
the count of that element.
BiMap
backed by two EnumMap
instances.BiMap
backed by an EnumMap
instance for keys-to-values, and
a HashMap
instance for values-to-keys.EnumMap
.Enum
instances.true
if Equivalence.equivalent(Object, Object)
applied to the wrapped
references is true
and both wrappers use the same
equivalence.
Object.equals(java.lang.Object)
and Object.hashCode()
.
true
if object
is an Optional
instance, and either
the contained references are equal to each other or both
are absent.
MapDifference.ValueDifference.leftValue()
values are equal and their MapDifference.ValueDifference.rightValue()
values are also equal.
true
if object
is a range having the same
endpoints and bound types as this range.
true
if the object being
tested equals()
the given target or both are null.
Equivalence.Wrapper.equals(Object)
and Equivalence.Wrapper.hashCode()
delegate to an
Equivalence
.Equivalence
instances.true
if the given objects are considered equivalent.
target
according to this equivalence relation.
null
with the specified keys, assuming both
keys are valid.
null
with every pair of allowed row and column
keys.
identifier
.
MapMaker
is being moved to
CacheBuilder
. Functionality similar to
MapMaker.evictionListener(com.google.common.collect.MapEvictionListener)
is provided by CacheBuilder.removalListener(com.google.common.cache.RemovalListener)
which also provides
additional information about the entry being evicted; note that evictionListener
only notifies on removals due to eviction, while removalListener
also notifies on
explicit removal (providing the RemovalCause
to
indicate the specific cause of removal. This method is scheduled for deletion in Guava
release 11.
MapMaker
is being moved to
CacheBuilder
. Functionality similar to
EvictionListeners
is provided by RemovalListeners
. This class is scheduled for
deletion from Guava in Guava release 11.0.Error
variant of ExecutionException
.null
as its detail message.
Executor
, that
guarantees that every Runnable
that is added will
be executed after ExecutionList.execute()
is called.ExecutionList
.
Executor
that will be used to run this service.
Executor
that will be used to run this service.
expectedSize
.
MinMaxPriorityQueue
instances sized appropriately to hold expectedSize
elements.
MapMaker
is being moved to
CacheBuilder
. Functionality equivalent to
MapMaker.expiration(long, java.util.concurrent.TimeUnit)
is provided by
CacheBuilder.expireAfterWrite(long, java.util.concurrent.TimeUnit)
.
This method is scheduled for deletion in July 2012.
OutputStream
that starts buffering to a byte array, but
switches to file buffering once the data reaches a configurable size.InputSupplier
returned by
FileBackedOutputStream.getSupplier()
is finalized.
InputSupplier
returned
by FileBackedOutputStream.getSupplier()
is finalized.
unfiltered
that satisfy a predicate.
unfiltered
that satisfy a predicate.
type
in unfiltered
.
unfiltered
that satisfy a predicate.
type
in unfiltered
.
unfiltered
that satisfy a predicate.
unfiltered
that satisfy a
predicate.
unfiltered
that
satisfy a predicate.
unfiltered
whose keys
satisfy a predicate.
unfiltered
whose
keys satisfy a predicate.
unfiltered
whose values
satisfy a predicate.
unfiltered
whose
values satisfy a predicate.
finalizeReferent()
method which a background thread invokes
after the garbage collector reclaims the referent.FinalizableReference.finalizeReferent()
on them.finalizeReferent()
method which a background thread invokes after
the garbage collector reclaims the referent.finalizeReferent()
method which a background thread invokes after
the garbage collector reclaims the referent.iterable
that satisfies the given
predicate.
iterable
that satisfies the given
predicate, or defaultValue
if none found.
iterator
that satisfies the given
predicate.
iterator
that satisfies the given
predicate.
null
, if
either is, or otherwise throws a NullPointerException
.
float
primitives, that are not
already found in either Float
or Arrays
.Flushable
, with control over whether an
IOException
may be thrown.
Flushable
objects.flush(flushable, true)
, but with no
IOException
in the signature.
array
in order.
put
that silently removes any existing entry
with the value value
before proceeding with the BiMap.put(K, V)
operation.
Enumeration
to the Iterator
interface.
Character
-based predicate, but
which operates on primitive char
instances instead.
InetAddress
having the given string
representation.
Supplier.get()
on supplier
, regardless of its input.
BlockingQueue
which forwards all its method calls to another
BlockingQueue
.ForwardingCache
where subclasses can pass in an already
constructed Cache
as the delegete.ForwardingCheckedFuture
where subclasses
can pass in an already constructed CheckedFuture
as the delegate.ForwardingFuture.SimpleForwardingFuture
which forwards all its method calls to another future.ForwardingFuture
where subclasses
can pass in an already constructed Future
as the delegate.ForwardingListenableFuture.SimpleForwardingListenableFuture
which forwards all its method calls to another
future.ForwardingListenableFuture
where subclasses
can pass in an already constructed ListenableFuture
as the delegate.Map.entrySet()
in terms of the following
methods: ForwardingMap.clear()
, ForwardingMap.containsKey(java.lang.Object)
,
ForwardingMap.get(java.lang.Object)
, ForwardingMap.isEmpty()
, ForwardingMap.remove(java.lang.Object)
, and ForwardingMap.size()
.Map.keySet()
in terms of the following
methods: ForwardingMap.clear()
, ForwardingMap.containsKey(java.lang.Object)
,
ForwardingMap.isEmpty()
, ForwardingMap.remove(java.lang.Object)
, ForwardingMap.size()
, and the Set.iterator()
method of ForwardingMap.entrySet()
.Map.values()
in terms of the following
methods: ForwardingMap.clear()
, ForwardingMap.containsValue(java.lang.Object)
,
ForwardingMap.isEmpty()
, ForwardingMap.size()
, and the Set.iterator()
method of ForwardingMap.entrySet()
.Multiset.elementSet()
in terms of the
following methods: ForwardingCollection.clear()
, ForwardingCollection.contains(java.lang.Object)
, ForwardingCollection.containsAll(java.util.Collection>)
,
ForwardingMultiset.count(java.lang.Object)
, ForwardingCollection.isEmpty()
, the
Set.size()
and Set.iterator()
methods of ForwardingMultiset.entrySet()
, and ForwardingMultiset.remove(Object,
int)
.Service
that forwards all method calls to another service.CacheLoader
which creates values by applying a Function
to the key.
CacheLoader
which obtains values from a Supplier
(independent of the
key).
comparator
.
HostSpecifier
for the given string, throwing
an exception if parsing fails.
InternetDomainName
after lenient
validation.
char
value whose big-endian representation is
stored in the first 2 bytes of bytes
; equivalent to ByteBuffer.wrap(bytes).getChar()
.
int
value whose big-endian representation is stored in
the first 4 bytes of bytes
; equivalent to ByteBuffer.wrap(bytes).getInt()
.
long
value whose big-endian representation is
stored in the first 8 bytes of bytes
; equivalent to ByteBuffer.wrap(bytes).getLong()
.
short
value whose big-endian representation is
stored in the first 2 bytes of bytes
; equivalent to ByteBuffer.wrap(bytes).getShort()
.
char
value whose byte representation is the given 2
bytes, in big-endian order; equivalent to Chars.fromByteArray(new
byte[] {b1, b2})
.
int
value whose byte representation is the given 4
bytes, in big-endian order; equivalent to Ints.fromByteArray(new
byte[] {b1, b2, b3, b4})
.
long
value whose byte representation is the given 8
bytes, in big-endian order; equivalent to Longs.fromByteArray(new
byte[] {b1, b2, b3, b4, b5, b6, b7, b8})
.
short
value whose byte representation is the given 2
bytes, in big-endian order; equivalent to Shorts.fromByteArray(new
byte[] {b1, b2})
.
InternetDomainName.from(String)
InetAddress.getByAddress(java.lang.String, byte[])
expects).
nullableReference
is non-null, returns an Optional
instance containing that
reference; otherwise returns Optional.absent()
.
ImmutableMap<String, String>
from a Properties
instance.
HostSpecifier
built from the provided specifier
,
which is already known to be valid.
Function
instances.Future
computation asynchronously.Future
interface.MapMaker
, except restricted in the types of maps it can build.iterator
position + 1
times, returning the
element at the position
th position.
iterator
position + 1
times, returning the
element at the position
th position or defaultValue
otherwise.
null
if no such mapping exists.
Future.get()
, converting most exceptions to a
new instance of the given checked exception type.
Future.get(long, TimeUnit)
, converting most
exceptions to a new instance of the given checked exception type.
Throwable
cause chain as a list.
iterable
or defaultValue
if
the iterable is empty.
HostAndPort
instance that should
represent the hostname or IPv4/IPv6 literal.
null
if no
entry for this class is present.
iterable
.
iterable
or defaultValue
if
the iterable is empty.
iterator
to the end, returning the last element.
iterator
to the end, returning the last element or
defaultValue
if the iterator is empty.
iterator
or defaultValue
if
the iterator is empty.
iterable
.
iterable
, or defaultValue
if the iterable is empty.
iterator
.
iterator
, or defaultValue
if the iterator is empty.
URL
pointing to resourceName
if the resource is
found in the class path.
URL
pointing to resourceName
that is relative to
contextClass
, if the resource is found in the class path.
throwable
.
toString()
, followed by the full, recursive
stack trace of throwable
.
Future.get()
uninterruptibly on a
task known not to throw a checked exception.
future.
get()
uninterruptibly.
future.
get(timeout, unit)
uninterruptibly.
endpoint
.
k
greatest elements of the given iterable according to
this ordering, in order from greatest to least.
GwtCompatible
and accessible in
GWT.t
.
Table
using hash tables.BiMap
backed by two HashMap
instances.Equivalence.hash(Object)
applied to the the wrapped reference.
Arrays.asList(leftValue(), rightValue()).hashCode()
.
value
; equal to the result of invoking
((Boolean) value).hashCode()
.
value
; equal to the result of invoking
((Byte) value).hashCode()
.
value
; equal to the result of invoking
((Character) value).hashCode()
.
value
; equal to the result of invoking
((Double) value).hashCode()
.
value
; equal to the result of invoking
((Float) value).hashCode()
.
value
; equal to the result of invoking
((Integer) value).hashCode()
.
value
; equal to the result of invoking
((Long) value).hashCode()
.
value
; equal to the result of invoking
((Short) value).hashCode()
.
Multimap
using hash tables.HashMap
.true
if this range has a lower endpoint.
true
if this range has an upper endpoint.
ImmutableSortedMap
, consisting of the entries
whose keys are less than toKey
.
Cache
lookup methods have returned a cached value.
==
to compare values and System.identityHashCode(Object)
to compute the hash code.
CheckedFuture
which has its value set immediately upon
construction.
CheckedFuture
which has an exception set immediately upon
construction.
ListenableFuture
which has an exception set immediately
upon construction.
ListenableFuture
which has its value set immediately upon
construction.
BiMap
with reliable user-specified iteration order.public
static final
bimaps ("constant bimaps").ImmutableMap
.ImmutableCollection
types.List
implementation.public
static final
lists ("constant lists").ListMultimap
with reliable user-specified key and value
iteration order.ListMultimap
instances, especially
public static final
multimaps ("constant multimaps").Map
with reliable user-specified iteration
order.public
static final
maps ("constant maps").Multimap
.public static final
multimaps ("constant multimaps").public static final
multisets ("constant multisets").Set
with reliable, user-specified
iteration order.public
static final
sets ("constant sets").SetMultimap
with reliable user-specified key and value
iteration order.SetMultimap
instances, especially
public static final
multimaps ("constant multimaps").SortedMap
.public static final
maps ("constant maps").SortedSet
that stores its elements in a sorted array.public static final
sets ("constant sets"), with a given comparator.true
if the object reference
being tested is a member of the given collection.
other
.
ImmutableListMultimap
that contains the results of
applying a specified function to each item in an Iterable
of
values.
Multimaps.index(Iterator, Function)
by casting values
to Iterator<V>
, or better yet, by implementing only
Iterator
and not Iterable
. This method is scheduled
for deletion in March 2012.
ImmutableListMultimap
that contains the results of
applying a specified function to each item in an Iterator
of
values.
-1
if no
matching character is present.
-1
if no character matches after that position.
iterable
of the first element that satisfies
the provided predicate
, or -1
if the Iterable has no such
elements.
iterator
of the first element that satisfies
the provided predicate
, or -1
if the Iterator has no such
elements.
target
in
array
.
target
within array
, or -1
if there is no such occurrence.
target
in
array
.
target
within array
, or -1
if there is no such occurrence.
target
in
array
.
target
within array
, or -1
if there is no such occurrence.
target
in
array
.
target
within array
, or -1
if there is no such occurrence.
target
in
array
.
target
within array
, or -1
if there is no such occurrence.
target
in
array
.
target
within array
, or -1
if there is no such occurrence.
target
in
array
.
target
within array
, or -1
if there is no such occurrence.
target
in
array
.
target
within array
, or -1
if there is no such occurrence.
InetAddress
instances.MapMaker.initialCapacity
.
char
matcher that matches any character in a given range (both endpoints are
inclusive).
true
if the object being
tested is an instance of the given class.
Integer
.
String.intern()
for other immutable
types.Interner
.com
or foo.co.uk
.other
, if such a range exists.
int
primitives, that are not
already found in either Integer
or Arrays
.key
, possibly asynchronously, so that a future
invocation of get(key)
will result in a cache miss and reload.
source
into dest
, with
its key and value reversed.
char
matcher that matches only one specified character.
true
if there exists a (possibly empty) range which is
enclosed by both this range and other
.
false
.
true
if the multimap contains no key-value pairs.
true
if this range is of the form [v..v)
or (v..v]
.
true
if the table contains no mappings.
true
if value
represents a real number.
true
if value
represents a real number.
true
if the supplied string is a valid IP string
literal, false
otherwise.
c
is one of the twenty-six lowercase ASCII alphabetic characters
between 'a'
and 'z'
inclusive.
char
matcher that matches any character except the one specified.
true
if the object reference
being tested is null.
true
if the given string is null or is the empty string.
true
if each element in iterable
after the first is
greater than or equal to the element that preceded it, according to this
ordering.
true
if this holder contains a (non-null) instance.
true
if Stopwatch.start()
has been called on this stopwatch,
and Stopwatch.stop()
has not been called since the last call to start()
.
true
if this service is running.
true
if each element in iterable
after the first is
strictly greater than the element that preceded it, according to
this ordering.
c
is one of the twenty-six uppercase ASCII alphabetic characters
between 'A'
and 'Z'
inclusive.
true
if the supplied string is a valid URI IP string
literal, false
otherwise.
specifier
represents a valid
HostSpecifier
as described in the documentation for
HostSpecifier.fromValid(String)
.
InternetDomainName.isValid(String)
instead
true
if type
is one of the nine
primitive-wrapper types, such as Integer
.
Iterable
.Iterator
.Java's
definition
.
Character.isISOControl(char)
.
Java's
definition
.
Java's definition
.
Java's definition
.
Java's definition
.
Java's definition
; it is usually preferable to use CharMatcher.WHITESPACE
.
Future
instances.parts
, using the
previously configured separator between each.
parts
, using the
previously configured separator between each.
map
, using the
previously configured separator and key-value separator.
entries
, using
the previously configured separator and key-value separator.
InputStream
suppliers into a single supplier.
ByteStreams.join(Iterable)
.
Reader
suppliers into a single supplier.
CharStreams.join(Iterable)
.
boolean
values separated
by separator
.
char
values separated
by separator
.
double
values, converted
to strings as specified by Double.toString(double)
, and separated
by separator
.
float
values, converted
to strings as specified by Float.toString(float)
, and separated by
separator
.
int
values separated
by separator
.
long
values separated
by separator
.
short
values separated
by separator
.
byte
values separated
by separator
.
byte
values separated by
separator
.
long
values separated by
separator
.
Iterable
, varargs or even a
Map
) with a separator.Joiner
joins iterables and
arrays.toJoin.
join()
uninterruptibly.
unit.
timedJoin(toJoin, timeout)
uninterruptibly.
-1
if no
matching character is present.
target
in
array
.
target
in
array
.
target
in
array
.
target
in
array
.
target
in
array
.
target
in
array
.
target
in
array
.
target
in
array
.
Futures.transform(ListenableFuture, Function)
except that the
transformation function
is invoked on each call to
get()
on the returned future.
k
least elements of the given iterable according to
this ordering, in order from least to greatest.
endpoint
.
boolean
arrays
lexicographically.
char
arrays
lexicographically.
double
arrays
lexicographically.
float
arrays
lexicographically.
int
arrays
lexicographically.
long
arrays
lexicographically.
short
arrays
lexicographically.
byte
arrays
lexicographically.
byte
arrays
lexicographically.
long
arrays lexicographically.
this
splitter but
stops splitting after it reaches the limit.
limitSize
elements of the given
iterable.
limitSize
elements of the
given iterator.
readLines
methods.Readable
object.
Multimap
that does not allow duplicate key-value
entries and that returns collections whose iterators follow the ordering in
which the data was added to the multimap.Multiset
implementation with predictable iteration order.ListMultimap
that supports deterministic
iteration order for both keys and values.Future
that accepts completion listeners.FutureTask
that also implements the ListenableFuture
interface.ExecutorService
whose submit
and invokeAll
methods submit ListenableFutureTask
instances to the
given delegate executor.
ScheduledExecutorService
whose submit
and invokeAll
methods submit ListenableFutureTask
instances to the
given delegate executor.
ExecutorService
that returns ListenableFuture
instances.ScheduledExecutorService
that returns ListenableFuture
instances from its ExecutorService
methods.Future
to provide ListenableFuture
functionality.
Multimap
that can hold duplicate key-value pairs and that maintains
the insertion ordering of values for a given key.List
instances.DataInput
that uses little-endian byte ordering
for reading short
, int
, float
, double
, and
long
values.LittleEndianDataInputStream
that wraps the given stream.
DataOutput
that uses little-endian byte ordering
for writing char
, short
, int
, float
, double
, and long
values.LittleEndianDataOutputStream
that wraps the given stream.
key
.
Cache
lookup methods attempted to load new
values.
Cache
lookup methods threw an exception while loading a
new value.
Cache
lookup methods have successfully loaded a new value.
Long
.
long
primitives, that are not
already found in either Long
or Arrays
.BoundType.CLOSED
if
the range includes its lower endpoint, BoundType.OPEN
if it does
not.
ListenableFuture
, following the advice in its
documentation and use Futures.makeChecked(ListenableFuture, Function)
.
This method is scheduled for deletion from Guava in Guava release
11.0.
CheckedFuture
out of a normal ListenableFuture
and a Function
that maps from Exception
instances into the
appropriate checked type.
ListenableFuture
instances with SettableFuture
, MoreExecutors.listeningDecorator(
java.util.concurrent.ExecutorService)
, ListenableFutureTask
,
AbstractFuture
, and other utilities over creating plain Future
instances to be upgraded to ListenableFuture
after the
fact. If this is not possible, the functionality of makeListenable
is now available as JdkFutureAdapters.listenInPoolThread(java.util.concurrent.Future)
. This method is scheduled
for deletion from Guava in Guava release 11.0.
MapMaker.makeMap()
.
getUninterruptibly
.
This method is scheduled for deletion in Guava Release 11.
FileChannel.map(java.nio.channels.FileChannel.MapMode, long, long)
.
FileChannel.map(java.nio.channels.FileChannel.MapMode, long, long)
using the requested FileChannel.MapMode
.
FileChannel.map(java.nio.channels.FileChannel.MapMode, long, long)
using the requested FileChannel.MapMode
.
Map
or
Multimap
.MapConstraint
interface.MapMaker.RemovalListener
This class is scheduled
for deletion from Guava in Guava release 11.0.InterruptedException
,
CancellationException
or ExecutionException
thrown by
get
to an exception of type X
to be thrown by
checkedGet
.
ConcurrentMap
instances having any combination of the following features:
keys or values automatically wrapped in weak or soft references
least-recently-used eviction when a maximum size is exceeded
time-based expiration of entries, measured since last access or last write
notification of evicted (or otherwise removed) entries
on-demand computation of values for keys not already present
MapMaker
instance with default settings, including strong keys, strong
values, and no automatic eviction of any kind.
Map
instances.true
if a character sequence contains only matching characters.
true
if a character sequence contains at least one matching character.
true
if a character sequence contains no matching characters.
array
.
array
, using the same rules
of comparison as Math.max(double, double)
.
array
, using the same rules
of comparison as Math.min(float, float)
.
array
.
array
.
array
.
array
.
array
.
array
.
int
.
long
.
short
.
byte
.
byte
.
MinMaxPriorityQueue
instances
that are limited to maximumSize
elements.
MinMaxPriorityQueue
instances that are limited to maximumSize
elements.
C
, if it has one.
get()
and returns that value on subsequent calls to
get()
.
array
.
array
, using the same rules of
comparison as Math.min(double, double)
.
array
, using the same rules of
comparison as Math.min(float, float)
.
array
.
array
.
array
.
array
.
array
.
array
.
CacheStats
representing the difference between this CacheStats
and other
.
C
, if it has one.
Cache
lookup methods have returned an uncached (newly
loaded) value, or null.
Executor
, ExecutorService
, and ThreadFactory
.Map
, but which may associate multiple
values with a single key.Multimap
.Set
, but
may have duplicate elements.Multiset
instances.ArrayList
instance.
ArrayList
instance containing the given
elements.
ArrayList
instance containing the given
elements.
ArrayList
instance containing the given
elements.
ArrayList
instance backed by an array of the
exact size specified; equivalent to
ArrayList.ArrayList(int)
.
ArrayList
instance sized appropriately to hold an
estimated number of elements without resizing.
CacheBuilder
instance with default settings, including strong keys,
strong values, and no automatic eviction of any kind.
ConcurrentMap
, which supports
all optional operations of the ConcurrentMap interface.
ByteArrayDataInput
instance to read from the bytes
array from the beginning.
ByteArrayDataInput
instance to read from the bytes
array, starting at the given position.
ByteArrayDataOutput
instance with a default size.
ByteArrayDataOutput
instance sized to hold
size
bytes before resizing.
EnumMap
instance.
EnumMap
with the same mappings as the specified map.
EnumSet
instance containing the given elements.
HashMap
instance.
HashMap
instance with the same mappings as
the specified map.
HashMap
instance, with a high enough "initial capacity"
that it should hold expectedSize
elements without growth.
HashSet
instance.
HashSet
instance containing the given
elements in unspecified order.
HashSet
instance containing the given
elements in unspecified order.
HashSet
instance containing the given
elements in unspecified order.
HashSet
instance, with a high enough "initial capacity"
that it should hold expectedSize
elements without growth.
IdentityHashMap
instance.
Set
that uses identity to determine equality.
ByteArrayInputStream
that read from the given byte array.
ByteArrayInputStream
that read from the given byte array.
FileInputStream
that read from a file.
InputStream
that
read from the given URL.
LinkedHashMap
instance.
LinkedHashMap
instance
with the same mappings as the specified map.
LinkedHashSet
instance.
LinkedHashSet
instance containing the
given elements in order.
LinkedList
instance.
LinkedList
instance containing the given elements.
ListMultimap
that uses the provided map and factory.
Multimap
that uses the provided map and factory.
FileOutputStream
that write to a file.
FileOutputStream
that write to or append to a file.
interfaceType
that delegates all method
calls to the target
object, enforcing the specified time limit on
each call.
StringReader
that
read a string value.
InputStreamReader
,
using the given InputStream
factory and character set.
InputStreamReader
that read a file using the given character set.
InputStreamReader
that read a URL using the given character set.
AtomicReference
instance with no initial value.
AtomicReference
instance with the given initial value.
AtomicReferenceArray
instance of given length.
AtomicReferenceArray
instance with the same length as,
and all elements copied from, the given array.
SetMultimap
that uses the provided map and factory.
SortedSetMultimap
that uses the provided map and
factory.
TreeMap
instance using the natural
ordering of its elements.
TreeMap
instance with the same mappings as
the specified map and using the same ordering as the specified map.
TreeMap
instance using the given
comparator.
TreeSet
instance sorted by the
natural sort ordering of its elements.
TreeSet
instance containing the given
elements sorted by their natural ordering.
TreeSet
instance with the given
comparator.
OutputStreamWriter
,
using the given OutputStream
factory and character set.
OutputStreamWriter
that write to a file using the given character set.
OutputStreamWriter
that write to or append to a file using the given character set.
C
that is greater than
value
, or null
if none exists.
Ascii.LF
.
char
matcher that matches any character not present in the given character
sequence.
true
if the given predicate
evaluates to false
.
Service.State.FAILED
.
true
if the object reference
being tested is not null.
OutputStream
that simply discards written bytes.null
as less than all other values
and uses this
to compare non-null values.
null
as greater than all other
values and uses this ordering to compare non-null values.
Object
.Objects.toStringHelper(java.lang.Object)
.Optional
instance containing the given non-null reference.
ImmutableList.copyOf(Object[])
. This method is scheduled for
deletion in October 2011.
ImmutableMultiset.copyOf(Object[])
. This method is scheduled for
deletion in January 2012.
ImmutableSet.copyOf(Object[])
. This method is scheduled for
deletion in October 2011.
ImmutableSortedSet.copyOf(Comparable[])
. This method is scheduled
for deletion in October 2011.
instance
.
this
splitter, but
automatically omits empty strings from the results.
separator
between consecutive elements.
separator
between consecutive elements.
CharMatcher
to be a separator.
pattern
to be a separator.
Future
computation fails or is canceled.
F
which evaluates equivalence by first applying
function
to the argument, then evaluating using this
.
F
which orders elements by first applying
a function to them, then comparing those results using this
.
Future
computation when it is
successful.
lower
and strictly less than upper
.
lower
and less than or equal to upper
.
other
.
defaultValue
otherwise.
Optional
if it has a value present; secondChoice
otherwise.
supplier.get()
otherwise.
true
if any one of its
components evaluates to true
.
true
if any one of its
components evaluates to true
.
true
if either of its
components evaluates to true
.
MinMaxPriorityQueue
instances that use comparator
to determine the
least and greatest elements.
null
otherwise.
minLength
, consisting of
string
appended with as many copies of padChar
as are
necessary to reach that length.
minLength
, consisting of
string
prepended with as many copies of padChar
as are
necessary to reach that length.
Equivalence.pairwise()
, which behaves exactly the same. This method is
scheduled for deletion from Guava in Guava release 11.0.
InternetDomainName
that is the immediate ancestor of
this one; that is, the current domain with the leftmost part removed.
long
value represented by the given decimal string.
long
value represented by a string with the given radix.
PeekingIterator.peek()
.
null
if the queue is empty.
PeekingIterator
backed by the given iterator.
null
if the queue is empty.
null
if the queue is empty.
null
if the queue is empty.
set
.
char
matcher functionally equivalent to this one, but which may be faster to
query than the original; your mileage may vary.
Predicate
instances.C
that is less than
value
, or null
if none exists.
throwable
as-is if it is an instance of
RuntimeException
or Error
, or else as a last resort, wraps
it in a RuntimeException
then propagates.
throwable
exactly as-is, if and only if it is an
instance of declaredType
.
throwable
exactly as-is, if and only if it is an
instance of RuntimeException
or Error
.
throwable
exactly as-is, if and only if it is an
instance of RuntimeException
, Error
, or
declaredType
.
throwable
exactly as-is, if and only if it is an
instance of RuntimeException
, Error
, declaredType1
,
or declaredType2
.
null
if no public suffix is present.
key
with value
in the built bimap.
key
with value
in the built map.
key
with value
in the built map.
key
with value
in the built map.
map's
keys and values in the built map.
queue.
put(element)
uninterruptibly.
lower
to upper
, where each endpoint may be either inclusive (closed) or exclusive
(open).
Range
instances.b
.
DataInputStream.readChar()
, except
using little-endian byte order.
double
as specified by
DataInputStream.readDouble()
, except using little-endian byte
order.
Readable
& Closeable
object
supplied by a factory.
float
as specified by DataInputStream.readFloat()
,
except using little-endian byte order.
DataInput.readFully(byte[])
.
len
bytes from the stream into the given array
starting at off
, with the same behavior as
DataInput.readFully(byte[], int, int)
.
DataInputStream.readInt()
, except
using little-endian byte order.
UnsupportedOperationException
.
Readable
& Closeable
object
supplied by a factory.
Readable
object.
Readable
and Closeable
object
supplied by a factory, stopping when our callback returns false, or we
have read all of the lines.
File
, stopping when our callback returns
false, or we have read all of the lines.
long
as specified by DataInputStream.readLong()
,
except using little-endian byte order.
short
as specified by DataInputStream.readShort()
,
except using little-endian byte order.
short
as specified by
DataInputStream.readUnsignedShort()
, except using little-endian
byte order.
object
to receive events.
CacheBuilder
will
notify each time an entry is removed from the cache by any means.
ArrayTable.erase(java.lang.Object, java.lang.Object)
element
, or
makes no change if this is not possible.
e
in occurrencesToRemove
,
removes one occurrence of e
in multisetToModify
.
Cache
lookup methods have returned either a cached or
uncached value.
FileBackedOutputStream.close()
if not already closed, and then resets this
object back to its initial state, for reuse.
multisetToModify
so that its count for an element
e
is at most multisetToRetain.count(e)
.
Callable
which immediately returns a preset value each
time it is called.
Lists.reverse(List)
or ImmutableList.reverse()
. This method is scheduled for deletion in
July 2012.
Ordering
equivalent to
Collections.reverseOrder(Comparator)
.
Table
and whose rows are sorted.ExecutionList.execute()
. This method will be removed in Guava
release 11.
execute/submit
, as in ThreadPoolExecutor.CallerRunsPolicy
This
applies both to individually submitted tasks and to collections of tasks
submitted via invokeAll
or invokeAny
.
char
nearest in value to value
.
int
nearest in value to value
.
short
nearest in value to value
.
byte
nearest in value to value
.
byte
value that, when treated as unsigned, is nearest
in value to value
.
Service.start()
and
Service.stop()
lifecycle methods to transfer into and out of this state.value
with the specified row and column indices.
value
.
element
such that the ConcurrentHashMultiset.count(java.lang.Object)
of the element becomes count
.
element
to newCount
, but
only if the count is currently expectedOldCount
.
Multiset.setCount(Object, int)
, provided that the element has the expected
current count.
throwable
.
Multimap
that cannot hold duplicate key-value pairs.Thread.setName(java.lang.String)
)
which are created with this ThreadFactory.
Set
instances.ListenableFuture
whose result may be set by a SettableFuture.set(Object)
or SettableFuture.setException(Throwable)
call.ThreadFactory
for new threads created with this
ThreadFactory.
Thread.UncaughtExceptionHandler
for new threads created with this
ThreadFactory.
short
primitives, that are not
already found in either Short
or Arrays
.byte
primitives that
interpret values as signed.ExecutorService
.Executors.newCachedThreadPool()
to execute proxied method calls.
value
.
iterable
.
iterator
.
iterable
that skips its first
numberToSkip
elements.
next()
on iterator
, either numberToSkip
times
or until hasNext()
returns false
, whichever comes first.
n
bytes of data from the input stream.
n
characters of data from the reader.
unit.
sleep(sleepFor)
uninterruptibly.
InputSupplier
that returns input streams from the
an underlying supplier, where each stream starts at the given
offset and is limited to the specified number of bytes.
MapMaker.softValues()
to create a memory-sensitive map, or MapMaker.weakKeys()
to
create a map that doesn't hold strong references to the keys.
This method is scheduled for deletion in January 2013.
SoftReference
(by default, strong references are used).
MapMaker.softValues()
.
SoftReference
(by default, strong references are used).
SortedMap
instances.SetMultimap
whose set of values for a given key are kept sorted;
that is, they comprise a SortedSet
.Ascii.SP
.
other
.
sequence
into substrings, splits each substring into
an entry, and returns an unmodifiable map with each of the entries.
sequence
into string components and makes them available
through an Iterator
, which may be lazily evaluated.
CharSequence
)
into substrings, by recognizing a separator (a.k.a.Splitter
splits
iterables and lists.ForwardingCollection.add(Object)
, in terms of
ForwardingList.add(int, Object)
.
ForwardingCollection.add(Object)
in terms of ForwardingMultiset.add(Object, int)
.
ForwardingCollection.addAll(java.util.Collection extends E>)
in terms of ForwardingCollection.add(E)
.
ForwardingList.addAll(int, Collection)
, in
terms of the add
method of ForwardingList.listIterator(int)
.
ForwardingCollection.addAll(Collection)
in terms of ForwardingCollection.add(Object)
and ForwardingMultiset.add(Object, int)
.
ForwardingCollection.clear()
in terms of ForwardingCollection.iterator()
,
using the iterator's remove
method.
ForwardingMap.clear()
in terms of the iterator
method of ForwardingMap.entrySet()
.
ForwardingCollection.clear()
in terms of the iterator
method of ForwardingMultiset.entrySet()
.
ForwardingCollection.contains(java.lang.Object)
in terms of ForwardingCollection.iterator()
.
ForwardingCollection.contains(java.lang.Object)
in terms of ForwardingMultiset.count(java.lang.Object)
.
ForwardingCollection.contains(java.lang.Object)
in terms of the first()
method of ForwardingSortedSet.tailSet(E)
.
ForwardingCollection.containsAll(java.util.Collection>)
in terms of ForwardingCollection.contains(java.lang.Object)
.
ForwardingMap.containsKey(java.lang.Object)
in terms
of the iterator
method of ForwardingMap.entrySet()
.
ForwardingMap.containsKey(java.lang.Object)
in terms of the firstKey()
method of ForwardingSortedMap.tailMap(K)
.
ForwardingMap.containsValue(java.lang.Object)
in terms of the iterator
method of ForwardingMap.entrySet()
.
ForwardingMultiset.count(java.lang.Object)
in terms of
ForwardingMultiset.entrySet()
.
StandardElementSet
constructor instead. This
method will be removed from Guava in Guava release 11.0.
StandardEntrySet
instead. This method will be
removed from Guava in Guava release 11.0.
ForwardingList.equals(Object)
in terms of ForwardingCollection.size()
and ForwardingCollection.iterator()
.
ForwardingMap.equals(java.lang.Object)
in terms of the equals
method of ForwardingMap.entrySet()
.
ForwardingMapEntry.equals(Object)
in terms of ForwardingMapEntry.getKey()
and ForwardingMapEntry.getValue()
.
ForwardingCollection.size()
in terms of
entrySet().size()
and ForwardingMultiset.count(java.lang.Object)
.
ForwardingSet.equals(java.lang.Object)
in terms of ForwardingCollection.size()
and
ForwardingCollection.containsAll(java.util.Collection>)
.
ForwardingList.hashCode()
in terms of ForwardingCollection.iterator()
.
ForwardingMap.hashCode()
in terms of the iterator
method of ForwardingMap.entrySet()
.
ForwardingMapEntry.hashCode()
in terms of ForwardingMapEntry.getKey()
and ForwardingMapEntry.getValue()
.
ForwardingMultiset.hashCode()
as entrySet().hashCode()
.
ForwardingSet.hashCode()
in terms of ForwardingCollection.iterator()
.
ForwardingList.indexOf(java.lang.Object)
, in terms of ForwardingList.listIterator()
.
ForwardingCollection.isEmpty()
as !iterator().hasNext
.
ForwardingMap.isEmpty()
in terms of the iterator
method of ForwardingMap.entrySet()
.
ForwardingCollection.iterator()
, in terms of
ForwardingList.listIterator()
.
ForwardingCollection.iterator()
in terms of ForwardingMultiset.entrySet()
and ForwardingCollection.remove(Object)
.
StandardKeySet
constructor instead. This
method will be removed from Guava in Guava release 11.0.
ForwardingList.lastIndexOf(java.lang.Object)
, in terms of
ForwardingList.listIterator(int)
.
ForwardingList.listIterator()
, in terms of
ForwardingList.listIterator(int)
.
ForwardingList.listIterator(int)
, in terms
of ForwardingCollection.size()
and ForwardingList.get(int)
.
ForwardingQueue.offer(E)
in terms of ForwardingCollection.add(E)
.
ForwardingQueue.peek()
in terms of ForwardingQueue.element()
.
ForwardingQueue.poll()
in terms of ForwardingQueue.remove()
.
ForwardingMap.putAll(Map)
in terms of ForwardingMap.put(Object, Object)
.
ForwardingCollection.remove(java.lang.Object)
in terms of ForwardingCollection.iterator()
,
using the iterator's remove
method.
ForwardingMap.remove(java.lang.Object)
in terms of
the iterator
method of ForwardingMap.entrySet()
.
ForwardingCollection.remove(Object)
in terms of ForwardingMultiset.remove(Object, int)
.
ForwardingMap.remove(java.lang.Object)
in terms of the iterator()
of the entrySet()
of ForwardingSortedMap.tailMap(K)
.
ForwardingCollection.remove(java.lang.Object)
in terms of the iterator()
method of ForwardingSortedSet.tailSet(E)
.
ForwardingCollection.removeAll(java.util.Collection>)
in terms of ForwardingCollection.iterator()
,
using the iterator's remove
method.
ForwardingCollection.removeAll(java.util.Collection>)
in terms of the removeAll
method of ForwardingMultiset.elementSet()
.
ForwardingCollection.retainAll(java.util.Collection>)
in terms of ForwardingCollection.iterator()
,
using the iterator's remove
method.
ForwardingCollection.retainAll(java.util.Collection>)
in terms of the retainAll
method of ForwardingMultiset.elementSet()
.
ForwardingMultiset.setCount(Object, int)
in terms of ForwardingMultiset.count(Object)
, ForwardingMultiset.add(Object, int)
, and ForwardingMultiset.remove(Object,
int)
.
ForwardingMultiset.setCount(Object, int, int)
in terms of
ForwardingMultiset.count(Object)
and ForwardingMultiset.setCount(Object, int)
.
ForwardingCollection.size()
in terms of
ForwardingMultiset.entrySet()
.
ForwardingService.startAndWait()
, in terms of
ForwardingService.start()
.
ForwardingService.stopAndWait()
, in terms of
ForwardingService.stop()
.
ForwardingList.subList(int, int)
.
ForwardingSortedMap.subMap(Object, Object)
in
terms of ForwardingSortedMap.headMap(Object)
and ForwardingSortedMap.tailMap(Object)
.
ForwardingSortedSet.subSet(Object, Object)
in
terms of ForwardingSortedSet.headSet(Object)
and ForwardingSortedSet.tailSet(Object)
.
ForwardingCollection.toArray()
in terms of ForwardingCollection.toArray(Object[])
.
ForwardingCollection.toArray(Object[])
in terms of ForwardingCollection.size()
and ForwardingCollection.iterator()
.
ForwardingObject.toString()
in terms of ForwardingCollection.iterator()
.
ForwardingObject.toString()
in terms of the iterator
method of ForwardingMap.entrySet()
.
ForwardingObject.toString()
in terms of ForwardingMapEntry.getKey()
and ForwardingMapEntry.getValue()
.
ForwardingObject.toString()
as entrySet().toString()
.
StandardValues
constructor instead. This
method will be removed from Guava in Guava release 11.0.
Service.State.NEW
, this initiates service startup
and returns immediately.
System.nanoTime()
as its time source.
String
or CharSequence
instances.fromIndex
, inclusive, and toIndex
, exclusive.
ImmutableSortedMap
, consisting of the entries
whose keys ranges from fromKey
, inclusive, to toKey
,
exclusive.
AnnotatedHandlerFinder
and EventBus
.ListenableFuture
whose value is a list containing the
values of all its successful input futures.
ListenableFuture
whose value is a list containing the
values of all its successful input futures.
Supplier.get()
on that supplier.
ListMultimap
backed by the
specified multimap.
SetMultimap
backed by the
specified multimap.
SortedSetMultimap
backed by
the specified multimap.
get()
method synchronizes on
delegate
before calling it, making it thread-safe.
System.nanoTime()
.
Table
.ImmutableSortedMap
, consisting of the entries
whose keys are greater than or equals to fromKey
.
queue.
take()
uninterruptibly.
setThreadFactory(
Executors.defaultThreadFactory()
)
.ThreadFactory
builder.
Throwable
.throwCause(e, false)
, use propagateIfPossible(e.getCause(), Exception.class); throw e;
. For
throwCause(e, true)
, there is no exact equivalent. Callers are
encouraged to consider whether the cause contains all useful stack
trace context. (It usually does if it comes from within the thread,
e.g., for an InvocationTargetException
, and it usually does not
otherwise, e.g., for an ExecutionException
.) If the cause
contains all useful context, consider throwing it directly if your
method signature permits or wrapping it in an appropriate exception if
not. If the cause does not contain all useful context, consider
propagating the wrapper exception or rewrapping the cause in an
appropriate exception. For the particular case of exceptions thrown by
Future.get
, consider Futures.get(java.util.concurrent.Future,
Class)
. This method will be removed from Guava in Guava release 11.0.
String s
from this format to the specified format
.
InetAddress
.
Boolean
instances into a new array of
primitive boolean
values.
Byte
instances into a new array of
primitive byte
values.
Character
instances into a new array of
primitive char
values.
Double
instances into a new array of
primitive double
values.
Float
instances into a new array of
primitive float
values.
Integer
instances into a new array of
primitive int
values.
Long
instances into a new array of
primitive long
values.
Short
instances into a new array of
primitive short
values.
InputStream
factory as a byte array.
value
in a 2-element byte
array; equivalent to ByteBuffer.allocate(2).putChar(value).array()
.
value
in a 4-element byte
array; equivalent to ByteBuffer.allocate(4).putInt(value).array()
.
value
in an 8-element byte
array; equivalent to ByteBuffer.allocate(8).putLong(value).array()
.
value
in a 2-element byte
array; equivalent to ByteBuffer.allocate(2).putShort(value).array()
.
Objects.toStringHelper(Object)
.
toString(4)
(four significant figures).
{key}={value}
.
rowMap().toString()
.
"[1..100]"
.
toString
method.
iterable
, with the format
[e1, e2, ..., en]
.
iterator
, with the format
[e1, e2, ..., en]
.
toString
on the map returned by Multimap.asMap()
.
"[3..5)"
(other examples are listed in the class documentation).
Readable
object into a String
.
Readable
& Closeable
object
supplied by a factory as a String
.
String
, using the given
character set.
String
, using the given
character set.
x
for the given radix, where x
is treated
as unsigned.
toString()
on its argument.
Objects.ToStringHelper
.
Objects.ToStringHelper
in the same manner as
Objects.toStringHelper(Object)
, but using the name of clazz
instead of using an instance's Object.getClass()
.
Objects.ToStringHelper
in the same manner as
Objects.toStringHelper(Object)
, but using className
instead
of using an instance's Object.getClass()
.
InetAddress
suitable
for inclusion in a URI.
function
to each element of
fromCollection
.
function
to each element of fromIterable
.
function
to each element of fromIterator
.
function
to each element of fromList
.
ListenableFuture
whose result is the product of
applying the given Function
to the result of the given Future
.
ListenableFuture
whose result is the product of
applying the given Function
to the result of the given Future
.
ListenableFuture
(following the advice in its
documentation) and use Futures.transform(ListenableFuture, Function)
or use Futures.lazyTransform(Future, Function)
, which will apply the
transformation on each call to get()
.
This method is scheduled for deletion from Guava in Guava release
11.0.
ListMultimap
whose values are derived from the
original multimap's entries.
ListMultimap
where each value is transformed by
a function.
Table
whose row keys and column keys are ordered
by their natural ordering or by supplied comparators.Multimap
whose keys and values are ordered by
their natural ordering or by supplied comparators.Comparator
.CharMatcher.collapseFrom(java.lang.CharSequence, char)
does, except that
groups of matching characters at the start or end of the sequence are removed without
replacement.
this
splitter, but
automatically removes leading and trailing whitespace from each returned substring; equivalent
to trimResults(CharMatcher.WHITESPACE)
.
this
splitter, but
removes all leading or trailing characters matching the given CharMatcher
from each returned substring.
ArrayListMultimap
, if feasible.
Thread.UncaughtExceptionHandler
instances.ExecutionException
.null
as its detail message.
TimeoutException
.getUninterruptibly
.
Scheduled for deletion in Guava Release 11.Map.values()
are the given
elements in the given order, and each key is the product of invoking a
supplied function on its corresponding value.
Maps.uniqueIndex(Iterator, Function)
by casting values
to Iterator<V>
, or better yet, by implementing only
Iterator
and not Iterable
. This method is scheduled
for deletion in March 2012.
Map.values()
are the given
elements in the given order, and each key is the product of invoking a
supplied function on its corresponding value.
iterable
.
iterator
.
UnmodifiableIterator.remove()
.UnmodifiableIterator.remove()
, UnmodifiableListIterator.add(E)
, or
UnmodifiableListIterator.set(E)
.ListMultimap
.
SetMultimap
.
SortedSetMultimap
.
object
.
byte
primitives that interpret
values as unsigned (that is, any negative value b
is treated
as the positive value 256 + b
).long
primitives that interpret values as
unsigned (that is, any negative value x
is treated as the positive value
2^64 + x
).type
if it is a
wrapper type; otherwise returns type
itself.
BoundType.CLOSED
if
the range includes its upper endpoint, BoundType.OPEN
if it does
not.
nullText
for any provided null keys or values.
nullText
for any provided null elements.
toString()
.
null
indicating that natural ordering is used.
Function
that maps an Enum
name to the associated
Enum
constant.
true
if there was an automatic removal due to eviction (the cause is neither
RemovalCause.EXPLICIT
nor RemovalCause.REPLACED
).
WeakReference
(by default, strong references are used).
MapMaker.weakKeys()
.
WeakReference
(by default, strong references are used).
WeakReference
(by default, strong references are used).
MapMaker.weakValues()
.
WeakReference
(by default, strong references are used).
MapJoiner
using the given key-value separator, and the same configuration as
this Joiner
otherwise.
MapSplitter
which splits entries based on this splitter,
and splits entries into keys and values using the specified separator.
MapSplitter
which splits entries based on this splitter,
and splits entries into keys and values using the specified key-value
splitter.
reference
that implements
Object.equals()
such that
wrap(this, a).equals(wrap(this, b))
if and only if this.equivalent(a, b)
.
type
if it is a primitive
type; otherwise returns type
itself.
write(s.getBytes(Charsets.UTF_8))
.
writeBytes(String s)
are considered
dangerous. Please use LittleEndianDataOutputStream.writeUTF(String s)
,
LittleEndianDataOutputStream.writeChars(String s)
or another write method instead.
DataOutputStream.writeChar(int)
,
except using little-endian byte order.
String
as specified by
DataOutputStream.writeChars(String)
, except each character is
written using little-endian byte order.
double
as specified by
DataOutputStream.writeDouble(double)
, except using little-endian
byte order.
float
as specified by
DataOutputStream.writeFloat(float)
, except using little-endian byte
order.
int
as specified by
DataOutputStream.writeInt(int)
, except using little-endian byte
order.
long
as specified by
DataOutputStream.writeLong(long)
, except using little-endian byte
order.
short
as specified by
DataOutputStream.writeShort(int)
, except using little-endian byte
order.
|
||||||||||
PREV NEXT | FRAMES NO FRAMES |