Beispiel #1
0
        public FileHandler(CloudStorageAccount storageAccount, ImageTestContext context)
        {
            // Retrieve storage account from connection string.
            _storageAccount = storageAccount;
            // Create the blob client.
            _blobClient = _storageAccount.CreateCloudBlobClient();
            // Retrieve reference to a previously created container.
            _container = _blobClient.GetContainerReference("pictures");
            _container.CreateIfNotExistsAsync();

            _db = context;

            imageSizes = new List<ImageSize>
            {
                new ImageSize { Size = Sizes.thumb, width = 80 },
                new ImageSize { Size = Sizes.small, width = 360 },
                new ImageSize { Size = Sizes.medium, width = 640 },
                new ImageSize { Size = Sizes.large, width = 1024 }
            };
            
        }
Beispiel #2
0
 public DbPicture(ImageTestContext context)
 {
     db = context;
 }