/external/guava/guava-tests/test/com/google/common/base/ |
D | SuppliersTest.java | 271 Supplier<Object> objectSupplier = Suppliers.ofInstance(toBeSupplied); in testOfInstanceSuppliesSameInstance() 277 Supplier<Integer> nullSupplier = Suppliers.ofInstance(null); in testOfInstanceSuppliesNull() 424 Supplier<Integer> supplier = Suppliers.ofInstance(14); in testSupplierFunction() 432 assertEquals(Integer.valueOf(5), reserialize(Suppliers.ofInstance(5)).get()); in testSerialization() 435 reserialize(Suppliers.compose(Functions.identity(), Suppliers.ofInstance(5))).get()); in testSerialization() 436 assertEquals(Integer.valueOf(5), reserialize(Suppliers.memoize(Suppliers.ofInstance(5))).get()); in testSerialization() 439 reserialize(Suppliers.memoizeWithExpiration(Suppliers.ofInstance(5), 30, TimeUnit.SECONDS)) in testSerialization() 443 reserialize(Suppliers.synchronizedSupplier(Suppliers.ofInstance(5))).get()); in testSerialization() 459 .addEqualityGroup(Suppliers.ofInstance("foo"), Suppliers.ofInstance("foo")) in testOfInstance_equals() 460 .addEqualityGroup(Suppliers.ofInstance("bar")) in testOfInstance_equals() [all …]
|
D | OptionalTest.java | 114 assertEquals("a", Optional.of("a").or(Suppliers.ofInstance("fallback"))); in testOr_supplier_present() 118 assertEquals("fallback", Optional.absent().or(Suppliers.ofInstance("fallback"))); in testOr_supplier_absent() 122 Supplier<Object> nullSupplier = Suppliers.ofInstance(null); in testOr_nullSupplier_absent() 132 Supplier<String> nullSupplier = Suppliers.ofInstance(null); in testOr_nullSupplier_present()
|
D | FunctionsTest.java | 404 .addEqualityGroup(Functions.forSupplier(Suppliers.ofInstance(12))) in testForSupplier()
|
/external/guava/android/guava-tests/test/com/google/common/base/ |
D | SuppliersTest.java | 271 Supplier<Object> objectSupplier = Suppliers.ofInstance(toBeSupplied); in testOfInstanceSuppliesSameInstance() 277 Supplier<Integer> nullSupplier = Suppliers.ofInstance(null); in testOfInstanceSuppliesNull() 424 Supplier<Integer> supplier = Suppliers.ofInstance(14); in testSupplierFunction() 432 assertEquals(Integer.valueOf(5), reserialize(Suppliers.ofInstance(5)).get()); in testSerialization() 435 reserialize(Suppliers.compose(Functions.identity(), Suppliers.ofInstance(5))).get()); in testSerialization() 436 assertEquals(Integer.valueOf(5), reserialize(Suppliers.memoize(Suppliers.ofInstance(5))).get()); in testSerialization() 439 reserialize(Suppliers.memoizeWithExpiration(Suppliers.ofInstance(5), 30, TimeUnit.SECONDS)) in testSerialization() 443 reserialize(Suppliers.synchronizedSupplier(Suppliers.ofInstance(5))).get()); in testSerialization() 459 .addEqualityGroup(Suppliers.ofInstance("foo"), Suppliers.ofInstance("foo")) in testOfInstance_equals() 460 .addEqualityGroup(Suppliers.ofInstance("bar")) in testOfInstance_equals() [all …]
|
D | OptionalTest.java | 97 assertEquals("a", Optional.of("a").or(Suppliers.ofInstance("fallback"))); in testOr_supplier_present() 101 assertEquals("fallback", Optional.absent().or(Suppliers.ofInstance("fallback"))); in testOr_supplier_absent() 105 Supplier<Object> nullSupplier = Suppliers.ofInstance(null); in testOr_nullSupplier_absent() 115 Supplier<String> nullSupplier = Suppliers.ofInstance(null); in testOr_nullSupplier_present()
|
D | FunctionsTest.java | 404 .addEqualityGroup(Functions.forSupplier(Suppliers.ofInstance(12))) in testForSupplier()
|
/external/mockito/src/main/java/org/mockito/internal/configuration/injection/ |
D | MockInjection.java | 35 public static OngoingMockInjection onField(Field field, Object ofInstance) { in onField() argument 36 return new OngoingMockInjection(field, ofInstance); in onField() 47 public static OngoingMockInjection onFields(Set<Field> fields, Object ofInstance) { in onFields() argument 48 return new OngoingMockInjection(fields, ofInstance); in onFields()
|
/external/guava/android/guava-tests/test/com/google/common/util/concurrent/ |
D | CallablesTest.java | 92 final Supplier<String> newName = Suppliers.ofInstance("MyCrazyThreadName"); in testRenaming() 108 final Supplier<String> newName = Suppliers.ofInstance("MyCrazyThreadName"); in testRenaming_exceptionalReturn() 143 Supplier<String> newName = Suppliers.ofInstance("MyCrazyThreadName"); in testRenaming_noPermissions()
|
D | MoreExecutorsTest.java | 646 renamingDecorator(newDirectExecutorService(), Suppliers.ofInstance("FooBar")); in testThreadRenaming()
|
/external/guava/guava-tests/test/com/google/common/util/concurrent/ |
D | CallablesTest.java | 92 final Supplier<String> newName = Suppliers.ofInstance("MyCrazyThreadName"); in testRenaming() 108 final Supplier<String> newName = Suppliers.ofInstance("MyCrazyThreadName"); in testRenaming_exceptionalReturn() 143 Supplier<String> newName = Suppliers.ofInstance("MyCrazyThreadName"); in testRenaming_noPermissions()
|
D | MoreExecutorsTest.java | 646 renamingDecorator(newDirectExecutorService(), Suppliers.ofInstance("FooBar")); in testThreadRenaming()
|
/external/guava/android/guava-tests/test/com/google/common/cache/ |
D | CacheBuilderSpecTest.java | 473 builder.weigher(constantWeigher(42)).build(CacheLoader.from(Suppliers.ofInstance(null))); in testMaximumWeight_withWeigher() 479 builder.build(CacheLoader.from(Suppliers.ofInstance(null))); in testMaximumWeight_withoutWeigher() 487 builder.weigher(constantWeigher(42)).build(CacheLoader.from(Suppliers.ofInstance(null))); in testMaximumSize_withWeigher() 492 builder.build(CacheLoader.from(Suppliers.ofInstance(null))); in testMaximumSize_withoutWeigher() 502 builder.build(CacheLoader.from(Suppliers.ofInstance(value))); in testDisableCaching()
|
/external/guava/guava-tests/test/com/google/common/cache/ |
D | CacheBuilderSpecTest.java | 473 builder.weigher(constantWeigher(42)).build(CacheLoader.from(Suppliers.ofInstance(null))); in testMaximumWeight_withWeigher() 479 builder.build(CacheLoader.from(Suppliers.ofInstance(null))); in testMaximumWeight_withoutWeigher() 487 builder.weigher(constantWeigher(42)).build(CacheLoader.from(Suppliers.ofInstance(null))); in testMaximumSize_withWeigher() 492 builder.build(CacheLoader.from(Suppliers.ofInstance(null))); in testMaximumSize_withoutWeigher() 502 builder.build(CacheLoader.from(Suppliers.ofInstance(value))); in testDisableCaching()
|
/external/guava/android/guava/src/com/google/common/base/ |
D | Suppliers.java | 267 public static <T> Supplier<T> ofInstance(@NullableDecl T instance) { in ofInstance() method in Suppliers
|
/external/guava/guava/src/com/google/common/base/ |
D | Suppliers.java | 267 public static <T> Supplier<T> ofInstance(@Nullable T instance) { in ofInstance() method in Suppliers
|
/external/turbine/java/com/google/turbine/processing/ |
D | TurbineFiler.java | 189 return new BytesFileObject(path, Suppliers.ofInstance(generated)); in getResource()
|
/external/guava/android/guava/src/com/google/common/cache/ |
D | CacheBuilder.java | 166 Suppliers.ofInstance(
|
/external/guava/guava/src/com/google/common/cache/ |
D | CacheBuilder.java | 165 Suppliers.ofInstance(
|