diff --git a/containerregistry/resource-manager/v2016_06_27_preview/pom.xml b/containerregistry/resource-manager/v2016_06_27_preview/pom.xml index ca2b7a844b3d2..290c7c0ff17c5 100644 --- a/containerregistry/resource-manager/v2016_06_27_preview/pom.xml +++ b/containerregistry/resource-manager/v2016_06_27_preview/pom.xml @@ -11,7 +11,7 @@ com.microsoft.azure azure-arm-parent - 0.0.3-beta + 0.0.2-beta ../../../pom.xml azure-mgmt-containerregistry diff --git a/containerregistry/resource-manager/v2017_03_01/pom.xml b/containerregistry/resource-manager/v2017_03_01/pom.xml index fc6968658af92..78f9cd3f98c91 100644 --- a/containerregistry/resource-manager/v2017_03_01/pom.xml +++ b/containerregistry/resource-manager/v2017_03_01/pom.xml @@ -11,7 +11,7 @@ com.microsoft.azure azure-arm-parent - 0.0.3-beta + 0.0.2-beta ../../../pom.xml azure-mgmt-containerregistry diff --git a/containerregistry/resource-manager/v2017_06_01_preview/pom.xml b/containerregistry/resource-manager/v2017_06_01_preview/pom.xml index eb2bdb7a95a7d..f96d71dc1f870 100644 --- a/containerregistry/resource-manager/v2017_06_01_preview/pom.xml +++ b/containerregistry/resource-manager/v2017_06_01_preview/pom.xml @@ -11,7 +11,7 @@ com.microsoft.azure azure-arm-parent - 0.0.3-beta + 0.0.2-beta ../../../pom.xml azure-mgmt-containerregistry diff --git a/containerregistry/resource-manager/v2017_10_01/pom.xml b/containerregistry/resource-manager/v2017_10_01/pom.xml index f500eefc23959..89ef8869e6081 100644 --- a/containerregistry/resource-manager/v2017_10_01/pom.xml +++ b/containerregistry/resource-manager/v2017_10_01/pom.xml @@ -11,7 +11,7 @@ com.microsoft.azure azure-arm-parent - 0.0.3-beta + 0.0.2-beta ../../../pom.xml azure-mgmt-containerregistry diff --git a/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/ImportSource.java b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/ImportSource.java index 81b5c0626dc3c..fb6e17c1acbb4 100644 --- a/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/ImportSource.java +++ b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/ImportSource.java @@ -21,11 +21,17 @@ public class ImportSource { private String resourceId; /** - * The address of the source registry. + * The address of the source registry (e.g. 'mcr.microsoft.com'). */ @JsonProperty(value = "registryUri") private String registryUri; + /** + * Credentials used when importing from a registry uri. + */ + @JsonProperty(value = "credentials") + private ImportSourceCredentials credentials; + /** * Repository name of the source image. * Specify an image by repository ('hello-world'). This will use the @@ -58,7 +64,7 @@ public ImportSource withResourceId(String resourceId) { } /** - * Get the address of the source registry. + * Get the address of the source registry (e.g. 'mcr.microsoft.com'). * * @return the registryUri value */ @@ -67,7 +73,7 @@ public String registryUri() { } /** - * Set the address of the source registry. + * Set the address of the source registry (e.g. 'mcr.microsoft.com'). * * @param registryUri the registryUri value to set * @return the ImportSource object itself. @@ -77,6 +83,26 @@ public ImportSource withRegistryUri(String registryUri) { return this; } + /** + * Get credentials used when importing from a registry uri. + * + * @return the credentials value + */ + public ImportSourceCredentials credentials() { + return this.credentials; + } + + /** + * Set credentials used when importing from a registry uri. + * + * @param credentials the credentials value to set + * @return the ImportSource object itself. + */ + public ImportSource withCredentials(ImportSourceCredentials credentials) { + this.credentials = credentials; + return this; + } + /** * Get repository name of the source image. Specify an image by repository ('hello-world'). This will use the 'latest' tag. diff --git a/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/ImportSourceCredentials.java b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/ImportSourceCredentials.java new file mode 100644 index 0000000000000..5d551e0b6c656 --- /dev/null +++ b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/ImportSourceCredentials.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.containerregistry.v2017_10_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The ImportSourceCredentials model. + */ +public class ImportSourceCredentials { + /** + * The username to authenticate with the source registry. + */ + @JsonProperty(value = "username") + private String username; + + /** + * The password used to authenticate with the source registry. + */ + @JsonProperty(value = "password", required = true) + private String password; + + /** + * Get the username to authenticate with the source registry. + * + * @return the username value + */ + public String username() { + return this.username; + } + + /** + * Set the username to authenticate with the source registry. + * + * @param username the username value to set + * @return the ImportSourceCredentials object itself. + */ + public ImportSourceCredentials withUsername(String username) { + this.username = username; + return this; + } + + /** + * Get the password used to authenticate with the source registry. + * + * @return the password value + */ + public String password() { + return this.password; + } + + /** + * Set the password used to authenticate with the source registry. + * + * @param password the password value to set + * @return the ImportSourceCredentials object itself. + */ + public ImportSourceCredentials withPassword(String password) { + this.password = password; + return this; + } + +} diff --git a/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/Registry.java b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/Registry.java index 566b512b6fe6e..4a58f1862409d 100644 --- a/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/Registry.java +++ b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/Registry.java @@ -35,6 +35,11 @@ public interface Registry extends HasInner, Resource, GroupableRe */ DateTime creationDate(); + /** + * @return the identity value. + */ + RegistryIdentity identity(); + /** * @return the loginServer value. */ @@ -106,6 +111,18 @@ interface WithAdminUserEnabled { WithCreate withAdminUserEnabled(Boolean adminUserEnabled); } + /** + * The stage of the registry definition allowing to specify Identity. + */ + interface WithIdentity { + /** + * Specifies identity. + * @param identity The identity of the container registry + * @return the next definition stage + */ + WithCreate withIdentity(RegistryIdentity identity); + } + /** * The stage of the registry definition allowing to specify StorageAccount. */ @@ -123,13 +140,13 @@ interface WithStorageAccount { * the resource to be created (via {@link WithCreate#create()}), but also allows * for any other optional settings to be specified. */ - interface WithCreate extends Creatable, Resource.DefinitionWithTags, DefinitionStages.WithAdminUserEnabled, DefinitionStages.WithStorageAccount { + interface WithCreate extends Creatable, Resource.DefinitionWithTags, DefinitionStages.WithAdminUserEnabled, DefinitionStages.WithIdentity, DefinitionStages.WithStorageAccount { } } /** * The template for a Registry update operation, containing all the settings that can be modified. */ - interface Update extends Appliable, Resource.UpdateWithTags, UpdateStages.WithAdminUserEnabled, UpdateStages.WithSku, UpdateStages.WithStorageAccount { + interface Update extends Appliable, Resource.UpdateWithTags, UpdateStages.WithAdminUserEnabled, UpdateStages.WithIdentity, UpdateStages.WithSku, UpdateStages.WithStorageAccount { } /** @@ -148,6 +165,18 @@ interface WithAdminUserEnabled { Update withAdminUserEnabled(Boolean adminUserEnabled); } + /** + * The stage of the registry update allowing to specify Identity. + */ + interface WithIdentity { + /** + * Specifies identity. + * @param identity The identity of the container registry + * @return the next update stage + */ + Update withIdentity(RegistryIdentity identity); + } + /** * The stage of the registry update allowing to specify Sku. */ diff --git a/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/RegistryIdentity.java b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/RegistryIdentity.java new file mode 100644 index 0000000000000..89dd908cfb2e7 --- /dev/null +++ b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/RegistryIdentity.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.containerregistry.v2017_10_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The identity of the container registry. + */ +public class RegistryIdentity { + /** + * The type of identity used for the registry. + */ + @JsonProperty(value = "type") + private String type; + + /** + * The principal ID of registry identity. + */ + @JsonProperty(value = "principalId") + private String principalId; + + /** + * The tenant ID associated with the registry. + */ + @JsonProperty(value = "tenantId") + private String tenantId; + + /** + * Get the type of identity used for the registry. + * + * @return the type value + */ + public String type() { + return this.type; + } + + /** + * Set the type of identity used for the registry. + * + * @param type the type value to set + * @return the RegistryIdentity object itself. + */ + public RegistryIdentity withType(String type) { + this.type = type; + return this; + } + + /** + * Get the principal ID of registry identity. + * + * @return the principalId value + */ + public String principalId() { + return this.principalId; + } + + /** + * Set the principal ID of registry identity. + * + * @param principalId the principalId value to set + * @return the RegistryIdentity object itself. + */ + public RegistryIdentity withPrincipalId(String principalId) { + this.principalId = principalId; + return this; + } + + /** + * Get the tenant ID associated with the registry. + * + * @return the tenantId value + */ + public String tenantId() { + return this.tenantId; + } + + /** + * Set the tenant ID associated with the registry. + * + * @param tenantId the tenantId value to set + * @return the RegistryIdentity object itself. + */ + public RegistryIdentity withTenantId(String tenantId) { + this.tenantId = tenantId; + return this; + } + +} diff --git a/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/RegistryUpdateParameters.java b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/RegistryUpdateParameters.java index 12dd3899d44b6..39b0552f4ad05 100644 --- a/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/RegistryUpdateParameters.java +++ b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/RegistryUpdateParameters.java @@ -29,6 +29,12 @@ public class RegistryUpdateParameters { @JsonProperty(value = "sku") private Sku sku; + /** + * The identity of the container registry. + */ + @JsonProperty(value = "identity") + private RegistryIdentity identity; + /** * The value that indicates whether the admin user is enabled. */ @@ -83,6 +89,26 @@ public RegistryUpdateParameters withSku(Sku sku) { return this; } + /** + * Get the identity of the container registry. + * + * @return the identity value + */ + public RegistryIdentity identity() { + return this.identity; + } + + /** + * Set the identity of the container registry. + * + * @param identity the identity value to set + * @return the RegistryUpdateParameters object itself. + */ + public RegistryUpdateParameters withIdentity(RegistryIdentity identity) { + this.identity = identity; + return this; + } + /** * Get the value that indicates whether the admin user is enabled. * diff --git a/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/implementation/RegistryImpl.java b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/implementation/RegistryImpl.java index f8fbda520871f..f3d8199ddf649 100644 --- a/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/implementation/RegistryImpl.java +++ b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/implementation/RegistryImpl.java @@ -13,6 +13,7 @@ import rx.Observable; import com.microsoft.azure.management.containerregistry.v2017_10_01.RegistryUpdateParameters; import com.microsoft.azure.management.containerregistry.v2017_10_01.Sku; +import com.microsoft.azure.management.containerregistry.v2017_10_01.RegistryIdentity; import org.joda.time.DateTime; import com.microsoft.azure.management.containerregistry.v2017_10_01.ProvisioningState; import com.microsoft.azure.management.containerregistry.v2017_10_01.Status; @@ -79,6 +80,11 @@ public DateTime creationDate() { return this.inner().creationDate(); } + @Override + public RegistryIdentity identity() { + return this.inner().identity(); + } + @Override public String loginServer() { return this.inner().loginServer(); @@ -124,6 +130,16 @@ public RegistryImpl withAdminUserEnabled(Boolean adminUserEnabled) { return this; } + @Override + public RegistryImpl withIdentity(RegistryIdentity identity) { + if (isInCreateMode()) { + this.inner().withIdentity(identity); + } else { + this.updateParameter.withIdentity(identity); + } + return this; + } + @Override public RegistryImpl withStorageAccount(StorageAccountProperties storageAccount) { if (isInCreateMode()) { diff --git a/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/implementation/RegistryInner.java b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/implementation/RegistryInner.java index 65021b6d83479..4b9a372c13bcd 100644 --- a/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/implementation/RegistryInner.java +++ b/containerregistry/resource-manager/v2017_10_01/src/main/java/com/microsoft/azure/management/containerregistry/v2017_10_01/implementation/RegistryInner.java @@ -9,6 +9,7 @@ package com.microsoft.azure.management.containerregistry.v2017_10_01.implementation; import com.microsoft.azure.management.containerregistry.v2017_10_01.Sku; +import com.microsoft.azure.management.containerregistry.v2017_10_01.RegistryIdentity; import org.joda.time.DateTime; import com.microsoft.azure.management.containerregistry.v2017_10_01.ProvisioningState; import com.microsoft.azure.management.containerregistry.v2017_10_01.Status; @@ -28,6 +29,12 @@ public class RegistryInner extends Resource { @JsonProperty(value = "sku", required = true) private Sku sku; + /** + * The identity of the container registry. + */ + @JsonProperty(value = "identity") + private RegistryIdentity identity; + /** * The URL that can be used to log into the container registry. */ @@ -88,6 +95,26 @@ public RegistryInner withSku(Sku sku) { return this; } + /** + * Get the identity of the container registry. + * + * @return the identity value + */ + public RegistryIdentity identity() { + return this.identity; + } + + /** + * Set the identity of the container registry. + * + * @param identity the identity value to set + * @return the RegistryInner object itself. + */ + public RegistryInner withIdentity(RegistryIdentity identity) { + this.identity = identity; + return this; + } + /** * Get the URL that can be used to log into the container registry. * diff --git a/containerregistry/resource-manager/v2018_02_01_preview/pom.xml b/containerregistry/resource-manager/v2018_02_01_preview/pom.xml index 016cfd99dae64..ca923dbd01405 100644 --- a/containerregistry/resource-manager/v2018_02_01_preview/pom.xml +++ b/containerregistry/resource-manager/v2018_02_01_preview/pom.xml @@ -11,7 +11,7 @@ com.microsoft.azure azure-arm-parent - 0.0.3-beta + 0.0.2-beta ../../../pom.xml azure-mgmt-containerregistry diff --git a/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/ImportSource.java b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/ImportSource.java index 5376d6b36bc6a..62c4bb669a82a 100644 --- a/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/ImportSource.java +++ b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/ImportSource.java @@ -21,11 +21,17 @@ public class ImportSource { private String resourceId; /** - * The address of the source registry. + * The address of the source registry (e.g. 'mcr.microsoft.com'). */ @JsonProperty(value = "registryUri") private String registryUri; + /** + * Credentials used when importing from a registry uri. + */ + @JsonProperty(value = "credentials") + private ImportSourceCredentials credentials; + /** * Repository name of the source image. * Specify an image by repository ('hello-world'). This will use the @@ -58,7 +64,7 @@ public ImportSource withResourceId(String resourceId) { } /** - * Get the address of the source registry. + * Get the address of the source registry (e.g. 'mcr.microsoft.com'). * * @return the registryUri value */ @@ -67,7 +73,7 @@ public String registryUri() { } /** - * Set the address of the source registry. + * Set the address of the source registry (e.g. 'mcr.microsoft.com'). * * @param registryUri the registryUri value to set * @return the ImportSource object itself. @@ -77,6 +83,26 @@ public ImportSource withRegistryUri(String registryUri) { return this; } + /** + * Get credentials used when importing from a registry uri. + * + * @return the credentials value + */ + public ImportSourceCredentials credentials() { + return this.credentials; + } + + /** + * Set credentials used when importing from a registry uri. + * + * @param credentials the credentials value to set + * @return the ImportSource object itself. + */ + public ImportSource withCredentials(ImportSourceCredentials credentials) { + this.credentials = credentials; + return this; + } + /** * Get repository name of the source image. Specify an image by repository ('hello-world'). This will use the 'latest' tag. diff --git a/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/ImportSourceCredentials.java b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/ImportSourceCredentials.java new file mode 100644 index 0000000000000..9f641ddcfe3a2 --- /dev/null +++ b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/ImportSourceCredentials.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.containerregistry.v2018_02_01_preview; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The ImportSourceCredentials model. + */ +public class ImportSourceCredentials { + /** + * The username to authenticate with the source registry. + */ + @JsonProperty(value = "username") + private String username; + + /** + * The password used to authenticate with the source registry. + */ + @JsonProperty(value = "password", required = true) + private String password; + + /** + * Get the username to authenticate with the source registry. + * + * @return the username value + */ + public String username() { + return this.username; + } + + /** + * Set the username to authenticate with the source registry. + * + * @param username the username value to set + * @return the ImportSourceCredentials object itself. + */ + public ImportSourceCredentials withUsername(String username) { + this.username = username; + return this; + } + + /** + * Get the password used to authenticate with the source registry. + * + * @return the password value + */ + public String password() { + return this.password; + } + + /** + * Set the password used to authenticate with the source registry. + * + * @param password the password value to set + * @return the ImportSourceCredentials object itself. + */ + public ImportSourceCredentials withPassword(String password) { + this.password = password; + return this; + } + +} diff --git a/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/Registry.java b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/Registry.java index 11f8f5fa56c33..e634ecbcaeeea 100644 --- a/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/Registry.java +++ b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/Registry.java @@ -35,6 +35,11 @@ public interface Registry extends HasInner, Resource, GroupableRe */ DateTime creationDate(); + /** + * @return the identity value. + */ + RegistryIdentity identity(); + /** * @return the loginServer value. */ @@ -106,6 +111,18 @@ interface WithAdminUserEnabled { WithCreate withAdminUserEnabled(Boolean adminUserEnabled); } + /** + * The stage of the registry definition allowing to specify Identity. + */ + interface WithIdentity { + /** + * Specifies identity. + * @param identity The identity of the container registry + * @return the next definition stage + */ + WithCreate withIdentity(RegistryIdentity identity); + } + /** * The stage of the registry definition allowing to specify StorageAccount. */ @@ -123,13 +140,13 @@ interface WithStorageAccount { * the resource to be created (via {@link WithCreate#create()}), but also allows * for any other optional settings to be specified. */ - interface WithCreate extends Creatable, Resource.DefinitionWithTags, DefinitionStages.WithAdminUserEnabled, DefinitionStages.WithStorageAccount { + interface WithCreate extends Creatable, Resource.DefinitionWithTags, DefinitionStages.WithAdminUserEnabled, DefinitionStages.WithIdentity, DefinitionStages.WithStorageAccount { } } /** * The template for a Registry update operation, containing all the settings that can be modified. */ - interface Update extends Appliable, Resource.UpdateWithTags, UpdateStages.WithAdminUserEnabled, UpdateStages.WithSku, UpdateStages.WithStorageAccount { + interface Update extends Appliable, Resource.UpdateWithTags, UpdateStages.WithAdminUserEnabled, UpdateStages.WithIdentity, UpdateStages.WithSku, UpdateStages.WithStorageAccount { } /** @@ -148,6 +165,18 @@ interface WithAdminUserEnabled { Update withAdminUserEnabled(Boolean adminUserEnabled); } + /** + * The stage of the registry update allowing to specify Identity. + */ + interface WithIdentity { + /** + * Specifies identity. + * @param identity The identity of the container registry + * @return the next update stage + */ + Update withIdentity(RegistryIdentity identity); + } + /** * The stage of the registry update allowing to specify Sku. */ diff --git a/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/RegistryIdentity.java b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/RegistryIdentity.java new file mode 100644 index 0000000000000..bd7a1cc0897f9 --- /dev/null +++ b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/RegistryIdentity.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.containerregistry.v2018_02_01_preview; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The identity of the container registry. + */ +public class RegistryIdentity { + /** + * The type of identity used for the registry. + */ + @JsonProperty(value = "type") + private String type; + + /** + * The principal ID of registry identity. + */ + @JsonProperty(value = "principalId") + private String principalId; + + /** + * The tenant ID associated with the registry. + */ + @JsonProperty(value = "tenantId") + private String tenantId; + + /** + * Get the type of identity used for the registry. + * + * @return the type value + */ + public String type() { + return this.type; + } + + /** + * Set the type of identity used for the registry. + * + * @param type the type value to set + * @return the RegistryIdentity object itself. + */ + public RegistryIdentity withType(String type) { + this.type = type; + return this; + } + + /** + * Get the principal ID of registry identity. + * + * @return the principalId value + */ + public String principalId() { + return this.principalId; + } + + /** + * Set the principal ID of registry identity. + * + * @param principalId the principalId value to set + * @return the RegistryIdentity object itself. + */ + public RegistryIdentity withPrincipalId(String principalId) { + this.principalId = principalId; + return this; + } + + /** + * Get the tenant ID associated with the registry. + * + * @return the tenantId value + */ + public String tenantId() { + return this.tenantId; + } + + /** + * Set the tenant ID associated with the registry. + * + * @param tenantId the tenantId value to set + * @return the RegistryIdentity object itself. + */ + public RegistryIdentity withTenantId(String tenantId) { + this.tenantId = tenantId; + return this; + } + +} diff --git a/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/RegistryUpdateParameters.java b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/RegistryUpdateParameters.java index 4365c94c85db3..d02aee11e0960 100644 --- a/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/RegistryUpdateParameters.java +++ b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/RegistryUpdateParameters.java @@ -29,6 +29,12 @@ public class RegistryUpdateParameters { @JsonProperty(value = "sku") private Sku sku; + /** + * The identity of the container registry. + */ + @JsonProperty(value = "identity") + private RegistryIdentity identity; + /** * The value that indicates whether the admin user is enabled. */ @@ -83,6 +89,26 @@ public RegistryUpdateParameters withSku(Sku sku) { return this; } + /** + * Get the identity of the container registry. + * + * @return the identity value + */ + public RegistryIdentity identity() { + return this.identity; + } + + /** + * Set the identity of the container registry. + * + * @param identity the identity value to set + * @return the RegistryUpdateParameters object itself. + */ + public RegistryUpdateParameters withIdentity(RegistryIdentity identity) { + this.identity = identity; + return this; + } + /** * Get the value that indicates whether the admin user is enabled. * diff --git a/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/implementation/RegistryImpl.java b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/implementation/RegistryImpl.java index 74b0ff4737e3d..55776ba7453bd 100644 --- a/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/implementation/RegistryImpl.java +++ b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/implementation/RegistryImpl.java @@ -13,6 +13,7 @@ import rx.Observable; import com.microsoft.azure.management.containerregistry.v2018_02_01_preview.RegistryUpdateParameters; import com.microsoft.azure.management.containerregistry.v2018_02_01_preview.Sku; +import com.microsoft.azure.management.containerregistry.v2018_02_01_preview.RegistryIdentity; import org.joda.time.DateTime; import com.microsoft.azure.management.containerregistry.v2018_02_01_preview.ProvisioningState; import com.microsoft.azure.management.containerregistry.v2018_02_01_preview.Status; @@ -79,6 +80,11 @@ public DateTime creationDate() { return this.inner().creationDate(); } + @Override + public RegistryIdentity identity() { + return this.inner().identity(); + } + @Override public String loginServer() { return this.inner().loginServer(); @@ -124,6 +130,16 @@ public RegistryImpl withAdminUserEnabled(Boolean adminUserEnabled) { return this; } + @Override + public RegistryImpl withIdentity(RegistryIdentity identity) { + if (isInCreateMode()) { + this.inner().withIdentity(identity); + } else { + this.updateParameter.withIdentity(identity); + } + return this; + } + @Override public RegistryImpl withStorageAccount(StorageAccountProperties storageAccount) { if (isInCreateMode()) { diff --git a/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/implementation/RegistryInner.java b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/implementation/RegistryInner.java index ebfd71e2d02c1..fcf89643f41de 100644 --- a/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/implementation/RegistryInner.java +++ b/containerregistry/resource-manager/v2018_02_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2018_02_01_preview/implementation/RegistryInner.java @@ -9,6 +9,7 @@ package com.microsoft.azure.management.containerregistry.v2018_02_01_preview.implementation; import com.microsoft.azure.management.containerregistry.v2018_02_01_preview.Sku; +import com.microsoft.azure.management.containerregistry.v2018_02_01_preview.RegistryIdentity; import org.joda.time.DateTime; import com.microsoft.azure.management.containerregistry.v2018_02_01_preview.ProvisioningState; import com.microsoft.azure.management.containerregistry.v2018_02_01_preview.Status; @@ -28,6 +29,12 @@ public class RegistryInner extends Resource { @JsonProperty(value = "sku", required = true) private Sku sku; + /** + * The identity of the container registry. + */ + @JsonProperty(value = "identity") + private RegistryIdentity identity; + /** * The URL that can be used to log into the container registry. */ @@ -88,6 +95,26 @@ public RegistryInner withSku(Sku sku) { return this; } + /** + * Get the identity of the container registry. + * + * @return the identity value + */ + public RegistryIdentity identity() { + return this.identity; + } + + /** + * Set the identity of the container registry. + * + * @param identity the identity value to set + * @return the RegistryInner object itself. + */ + public RegistryInner withIdentity(RegistryIdentity identity) { + this.identity = identity; + return this; + } + /** * Get the URL that can be used to log into the container registry. * diff --git a/containerregistry/resource-manager/v2018_09_01/pom.xml b/containerregistry/resource-manager/v2018_09_01/pom.xml index 955daf05d8d72..b2144db9d2ae8 100644 --- a/containerregistry/resource-manager/v2018_09_01/pom.xml +++ b/containerregistry/resource-manager/v2018_09_01/pom.xml @@ -11,11 +11,11 @@ com.microsoft.azure azure-arm-parent - 0.0.3-beta + 0.0.2-beta ../../../pom.xml azure-mgmt-containerregistry - 1.0.0-beta-1 + 1.0.0-beta jar Microsoft Azure SDK for ContainerRegistry Management This package contains Microsoft ContainerRegistry Management SDK. diff --git a/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/ImportSource.java b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/ImportSource.java index ad69fe0e1df09..8d9f89c456657 100644 --- a/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/ImportSource.java +++ b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/ImportSource.java @@ -21,11 +21,17 @@ public class ImportSource { private String resourceId; /** - * The address of the source registry. + * The address of the source registry (e.g. 'mcr.microsoft.com'). */ @JsonProperty(value = "registryUri") private String registryUri; + /** + * Credentials used when importing from a registry uri. + */ + @JsonProperty(value = "credentials") + private ImportSourceCredentials credentials; + /** * Repository name of the source image. * Specify an image by repository ('hello-world'). This will use the @@ -58,7 +64,7 @@ public ImportSource withResourceId(String resourceId) { } /** - * Get the address of the source registry. + * Get the address of the source registry (e.g. 'mcr.microsoft.com'). * * @return the registryUri value */ @@ -67,7 +73,7 @@ public String registryUri() { } /** - * Set the address of the source registry. + * Set the address of the source registry (e.g. 'mcr.microsoft.com'). * * @param registryUri the registryUri value to set * @return the ImportSource object itself. @@ -77,6 +83,26 @@ public ImportSource withRegistryUri(String registryUri) { return this; } + /** + * Get credentials used when importing from a registry uri. + * + * @return the credentials value + */ + public ImportSourceCredentials credentials() { + return this.credentials; + } + + /** + * Set credentials used when importing from a registry uri. + * + * @param credentials the credentials value to set + * @return the ImportSource object itself. + */ + public ImportSource withCredentials(ImportSourceCredentials credentials) { + this.credentials = credentials; + return this; + } + /** * Get repository name of the source image. Specify an image by repository ('hello-world'). This will use the 'latest' tag. diff --git a/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/ImportSourceCredentials.java b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/ImportSourceCredentials.java new file mode 100644 index 0000000000000..86b39d6e50a9f --- /dev/null +++ b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/ImportSourceCredentials.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.containerregistry.v2018_09_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The ImportSourceCredentials model. + */ +public class ImportSourceCredentials { + /** + * The username to authenticate with the source registry. + */ + @JsonProperty(value = "username") + private String username; + + /** + * The password used to authenticate with the source registry. + */ + @JsonProperty(value = "password", required = true) + private String password; + + /** + * Get the username to authenticate with the source registry. + * + * @return the username value + */ + public String username() { + return this.username; + } + + /** + * Set the username to authenticate with the source registry. + * + * @param username the username value to set + * @return the ImportSourceCredentials object itself. + */ + public ImportSourceCredentials withUsername(String username) { + this.username = username; + return this; + } + + /** + * Get the password used to authenticate with the source registry. + * + * @return the password value + */ + public String password() { + return this.password; + } + + /** + * Set the password used to authenticate with the source registry. + * + * @param password the password value to set + * @return the ImportSourceCredentials object itself. + */ + public ImportSourceCredentials withPassword(String password) { + this.password = password; + return this; + } + +} diff --git a/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/Registry.java b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/Registry.java index b0e249cf5ddfc..35a7ea24e3c03 100644 --- a/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/Registry.java +++ b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/Registry.java @@ -35,6 +35,11 @@ public interface Registry extends HasInner, Resource, GroupableRe */ DateTime creationDate(); + /** + * @return the identity value. + */ + RegistryIdentity identity(); + /** * @return the loginServer value. */ @@ -106,6 +111,18 @@ interface WithAdminUserEnabled { WithCreate withAdminUserEnabled(Boolean adminUserEnabled); } + /** + * The stage of the registry definition allowing to specify Identity. + */ + interface WithIdentity { + /** + * Specifies identity. + * @param identity The identity of the container registry + * @return the next definition stage + */ + WithCreate withIdentity(RegistryIdentity identity); + } + /** * The stage of the registry definition allowing to specify StorageAccount. */ @@ -123,13 +140,13 @@ interface WithStorageAccount { * the resource to be created (via {@link WithCreate#create()}), but also allows * for any other optional settings to be specified. */ - interface WithCreate extends Creatable, Resource.DefinitionWithTags, DefinitionStages.WithAdminUserEnabled, DefinitionStages.WithStorageAccount { + interface WithCreate extends Creatable, Resource.DefinitionWithTags, DefinitionStages.WithAdminUserEnabled, DefinitionStages.WithIdentity, DefinitionStages.WithStorageAccount { } } /** * The template for a Registry update operation, containing all the settings that can be modified. */ - interface Update extends Appliable, Resource.UpdateWithTags, UpdateStages.WithAdminUserEnabled, UpdateStages.WithSku, UpdateStages.WithStorageAccount { + interface Update extends Appliable, Resource.UpdateWithTags, UpdateStages.WithAdminUserEnabled, UpdateStages.WithIdentity, UpdateStages.WithSku, UpdateStages.WithStorageAccount { } /** @@ -148,6 +165,18 @@ interface WithAdminUserEnabled { Update withAdminUserEnabled(Boolean adminUserEnabled); } + /** + * The stage of the registry update allowing to specify Identity. + */ + interface WithIdentity { + /** + * Specifies identity. + * @param identity The identity of the container registry + * @return the next update stage + */ + Update withIdentity(RegistryIdentity identity); + } + /** * The stage of the registry update allowing to specify Sku. */ diff --git a/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/RegistryIdentity.java b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/RegistryIdentity.java new file mode 100644 index 0000000000000..2d6bdd0c70c59 --- /dev/null +++ b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/RegistryIdentity.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.containerregistry.v2018_09_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The identity of the container registry. + */ +public class RegistryIdentity { + /** + * The type of identity used for the registry. + */ + @JsonProperty(value = "type") + private String type; + + /** + * The principal ID of registry identity. + */ + @JsonProperty(value = "principalId") + private String principalId; + + /** + * The tenant ID associated with the registry. + */ + @JsonProperty(value = "tenantId") + private String tenantId; + + /** + * Get the type of identity used for the registry. + * + * @return the type value + */ + public String type() { + return this.type; + } + + /** + * Set the type of identity used for the registry. + * + * @param type the type value to set + * @return the RegistryIdentity object itself. + */ + public RegistryIdentity withType(String type) { + this.type = type; + return this; + } + + /** + * Get the principal ID of registry identity. + * + * @return the principalId value + */ + public String principalId() { + return this.principalId; + } + + /** + * Set the principal ID of registry identity. + * + * @param principalId the principalId value to set + * @return the RegistryIdentity object itself. + */ + public RegistryIdentity withPrincipalId(String principalId) { + this.principalId = principalId; + return this; + } + + /** + * Get the tenant ID associated with the registry. + * + * @return the tenantId value + */ + public String tenantId() { + return this.tenantId; + } + + /** + * Set the tenant ID associated with the registry. + * + * @param tenantId the tenantId value to set + * @return the RegistryIdentity object itself. + */ + public RegistryIdentity withTenantId(String tenantId) { + this.tenantId = tenantId; + return this; + } + +} diff --git a/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/RegistryUpdateParameters.java b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/RegistryUpdateParameters.java index 97ddffade2478..1048cf0acdeea 100644 --- a/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/RegistryUpdateParameters.java +++ b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/RegistryUpdateParameters.java @@ -29,6 +29,12 @@ public class RegistryUpdateParameters { @JsonProperty(value = "sku") private Sku sku; + /** + * The identity of the container registry. + */ + @JsonProperty(value = "identity") + private RegistryIdentity identity; + /** * The value that indicates whether the admin user is enabled. */ @@ -83,6 +89,26 @@ public RegistryUpdateParameters withSku(Sku sku) { return this; } + /** + * Get the identity of the container registry. + * + * @return the identity value + */ + public RegistryIdentity identity() { + return this.identity; + } + + /** + * Set the identity of the container registry. + * + * @param identity the identity value to set + * @return the RegistryUpdateParameters object itself. + */ + public RegistryUpdateParameters withIdentity(RegistryIdentity identity) { + this.identity = identity; + return this; + } + /** * Get the value that indicates whether the admin user is enabled. * diff --git a/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/implementation/RegistryImpl.java b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/implementation/RegistryImpl.java index 83691c502116c..aa941705ea1d3 100644 --- a/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/implementation/RegistryImpl.java +++ b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/implementation/RegistryImpl.java @@ -13,6 +13,7 @@ import rx.Observable; import com.microsoft.azure.management.containerregistry.v2018_09_01.RegistryUpdateParameters; import com.microsoft.azure.management.containerregistry.v2018_09_01.Sku; +import com.microsoft.azure.management.containerregistry.v2018_09_01.RegistryIdentity; import org.joda.time.DateTime; import com.microsoft.azure.management.containerregistry.v2018_09_01.ProvisioningState; import com.microsoft.azure.management.containerregistry.v2018_09_01.Status; @@ -79,6 +80,11 @@ public DateTime creationDate() { return this.inner().creationDate(); } + @Override + public RegistryIdentity identity() { + return this.inner().identity(); + } + @Override public String loginServer() { return this.inner().loginServer(); @@ -124,6 +130,16 @@ public RegistryImpl withAdminUserEnabled(Boolean adminUserEnabled) { return this; } + @Override + public RegistryImpl withIdentity(RegistryIdentity identity) { + if (isInCreateMode()) { + this.inner().withIdentity(identity); + } else { + this.updateParameter.withIdentity(identity); + } + return this; + } + @Override public RegistryImpl withStorageAccount(StorageAccountProperties storageAccount) { if (isInCreateMode()) { diff --git a/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/implementation/RegistryInner.java b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/implementation/RegistryInner.java index 8ff0a1cbef071..6bff5571a8877 100644 --- a/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/implementation/RegistryInner.java +++ b/containerregistry/resource-manager/v2018_09_01/src/main/java/com/microsoft/azure/management/containerregistry/v2018_09_01/implementation/RegistryInner.java @@ -9,6 +9,7 @@ package com.microsoft.azure.management.containerregistry.v2018_09_01.implementation; import com.microsoft.azure.management.containerregistry.v2018_09_01.Sku; +import com.microsoft.azure.management.containerregistry.v2018_09_01.RegistryIdentity; import org.joda.time.DateTime; import com.microsoft.azure.management.containerregistry.v2018_09_01.ProvisioningState; import com.microsoft.azure.management.containerregistry.v2018_09_01.Status; @@ -28,6 +29,12 @@ public class RegistryInner extends Resource { @JsonProperty(value = "sku", required = true) private Sku sku; + /** + * The identity of the container registry. + */ + @JsonProperty(value = "identity") + private RegistryIdentity identity; + /** * The URL that can be used to log into the container registry. */ @@ -88,6 +95,26 @@ public RegistryInner withSku(Sku sku) { return this; } + /** + * Get the identity of the container registry. + * + * @return the identity value + */ + public RegistryIdentity identity() { + return this.identity; + } + + /** + * Set the identity of the container registry. + * + * @param identity the identity value to set + * @return the RegistryInner object itself. + */ + public RegistryInner withIdentity(RegistryIdentity identity) { + this.identity = identity; + return this; + } + /** * Get the URL that can be used to log into the container registry. *