SharedFieldInstanceHandler<R extends SharedReference, O extends ReferenceableType, F extends SharedObjectField<R, O, F>> constructor

SharedFieldInstanceHandler<R extends SharedReference, O extends ReferenceableType, F extends SharedObjectField<R, O, F>>({
  1. required SharedFieldInstantiator<R, O, F> fieldInstantiator,
  2. required SharedObjectInstantiator<R, O> sharedObjectInstantiator,
  3. (Type, Object?)? group,
})

Implementation

factory SharedFieldInstanceHandler(
    {required SharedFieldInstantiator<R, O, F> fieldInstantiator,
    required SharedObjectInstantiator<R, O> sharedObjectInstantiator,
    (Type, Object?)? group}) {
  var fieldHandler = _instances[(F, group)] ??=
      SharedFieldInstanceHandler<R, O, F>._(
          fieldInstantiator, sharedObjectInstantiator,
          group: group);

  return fieldHandler as SharedFieldInstanceHandler<R, O, F>;
}