CollectionBindToChain
interface
Type parameters
-
S
-
T
Methods
-
as( Class ) → void
module:utils/collection~CollectionBindToChain#as
Creates the class factory binding in which items of the source collection are passed to the constructor of the specified class.
Parameters
Class : new ( item: S ) => T
The class constructor used to create instances in the factory.
Returns
void
-
using( callbackOrProperty ) → void
module:utils/collection~CollectionBindToChain#using
Creates a callback or a property binding.
Parameters
callbackOrProperty : keyof S | ( item: S ) => ( null | T )
When the function is passed, it should return the collection items. When the string is provided, the property value is used to create the bound collection items.
Returns
void