title: How to check wether a CloudBlobDirectory exists or not?
body: <p>In the software that I am programming, I am attempting to create a virtual file system over the blobs structure of Azure.</p>
  
  <p>Many times in the process, I get a path from the system and I need to tell whether the path is of a <code>Blob</code> or just a virtual <code>BlobDirectory</code> that azure provides. I did this by casting it from one form to another and handling the error.</p>
  
  <p>But now, if I know that a path points to a virtual directory, how can I check whether this virtual directory exists or not?</p>
  
  <p>I can get the reference to the <code>CloudBlobDirectory</code> with the following code:</p>
  
  <pre><code>var blobDirectory = client.GetBlobDirectoryReference("Path_to_dir");
  </code></pre>