| | 1 | | // Copyright (c) Microsoft and contributors. All rights reserved. |
| | 2 | | // |
| | 3 | | // Licensed under the Apache License, Version 2.0 (the "License"); |
| | 4 | | // you may not use this file except in compliance with the License. |
| | 5 | | // You may obtain a copy of the License at |
| | 6 | | // http://www.apache.org/licenses/LICENSE-2.0 |
| | 7 | | // |
| | 8 | | // Unless required by applicable law or agreed to in writing, software |
| | 9 | | // distributed under the License is distributed on an "AS IS" BASIS, |
| | 10 | | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| | 11 | | // |
| | 12 | | // See the License for the specific language governing permissions and |
| | 13 | | // limitations under the License. |
| | 14 | |
|
| | 15 | | using System; |
| | 16 | |
|
| | 17 | | namespace Microsoft.Azure.Batch.FileStaging |
| | 18 | | { |
| | 19 | | /// <summary> |
| | 20 | | /// The file staging artifact payload for this file staging provider |
| | 21 | | /// </summary> |
| | 22 | | public sealed class SequentialFileStagingArtifact : IFileStagingArtifact |
| | 23 | | { |
| | 24 | | private string _namingFragment; |
| | 25 | |
|
| | 26 | | /// <summary> |
| | 27 | | /// The name of any blob container created. |
| | 28 | | /// |
| | 29 | | /// A blob container is created if there is at least one file |
| | 30 | | /// to be uploaded that does not have an explicit container specified. |
| | 31 | | /// </summary> |
| 0 | 32 | | public string BlobContainerCreated { get; internal set;} |
| | 33 | |
|
| | 34 | | /// <summary> |
| | 35 | | /// Optionally set by caller. Optionally used by implementation. A name fragment that can be used when construc |
| | 36 | | /// |
| | 37 | | /// Can only be set once. |
| | 38 | | /// </summary> |
| | 39 | | public string NamingFragment |
| | 40 | | { |
| 0 | 41 | | get { return _namingFragment;} |
| | 42 | |
|
| | 43 | | set |
| | 44 | | { |
| 0 | 45 | | if (null != _namingFragment) |
| | 46 | | { |
| 0 | 47 | | throw new ArgumentException(string.Format(ErrorMessages.FileStagingPropertyCanBeSetOnlyOnce, "Naming |
| | 48 | | } |
| | 49 | |
|
| 0 | 50 | | _namingFragment = value; |
| 0 | 51 | | } |
| | 52 | | } |
| | 53 | |
|
| | 54 | | /// <summary> |
| | 55 | | /// Holds the SAS for the default container after it is created. |
| | 56 | | /// </summary> |
| 0 | 57 | | internal string DefaultContainerSAS { get; set;} |
| | 58 | | } |
| | 59 | | } |