Class ProtectConfig.Builder (2.20.0) 
  
  
  
   
  
    
  
  
    
    
    
    
  Version 2.20.0keyboard_arrow_down  
  
 
    
    
    
    
      
  
  
  
    
public   static   final   class  ProtectConfig . Builder   extends   GeneratedMessageV3 . Builder<ProtectConfig . Builder >  implements   ProtectConfigOrBuilder  
   ProtectConfig defines the flags needed to enable/disable features for the
 Protect API.
 Protobuf type google.container.v1beta1.ProtectConfig
    Inherited Members 
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
      com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder() 
    
    
    
    
    
    
    
    
    
    
    
    
      com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString) 
    
    
      com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int) 
    
    
    
    
    
      com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int) 
    
    
    
    
      com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder) 
    
    
    
    
    
    
    
    
    
    
    
    
   
  Static Methods
   
  getDescriptor() 
  
    
public   static   final   Descriptors . Descriptor   getDescriptor ()  
  
  Methods
   
  addRepeatedField(Descriptors.FieldDescriptor field, Object value) 
  
    
public   ProtectConfig . Builder   addRepeatedField ( Descriptors . FieldDescriptor   field ,   Object   value )  
  
  
  Overrides 
  
  build() 
  
    
public   ProtectConfig   build ()  
  
  buildPartial() 
  
    
public   ProtectConfig   buildPartial ()  
  
  clear() 
  
    
public   ProtectConfig . Builder   clear ()  
  
  Overrides 
  
  clearField(Descriptors.FieldDescriptor field) 
  
    
public   ProtectConfig . Builder   clearField ( Descriptors . FieldDescriptor   field )  
  
  
  Overrides 
  
  clearOneof(Descriptors.OneofDescriptor oneof) 
  
    
public   ProtectConfig . Builder   clearOneof ( Descriptors . OneofDescriptor   oneof )  
  
  
  Overrides 
  
  clearWorkloadConfig() 
  
    
public   ProtectConfig . Builder   clearWorkloadConfig ()  
   WorkloadConfig defines which actions are enabled for a cluster's workload
 configurations.
 optional .google.container.v1beta1.WorkloadConfig workload_config = 1;
clearWorkloadVulnerabilityMode() 
  
    
public   ProtectConfig . Builder   clearWorkloadVulnerabilityMode ()  
   Sets which mode to use for Protect workload vulnerability scanning feature.
 
 optional .google.container.v1beta1.ProtectConfig.WorkloadVulnerabilityMode workload_vulnerability_mode = 2;
 
clone() 
  
    
public   ProtectConfig . Builder   clone ()  
  
  Overrides 
  
  getDefaultInstanceForType() 
  
    
public   ProtectConfig   getDefaultInstanceForType ()  
  
  getDescriptorForType() 
  
    
public   Descriptors . Descriptor   getDescriptorForType ()  
  
  Overrides 
  
  getWorkloadConfig() 
  
    
public   WorkloadConfig   getWorkloadConfig ()  
   WorkloadConfig defines which actions are enabled for a cluster's workload
 configurations.
 optional .google.container.v1beta1.WorkloadConfig workload_config = 1;
getWorkloadConfigBuilder() 
  
    
public   WorkloadConfig . Builder   getWorkloadConfigBuilder ()  
   WorkloadConfig defines which actions are enabled for a cluster's workload
 configurations.
 optional .google.container.v1beta1.WorkloadConfig workload_config = 1;
getWorkloadConfigOrBuilder() 
  
    
public   WorkloadConfigOrBuilder   getWorkloadConfigOrBuilder ()  
   WorkloadConfig defines which actions are enabled for a cluster's workload
 configurations.
 optional .google.container.v1beta1.WorkloadConfig workload_config = 1;
getWorkloadVulnerabilityMode() 
  
    
public   ProtectConfig . WorkloadVulnerabilityMode   getWorkloadVulnerabilityMode ()  
   Sets which mode to use for Protect workload vulnerability scanning feature.
 
 optional .google.container.v1beta1.ProtectConfig.WorkloadVulnerabilityMode workload_vulnerability_mode = 2;
 
getWorkloadVulnerabilityModeValue() 
  
    
public   int   getWorkloadVulnerabilityModeValue ()  
   Sets which mode to use for Protect workload vulnerability scanning feature.
 
 optional .google.container.v1beta1.ProtectConfig.WorkloadVulnerabilityMode workload_vulnerability_mode = 2;
 
    
      
        Returns  
      
        Type Description  
      
        int The enum numeric value on the wire for workloadVulnerabilityMode.
 
     
  
  hasWorkloadConfig() 
  
    
