/// <summary> /// Detectes whether a provider is included in the list. /// </summary> /// <param name="provider">The provider.</param> /// <returns><c>true</c> if the provider is included, <c>false</c> otherwise.</returns> private bool IsProviderIncludedInList(IProviderV40 provider) { IStorageProviderV40 storageProvider = provider as IStorageProviderV40; IUsersStorageProviderV40 usersProvider = provider as IUsersStorageProviderV40; switch (providerType) { case ProviderType.Users: return(IsUsersProviderIncludedInList(usersProvider)); case ProviderType.Pages: return(storageProvider == null || (!storageProvider.ReadOnly || storageProvider.ReadOnly && !excludeReadOnly)); case ProviderType.Files: return(storageProvider == null || (!storageProvider.ReadOnly || storageProvider.ReadOnly && !excludeReadOnly)); case ProviderType.Themes: return(storageProvider == null || (!storageProvider.ReadOnly || storageProvider.ReadOnly && !excludeReadOnly)); default: throw new NotSupportedException(); } }
/// <summary> /// Initializes a new instance of the <see cref="T:IndexRow" /> class. /// </summary> /// <param name="provider">The original provider.</param> public IndexRow(string command, IStorageProviderV40 provider) { this.command = command; this.provider = provider.Information.Name; providerType = provider.GetType().FullName; }