/// <summary> /// Initializes a new instance of the <see cref="MultiplexedReadOnlyContentSession"/> class. /// </summary> public MultiplexedReadOnlyContentSession( Dictionary <string, IReadOnlyContentSession> sessionsByCacheRoot, string name, MultiplexedContentStore store) { Contract.Requires(name != null); Contract.Requires(sessionsByCacheRoot != null); Contract.Requires(sessionsByCacheRoot.Count > 0); Name = name; SessionsByCacheRoot = sessionsByCacheRoot; Store = store; if (!SessionsByCacheRoot.TryGetValue(store.PreferredCacheDrive, out PreferredContentSession)) { throw new ArgumentException(nameof(store.PreferredCacheDrive)); } }
/// <summary> /// Initializes a new instance of the <see cref="MultiplexedContentSession"/> class. /// </summary> public MultiplexedContentSession(Dictionary <string, IReadOnlyContentSession> cacheSessionsByRoot, string name, MultiplexedContentStore store) : base(cacheSessionsByRoot, name, store) { }