InstanceBox IPluginRepo.AddInstanceBox(Type type, InstanceBox box) { Validate.NotNull(box); InstanceBox prev; if (_instances.TryGetValue(type, out prev)) return prev; _instances.Add(type, box); return box; }
InstanceBox IPluginRepo.AddInstanceBox(Type type, InstanceBox box) { lock (_mutex) return _impl.AddInstanceBox(type, box); }