Class UserArtifactSettings
java.lang.Object
com.azure.resourcemanager.compute.models.UserArtifactSettings
- All Implemented Interfaces:
com.azure.json.JsonSerializable<UserArtifactSettings>
public final class UserArtifactSettings
extends Object
implements com.azure.json.JsonSerializable<UserArtifactSettings>
Additional settings for the VM app that contains the target package and config file name when it is deployed to
target VM or VM scale set.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the configFileName property: Optional.static UserArtifactSettingsfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of UserArtifactSettings from the JsonReader.Get the packageFileName property: Optional.Get the scriptBehaviorAfterReboot property: Optional.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) voidvalidate()Validates the instance.withConfigFileName(String configFileName) Set the configFileName property: Optional.withPackageFileName(String packageFileName) Set the packageFileName property: Optional.withScriptBehaviorAfterReboot(GalleryApplicationScriptRebootBehavior scriptBehaviorAfterReboot) Set the scriptBehaviorAfterReboot property: Optional.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
UserArtifactSettings
public UserArtifactSettings()Creates an instance of UserArtifactSettings class.
-
-
Method Details
-
packageFileName
Get the packageFileName property: Optional. The name to assign the downloaded package file on the VM. This is limited to 4096 characters. If not specified, the package file will be named the same as the Gallery Application name.- Returns:
- the packageFileName value.
-
withPackageFileName
Set the packageFileName property: Optional. The name to assign the downloaded package file on the VM. This is limited to 4096 characters. If not specified, the package file will be named the same as the Gallery Application name.- Parameters:
packageFileName- the packageFileName value to set.- Returns:
- the UserArtifactSettings object itself.
-
configFileName
Get the configFileName property: Optional. The name to assign the downloaded config file on the VM. This is limited to 4096 characters. If not specified, the config file will be named the Gallery Application name appended with "_config".- Returns:
- the configFileName value.
-
withConfigFileName
Set the configFileName property: Optional. The name to assign the downloaded config file on the VM. This is limited to 4096 characters. If not specified, the config file will be named the Gallery Application name appended with "_config".- Parameters:
configFileName- the configFileName value to set.- Returns:
- the UserArtifactSettings object itself.
-
scriptBehaviorAfterReboot
Get the scriptBehaviorAfterReboot property: Optional. The action to be taken with regards to install/update/remove of the gallery application in the event of a reboot.- Returns:
- the scriptBehaviorAfterReboot value.
-
withScriptBehaviorAfterReboot
public UserArtifactSettings withScriptBehaviorAfterReboot(GalleryApplicationScriptRebootBehavior scriptBehaviorAfterReboot) Set the scriptBehaviorAfterReboot property: Optional. The action to be taken with regards to install/update/remove of the gallery application in the event of a reboot.- Parameters:
scriptBehaviorAfterReboot- the scriptBehaviorAfterReboot value to set.- Returns:
- the UserArtifactSettings object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
toJson
- Specified by:
toJsonin interfacecom.azure.json.JsonSerializable<UserArtifactSettings>- Throws:
IOException
-
fromJson
public static UserArtifactSettings fromJson(com.azure.json.JsonReader jsonReader) throws IOException Reads an instance of UserArtifactSettings from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of UserArtifactSettings 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 UserArtifactSettings.
-