예제 #1
0
 void CheckExists(AzureBlobFolder folder)
 {
     if (folder.Exists() == false)
     {
         throw new System.IO.DirectoryNotFoundException($"Folder '{folder.Uri.AbsoluteUri}' does not exist");
     }
 }
예제 #2
0
        public IAzureBlobFile GetFile(string name)
        {
            CheckValidFilePath(name);

            AzureBlobFolder folder = this;

            string[] components = SplitFileComponents(name);

            string filename = components[0];

            // Get folder
            if (components.Length > 1)
            {
                string parentDirectory = components[0];
                folder = GetChildFolderRecursive(parentDirectory);

                filename = components[1];
            }

            return(folder.GetChildFile(filename));
        }