Class GuestPolicies.SoftwareRecipe.Builder

  • All Implemented Interfaces:
    GuestPolicies.SoftwareRecipeOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
    Enclosing class:
    GuestPolicies.SoftwareRecipe

    public static final class GuestPolicies.SoftwareRecipe.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<GuestPolicies.SoftwareRecipe.Builder>
    implements GuestPolicies.SoftwareRecipeOrBuilder
     A software recipe is a set of instructions for installing and configuring a
     piece of software. It consists of a set of artifacts that are
     downloaded, and a set of steps that install, configure, and/or update the
     software.
    
     Recipes support installing and updating software from artifacts in the
     following formats:
     Zip archive, Tar archive, Windows MSI, Debian package, and RPM package.
    
     Additionally, recipes support executing a script (either defined in a file or
     directly in this api) in bash, sh, cmd, and powershell.
    
     Updating a software recipe
    
     If a recipe is assigned to an instance and there is a recipe with the same
     name but a lower version already installed and the assigned state
     of the recipe is `UPDATED`, then the recipe is updated to
     the new version.
    
     Script Working Directories
    
     Each script or execution step is run in its own temporary directory which
     is deleted after completing the step.
     
    Protobuf type google.cloud.osconfig.v1beta.SoftwareRecipe
    • Method Detail

      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<GuestPolicies.SoftwareRecipe.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<GuestPolicies.SoftwareRecipe.Builder>
      • getDefaultInstanceForType

        public GuestPolicies.SoftwareRecipe getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public GuestPolicies.SoftwareRecipe build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public GuestPolicies.SoftwareRecipe buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<GuestPolicies.SoftwareRecipe.Builder>
      • mergeFrom

        public GuestPolicies.SoftwareRecipe.Builder mergeFrom​(com.google.protobuf.CodedInputStream input,
                                                              com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                       throws IOException
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Specified by:
        mergeFrom in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<GuestPolicies.SoftwareRecipe.Builder>
        Throws:
        IOException
      • getName

        public String getName()
         Required. Unique identifier for the recipe. Only one recipe with a given name is
         installed on an instance.
        
         Names are also used to identify resources which helps to determine whether
         guest policies have conflicts. This means that requests to create multiple
         recipes with the same name and version are rejected since they
         could potentially have conflicting assignments.
         
        string name = 1 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        getName in interface GuestPolicies.SoftwareRecipeOrBuilder
        Returns:
        The name.
      • getNameBytes

        public com.google.protobuf.ByteString getNameBytes()
         Required. Unique identifier for the recipe. Only one recipe with a given name is
         installed on an instance.
        
         Names are also used to identify resources which helps to determine whether
         guest policies have conflicts. This means that requests to create multiple
         recipes with the same name and version are rejected since they
         could potentially have conflicting assignments.
         
        string name = 1 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        getNameBytes in interface GuestPolicies.SoftwareRecipeOrBuilder
        Returns:
        The bytes for name.
      • setName

        public GuestPolicies.SoftwareRecipe.Builder setName​(String value)
         Required. Unique identifier for the recipe. Only one recipe with a given name is
         installed on an instance.
        
         Names are also used to identify resources which helps to determine whether
         guest policies have conflicts. This means that requests to create multiple
         recipes with the same name and version are rejected since they
         could potentially have conflicting assignments.
         
        string name = 1 [(.google.api.field_behavior) = REQUIRED];
        Parameters:
        value - The name to set.
        Returns:
        This builder for chaining.
      • clearName

        public GuestPolicies.SoftwareRecipe.Builder clearName()
         Required. Unique identifier for the recipe. Only one recipe with a given name is
         installed on an instance.
        
         Names are also used to identify resources which helps to determine whether
         guest policies have conflicts. This means that requests to create multiple
         recipes with the same name and version are rejected since they
         could potentially have conflicting assignments.
         
        string name = 1 [(.google.api.field_behavior) = REQUIRED];
        Returns:
        This builder for chaining.
      • setNameBytes

        public GuestPolicies.SoftwareRecipe.Builder setNameBytes​(com.google.protobuf.ByteString value)
         Required. Unique identifier for the recipe. Only one recipe with a given name is
         installed on an instance.
        
         Names are also used to identify resources which helps to determine whether
         guest policies have conflicts. This means that requests to create multiple
         recipes with the same name and version are rejected since they
         could potentially have conflicting assignments.
         
        string name = 1 [(.google.api.field_behavior) = REQUIRED];
        Parameters:
        value - The bytes for name to set.
        Returns:
        This builder for chaining.
      • getVersion

        public String getVersion()
         The version of this software recipe. Version can be up to 4 period
         separated numbers (e.g. 12.34.56.78).
         
        string version = 2;
        Specified by:
        getVersion in interface GuestPolicies.SoftwareRecipeOrBuilder
        Returns:
        The version.
      • getVersionBytes

        public com.google.protobuf.ByteString getVersionBytes()
         The version of this software recipe. Version can be up to 4 period
         separated numbers (e.g. 12.34.56.78).
         
        string version = 2;
        Specified by:
        getVersionBytes in interface GuestPolicies.SoftwareRecipeOrBuilder
        Returns:
        The bytes for version.
      • setVersion

        public GuestPolicies.SoftwareRecipe.Builder setVersion​(String value)
         The version of this software recipe. Version can be up to 4 period
         separated numbers (e.g. 12.34.56.78).
         
        string version = 2;
        Parameters:
        value - The version to set.
        Returns:
        This builder for chaining.
      • clearVersion

        public GuestPolicies.SoftwareRecipe.Builder clearVersion()
         The version of this software recipe. Version can be up to 4 period
         separated numbers (e.g. 12.34.56.78).
         
        string version = 2;
        Returns:
        This builder for chaining.
      • setVersionBytes

        public GuestPolicies.SoftwareRecipe.Builder setVersionBytes​(com.google.protobuf.ByteString value)
         The version of this software recipe. Version can be up to 4 period
         separated numbers (e.g. 12.34.56.78).
         
        string version = 2;
        Parameters:
        value - The bytes for version to set.
        Returns:
        This builder for chaining.
      • getArtifactsCount

        public int getArtifactsCount()
         Resources available to be used in the steps in the recipe.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Artifact artifacts = 3;
        Specified by:
        getArtifactsCount in interface GuestPolicies.SoftwareRecipeOrBuilder
      • clearArtifacts

        public GuestPolicies.SoftwareRecipe.Builder clearArtifacts()
         Resources available to be used in the steps in the recipe.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Artifact artifacts = 3;
      • removeArtifacts

        public GuestPolicies.SoftwareRecipe.Builder removeArtifacts​(int index)
         Resources available to be used in the steps in the recipe.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Artifact artifacts = 3;
      • getArtifactsBuilder

        public GuestPolicies.SoftwareRecipe.Artifact.Builder getArtifactsBuilder​(int index)
         Resources available to be used in the steps in the recipe.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Artifact artifacts = 3;
      • addArtifactsBuilder

        public GuestPolicies.SoftwareRecipe.Artifact.Builder addArtifactsBuilder()
         Resources available to be used in the steps in the recipe.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Artifact artifacts = 3;
      • addArtifactsBuilder

        public GuestPolicies.SoftwareRecipe.Artifact.Builder addArtifactsBuilder​(int index)
         Resources available to be used in the steps in the recipe.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Artifact artifacts = 3;
      • getArtifactsBuilderList

        public List<GuestPolicies.SoftwareRecipe.Artifact.Builder> getArtifactsBuilderList()
         Resources available to be used in the steps in the recipe.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Artifact artifacts = 3;
      • getInstallStepsCount

        public int getInstallStepsCount()
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
        Specified by:
        getInstallStepsCount in interface GuestPolicies.SoftwareRecipeOrBuilder
      • getInstallSteps

        public GuestPolicies.SoftwareRecipe.Step getInstallSteps​(int index)
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
        Specified by:
        getInstallSteps in interface GuestPolicies.SoftwareRecipeOrBuilder
      • setInstallSteps

        public GuestPolicies.SoftwareRecipe.Builder setInstallSteps​(int index,
                                                                    GuestPolicies.SoftwareRecipe.Step value)
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • setInstallSteps

        public GuestPolicies.SoftwareRecipe.Builder setInstallSteps​(int index,
                                                                    GuestPolicies.SoftwareRecipe.Step.Builder builderForValue)
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • addInstallSteps

        public GuestPolicies.SoftwareRecipe.Builder addInstallSteps​(GuestPolicies.SoftwareRecipe.Step value)
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • addInstallSteps

        public GuestPolicies.SoftwareRecipe.Builder addInstallSteps​(int index,
                                                                    GuestPolicies.SoftwareRecipe.Step value)
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • addInstallSteps

        public GuestPolicies.SoftwareRecipe.Builder addInstallSteps​(GuestPolicies.SoftwareRecipe.Step.Builder builderForValue)
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • addInstallSteps

        public GuestPolicies.SoftwareRecipe.Builder addInstallSteps​(int index,
                                                                    GuestPolicies.SoftwareRecipe.Step.Builder builderForValue)
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • addAllInstallSteps

        public GuestPolicies.SoftwareRecipe.Builder addAllInstallSteps​(Iterable<? extends GuestPolicies.SoftwareRecipe.Step> values)
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • clearInstallSteps

        public GuestPolicies.SoftwareRecipe.Builder clearInstallSteps()
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • removeInstallSteps

        public GuestPolicies.SoftwareRecipe.Builder removeInstallSteps​(int index)
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • getInstallStepsBuilder

        public GuestPolicies.SoftwareRecipe.Step.Builder getInstallStepsBuilder​(int index)
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • addInstallStepsBuilder

        public GuestPolicies.SoftwareRecipe.Step.Builder addInstallStepsBuilder()
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • addInstallStepsBuilder

        public GuestPolicies.SoftwareRecipe.Step.Builder addInstallStepsBuilder​(int index)
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • getInstallStepsBuilderList

        public List<GuestPolicies.SoftwareRecipe.Step.Builder> getInstallStepsBuilderList()
         Actions to be taken for installing this recipe. On failure it stops
         executing steps and does not attempt another installation. Any steps taken
         (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step install_steps = 4;
      • getUpdateStepsList

        public List<GuestPolicies.SoftwareRecipe.Step> getUpdateStepsList()
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
        Specified by:
        getUpdateStepsList in interface GuestPolicies.SoftwareRecipeOrBuilder
      • getUpdateStepsCount

        public int getUpdateStepsCount()
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
        Specified by:
        getUpdateStepsCount in interface GuestPolicies.SoftwareRecipeOrBuilder
      • getUpdateSteps

        public GuestPolicies.SoftwareRecipe.Step getUpdateSteps​(int index)
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
        Specified by:
        getUpdateSteps in interface GuestPolicies.SoftwareRecipeOrBuilder
      • setUpdateSteps

        public GuestPolicies.SoftwareRecipe.Builder setUpdateSteps​(int index,
                                                                   GuestPolicies.SoftwareRecipe.Step value)
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • setUpdateSteps

        public GuestPolicies.SoftwareRecipe.Builder setUpdateSteps​(int index,
                                                                   GuestPolicies.SoftwareRecipe.Step.Builder builderForValue)
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • addUpdateSteps

        public GuestPolicies.SoftwareRecipe.Builder addUpdateSteps​(GuestPolicies.SoftwareRecipe.Step value)
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • addUpdateSteps

        public GuestPolicies.SoftwareRecipe.Builder addUpdateSteps​(int index,
                                                                   GuestPolicies.SoftwareRecipe.Step value)
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • addUpdateSteps

        public GuestPolicies.SoftwareRecipe.Builder addUpdateSteps​(GuestPolicies.SoftwareRecipe.Step.Builder builderForValue)
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • addUpdateSteps

        public GuestPolicies.SoftwareRecipe.Builder addUpdateSteps​(int index,
                                                                   GuestPolicies.SoftwareRecipe.Step.Builder builderForValue)
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • addAllUpdateSteps

        public GuestPolicies.SoftwareRecipe.Builder addAllUpdateSteps​(Iterable<? extends GuestPolicies.SoftwareRecipe.Step> values)
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • clearUpdateSteps

        public GuestPolicies.SoftwareRecipe.Builder clearUpdateSteps()
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • removeUpdateSteps

        public GuestPolicies.SoftwareRecipe.Builder removeUpdateSteps​(int index)
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • getUpdateStepsBuilder

        public GuestPolicies.SoftwareRecipe.Step.Builder getUpdateStepsBuilder​(int index)
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • addUpdateStepsBuilder

        public GuestPolicies.SoftwareRecipe.Step.Builder addUpdateStepsBuilder()
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • addUpdateStepsBuilder

        public GuestPolicies.SoftwareRecipe.Step.Builder addUpdateStepsBuilder​(int index)
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • getUpdateStepsBuilderList

        public List<GuestPolicies.SoftwareRecipe.Step.Builder> getUpdateStepsBuilderList()
         Actions to be taken for updating this recipe. On failure it stops
         executing steps and  does not attempt another update for this recipe. Any
         steps taken (including partially completed steps) are not rolled back.
         
        repeated .google.cloud.osconfig.v1beta.SoftwareRecipe.Step update_steps = 5;
      • getDesiredStateValue

        public int getDesiredStateValue()
         Default is INSTALLED. The desired state the agent should maintain for this
         recipe.
        
         INSTALLED: The software recipe is installed on the instance but
                    won't be updated to new versions.
         UPDATED: The software recipe is installed on the instance. The recipe is
                  updated to a higher version, if a higher version of the recipe is
                  assigned to this instance.
         REMOVE: Remove is unsupported for software recipes and attempts to
                 create or update a recipe to the REMOVE state is rejected.
         
        .google.cloud.osconfig.v1beta.DesiredState desired_state = 6;
        Specified by:
        getDesiredStateValue in interface GuestPolicies.SoftwareRecipeOrBuilder
        Returns:
        The enum numeric value on the wire for desiredState.
      • setDesiredStateValue

        public GuestPolicies.SoftwareRecipe.Builder setDesiredStateValue​(int value)
         Default is INSTALLED. The desired state the agent should maintain for this
         recipe.
        
         INSTALLED: The software recipe is installed on the instance but
                    won't be updated to new versions.
         UPDATED: The software recipe is installed on the instance. The recipe is
                  updated to a higher version, if a higher version of the recipe is
                  assigned to this instance.
         REMOVE: Remove is unsupported for software recipes and attempts to
                 create or update a recipe to the REMOVE state is rejected.
         
        .google.cloud.osconfig.v1beta.DesiredState desired_state = 6;
        Parameters:
        value - The enum numeric value on the wire for desiredState to set.
        Returns:
        This builder for chaining.
      • getDesiredState

        public GuestPolicies.DesiredState getDesiredState()
         Default is INSTALLED. The desired state the agent should maintain for this
         recipe.
        
         INSTALLED: The software recipe is installed on the instance but
                    won't be updated to new versions.
         UPDATED: The software recipe is installed on the instance. The recipe is
                  updated to a higher version, if a higher version of the recipe is
                  assigned to this instance.
         REMOVE: Remove is unsupported for software recipes and attempts to
                 create or update a recipe to the REMOVE state is rejected.
         
        .google.cloud.osconfig.v1beta.DesiredState desired_state = 6;
        Specified by:
        getDesiredState in interface GuestPolicies.SoftwareRecipeOrBuilder
        Returns:
        The desiredState.
      • setDesiredState

        public GuestPolicies.SoftwareRecipe.Builder setDesiredState​(GuestPolicies.DesiredState value)
         Default is INSTALLED. The desired state the agent should maintain for this
         recipe.
        
         INSTALLED: The software recipe is installed on the instance but
                    won't be updated to new versions.
         UPDATED: The software recipe is installed on the instance. The recipe is
                  updated to a higher version, if a higher version of the recipe is
                  assigned to this instance.
         REMOVE: Remove is unsupported for software recipes and attempts to
                 create or update a recipe to the REMOVE state is rejected.
         
        .google.cloud.osconfig.v1beta.DesiredState desired_state = 6;
        Parameters:
        value - The desiredState to set.
        Returns:
        This builder for chaining.
      • clearDesiredState

        public GuestPolicies.SoftwareRecipe.Builder clearDesiredState()
         Default is INSTALLED. The desired state the agent should maintain for this
         recipe.
        
         INSTALLED: The software recipe is installed on the instance but
                    won't be updated to new versions.
         UPDATED: The software recipe is installed on the instance. The recipe is
                  updated to a higher version, if a higher version of the recipe is
                  assigned to this instance.
         REMOVE: Remove is unsupported for software recipes and attempts to
                 create or update a recipe to the REMOVE state is rejected.
         
        .google.cloud.osconfig.v1beta.DesiredState desired_state = 6;
        Returns:
        This builder for chaining.