Class SubnetOverride
java.lang.Object
com.azure.resourcemanager.devtestlabs.models.SubnetOverride
- All Implemented Interfaces:
com.azure.json.JsonSerializable<SubnetOverride>
public final class SubnetOverride
extends Object
implements com.azure.json.JsonSerializable<SubnetOverride>
Property overrides on a subnet of a virtual network.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic SubnetOverride
fromJson
(com.azure.json.JsonReader jsonReader) Reads an instance of SubnetOverride from the JsonReader.Get the labSubnetName property: The name given to the subnet within the lab.Get the resourceId property: The resource ID of the subnet.Get the sharedPublicIpAddressConfiguration property: Properties that virtual machines on this subnet will share.com.azure.json.JsonWriter
toJson
(com.azure.json.JsonWriter jsonWriter) Get the useInVmCreationPermission property: Indicates whether this subnet can be used during virtual machine creation (i.e.Get the usePublicIpAddressPermission property: Indicates whether public IP addresses can be assigned to virtual machines on this subnet (i.e.void
validate()
Validates the instance.Get the virtualNetworkPoolName property: The virtual network pool associated with this subnet.withLabSubnetName
(String labSubnetName) Set the labSubnetName property: The name given to the subnet within the lab.withResourceId
(String resourceId) Set the resourceId property: The resource ID of the subnet.withSharedPublicIpAddressConfiguration
(SubnetSharedPublicIpAddressConfiguration sharedPublicIpAddressConfiguration) Set the sharedPublicIpAddressConfiguration property: Properties that virtual machines on this subnet will share.withUseInVmCreationPermission
(UsagePermissionType useInVmCreationPermission) Set the useInVmCreationPermission property: Indicates whether this subnet can be used during virtual machine creation (i.e.withUsePublicIpAddressPermission
(UsagePermissionType usePublicIpAddressPermission) Set the usePublicIpAddressPermission property: Indicates whether public IP addresses can be assigned to virtual machines on this subnet (i.e.withVirtualNetworkPoolName
(String virtualNetworkPoolName) Set the virtualNetworkPoolName property: The virtual network pool associated with this subnet.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
SubnetOverride
public SubnetOverride()Creates an instance of SubnetOverride class.
-
-
Method Details
-
resourceId
Get the resourceId property: The resource ID of the subnet.- Returns:
- the resourceId value.
-
withResourceId
Set the resourceId property: The resource ID of the subnet.- Parameters:
resourceId
- the resourceId value to set.- Returns:
- the SubnetOverride object itself.
-
labSubnetName
Get the labSubnetName property: The name given to the subnet within the lab.- Returns:
- the labSubnetName value.
-
withLabSubnetName
Set the labSubnetName property: The name given to the subnet within the lab.- Parameters:
labSubnetName
- the labSubnetName value to set.- Returns:
- the SubnetOverride object itself.
-
useInVmCreationPermission
Get the useInVmCreationPermission property: Indicates whether this subnet can be used during virtual machine creation (i.e. Allow, Deny).- Returns:
- the useInVmCreationPermission value.
-
withUseInVmCreationPermission
Set the useInVmCreationPermission property: Indicates whether this subnet can be used during virtual machine creation (i.e. Allow, Deny).- Parameters:
useInVmCreationPermission
- the useInVmCreationPermission value to set.- Returns:
- the SubnetOverride object itself.
-
usePublicIpAddressPermission
Get the usePublicIpAddressPermission property: Indicates whether public IP addresses can be assigned to virtual machines on this subnet (i.e. Allow, Deny).- Returns:
- the usePublicIpAddressPermission value.
-
withUsePublicIpAddressPermission
public SubnetOverride withUsePublicIpAddressPermission(UsagePermissionType usePublicIpAddressPermission) Set the usePublicIpAddressPermission property: Indicates whether public IP addresses can be assigned to virtual machines on this subnet (i.e. Allow, Deny).- Parameters:
usePublicIpAddressPermission
- the usePublicIpAddressPermission value to set.- Returns:
- the SubnetOverride object itself.
-
virtualNetworkPoolName
Get the virtualNetworkPoolName property: The virtual network pool associated with this subnet.- Returns:
- the virtualNetworkPoolName value.
-
withVirtualNetworkPoolName
Set the virtualNetworkPoolName property: The virtual network pool associated with this subnet.- Parameters:
virtualNetworkPoolName
- the virtualNetworkPoolName value to set.- Returns:
- the SubnetOverride object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException
- thrown if the instance is not valid.
-
toJson
- Specified by:
toJson
in interfacecom.azure.json.JsonSerializable<SubnetOverride>
- Throws:
IOException
-
fromJson
Reads an instance of SubnetOverride from the JsonReader.- Parameters:
jsonReader
- The JsonReader being read.- Returns:
- An instance of SubnetOverride if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IOException
- If an error occurs while reading the SubnetOverride.
-