| | 1 | | // Copyright (c) Microsoft Corporation. All rights reserved. |
| | 2 | | // Licensed under the MIT License. See License.txt in the project root for license information. |
| | 3 | | // |
| | 4 | | // Code generated by Microsoft (R) AutoRest Code Generator. |
| | 5 | | // Changes may cause incorrect behavior and will be lost if the code is |
| | 6 | | // regenerated. |
| | 7 | |
|
| | 8 | | // |
| | 9 | | // This file was autogenerated by a tool. |
| | 10 | | // Do not modify it. |
| | 11 | | // |
| | 12 | |
|
| | 13 | | namespace Microsoft.Azure.Batch |
| | 14 | | { |
| | 15 | | using Models = Microsoft.Azure.Batch.Protocol.Models; |
| | 16 | | using System; |
| | 17 | | using System.Collections.Generic; |
| | 18 | | using System.Linq; |
| | 19 | |
|
| | 20 | | /// <summary> |
| | 21 | | /// Information used to connect to an Azure Fileshare. |
| | 22 | | /// </summary> |
| | 23 | | public partial class AzureFileShareConfiguration : ITransportObjectProvider<Models.AzureFileShareConfiguration>, IPr |
| | 24 | | { |
| | 25 | | #region Constructors |
| | 26 | | /// <summary> |
| | 27 | | /// Initializes a new instance of the <see cref="AzureFileShareConfiguration"/> class. |
| | 28 | | /// </summary> |
| | 29 | | /// <param name='accountName'>The Azure Storage Account name.</param> |
| | 30 | | /// <param name='azureFileUrl'>The Azure Files URL.</param> |
| | 31 | | /// <param name='relativeMountPath'>The relative path on the compute node where the file system will be mounted. |
| | 32 | | /// <param name='accountKey'>The Azure Storage Account key.</param> |
| | 33 | | /// <param name='mountOptions'>Additional command line options to pass to the mount command.</param> |
| 935 | 34 | | public AzureFileShareConfiguration( |
| 935 | 35 | | string accountName, |
| 935 | 36 | | string azureFileUrl, |
| 935 | 37 | | string relativeMountPath, |
| 935 | 38 | | string accountKey, |
| 935 | 39 | | string mountOptions = default(string)) |
| | 40 | | { |
| 935 | 41 | | this.AccountName = accountName; |
| 935 | 42 | | this.AzureFileUrl = azureFileUrl; |
| 935 | 43 | | this.RelativeMountPath = relativeMountPath; |
| 935 | 44 | | this.AccountKey = accountKey; |
| 935 | 45 | | this.MountOptions = mountOptions; |
| 935 | 46 | | } |
| | 47 | |
|
| 1351 | 48 | | internal AzureFileShareConfiguration(Models.AzureFileShareConfiguration protocolObject) |
| | 49 | | { |
| 1351 | 50 | | this.AccountKey = protocolObject.AccountKey; |
| 1351 | 51 | | this.AccountName = protocolObject.AccountName; |
| 1351 | 52 | | this.AzureFileUrl = protocolObject.AzureFileUrl; |
| 1351 | 53 | | this.MountOptions = protocolObject.MountOptions; |
| 1351 | 54 | | this.RelativeMountPath = protocolObject.RelativeMountPath; |
| 1351 | 55 | | } |
| | 56 | |
|
| | 57 | | #endregion Constructors |
| | 58 | |
|
| | 59 | | #region AzureFileShareConfiguration |
| | 60 | |
|
| | 61 | | /// <summary> |
| | 62 | | /// Gets the Azure Storage Account key. |
| | 63 | | /// </summary> |
| 3218 | 64 | | public string AccountKey { get; } |
| | 65 | |
|
| | 66 | | /// <summary> |
| | 67 | | /// Gets the Azure Storage Account name. |
| | 68 | | /// </summary> |
| 3218 | 69 | | public string AccountName { get; } |
| | 70 | |
|
| | 71 | | /// <summary> |
| | 72 | | /// Gets the Azure Files URL. |
| | 73 | | /// </summary> |
| | 74 | | /// <remarks> |
| | 75 | | /// This is of the form 'https://myaccount.file.core.windows.net/'. |
| | 76 | | /// </remarks> |
| 3218 | 77 | | public string AzureFileUrl { get; } |
| | 78 | |
|
| | 79 | | /// <summary> |
| | 80 | | /// Gets additional command line options to pass to the mount command. |
| | 81 | | /// </summary> |
| | 82 | | /// <remarks> |
| | 83 | | /// These are 'net use' options in Windows and 'mount' options in Linux. |
| | 84 | | /// </remarks> |
| 3218 | 85 | | public string MountOptions { get; } |
| | 86 | |
|
| | 87 | | /// <summary> |
| | 88 | | /// Gets the relative path on the compute node where the file system will be mounted. |
| | 89 | | /// </summary> |
| | 90 | | /// <remarks> |
| | 91 | | /// All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS |
| | 92 | | /// environment variable. |
| | 93 | | /// </remarks> |
| 3218 | 94 | | public string RelativeMountPath { get; } |
| | 95 | |
|
| | 96 | | #endregion // AzureFileShareConfiguration |
| | 97 | |
|
| | 98 | | #region IPropertyMetadata |
| | 99 | |
|
| | 100 | | bool IModifiable.HasBeenModified |
| | 101 | | { |
| | 102 | | //This class is compile time readonly so it cannot have been modified |
| 0 | 103 | | get { return false; } |
| | 104 | | } |
| | 105 | |
|
| | 106 | | bool IReadOnly.IsReadOnly |
| | 107 | | { |
| 0 | 108 | | get { return true; } |
| | 109 | | set |
| | 110 | | { |
| | 111 | | // This class is compile time readonly already |
| 1352 | 112 | | } |
| | 113 | | } |
| | 114 | |
|
| | 115 | | #endregion // IPropertyMetadata |
| | 116 | |
|
| | 117 | | #region Internal/private methods |
| | 118 | |
|
| | 119 | | /// <summary> |
| | 120 | | /// Return a protocol object of the requested type. |
| | 121 | | /// </summary> |
| | 122 | | /// <returns>The protocol object of the requested type.</returns> |
| | 123 | | Models.AzureFileShareConfiguration ITransportObjectProvider<Models.AzureFileShareConfiguration>.GetTransportObje |
| | 124 | | { |
| 933 | 125 | | Models.AzureFileShareConfiguration result = new Models.AzureFileShareConfiguration() |
| 933 | 126 | | { |
| 933 | 127 | | AccountKey = this.AccountKey, |
| 933 | 128 | | AccountName = this.AccountName, |
| 933 | 129 | | AzureFileUrl = this.AzureFileUrl, |
| 933 | 130 | | MountOptions = this.MountOptions, |
| 933 | 131 | | RelativeMountPath = this.RelativeMountPath, |
| 933 | 132 | | }; |
| | 133 | |
|
| 933 | 134 | | return result; |
| | 135 | | } |
| | 136 | |
|
| | 137 | |
|
| | 138 | | #endregion // Internal/private methods |
| | 139 | | } |
| | 140 | | } |