aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/Tango.Web/Storage/ExtensionMethods.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Software/Visual_Studio/Tango.Web/Storage/ExtensionMethods.cs')
-rw-r--r--Software/Visual_Studio/Tango.Web/Storage/ExtensionMethods.cs7
1 files changed, 7 insertions, 0 deletions
diff --git a/Software/Visual_Studio/Tango.Web/Storage/ExtensionMethods.cs b/Software/Visual_Studio/Tango.Web/Storage/ExtensionMethods.cs
index 4acd10082..e9e361f21 100644
--- a/Software/Visual_Studio/Tango.Web/Storage/ExtensionMethods.cs
+++ b/Software/Visual_Studio/Tango.Web/Storage/ExtensionMethods.cs
@@ -21,6 +21,13 @@ namespace Tango.Web.Storage
return emptyBlob;
}
+ public static CloudBlockBlob UploadNewBlob(this CloudBlobContainer container, Stream stream, String name)
+ {
+ CloudBlockBlob emptyBlob = container.GetBlockBlobReference(name);
+ emptyBlob.UploadFromStream(stream);
+ return emptyBlob;
+ }
+
public static String GenerateReadSignature(this CloudBlockBlob blob, TimeSpan duration)
{
String signature = blob.GetSharedAccessSignature(new SharedAccessBlobPolicy()