public void Dispose() { if (_wasDisposed) { return; } _wasDisposed = true; if (Role == ContainerRole.Root) { _singletons.DisposeAndClear(); } ContainerCache.DisposeAndClear(); _transients.DisposeAndClear(); _pluginGraph.SafeDispose(); if (Role == ContainerRole.Root) { _profiles.AllProfiles().Each(x => x.Dispose()); } _trackedDisposables.Each(x => x.Dispose()); }
public void Dispose() { if (Role == ContainerRole.Root) { _singletons.DisposeAndClear(); } _transients.DisposeAndClear(); _pluginGraph.SafeDispose(); }
public void Dispose() { //might need some locking in here, since _factories is being modified if (_factories.ContainsKey(typeof(IContainer))) { _factories[typeof(IContainer)].AllInstances.Each(x => x.SafeDispose()); } foreach (var factory in _factories) { factory.Value.Dispose(); } _factories.Clear(); _profileManager.Dispose(); _genericsGraph.ClearAll(); _transientCache.DisposeAndClear(); }
public void Dispose() { _transients.DisposeAndClear(); _pluginGraph.SafeDispose(); }
public TimeExpiringLifeCycle(long timeInSeconds) { _secondsToExpire = timeInSeconds; _cache.DisposeAndClear(); }
public void EjectAll() { _objectCache.DisposeAndClear(); }
public override void EjectAll(ILifecycleContext context) { _cache.DisposeAndClear(); }
public void Dispose() { _transientCache.DisposeAndClear(); _outer.SafeDispose(); }