コード例 #1
0
        protected IConfiguration GetConfiguration(BinaryStorageProviderType storageProviderType, IConfigurationProvider configProvider)
        {
            switch (storageProviderType)
            {
            case BinaryStorageProviderType.AzureBlob:
                return(new AzureBlobStorageConfiguration(configProvider, configurationForEntityType));

            case BinaryStorageProviderType.AzureFile:
                return(new AzureFileStorageConfiguration(configProvider, configurationForEntityType));
            }
            return(null);
        }
コード例 #2
0
        protected BinaryStorageProviderType GetStorageProviderType(string storageProviderValue)
        {
            BinaryStorageProviderType providerType = BinaryStorageProviderType.CrmDefault;

            try
            {
                providerType = (BinaryStorageProviderType)Enum.Parse(typeof(BinaryStorageProviderType), storageProviderValue);
            }
            catch
            {
            }
            return(providerType);
        }