implementation ID (dispatch value)
implementation
Takes an object of dispatch values and their implementations and calls .add()
for each KV pair. Returns true, if all impls were added successfully. Note: Only numbers or strings are accepted as dispatch values here.
object of implementations
Similar to MultiFnBase.parents, but includes all transitive parent dispatch values for given dispatch value id
.
implementation ID
Returns true, if the function is callable (has a valid implementation) for given arguments.
arguments to find impl for
Returns iterator of all known dispatch values and their dependencies in the hierarchy of dispatch values. Each dependency is encoded as [value, parent-value?]
. If parent-value
is undefined, the dispatch value has no parent.
Returns a set of all registered dispatch values.
Updates dispatch hierarchy by declaring dispatch value id
to delegate to parent
's implementation. I.e. in terms of dispatch logic, id
is considered the same as `parent.
implementation ID
-parent implementation ID
Returns a set of immediate parent dispatch values for given dispatch value id
.
implementation ID
Returns all known dispatch relationships. This is an object with all registered dispatch values as keys, each with a set of parent dispatch values.
Removes implementation for dispatch value id
. Returns true, if successful.
implementation ID
Generated using TypeDoc
Registers implementation for dispatch value
id
. Returns true, if successful. Returns false if an implementation already exists (and does nothing in this case).