/// <summary>
 /// Initializes a new instance of the <see cref="BinaryStorageMetaBase" /> class.
 /// </summary>
 /// <param name="identifier">The identifier.</param>
 public BinaryStorageMetaData(BinaryStorageIdentifier identifier)
 {
     if (identifier != null)
     {
         Container  = identifier.Container;
         Identifier = identifier.Identifier;
     }
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="BinaryStorageMetaBase" /> class.
 /// </summary>
 /// <param name="identifier">The identifier.</param>
 public BinaryStorageMetaData(BinaryStorageIdentifier identifier)
 {
     if (identifier != null)
     {
         this.Container = identifier.Container;
         this.Identifier = identifier.Identifier;
     }
 }
 /// <summary>
 /// Gets the storage URL.
 /// </summary>
 /// <param name="storageIdentifier">The storage identifier.</param>
 /// <returns>System.String.</returns>
 public string GetStorageUrl(BinaryStorageIdentifier storageIdentifier)
 {
     return storageIdentifier == null ? string.Empty : GetStorageUrl(storageIdentifier.Container, storageIdentifier.Identifier);
 }
 /// <summary>
 /// Exists the specified storage identifier.
 /// </summary>
 /// <param name="storageIdentifier">The storage identifier.</param>
 /// <returns><c>true</c> if exists, <c>false</c> otherwise.</returns>
 public bool Exists(BinaryStorageIdentifier storageIdentifier)
 {
     return storageIdentifier != null && Exists(storageIdentifier.Container, storageIdentifier.Identifier);
 }
 /// <summary>
 /// Deletes the BLOB.
 /// </summary>
 /// <param name="storageIdentifier">The storage identifier.</param>
 public void DeleteBlob(BinaryStorageIdentifier storageIdentifier)
 {
     if (storageIdentifier != null)
     {
         DeleteBlob(storageIdentifier.Container, storageIdentifier.Identifier);
     }
 }
 /// <summary>
 /// Creates the BLOB URI download.
 /// </summary>
 /// <param name="storageIdentifier">The storage identifier.</param>
 /// <param name="expireOffsetInMinute">The expire offset in minute.</param>
 /// <returns>BinaryStorageActionCredential.</returns>
 public BinaryStorageActionCredential CreateBlobUriDownload(BinaryStorageIdentifier storageIdentifier, int expireOffsetInMinute = 10)
 {
     storageIdentifier.CheckNullObject("storageIdentifier");
     return CreateBlobUriDownload(storageIdentifier.Container, storageIdentifier.Identifier, expireOffsetInMinute);
 }
 /// <summary>
 /// Deletes the BLOB.
 /// </summary>
 /// <param name="storageIdentifier">The storage identifier.</param>
 public abstract void DeleteBlob(BinaryStorageIdentifier storageIdentifier);
 /// <summary>
 /// Check Existence of the specified identifier.
 /// </summary>
 /// <param name="identifier">The identifier.</param>
 /// <returns><c>true</c> if existed, <c>false</c> otherwise.</returns>
 public abstract bool Exists(BinaryStorageIdentifier identifier);
 /// <summary>
 /// Fetches the cloud meta. Returned object would only includes (md5, length, name, content type).
 /// </summary>
 /// <param name="identifier">The identifier.</param>
 /// <returns>BinaryStorageMetaBase.</returns>
 public abstract BinaryStorageMetaData FetchCloudMeta(BinaryStorageIdentifier identifier);
예제 #10
0
 /// <summary>
 /// Initializes a new instance of the <see cref="BinaryStorageCommitRequest"/> class.
 /// </summary>
 /// <param name="storageIdentifier">The storage identifier.</param>
 public BinaryStorageCommitRequest(BinaryStorageIdentifier storageIdentifier) : base(storageIdentifier)
 {
 }
예제 #11
0
 /// <summary>
 /// Creates the commit request.
 /// </summary>
 /// <param name="storageIdentifier">The storage identifier.</param>
 /// <returns></returns>
 public static BinaryStorageCommitRequest CreateCommitRequest(this BinaryStorageIdentifier storageIdentifier)
 {
     return(storageIdentifier == null ? null : new BinaryStorageCommitRequest(storageIdentifier));
 }