HomeSort by relevance Sort by last modified time
    Searched refs:Supplier (Results 1 - 25 of 37) sorted by null

1 2

  /external/guava/guava/src/com/google/common/base/
Suppliers.java 43 * Returns a new supplier which is the composition of the provided function
44 * and supplier. In other words, the new supplier's value will be computed by
45 * retrieving the value from {@code supplier}, and then applying
46 * {@code function} to that value. Note that the resulting supplier will not
47 * call {@code supplier} or invoke {@code function} until it is called.
49 public static <F, T> Supplier<T> compose(
50 Function<? super F, T> function, Supplier<F> supplier) {
52 Preconditions.checkNotNull(supplier);
59 final Supplier<F> supplier; field in class:Suppliers.SupplierComposition
    [all...]
Supplier.java 30 public interface Supplier<T> {
Optional.java 127 * Returns the contained instance if it is present; {@code supplier.get()} otherwise. If the
128 * supplier returns {@code null}, a {@link NullPointerException} will be thrown.
130 * @throws NullPointerException if the supplier returns {@code null}
132 public abstract T or(Supplier<? extends T> supplier);
223 @Override public T or(Supplier<? extends T> supplier) {
224 checkNotNull(supplier);
275 @Override public Object or(Supplier<?> supplier) {
    [all...]
Functions.java 311 * Returns a function that always returns the result of invoking {@link Supplier#get} on {@code
312 * supplier}, regardless of its input.
317 public static <T> Function<Object, T> forSupplier(Supplier<T> supplier) {
318 return new SupplierFunction<T>(supplier);
324 private final Supplier<T> supplier; field in class:Functions.SupplierFunction
326 private SupplierFunction(Supplier<T> supplier) {
327 this.supplier = checkNotNull(supplier)
    [all...]
  /external/guava/guava-tests/test/com/google/common/base/
SuppliersTest.java 45 Supplier<Integer> fiveSupplier = new Supplier<Integer>() {
60 Supplier<Integer> squareSupplier = Suppliers.compose(intValueFunction,
67 Supplier<ArrayList<Integer>> listSupplier
68 = new Supplier<ArrayList<Integer>>() {
85 Supplier<List<Integer>> addSupplier = Suppliers.compose(addElementFunction,
93 static class CountingSupplier implements Supplier<Integer>, Serializable {
105 Supplier<Integer> memoizedSupplier = Suppliers.memoize(countingSupplier);
111 Supplier<Integer> memoizedSupplier = Suppliers.memoize(countingSupplier);
118 Supplier<Integer> memoizedSupplier = Suppliers.memoize(countingSupplier)
271 final Supplier<Boolean> supplier = new Supplier<Boolean>() { local
372 Supplier<Integer> supplier = Suppliers.ofInstance(14); local
    [all...]
OptionalTest.java 105 Supplier<Object> nullSupplier = Suppliers.ofInstance(null);
FunctionsTest.java 385 implements Supplier<Integer>, Serializable {
411 Supplier<Integer> supplier = new CountingSupplier(); local
412 Function<Object, Integer> function = Functions.forSupplier(supplier);
418 .addEqualityGroup(function, Functions.forSupplier(supplier))
  /external/guava/guava-gwt/src-super/com/google/common/cache/super/com/google/common/cache/
CacheLoader.java 23 import com.google.common.base.Supplier;
99 * Returns a {@code CacheLoader} which obtains values from a {@code Supplier} (independent of the
102 public static <V> CacheLoader<Object, V> from(Supplier<V> supplier) {
103 return new SupplierToCacheLoader<V>(supplier);
108 private final Supplier<V> computingSupplier;
110 public SupplierToCacheLoader(Supplier<V> computingSupplier) {
  /external/guava/guava-tests/test/com/google/common/collect/
NewCustomTableTest.java 22 import com.google.common.base.Supplier;
37 Supplier<TreeMap<Integer, Character>> factory
38 = new Supplier<TreeMap<Integer, Character>>() {
MultimapCollectionTest.java 30 import com.google.common.base.Supplier;
123 static final Supplier<TreeSet<String>> STRING_TREESET_FACTORY
124 = new Supplier<TreeSet<String>>() {
    [all...]
  /external/guava/guava/src/com/google/common/cache/
CacheLoader.java 25 import com.google.common.base.Supplier;
126 * Returns a {@code CacheLoader} which obtains values from a {@code Supplier} (independent of the
129 public static <V> CacheLoader<Object, V> from(Supplier<V> supplier) {
130 return new SupplierToCacheLoader<V>(supplier);
135 private final Supplier<V> computingSupplier;
137 public SupplierToCacheLoader(Supplier<V> computingSupplier) {
CacheBuilder.java 31 import com.google.common.base.Supplier;
142 static final Supplier<? extends StatsCounter> NULL_STATS_COUNTER = Suppliers.ofInstance(
166 static final Supplier<SimpleStatsCounter> CACHE_STATS_COUNTER =
167 new Supplier<SimpleStatsCounter>() {
222 Supplier<? extends StatsCounter> statsCounterSupplier = CACHE_STATS_COUNTER;
720 Supplier<? extends StatsCounter> getStatsCounterSupplier() {
    [all...]
  /external/harfbuzz_ng/src/
hb-ot-layout-gsub-table.hh 89 Supplier<GlyphID> &glyphs,
165 Supplier<GlyphID> &glyphs,
166 Supplier<GlyphID> &substitutes,
196 Supplier<GlyphID> &glyphs,
197 Supplier<GlyphID> &substitutes,
288 Supplier<GlyphID> &glyphs,
352 Supplier<GlyphID> &glyphs,
353 Supplier<unsigned int> &substitute_len_list,
355 Supplier<GlyphID> &substitute_glyphs_list)
389 Supplier<GlyphID> &glyphs
    [all...]
hb-ot-shape-complex-arabic-fallback.hh 87 OT::Supplier<OT::GlyphID> glyphs_supplier (glyphs, num_glyphs);
88 OT::Supplier<OT::GlyphID> substitutes_supplier (substitutes, num_glyphs);
160 OT::Supplier<OT::GlyphID> first_glyphs_supplier (first_glyphs, num_first_glyphs);
161 OT::Supplier<unsigned int > ligature_per_first_glyph_count_supplier (ligature_per_first_glyph_count_list, num_first_glyphs);
162 OT::Supplier<OT::GlyphID> ligatures_supplier (ligature_list, num_ligatures);
163 OT::Supplier<unsigned int > component_count_supplier (component_count_list, num_ligatures);
164 OT::Supplier<OT::GlyphID> component_supplier (component_list, num_ligatures);
hb-open-type-private.hh 477 struct Supplier
479 inline Supplier (const Type *array, unsigned int len_)
499 inline Supplier (const Supplier<Type> &); /* Disallow copy */
500 inline Supplier<Type>& operator= (const Supplier<Type> &); /* Disallow copy */
790 Supplier<Type> &items,
905 Supplier<Type> &items,
hb-ot-layout-common-private.hh 639 Supplier<GlyphID> &glyphs,
707 Supplier<GlyphID> &glyphs,
816 Supplier<GlyphID> &glyphs,
    [all...]
  /external/guava/guava/src/com/google/common/collect/
HashBasedTable.java 23 import com.google.common.base.Supplier;
56 implements Supplier<Map<C, V>>, Serializable {
StandardRowSortedTable.java 22 import com.google.common.base.Supplier;
58 Supplier<? extends Map<C, V>> factory) {
Multimaps.java 32 import com.google.common.base.Supplier;
103 * @param factory supplier of new, empty collections that will each hold all
108 final Supplier<? extends Collection<V>> factory) {
113 transient Supplier<? extends Collection<V>> factory;
116 Supplier<? extends Collection<V>> factory) {
141 factory = (Supplier<? extends Collection<V>>) stream.readObject();
184 * @param factory supplier of new, empty lists that will each hold all values
189 Map<K, Collection<V>> map, final Supplier<? extends List<V>> factory) {
195 transient Supplier<? extends List<V>> factory;
198 Supplier<? extends List<V>> factory)
    [all...]
TreeBasedTable.java 25 import com.google.common.base.Supplier;
79 implements Supplier<TreeMap<C, V>>, Serializable {
StandardTable.java 26 import com.google.common.base.Supplier;
66 @GwtTransient final Supplier<? extends Map<C, V>> factory;
69 Supplier<? extends Map<C, V>> factory) {
    [all...]
Tables.java 26 import com.google.common.base.Supplier;
359 * @param factory supplier of new, empty maps that will each hold all column
365 Map<R, Map<C, V>> backingMap, Supplier<? extends Map<C, V>> factory) {
  /external/guava/guava/src/com/google/common/eventbus/
EventBus.java 21 import com.google.common.base.Supplier;
116 new Supplier<Set<EventHandler>>() {
  /external/guava/guava-testlib/src/com/google/common/testing/
NullPointerTester.java 24 import com.google.common.base.Supplier;
92 setDefault(Supplier.class, Suppliers.ofInstance(1));
  /external/guava/guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/
Multimaps.java 31 import com.google.common.base.Supplier;
99 * @param factory supplier of new, empty collections that will each hold all
104 final Supplier<? extends Collection<V>> factory) {
109 transient Supplier<? extends Collection<V>> factory;
112 Supplier<? extends Collection<V>> factory) {
159 * @param factory supplier of new, empty lists that will each hold all values
164 Map<K, Collection<V>> map, final Supplier<? extends List<V>> factory) {
170 transient Supplier<? extends List<V>> factory;
173 Supplier<? extends List<V>> factory) {
216 * @param factory supplier of new, empty sets that will each hold all value
    [all...]

Completed in 748 milliseconds

1 2