/// <summary> /// Clears the specified items of this instance. /// </summary> /// <param name="persistenceLevel">Persistence level of the item to add.</param> public void ClearItems(PersistenceLevels persistenceLevel = PersistenceLevels.Singleton) { switch (persistenceLevel) { case PersistenceLevels.Singleton: SingletonItems.Clear(); break; case PersistenceLevels.Scoped: ScopedItems.Clear(); break; case PersistenceLevels.Transient: TransientItems.Clear(); break; case PersistenceLevels.Any: SingletonItems.Clear(); ScopedItems.Clear(); TransientItems.Clear(); break; } }
/// <summary> /// Clears all the data of this instance. /// </summary> public void Clear() { SingletonItems.Clear(); ScopedItems.Clear(); TransientItems.Clear(); }