public   boolean   hasWorkloadConfig ()  
   WorkloadConfig defines which actions are enabled for a cluster's workload
 configurations.
 optional .google.container.v1beta1.WorkloadConfig workload_config = 1;
    
      
        Returns  
      
        Type Description  
      
        boolean Whether the workloadConfig field is set.
 
     
  
  hasWorkloadVulnerabilityMode() 
  
    
public   boolean   hasWorkloadVulnerabilityMode ()  
   Sets which mode to use for Protect workload vulnerability scanning feature.
 
 optional .google.container.v1beta1.ProtectConfig.WorkloadVulnerabilityMode workload_vulnerability_mode = 2;
 
    
      
        Returns  
      
        Type Description  
      
        boolean Whether the workloadVulnerabilityMode field is set.
 
     
  
  internalGetFieldAccessorTable() 
  
    
protected   GeneratedMessageV3 . FieldAccessorTable   internalGetFieldAccessorTable ()  
  
  Overrides 
  
  isInitialized() 
  
    
public   final   boolean   isInitialized ()  
  
  Overrides 
  
  mergeFrom(ProtectConfig other) 
  
    
public   ProtectConfig . Builder   mergeFrom ( ProtectConfig   other )  
  
  
  
    
public   ProtectConfig . Builder   mergeFrom ( CodedInputStream   input ,   ExtensionRegistryLite   extensionRegistry )  
  
  
  Overrides 
  
  
  mergeFrom(Message other) 
  
    
public   ProtectConfig . Builder   mergeFrom ( Message   other )  
  
    
      
        Parameter  
      
        Name Description  
      
        otherMessage  
     
  
  
  Overrides 
  
  mergeUnknownFields(UnknownFieldSet unknownFields) 
  
    
public   final   ProtectConfig . Builder   mergeUnknownFields ( UnknownFieldSet   unknownFields )  
  
  
  Overrides 
  
  mergeWorkloadConfig(WorkloadConfig value) 
  
    
public   ProtectConfig . Builder   mergeWorkloadConfig ( WorkloadConfig   value )  
   WorkloadConfig defines which actions are enabled for a cluster's workload
 configurations.
 optional .google.container.v1beta1.WorkloadConfig workload_config = 1;
setField(Descriptors.FieldDescriptor field, Object value) 
  
    
public   ProtectConfig . Builder   setField ( Descriptors . FieldDescriptor   field ,   Object   value )  
  
  
  Overrides 
  
  setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value) 
  
    
public   ProtectConfig . Builder   setRepeatedField ( Descriptors . FieldDescriptor   field ,   int   index ,   Object   value )  
  
  
  Overrides 
  
  setUnknownFields(UnknownFieldSet unknownFields) 
  
    
public   final   ProtectConfig . Builder   setUnknownFields ( UnknownFieldSet   unknownFields )  
  
  
  Overrides 
  
  setWorkloadConfig(WorkloadConfig value) 
  
    
public   ProtectConfig . Builder   setWorkloadConfig ( WorkloadConfig   value )  
   WorkloadConfig defines which actions are enabled for a cluster's workload
 configurations.
 optional .google.container.v1beta1.WorkloadConfig workload_config = 1;
setWorkloadConfig(WorkloadConfig.Builder builderForValue) 
  
    
public   ProtectConfig . Builder   setWorkloadConfig ( WorkloadConfig . Builder   builderForValue )  
   WorkloadConfig defines which actions are enabled for a cluster's workload
 configurations.
 optional .google.container.v1beta1.WorkloadConfig workload_config = 1;
setWorkloadVulnerabilityMode(ProtectConfig.WorkloadVulnerabilityMode value) 
  
    
public   ProtectConfig . Builder   setWorkloadVulnerabilityMode ( ProtectConfig . WorkloadVulnerabilityMode   value )  
   Sets which mode to use for Protect workload vulnerability scanning feature.
 
 optional .google.container.v1beta1.ProtectConfig.WorkloadVulnerabilityMode workload_vulnerability_mode = 2;
 
setWorkloadVulnerabilityModeValue(int value) 
  
    
public   ProtectConfig . Builder   setWorkloadVulnerabilityModeValue ( int   value )  
   Sets which mode to use for Protect workload vulnerability scanning feature.
 
 optional .google.container.v1beta1.ProtectConfig.WorkloadVulnerabilityMode workload_vulnerability_mode = 2;
 
    
      
        Parameter  
      
        Name Description  
      
        valueint The enum numeric value on the wire for workloadVulnerabilityMode to set.
 
     
  
  
 
     
    
  
  
  
     
  
    
    
      
       
    
    
  
  
 
  Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
  Last updated 2025-10-28 UTC.
 
 
  
  
  
    
      [[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-10-28 UTC."],[],[]]