T
- type which could be handled by Supplier
and this bridge.public class SupplierFactoryBridge<T> extends Object implements Factory<T>
Supplier
of the particular type and use this Supplier
to create a new
instance. If the Supplier
is not found then null
is returned.
If the found Supplier
is a type of DisposableSupplier
then this bridge can delegate
Factory.dispose(Object)
invocation to DisposableSupplier.dispose(Object)
.
It's recommended to register the instance of this class as a singleton and then the provide()
is called according to
a provided scope (for the created instance) during the binding process.
Copyright © 2007-2024, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.