All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.google.cloud.assuredworkloads.v1.Workload Maven / Gradle / Ivy

/*
 * Copyright 2024 Google LLC
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     https://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: google/cloud/assuredworkloads/v1/assuredworkloads.proto

// Protobuf Java Version: 3.25.4
package com.google.cloud.assuredworkloads.v1;

/**
 *
 *
 * 
 * A Workload object for managing highly regulated workloads of cloud
 * customers.
 * 
* * Protobuf type {@code google.cloud.assuredworkloads.v1.Workload} */ public final class Workload extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.assuredworkloads.v1.Workload) WorkloadOrBuilder { private static final long serialVersionUID = 0L; // Use Workload.newBuilder() to construct. private Workload(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private Workload() { name_ = ""; displayName_ = ""; resources_ = java.util.Collections.emptyList(); complianceRegime_ = 0; billingAccount_ = ""; etag_ = ""; provisionedResourcesParent_ = ""; resourceSettings_ = java.util.Collections.emptyList(); kajEnrollmentState_ = 0; compliantButDisallowedServices_ = com.google.protobuf.LazyStringArrayList.emptyList(); partner_ = 0; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new Workload(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_descriptor; } @SuppressWarnings({"rawtypes"}) @java.lang.Override protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( int number) { switch (number) { case 10: return internalGetLabels(); default: throw new RuntimeException("Invalid map field number: " + number); } } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.assuredworkloads.v1.Workload.class, com.google.cloud.assuredworkloads.v1.Workload.Builder.class); } /** * * *
   * Supported Compliance Regimes.
   * 
* * Protobuf enum {@code google.cloud.assuredworkloads.v1.Workload.ComplianceRegime} */ public enum ComplianceRegime implements com.google.protobuf.ProtocolMessageEnum { /** * * *
     * Unknown compliance regime.
     * 
* * COMPLIANCE_REGIME_UNSPECIFIED = 0; */ COMPLIANCE_REGIME_UNSPECIFIED(0), /** * * *
     * Information protection as per DoD IL4 requirements.
     * 
* * IL4 = 1; */ IL4(1), /** * * *
     * Criminal Justice Information Services (CJIS) Security policies.
     * 
* * CJIS = 2; */ CJIS(2), /** * * *
     * FedRAMP High data protection controls
     * 
* * FEDRAMP_HIGH = 3; */ FEDRAMP_HIGH(3), /** * * *
     * FedRAMP Moderate data protection controls
     * 
* * FEDRAMP_MODERATE = 4; */ FEDRAMP_MODERATE(4), /** * * *
     * Assured Workloads For US Regions data protection controls
     * 
* * US_REGIONAL_ACCESS = 5; */ US_REGIONAL_ACCESS(5), /** * * *
     * Health Insurance Portability and Accountability Act controls
     * 
* * HIPAA = 6; */ HIPAA(6), /** * * *
     * Health Information Trust Alliance controls
     * 
* * HITRUST = 7; */ HITRUST(7), /** * * *
     * Assured Workloads For EU Regions and Support controls
     * 
* * EU_REGIONS_AND_SUPPORT = 8; */ EU_REGIONS_AND_SUPPORT(8), /** * * *
     * Assured Workloads For Canada Regions and Support controls
     * 
* * CA_REGIONS_AND_SUPPORT = 9; */ CA_REGIONS_AND_SUPPORT(9), /** * * *
     * International Traffic in Arms Regulations
     * 
* * ITAR = 10; */ ITAR(10), /** * * *
     * Assured Workloads for Australia Regions and Support controls
     * Available for public preview consumption.
     * Don't create production workloads.
     * 
* * AU_REGIONS_AND_US_SUPPORT = 11; */ AU_REGIONS_AND_US_SUPPORT(11), /** * * *
     * Assured Workloads for Partners
     * 
* * ASSURED_WORKLOADS_FOR_PARTNERS = 12; */ ASSURED_WORKLOADS_FOR_PARTNERS(12), UNRECOGNIZED(-1), ; /** * * *
     * Unknown compliance regime.
     * 
* * COMPLIANCE_REGIME_UNSPECIFIED = 0; */ public static final int COMPLIANCE_REGIME_UNSPECIFIED_VALUE = 0; /** * * *
     * Information protection as per DoD IL4 requirements.
     * 
* * IL4 = 1; */ public static final int IL4_VALUE = 1; /** * * *
     * Criminal Justice Information Services (CJIS) Security policies.
     * 
* * CJIS = 2; */ public static final int CJIS_VALUE = 2; /** * * *
     * FedRAMP High data protection controls
     * 
* * FEDRAMP_HIGH = 3; */ public static final int FEDRAMP_HIGH_VALUE = 3; /** * * *
     * FedRAMP Moderate data protection controls
     * 
* * FEDRAMP_MODERATE = 4; */ public static final int FEDRAMP_MODERATE_VALUE = 4; /** * * *
     * Assured Workloads For US Regions data protection controls
     * 
* * US_REGIONAL_ACCESS = 5; */ public static final int US_REGIONAL_ACCESS_VALUE = 5; /** * * *
     * Health Insurance Portability and Accountability Act controls
     * 
* * HIPAA = 6; */ public static final int HIPAA_VALUE = 6; /** * * *
     * Health Information Trust Alliance controls
     * 
* * HITRUST = 7; */ public static final int HITRUST_VALUE = 7; /** * * *
     * Assured Workloads For EU Regions and Support controls
     * 
* * EU_REGIONS_AND_SUPPORT = 8; */ public static final int EU_REGIONS_AND_SUPPORT_VALUE = 8; /** * * *
     * Assured Workloads For Canada Regions and Support controls
     * 
* * CA_REGIONS_AND_SUPPORT = 9; */ public static final int CA_REGIONS_AND_SUPPORT_VALUE = 9; /** * * *
     * International Traffic in Arms Regulations
     * 
* * ITAR = 10; */ public static final int ITAR_VALUE = 10; /** * * *
     * Assured Workloads for Australia Regions and Support controls
     * Available for public preview consumption.
     * Don't create production workloads.
     * 
* * AU_REGIONS_AND_US_SUPPORT = 11; */ public static final int AU_REGIONS_AND_US_SUPPORT_VALUE = 11; /** * * *
     * Assured Workloads for Partners
     * 
* * ASSURED_WORKLOADS_FOR_PARTNERS = 12; */ public static final int ASSURED_WORKLOADS_FOR_PARTNERS_VALUE = 12; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static ComplianceRegime valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static ComplianceRegime forNumber(int value) { switch (value) { case 0: return COMPLIANCE_REGIME_UNSPECIFIED; case 1: return IL4; case 2: return CJIS; case 3: return FEDRAMP_HIGH; case 4: return FEDRAMP_MODERATE; case 5: return US_REGIONAL_ACCESS; case 6: return HIPAA; case 7: return HITRUST; case 8: return EU_REGIONS_AND_SUPPORT; case 9: return CA_REGIONS_AND_SUPPORT; case 10: return ITAR; case 11: return AU_REGIONS_AND_US_SUPPORT; case 12: return ASSURED_WORKLOADS_FOR_PARTNERS; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public ComplianceRegime findValueByNumber(int number) { return ComplianceRegime.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.Workload.getDescriptor().getEnumTypes().get(0); } private static final ComplianceRegime[] VALUES = values(); public static ComplianceRegime valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private ComplianceRegime(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.assuredworkloads.v1.Workload.ComplianceRegime) } /** * * *
   * Key Access Justifications(KAJ) Enrollment State.
   * 
* * Protobuf enum {@code google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState} */ public enum KajEnrollmentState implements com.google.protobuf.ProtocolMessageEnum { /** * * *
     * Default State for KAJ Enrollment.
     * 
* * KAJ_ENROLLMENT_STATE_UNSPECIFIED = 0; */ KAJ_ENROLLMENT_STATE_UNSPECIFIED(0), /** * * *
     * Pending State for KAJ Enrollment.
     * 
* * KAJ_ENROLLMENT_STATE_PENDING = 1; */ KAJ_ENROLLMENT_STATE_PENDING(1), /** * * *
     * Complete State for KAJ Enrollment.
     * 
* * KAJ_ENROLLMENT_STATE_COMPLETE = 2; */ KAJ_ENROLLMENT_STATE_COMPLETE(2), UNRECOGNIZED(-1), ; /** * * *
     * Default State for KAJ Enrollment.
     * 
* * KAJ_ENROLLMENT_STATE_UNSPECIFIED = 0; */ public static final int KAJ_ENROLLMENT_STATE_UNSPECIFIED_VALUE = 0; /** * * *
     * Pending State for KAJ Enrollment.
     * 
* * KAJ_ENROLLMENT_STATE_PENDING = 1; */ public static final int KAJ_ENROLLMENT_STATE_PENDING_VALUE = 1; /** * * *
     * Complete State for KAJ Enrollment.
     * 
* * KAJ_ENROLLMENT_STATE_COMPLETE = 2; */ public static final int KAJ_ENROLLMENT_STATE_COMPLETE_VALUE = 2; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static KajEnrollmentState valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static KajEnrollmentState forNumber(int value) { switch (value) { case 0: return KAJ_ENROLLMENT_STATE_UNSPECIFIED; case 1: return KAJ_ENROLLMENT_STATE_PENDING; case 2: return KAJ_ENROLLMENT_STATE_COMPLETE; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public KajEnrollmentState findValueByNumber(int number) { return KajEnrollmentState.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.Workload.getDescriptor().getEnumTypes().get(1); } private static final KajEnrollmentState[] VALUES = values(); public static KajEnrollmentState valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private KajEnrollmentState(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState) } /** * * *
   * Supported Assured Workloads Partners.
   * 
* * Protobuf enum {@code google.cloud.assuredworkloads.v1.Workload.Partner} */ public enum Partner implements com.google.protobuf.ProtocolMessageEnum { /** * * *
     * Unknown partner regime/controls.
     * 
* * PARTNER_UNSPECIFIED = 0; */ PARTNER_UNSPECIFIED(0), /** * * *
     * S3NS regime/controls.
     * 
* * LOCAL_CONTROLS_BY_S3NS = 1; */ LOCAL_CONTROLS_BY_S3NS(1), UNRECOGNIZED(-1), ; /** * * *
     * Unknown partner regime/controls.
     * 
* * PARTNER_UNSPECIFIED = 0; */ public static final int PARTNER_UNSPECIFIED_VALUE = 0; /** * * *
     * S3NS regime/controls.
     * 
* * LOCAL_CONTROLS_BY_S3NS = 1; */ public static final int LOCAL_CONTROLS_BY_S3NS_VALUE = 1; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static Partner valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static Partner forNumber(int value) { switch (value) { case 0: return PARTNER_UNSPECIFIED; case 1: return LOCAL_CONTROLS_BY_S3NS; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public Partner findValueByNumber(int number) { return Partner.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.Workload.getDescriptor().getEnumTypes().get(2); } private static final Partner[] VALUES = values(); public static Partner valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private Partner(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.assuredworkloads.v1.Workload.Partner) } public interface ResourceInfoOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.assuredworkloads.v1.Workload.ResourceInfo) com.google.protobuf.MessageOrBuilder { /** * * *
     * Resource identifier.
     * For a project this represents project_number.
     * 
* * int64 resource_id = 1; * * @return The resourceId. */ long getResourceId(); /** * * *
     * Indicates the type of resource.
     * 
* * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return The enum numeric value on the wire for resourceType. */ int getResourceTypeValue(); /** * * *
     * Indicates the type of resource.
     * 
* * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return The resourceType. */ com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType getResourceType(); } /** * * *
   * Represent the resources that are children of this Workload.
   * 
* * Protobuf type {@code google.cloud.assuredworkloads.v1.Workload.ResourceInfo} */ public static final class ResourceInfo extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.assuredworkloads.v1.Workload.ResourceInfo) ResourceInfoOrBuilder { private static final long serialVersionUID = 0L; // Use ResourceInfo.newBuilder() to construct. private ResourceInfo(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private ResourceInfo() { resourceType_ = 0; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new ResourceInfo(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_ResourceInfo_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_ResourceInfo_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.class, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.Builder.class); } /** * * *
     * The type of resource.
     * 
* * Protobuf enum {@code google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType} */ public enum ResourceType implements com.google.protobuf.ProtocolMessageEnum { /** * * *
       * Unknown resource type.
       * 
* * RESOURCE_TYPE_UNSPECIFIED = 0; */ RESOURCE_TYPE_UNSPECIFIED(0), /** * * *
       * Consumer project.
       * AssuredWorkloads Projects are no longer supported. This field will be
       * ignored only in CreateWorkload requests. ListWorkloads and GetWorkload
       * will continue to provide projects information.
       * Use CONSUMER_FOLDER instead.
       * 
* * CONSUMER_PROJECT = 1 [deprecated = true]; */ @java.lang.Deprecated CONSUMER_PROJECT(1), /** * * *
       * Consumer Folder.
       * 
* * CONSUMER_FOLDER = 4; */ CONSUMER_FOLDER(4), /** * * *
       * Consumer project containing encryption keys.
       * 
* * ENCRYPTION_KEYS_PROJECT = 2; */ ENCRYPTION_KEYS_PROJECT(2), /** * * *
       * Keyring resource that hosts encryption keys.
       * 
* * KEYRING = 3; */ KEYRING(3), UNRECOGNIZED(-1), ; /** * * *
       * Unknown resource type.
       * 
* * RESOURCE_TYPE_UNSPECIFIED = 0; */ public static final int RESOURCE_TYPE_UNSPECIFIED_VALUE = 0; /** * * *
       * Consumer project.
       * AssuredWorkloads Projects are no longer supported. This field will be
       * ignored only in CreateWorkload requests. ListWorkloads and GetWorkload
       * will continue to provide projects information.
       * Use CONSUMER_FOLDER instead.
       * 
* * CONSUMER_PROJECT = 1 [deprecated = true]; */ @java.lang.Deprecated public static final int CONSUMER_PROJECT_VALUE = 1; /** * * *
       * Consumer Folder.
       * 
* * CONSUMER_FOLDER = 4; */ public static final int CONSUMER_FOLDER_VALUE = 4; /** * * *
       * Consumer project containing encryption keys.
       * 
* * ENCRYPTION_KEYS_PROJECT = 2; */ public static final int ENCRYPTION_KEYS_PROJECT_VALUE = 2; /** * * *
       * Keyring resource that hosts encryption keys.
       * 
* * KEYRING = 3; */ public static final int KEYRING_VALUE = 3; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static ResourceType valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static ResourceType forNumber(int value) { switch (value) { case 0: return RESOURCE_TYPE_UNSPECIFIED; case 1: return CONSUMER_PROJECT; case 4: return CONSUMER_FOLDER; case 2: return ENCRYPTION_KEYS_PROJECT; case 3: return KEYRING; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public ResourceType findValueByNumber(int number) { return ResourceType.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.getDescriptor() .getEnumTypes() .get(0); } private static final ResourceType[] VALUES = values(); public static ResourceType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private ResourceType(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType) } public static final int RESOURCE_ID_FIELD_NUMBER = 1; private long resourceId_ = 0L; /** * * *
     * Resource identifier.
     * For a project this represents project_number.
     * 
* * int64 resource_id = 1; * * @return The resourceId. */ @java.lang.Override public long getResourceId() { return resourceId_; } public static final int RESOURCE_TYPE_FIELD_NUMBER = 2; private int resourceType_ = 0; /** * * *
     * Indicates the type of resource.
     * 
* * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return The enum numeric value on the wire for resourceType. */ @java.lang.Override public int getResourceTypeValue() { return resourceType_; } /** * * *
     * Indicates the type of resource.
     * 
* * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return The resourceType. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType getResourceType() { com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType result = com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType.forNumber( resourceType_); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType.UNRECOGNIZED : result; } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (resourceId_ != 0L) { output.writeInt64(1, resourceId_); } if (resourceType_ != com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType .RESOURCE_TYPE_UNSPECIFIED .getNumber()) { output.writeEnum(2, resourceType_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (resourceId_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, resourceId_); } if (resourceType_ != com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType .RESOURCE_TYPE_UNSPECIFIED .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, resourceType_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo)) { return super.equals(obj); } com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo other = (com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo) obj; if (getResourceId() != other.getResourceId()) return false; if (resourceType_ != other.resourceType_) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + RESOURCE_ID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getResourceId()); hash = (37 * hash) + RESOURCE_TYPE_FIELD_NUMBER; hash = (53 * hash) + resourceType_; hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder( com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
     * Represent the resources that are children of this Workload.
     * 
* * Protobuf type {@code google.cloud.assuredworkloads.v1.Workload.ResourceInfo} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.assuredworkloads.v1.Workload.ResourceInfo) com.google.cloud.assuredworkloads.v1.Workload.ResourceInfoOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_ResourceInfo_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_ResourceInfo_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.class, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.Builder.class); } // Construct using com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.newBuilder() private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; resourceId_ = 0L; resourceType_ = 0; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_ResourceInfo_descriptor; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo getDefaultInstanceForType() { return com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.getDefaultInstance(); } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo build() { com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo buildPartial() { com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo result = new com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartial0( com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.resourceId_ = resourceId_; } if (((from_bitField0_ & 0x00000002) != 0)) { result.resourceType_ = resourceType_; } } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo) { return mergeFrom((com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo other) { if (other == com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.getDefaultInstance()) return this; if (other.getResourceId() != 0L) { setResourceId(other.getResourceId()); } if (other.resourceType_ != 0) { setResourceTypeValue(other.getResourceTypeValue()); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 8: { resourceId_ = input.readInt64(); bitField0_ |= 0x00000001; break; } // case 8 case 16: { resourceType_ = input.readEnum(); bitField0_ |= 0x00000002; break; } // case 16 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private long resourceId_; /** * * *
       * Resource identifier.
       * For a project this represents project_number.
       * 
* * int64 resource_id = 1; * * @return The resourceId. */ @java.lang.Override public long getResourceId() { return resourceId_; } /** * * *
       * Resource identifier.
       * For a project this represents project_number.
       * 
* * int64 resource_id = 1; * * @param value The resourceId to set. * @return This builder for chaining. */ public Builder setResourceId(long value) { resourceId_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
       * Resource identifier.
       * For a project this represents project_number.
       * 
* * int64 resource_id = 1; * * @return This builder for chaining. */ public Builder clearResourceId() { bitField0_ = (bitField0_ & ~0x00000001); resourceId_ = 0L; onChanged(); return this; } private int resourceType_ = 0; /** * * *
       * Indicates the type of resource.
       * 
* * * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return The enum numeric value on the wire for resourceType. */ @java.lang.Override public int getResourceTypeValue() { return resourceType_; } /** * * *
       * Indicates the type of resource.
       * 
* * * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @param value The enum numeric value on the wire for resourceType to set. * @return This builder for chaining. */ public Builder setResourceTypeValue(int value) { resourceType_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** * * *
       * Indicates the type of resource.
       * 
* * * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return The resourceType. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType getResourceType() { com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType result = com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType.forNumber( resourceType_); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType.UNRECOGNIZED : result; } /** * * *
       * Indicates the type of resource.
       * 
* * * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @param value The resourceType to set. * @return This builder for chaining. */ public Builder setResourceType( com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000002; resourceType_ = value.getNumber(); onChanged(); return this; } /** * * *
       * Indicates the type of resource.
       * 
* * * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return This builder for chaining. */ public Builder clearResourceType() { bitField0_ = (bitField0_ & ~0x00000002); resourceType_ = 0; onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.assuredworkloads.v1.Workload.ResourceInfo) } // @@protoc_insertion_point(class_scope:google.cloud.assuredworkloads.v1.Workload.ResourceInfo) private static final com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo(); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public ResourceInfo parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException() .setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } @java.lang.Deprecated public interface KMSSettingsOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.assuredworkloads.v1.Workload.KMSSettings) com.google.protobuf.MessageOrBuilder { /** * * *
     * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
     * new version of the crypto key and mark it as the primary.
     * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return Whether the nextRotationTime field is set. */ boolean hasNextRotationTime(); /** * * *
     * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
     * new version of the crypto key and mark it as the primary.
     * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The nextRotationTime. */ com.google.protobuf.Timestamp getNextRotationTime(); /** * * *
     * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
     * new version of the crypto key and mark it as the primary.
     * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ com.google.protobuf.TimestampOrBuilder getNextRotationTimeOrBuilder(); /** * * *
     * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
     * Management Service automatically rotates a key. Must be at least 24 hours
     * and at most 876,000 hours.
     * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return Whether the rotationPeriod field is set. */ boolean hasRotationPeriod(); /** * * *
     * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
     * Management Service automatically rotates a key. Must be at least 24 hours
     * and at most 876,000 hours.
     * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The rotationPeriod. */ com.google.protobuf.Duration getRotationPeriod(); /** * * *
     * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
     * Management Service automatically rotates a key. Must be at least 24 hours
     * and at most 876,000 hours.
     * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ com.google.protobuf.DurationOrBuilder getRotationPeriodOrBuilder(); } /** * * *
   * Settings specific to the Key Management Service.
   * This message is deprecated.
   * In order to create a Keyring, callers should specify,
   * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
   * 
* * Protobuf type {@code google.cloud.assuredworkloads.v1.Workload.KMSSettings} */ @java.lang.Deprecated public static final class KMSSettings extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.assuredworkloads.v1.Workload.KMSSettings) KMSSettingsOrBuilder { private static final long serialVersionUID = 0L; // Use KMSSettings.newBuilder() to construct. private KMSSettings(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private KMSSettings() {} @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new KMSSettings(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_KMSSettings_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_KMSSettings_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.class, com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.Builder.class); } private int bitField0_; public static final int NEXT_ROTATION_TIME_FIELD_NUMBER = 1; private com.google.protobuf.Timestamp nextRotationTime_; /** * * *
     * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
     * new version of the crypto key and mark it as the primary.
     * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return Whether the nextRotationTime field is set. */ @java.lang.Override public boolean hasNextRotationTime() { return ((bitField0_ & 0x00000001) != 0); } /** * * *
     * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
     * new version of the crypto key and mark it as the primary.
     * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The nextRotationTime. */ @java.lang.Override public com.google.protobuf.Timestamp getNextRotationTime() { return nextRotationTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : nextRotationTime_; } /** * * *
     * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
     * new version of the crypto key and mark it as the primary.
     * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getNextRotationTimeOrBuilder() { return nextRotationTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : nextRotationTime_; } public static final int ROTATION_PERIOD_FIELD_NUMBER = 2; private com.google.protobuf.Duration rotationPeriod_; /** * * *
     * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
     * Management Service automatically rotates a key. Must be at least 24 hours
     * and at most 876,000 hours.
     * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return Whether the rotationPeriod field is set. */ @java.lang.Override public boolean hasRotationPeriod() { return ((bitField0_ & 0x00000002) != 0); } /** * * *
     * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
     * Management Service automatically rotates a key. Must be at least 24 hours
     * and at most 876,000 hours.
     * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The rotationPeriod. */ @java.lang.Override public com.google.protobuf.Duration getRotationPeriod() { return rotationPeriod_ == null ? com.google.protobuf.Duration.getDefaultInstance() : rotationPeriod_; } /** * * *
     * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
     * Management Service automatically rotates a key. Must be at least 24 hours
     * and at most 876,000 hours.
     * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ @java.lang.Override public com.google.protobuf.DurationOrBuilder getRotationPeriodOrBuilder() { return rotationPeriod_ == null ? com.google.protobuf.Duration.getDefaultInstance() : rotationPeriod_; } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (((bitField0_ & 0x00000001) != 0)) { output.writeMessage(1, getNextRotationTime()); } if (((bitField0_ & 0x00000002) != 0)) { output.writeMessage(2, getRotationPeriod()); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getNextRotationTime()); } if (((bitField0_ & 0x00000002) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getRotationPeriod()); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.assuredworkloads.v1.Workload.KMSSettings)) { return super.equals(obj); } com.google.cloud.assuredworkloads.v1.Workload.KMSSettings other = (com.google.cloud.assuredworkloads.v1.Workload.KMSSettings) obj; if (hasNextRotationTime() != other.hasNextRotationTime()) return false; if (hasNextRotationTime()) { if (!getNextRotationTime().equals(other.getNextRotationTime())) return false; } if (hasRotationPeriod() != other.hasRotationPeriod()) return false; if (hasRotationPeriod()) { if (!getRotationPeriod().equals(other.getRotationPeriod())) return false; } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); if (hasNextRotationTime()) { hash = (37 * hash) + NEXT_ROTATION_TIME_FIELD_NUMBER; hash = (53 * hash) + getNextRotationTime().hashCode(); } if (hasRotationPeriod()) { hash = (37 * hash) + ROTATION_PERIOD_FIELD_NUMBER; hash = (53 * hash) + getRotationPeriod().hashCode(); } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder( com.google.cloud.assuredworkloads.v1.Workload.KMSSettings prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
     * Settings specific to the Key Management Service.
     * This message is deprecated.
     * In order to create a Keyring, callers should specify,
     * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
     * 
* * Protobuf type {@code google.cloud.assuredworkloads.v1.Workload.KMSSettings} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.assuredworkloads.v1.Workload.KMSSettings) com.google.cloud.assuredworkloads.v1.Workload.KMSSettingsOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_KMSSettings_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_KMSSettings_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.class, com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.Builder.class); } // Construct using com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { getNextRotationTimeFieldBuilder(); getRotationPeriodFieldBuilder(); } } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; nextRotationTime_ = null; if (nextRotationTimeBuilder_ != null) { nextRotationTimeBuilder_.dispose(); nextRotationTimeBuilder_ = null; } rotationPeriod_ = null; if (rotationPeriodBuilder_ != null) { rotationPeriodBuilder_.dispose(); rotationPeriodBuilder_ = null; } return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_KMSSettings_descriptor; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.KMSSettings getDefaultInstanceForType() { return com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.getDefaultInstance(); } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.KMSSettings build() { com.google.cloud.assuredworkloads.v1.Workload.KMSSettings result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.KMSSettings buildPartial() { com.google.cloud.assuredworkloads.v1.Workload.KMSSettings result = new com.google.cloud.assuredworkloads.v1.Workload.KMSSettings(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartial0(com.google.cloud.assuredworkloads.v1.Workload.KMSSettings result) { int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (((from_bitField0_ & 0x00000001) != 0)) { result.nextRotationTime_ = nextRotationTimeBuilder_ == null ? nextRotationTime_ : nextRotationTimeBuilder_.build(); to_bitField0_ |= 0x00000001; } if (((from_bitField0_ & 0x00000002) != 0)) { result.rotationPeriod_ = rotationPeriodBuilder_ == null ? rotationPeriod_ : rotationPeriodBuilder_.build(); to_bitField0_ |= 0x00000002; } result.bitField0_ |= to_bitField0_; } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.assuredworkloads.v1.Workload.KMSSettings) { return mergeFrom((com.google.cloud.assuredworkloads.v1.Workload.KMSSettings) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.assuredworkloads.v1.Workload.KMSSettings other) { if (other == com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.getDefaultInstance()) return this; if (other.hasNextRotationTime()) { mergeNextRotationTime(other.getNextRotationTime()); } if (other.hasRotationPeriod()) { mergeRotationPeriod(other.getRotationPeriod()); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { input.readMessage( getNextRotationTimeFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000001; break; } // case 10 case 18: { input.readMessage( getRotationPeriodFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000002; break; } // case 18 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private com.google.protobuf.Timestamp nextRotationTime_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> nextRotationTimeBuilder_; /** * * *
       * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
       * new version of the crypto key and mark it as the primary.
       * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return Whether the nextRotationTime field is set. */ public boolean hasNextRotationTime() { return ((bitField0_ & 0x00000001) != 0); } /** * * *
       * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
       * new version of the crypto key and mark it as the primary.
       * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The nextRotationTime. */ public com.google.protobuf.Timestamp getNextRotationTime() { if (nextRotationTimeBuilder_ == null) { return nextRotationTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : nextRotationTime_; } else { return nextRotationTimeBuilder_.getMessage(); } } /** * * *
       * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
       * new version of the crypto key and mark it as the primary.
       * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public Builder setNextRotationTime(com.google.protobuf.Timestamp value) { if (nextRotationTimeBuilder_ == null) { if (value == null) { throw new NullPointerException(); } nextRotationTime_ = value; } else { nextRotationTimeBuilder_.setMessage(value); } bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
       * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
       * new version of the crypto key and mark it as the primary.
       * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public Builder setNextRotationTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (nextRotationTimeBuilder_ == null) { nextRotationTime_ = builderForValue.build(); } else { nextRotationTimeBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
       * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
       * new version of the crypto key and mark it as the primary.
       * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public Builder mergeNextRotationTime(com.google.protobuf.Timestamp value) { if (nextRotationTimeBuilder_ == null) { if (((bitField0_ & 0x00000001) != 0) && nextRotationTime_ != null && nextRotationTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getNextRotationTimeBuilder().mergeFrom(value); } else { nextRotationTime_ = value; } } else { nextRotationTimeBuilder_.mergeFrom(value); } if (nextRotationTime_ != null) { bitField0_ |= 0x00000001; onChanged(); } return this; } /** * * *
       * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
       * new version of the crypto key and mark it as the primary.
       * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public Builder clearNextRotationTime() { bitField0_ = (bitField0_ & ~0x00000001); nextRotationTime_ = null; if (nextRotationTimeBuilder_ != null) { nextRotationTimeBuilder_.dispose(); nextRotationTimeBuilder_ = null; } onChanged(); return this; } /** * * *
       * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
       * new version of the crypto key and mark it as the primary.
       * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public com.google.protobuf.Timestamp.Builder getNextRotationTimeBuilder() { bitField0_ |= 0x00000001; onChanged(); return getNextRotationTimeFieldBuilder().getBuilder(); } /** * * *
       * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
       * new version of the crypto key and mark it as the primary.
       * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public com.google.protobuf.TimestampOrBuilder getNextRotationTimeOrBuilder() { if (nextRotationTimeBuilder_ != null) { return nextRotationTimeBuilder_.getMessageOrBuilder(); } else { return nextRotationTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : nextRotationTime_; } } /** * * *
       * Required. Input only. Immutable. The time at which the Key Management Service will automatically create a
       * new version of the crypto key and mark it as the primary.
       * 
* * * .google.protobuf.Timestamp next_rotation_time = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> getNextRotationTimeFieldBuilder() { if (nextRotationTimeBuilder_ == null) { nextRotationTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( getNextRotationTime(), getParentForChildren(), isClean()); nextRotationTime_ = null; } return nextRotationTimeBuilder_; } private com.google.protobuf.Duration rotationPeriod_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> rotationPeriodBuilder_; /** * * *
       * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
       * Management Service automatically rotates a key. Must be at least 24 hours
       * and at most 876,000 hours.
       * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return Whether the rotationPeriod field is set. */ public boolean hasRotationPeriod() { return ((bitField0_ & 0x00000002) != 0); } /** * * *
       * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
       * Management Service automatically rotates a key. Must be at least 24 hours
       * and at most 876,000 hours.
       * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The rotationPeriod. */ public com.google.protobuf.Duration getRotationPeriod() { if (rotationPeriodBuilder_ == null) { return rotationPeriod_ == null ? com.google.protobuf.Duration.getDefaultInstance() : rotationPeriod_; } else { return rotationPeriodBuilder_.getMessage(); } } /** * * *
       * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
       * Management Service automatically rotates a key. Must be at least 24 hours
       * and at most 876,000 hours.
       * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public Builder setRotationPeriod(com.google.protobuf.Duration value) { if (rotationPeriodBuilder_ == null) { if (value == null) { throw new NullPointerException(); } rotationPeriod_ = value; } else { rotationPeriodBuilder_.setMessage(value); } bitField0_ |= 0x00000002; onChanged(); return this; } /** * * *
       * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
       * Management Service automatically rotates a key. Must be at least 24 hours
       * and at most 876,000 hours.
       * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public Builder setRotationPeriod(com.google.protobuf.Duration.Builder builderForValue) { if (rotationPeriodBuilder_ == null) { rotationPeriod_ = builderForValue.build(); } else { rotationPeriodBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000002; onChanged(); return this; } /** * * *
       * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
       * Management Service automatically rotates a key. Must be at least 24 hours
       * and at most 876,000 hours.
       * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public Builder mergeRotationPeriod(com.google.protobuf.Duration value) { if (rotationPeriodBuilder_ == null) { if (((bitField0_ & 0x00000002) != 0) && rotationPeriod_ != null && rotationPeriod_ != com.google.protobuf.Duration.getDefaultInstance()) { getRotationPeriodBuilder().mergeFrom(value); } else { rotationPeriod_ = value; } } else { rotationPeriodBuilder_.mergeFrom(value); } if (rotationPeriod_ != null) { bitField0_ |= 0x00000002; onChanged(); } return this; } /** * * *
       * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
       * Management Service automatically rotates a key. Must be at least 24 hours
       * and at most 876,000 hours.
       * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public Builder clearRotationPeriod() { bitField0_ = (bitField0_ & ~0x00000002); rotationPeriod_ = null; if (rotationPeriodBuilder_ != null) { rotationPeriodBuilder_.dispose(); rotationPeriodBuilder_ = null; } onChanged(); return this; } /** * * *
       * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
       * Management Service automatically rotates a key. Must be at least 24 hours
       * and at most 876,000 hours.
       * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public com.google.protobuf.Duration.Builder getRotationPeriodBuilder() { bitField0_ |= 0x00000002; onChanged(); return getRotationPeriodFieldBuilder().getBuilder(); } /** * * *
       * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
       * Management Service automatically rotates a key. Must be at least 24 hours
       * and at most 876,000 hours.
       * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public com.google.protobuf.DurationOrBuilder getRotationPeriodOrBuilder() { if (rotationPeriodBuilder_ != null) { return rotationPeriodBuilder_.getMessageOrBuilder(); } else { return rotationPeriod_ == null ? com.google.protobuf.Duration.getDefaultInstance() : rotationPeriod_; } } /** * * *
       * Required. Input only. Immutable. [next_rotation_time] will be advanced by this period when the Key
       * Management Service automatically rotates a key. Must be at least 24 hours
       * and at most 876,000 hours.
       * 
* * * .google.protobuf.Duration rotation_period = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> getRotationPeriodFieldBuilder() { if (rotationPeriodBuilder_ == null) { rotationPeriodBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>( getRotationPeriod(), getParentForChildren(), isClean()); rotationPeriod_ = null; } return rotationPeriodBuilder_; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.assuredworkloads.v1.Workload.KMSSettings) } // @@protoc_insertion_point(class_scope:google.cloud.assuredworkloads.v1.Workload.KMSSettings) private static final com.google.cloud.assuredworkloads.v1.Workload.KMSSettings DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.assuredworkloads.v1.Workload.KMSSettings(); } public static com.google.cloud.assuredworkloads.v1.Workload.KMSSettings getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public KMSSettings parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException() .setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.KMSSettings getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface ResourceSettingsOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.assuredworkloads.v1.Workload.ResourceSettings) com.google.protobuf.MessageOrBuilder { /** * * *
     * Resource identifier.
     * For a project this represents project_id. If the project is already
     * taken, the workload creation will fail.
     * For KeyRing, this represents the keyring_id.
     * For a folder, don't set this value as folder_id is assigned by Google.
     * 
* * string resource_id = 1; * * @return The resourceId. */ java.lang.String getResourceId(); /** * * *
     * Resource identifier.
     * For a project this represents project_id. If the project is already
     * taken, the workload creation will fail.
     * For KeyRing, this represents the keyring_id.
     * For a folder, don't set this value as folder_id is assigned by Google.
     * 
* * string resource_id = 1; * * @return The bytes for resourceId. */ com.google.protobuf.ByteString getResourceIdBytes(); /** * * *
     * Indicates the type of resource. This field should be specified to
     * correspond the id to the right resource type (CONSUMER_FOLDER or
     * ENCRYPTION_KEYS_PROJECT)
     * 
* * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return The enum numeric value on the wire for resourceType. */ int getResourceTypeValue(); /** * * *
     * Indicates the type of resource. This field should be specified to
     * correspond the id to the right resource type (CONSUMER_FOLDER or
     * ENCRYPTION_KEYS_PROJECT)
     * 
* * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return The resourceType. */ com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType getResourceType(); /** * * *
     * User-assigned resource display name.
     * If not empty it will be used to create a resource with the specified
     * name.
     * 
* * string display_name = 3; * * @return The displayName. */ java.lang.String getDisplayName(); /** * * *
     * User-assigned resource display name.
     * If not empty it will be used to create a resource with the specified
     * name.
     * 
* * string display_name = 3; * * @return The bytes for displayName. */ com.google.protobuf.ByteString getDisplayNameBytes(); } /** * * *
   * Represent the custom settings for the resources to be created.
   * 
* * Protobuf type {@code google.cloud.assuredworkloads.v1.Workload.ResourceSettings} */ public static final class ResourceSettings extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.assuredworkloads.v1.Workload.ResourceSettings) ResourceSettingsOrBuilder { private static final long serialVersionUID = 0L; // Use ResourceSettings.newBuilder() to construct. private ResourceSettings(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private ResourceSettings() { resourceId_ = ""; resourceType_ = 0; displayName_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new ResourceSettings(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_ResourceSettings_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_ResourceSettings_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.class, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.Builder.class); } public static final int RESOURCE_ID_FIELD_NUMBER = 1; @SuppressWarnings("serial") private volatile java.lang.Object resourceId_ = ""; /** * * *
     * Resource identifier.
     * For a project this represents project_id. If the project is already
     * taken, the workload creation will fail.
     * For KeyRing, this represents the keyring_id.
     * For a folder, don't set this value as folder_id is assigned by Google.
     * 
* * string resource_id = 1; * * @return The resourceId. */ @java.lang.Override public java.lang.String getResourceId() { java.lang.Object ref = resourceId_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); resourceId_ = s; return s; } } /** * * *
     * Resource identifier.
     * For a project this represents project_id. If the project is already
     * taken, the workload creation will fail.
     * For KeyRing, this represents the keyring_id.
     * For a folder, don't set this value as folder_id is assigned by Google.
     * 
* * string resource_id = 1; * * @return The bytes for resourceId. */ @java.lang.Override public com.google.protobuf.ByteString getResourceIdBytes() { java.lang.Object ref = resourceId_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); resourceId_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int RESOURCE_TYPE_FIELD_NUMBER = 2; private int resourceType_ = 0; /** * * *
     * Indicates the type of resource. This field should be specified to
     * correspond the id to the right resource type (CONSUMER_FOLDER or
     * ENCRYPTION_KEYS_PROJECT)
     * 
* * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return The enum numeric value on the wire for resourceType. */ @java.lang.Override public int getResourceTypeValue() { return resourceType_; } /** * * *
     * Indicates the type of resource. This field should be specified to
     * correspond the id to the right resource type (CONSUMER_FOLDER or
     * ENCRYPTION_KEYS_PROJECT)
     * 
* * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return The resourceType. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType getResourceType() { com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType result = com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType.forNumber( resourceType_); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType.UNRECOGNIZED : result; } public static final int DISPLAY_NAME_FIELD_NUMBER = 3; @SuppressWarnings("serial") private volatile java.lang.Object displayName_ = ""; /** * * *
     * User-assigned resource display name.
     * If not empty it will be used to create a resource with the specified
     * name.
     * 
* * string display_name = 3; * * @return The displayName. */ @java.lang.Override public java.lang.String getDisplayName() { java.lang.Object ref = displayName_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); displayName_ = s; return s; } } /** * * *
     * User-assigned resource display name.
     * If not empty it will be used to create a resource with the specified
     * name.
     * 
* * string display_name = 3; * * @return The bytes for displayName. */ @java.lang.Override public com.google.protobuf.ByteString getDisplayNameBytes() { java.lang.Object ref = displayName_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); displayName_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resourceId_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resourceId_); } if (resourceType_ != com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType .RESOURCE_TYPE_UNSPECIFIED .getNumber()) { output.writeEnum(2, resourceType_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, displayName_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resourceId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, resourceId_); } if (resourceType_ != com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType .RESOURCE_TYPE_UNSPECIFIED .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, resourceType_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, displayName_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings)) { return super.equals(obj); } com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings other = (com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings) obj; if (!getResourceId().equals(other.getResourceId())) return false; if (resourceType_ != other.resourceType_) return false; if (!getDisplayName().equals(other.getDisplayName())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + RESOURCE_ID_FIELD_NUMBER; hash = (53 * hash) + getResourceId().hashCode(); hash = (37 * hash) + RESOURCE_TYPE_FIELD_NUMBER; hash = (53 * hash) + resourceType_; hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; hash = (53 * hash) + getDisplayName().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings parseFrom( byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder( com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
     * Represent the custom settings for the resources to be created.
     * 
* * Protobuf type {@code google.cloud.assuredworkloads.v1.Workload.ResourceSettings} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.assuredworkloads.v1.Workload.ResourceSettings) com.google.cloud.assuredworkloads.v1.Workload.ResourceSettingsOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_ResourceSettings_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_ResourceSettings_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.class, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.Builder.class); } // Construct using com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.newBuilder() private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; resourceId_ = ""; resourceType_ = 0; displayName_ = ""; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_ResourceSettings_descriptor; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings getDefaultInstanceForType() { return com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.getDefaultInstance(); } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings build() { com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings buildPartial() { com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings result = new com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartial0( com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.resourceId_ = resourceId_; } if (((from_bitField0_ & 0x00000002) != 0)) { result.resourceType_ = resourceType_; } if (((from_bitField0_ & 0x00000004) != 0)) { result.displayName_ = displayName_; } } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings) { return mergeFrom((com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom( com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings other) { if (other == com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.getDefaultInstance()) return this; if (!other.getResourceId().isEmpty()) { resourceId_ = other.resourceId_; bitField0_ |= 0x00000001; onChanged(); } if (other.resourceType_ != 0) { setResourceTypeValue(other.getResourceTypeValue()); } if (!other.getDisplayName().isEmpty()) { displayName_ = other.displayName_; bitField0_ |= 0x00000004; onChanged(); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { resourceId_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 10 case 16: { resourceType_ = input.readEnum(); bitField0_ |= 0x00000002; break; } // case 16 case 26: { displayName_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000004; break; } // case 26 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private java.lang.Object resourceId_ = ""; /** * * *
       * Resource identifier.
       * For a project this represents project_id. If the project is already
       * taken, the workload creation will fail.
       * For KeyRing, this represents the keyring_id.
       * For a folder, don't set this value as folder_id is assigned by Google.
       * 
* * string resource_id = 1; * * @return The resourceId. */ public java.lang.String getResourceId() { java.lang.Object ref = resourceId_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); resourceId_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * Resource identifier.
       * For a project this represents project_id. If the project is already
       * taken, the workload creation will fail.
       * For KeyRing, this represents the keyring_id.
       * For a folder, don't set this value as folder_id is assigned by Google.
       * 
* * string resource_id = 1; * * @return The bytes for resourceId. */ public com.google.protobuf.ByteString getResourceIdBytes() { java.lang.Object ref = resourceId_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); resourceId_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * Resource identifier.
       * For a project this represents project_id. If the project is already
       * taken, the workload creation will fail.
       * For KeyRing, this represents the keyring_id.
       * For a folder, don't set this value as folder_id is assigned by Google.
       * 
* * string resource_id = 1; * * @param value The resourceId to set. * @return This builder for chaining. */ public Builder setResourceId(java.lang.String value) { if (value == null) { throw new NullPointerException(); } resourceId_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
       * Resource identifier.
       * For a project this represents project_id. If the project is already
       * taken, the workload creation will fail.
       * For KeyRing, this represents the keyring_id.
       * For a folder, don't set this value as folder_id is assigned by Google.
       * 
* * string resource_id = 1; * * @return This builder for chaining. */ public Builder clearResourceId() { resourceId_ = getDefaultInstance().getResourceId(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** * * *
       * Resource identifier.
       * For a project this represents project_id. If the project is already
       * taken, the workload creation will fail.
       * For KeyRing, this represents the keyring_id.
       * For a folder, don't set this value as folder_id is assigned by Google.
       * 
* * string resource_id = 1; * * @param value The bytes for resourceId to set. * @return This builder for chaining. */ public Builder setResourceIdBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); resourceId_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } private int resourceType_ = 0; /** * * *
       * Indicates the type of resource. This field should be specified to
       * correspond the id to the right resource type (CONSUMER_FOLDER or
       * ENCRYPTION_KEYS_PROJECT)
       * 
* * * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return The enum numeric value on the wire for resourceType. */ @java.lang.Override public int getResourceTypeValue() { return resourceType_; } /** * * *
       * Indicates the type of resource. This field should be specified to
       * correspond the id to the right resource type (CONSUMER_FOLDER or
       * ENCRYPTION_KEYS_PROJECT)
       * 
* * * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @param value The enum numeric value on the wire for resourceType to set. * @return This builder for chaining. */ public Builder setResourceTypeValue(int value) { resourceType_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** * * *
       * Indicates the type of resource. This field should be specified to
       * correspond the id to the right resource type (CONSUMER_FOLDER or
       * ENCRYPTION_KEYS_PROJECT)
       * 
* * * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return The resourceType. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType getResourceType() { com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType result = com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType.forNumber( resourceType_); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType.UNRECOGNIZED : result; } /** * * *
       * Indicates the type of resource. This field should be specified to
       * correspond the id to the right resource type (CONSUMER_FOLDER or
       * ENCRYPTION_KEYS_PROJECT)
       * 
* * * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @param value The resourceType to set. * @return This builder for chaining. */ public Builder setResourceType( com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000002; resourceType_ = value.getNumber(); onChanged(); return this; } /** * * *
       * Indicates the type of resource. This field should be specified to
       * correspond the id to the right resource type (CONSUMER_FOLDER or
       * ENCRYPTION_KEYS_PROJECT)
       * 
* * * .google.cloud.assuredworkloads.v1.Workload.ResourceInfo.ResourceType resource_type = 2; * * * @return This builder for chaining. */ public Builder clearResourceType() { bitField0_ = (bitField0_ & ~0x00000002); resourceType_ = 0; onChanged(); return this; } private java.lang.Object displayName_ = ""; /** * * *
       * User-assigned resource display name.
       * If not empty it will be used to create a resource with the specified
       * name.
       * 
* * string display_name = 3; * * @return The displayName. */ public java.lang.String getDisplayName() { java.lang.Object ref = displayName_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); displayName_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * User-assigned resource display name.
       * If not empty it will be used to create a resource with the specified
       * name.
       * 
* * string display_name = 3; * * @return The bytes for displayName. */ public com.google.protobuf.ByteString getDisplayNameBytes() { java.lang.Object ref = displayName_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); displayName_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * User-assigned resource display name.
       * If not empty it will be used to create a resource with the specified
       * name.
       * 
* * string display_name = 3; * * @param value The displayName to set. * @return This builder for chaining. */ public Builder setDisplayName(java.lang.String value) { if (value == null) { throw new NullPointerException(); } displayName_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } /** * * *
       * User-assigned resource display name.
       * If not empty it will be used to create a resource with the specified
       * name.
       * 
* * string display_name = 3; * * @return This builder for chaining. */ public Builder clearDisplayName() { displayName_ = getDefaultInstance().getDisplayName(); bitField0_ = (bitField0_ & ~0x00000004); onChanged(); return this; } /** * * *
       * User-assigned resource display name.
       * If not empty it will be used to create a resource with the specified
       * name.
       * 
* * string display_name = 3; * * @param value The bytes for displayName to set. * @return This builder for chaining. */ public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); displayName_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.assuredworkloads.v1.Workload.ResourceSettings) } // @@protoc_insertion_point(class_scope:google.cloud.assuredworkloads.v1.Workload.ResourceSettings) private static final com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings(); } public static com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public ResourceSettings parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException() .setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface SaaEnrollmentResponseOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse) com.google.protobuf.MessageOrBuilder { /** * * *
     * Indicates SAA enrollment status of a given workload.
     * 
* * * optional .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState setup_status = 1; * * * @return Whether the setupStatus field is set. */ boolean hasSetupStatus(); /** * * *
     * Indicates SAA enrollment status of a given workload.
     * 
* * * optional .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState setup_status = 1; * * * @return The enum numeric value on the wire for setupStatus. */ int getSetupStatusValue(); /** * * *
     * Indicates SAA enrollment status of a given workload.
     * 
* * * optional .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState setup_status = 1; * * * @return The setupStatus. */ com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState getSetupStatus(); /** * * *
     * Indicates SAA enrollment setup error if any.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @return A list containing the setupErrors. */ java.util.List getSetupErrorsList(); /** * * *
     * Indicates SAA enrollment setup error if any.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @return The count of setupErrors. */ int getSetupErrorsCount(); /** * * *
     * Indicates SAA enrollment setup error if any.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @param index The index of the element to return. * @return The setupErrors at the given index. */ com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError getSetupErrors( int index); /** * * *
     * Indicates SAA enrollment setup error if any.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @return A list containing the enum numeric values on the wire for setupErrors. */ java.util.List getSetupErrorsValueList(); /** * * *
     * Indicates SAA enrollment setup error if any.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @param index The index of the value to return. * @return The enum numeric value on the wire of setupErrors at the given index. */ int getSetupErrorsValue(int index); } /** * * *
   * Signed Access Approvals (SAA) enrollment response.
   * 
* * Protobuf type {@code google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse} */ public static final class SaaEnrollmentResponse extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse) SaaEnrollmentResponseOrBuilder { private static final long serialVersionUID = 0L; // Use SaaEnrollmentResponse.newBuilder() to construct. private SaaEnrollmentResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private SaaEnrollmentResponse() { setupStatus_ = 0; setupErrors_ = java.util.Collections.emptyList(); } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new SaaEnrollmentResponse(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_SaaEnrollmentResponse_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_SaaEnrollmentResponse_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.class, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.Builder.class); } /** * * *
     * Setup state of SAA enrollment.
     * 
* * Protobuf enum {@code * google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState} */ public enum SetupState implements com.google.protobuf.ProtocolMessageEnum { /** * * *
       * Unspecified.
       * 
* * SETUP_STATE_UNSPECIFIED = 0; */ SETUP_STATE_UNSPECIFIED(0), /** * * *
       * SAA enrollment pending.
       * 
* * STATUS_PENDING = 1; */ STATUS_PENDING(1), /** * * *
       * SAA enrollment comopleted.
       * 
* * STATUS_COMPLETE = 2; */ STATUS_COMPLETE(2), UNRECOGNIZED(-1), ; /** * * *
       * Unspecified.
       * 
* * SETUP_STATE_UNSPECIFIED = 0; */ public static final int SETUP_STATE_UNSPECIFIED_VALUE = 0; /** * * *
       * SAA enrollment pending.
       * 
* * STATUS_PENDING = 1; */ public static final int STATUS_PENDING_VALUE = 1; /** * * *
       * SAA enrollment comopleted.
       * 
* * STATUS_COMPLETE = 2; */ public static final int STATUS_COMPLETE_VALUE = 2; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static SetupState valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static SetupState forNumber(int value) { switch (value) { case 0: return SETUP_STATE_UNSPECIFIED; case 1: return STATUS_PENDING; case 2: return STATUS_COMPLETE; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public SetupState findValueByNumber(int number) { return SetupState.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.getDescriptor() .getEnumTypes() .get(0); } private static final SetupState[] VALUES = values(); public static SetupState valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private SetupState(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState) } /** * * *
     * Setup error of SAA enrollment.
     * 
* * Protobuf enum {@code * google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError} */ public enum SetupError implements com.google.protobuf.ProtocolMessageEnum { /** * * *
       * Unspecified.
       * 
* * SETUP_ERROR_UNSPECIFIED = 0; */ SETUP_ERROR_UNSPECIFIED(0), /** * * *
       * Invalid states for all customers, to be redirected to AA UI for
       * additional details.
       * 
* * ERROR_INVALID_BASE_SETUP = 1; */ ERROR_INVALID_BASE_SETUP(1), /** * * *
       * Returned when there is not an EKM key configured.
       * 
* * ERROR_MISSING_EXTERNAL_SIGNING_KEY = 2; */ ERROR_MISSING_EXTERNAL_SIGNING_KEY(2), /** * * *
       * Returned when there are no enrolled services or the customer is
       * enrolled in CAA only for a subset of services.
       * 
* * ERROR_NOT_ALL_SERVICES_ENROLLED = 3; */ ERROR_NOT_ALL_SERVICES_ENROLLED(3), /** * * *
       * Returned when exception was encountered during evaluation of other
       * criteria.
       * 
* * ERROR_SETUP_CHECK_FAILED = 4; */ ERROR_SETUP_CHECK_FAILED(4), UNRECOGNIZED(-1), ; /** * * *
       * Unspecified.
       * 
* * SETUP_ERROR_UNSPECIFIED = 0; */ public static final int SETUP_ERROR_UNSPECIFIED_VALUE = 0; /** * * *
       * Invalid states for all customers, to be redirected to AA UI for
       * additional details.
       * 
* * ERROR_INVALID_BASE_SETUP = 1; */ public static final int ERROR_INVALID_BASE_SETUP_VALUE = 1; /** * * *
       * Returned when there is not an EKM key configured.
       * 
* * ERROR_MISSING_EXTERNAL_SIGNING_KEY = 2; */ public static final int ERROR_MISSING_EXTERNAL_SIGNING_KEY_VALUE = 2; /** * * *
       * Returned when there are no enrolled services or the customer is
       * enrolled in CAA only for a subset of services.
       * 
* * ERROR_NOT_ALL_SERVICES_ENROLLED = 3; */ public static final int ERROR_NOT_ALL_SERVICES_ENROLLED_VALUE = 3; /** * * *
       * Returned when exception was encountered during evaluation of other
       * criteria.
       * 
* * ERROR_SETUP_CHECK_FAILED = 4; */ public static final int ERROR_SETUP_CHECK_FAILED_VALUE = 4; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static SetupError valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static SetupError forNumber(int value) { switch (value) { case 0: return SETUP_ERROR_UNSPECIFIED; case 1: return ERROR_INVALID_BASE_SETUP; case 2: return ERROR_MISSING_EXTERNAL_SIGNING_KEY; case 3: return ERROR_NOT_ALL_SERVICES_ENROLLED; case 4: return ERROR_SETUP_CHECK_FAILED; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public SetupError findValueByNumber(int number) { return SetupError.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.getDescriptor() .getEnumTypes() .get(1); } private static final SetupError[] VALUES = values(); public static SetupError valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private SetupError(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError) } private int bitField0_; public static final int SETUP_STATUS_FIELD_NUMBER = 1; private int setupStatus_ = 0; /** * * *
     * Indicates SAA enrollment status of a given workload.
     * 
* * * optional .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState setup_status = 1; * * * @return Whether the setupStatus field is set. */ @java.lang.Override public boolean hasSetupStatus() { return ((bitField0_ & 0x00000001) != 0); } /** * * *
     * Indicates SAA enrollment status of a given workload.
     * 
* * * optional .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState setup_status = 1; * * * @return The enum numeric value on the wire for setupStatus. */ @java.lang.Override public int getSetupStatusValue() { return setupStatus_; } /** * * *
     * Indicates SAA enrollment status of a given workload.
     * 
* * * optional .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState setup_status = 1; * * * @return The setupStatus. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState getSetupStatus() { com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState result = com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState.forNumber( setupStatus_); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState .UNRECOGNIZED : result; } public static final int SETUP_ERRORS_FIELD_NUMBER = 2; @SuppressWarnings("serial") private java.util.List setupErrors_; private static final com.google.protobuf.Internal.ListAdapter.Converter< java.lang.Integer, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError> setupErrors_converter_ = new com.google.protobuf.Internal.ListAdapter.Converter< java.lang.Integer, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError>() { public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError convert(java.lang.Integer from) { com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError result = com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse .SetupError.forNumber(from); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError .UNRECOGNIZED : result; } }; /** * * *
     * Indicates SAA enrollment setup error if any.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @return A list containing the setupErrors. */ @java.lang.Override public java.util.List< com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError> getSetupErrorsList() { return new com.google.protobuf.Internal.ListAdapter< java.lang.Integer, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError>( setupErrors_, setupErrors_converter_); } /** * * *
     * Indicates SAA enrollment setup error if any.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @return The count of setupErrors. */ @java.lang.Override public int getSetupErrorsCount() { return setupErrors_.size(); } /** * * *
     * Indicates SAA enrollment setup error if any.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @param index The index of the element to return. * @return The setupErrors at the given index. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError getSetupErrors(int index) { return setupErrors_converter_.convert(setupErrors_.get(index)); } /** * * *
     * Indicates SAA enrollment setup error if any.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @return A list containing the enum numeric values on the wire for setupErrors. */ @java.lang.Override public java.util.List getSetupErrorsValueList() { return setupErrors_; } /** * * *
     * Indicates SAA enrollment setup error if any.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @param index The index of the value to return. * @return The enum numeric value on the wire of setupErrors at the given index. */ @java.lang.Override public int getSetupErrorsValue(int index) { return setupErrors_.get(index); } private int setupErrorsMemoizedSerializedSize; private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { getSerializedSize(); if (((bitField0_ & 0x00000001) != 0)) { output.writeEnum(1, setupStatus_); } if (getSetupErrorsList().size() > 0) { output.writeUInt32NoTag(18); output.writeUInt32NoTag(setupErrorsMemoizedSerializedSize); } for (int i = 0; i < setupErrors_.size(); i++) { output.writeEnumNoTag(setupErrors_.get(i)); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, setupStatus_); } { int dataSize = 0; for (int i = 0; i < setupErrors_.size(); i++) { dataSize += com.google.protobuf.CodedOutputStream.computeEnumSizeNoTag(setupErrors_.get(i)); } size += dataSize; if (!getSetupErrorsList().isEmpty()) { size += 1; size += com.google.protobuf.CodedOutputStream.computeUInt32SizeNoTag(dataSize); } setupErrorsMemoizedSerializedSize = dataSize; } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse)) { return super.equals(obj); } com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse other = (com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse) obj; if (hasSetupStatus() != other.hasSetupStatus()) return false; if (hasSetupStatus()) { if (setupStatus_ != other.setupStatus_) return false; } if (!setupErrors_.equals(other.setupErrors_)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); if (hasSetupStatus()) { hash = (37 * hash) + SETUP_STATUS_FIELD_NUMBER; hash = (53 * hash) + setupStatus_; } if (getSetupErrorsCount() > 0) { hash = (37 * hash) + SETUP_ERRORS_FIELD_NUMBER; hash = (53 * hash) + setupErrors_.hashCode(); } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse parseFrom( byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder( com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
     * Signed Access Approvals (SAA) enrollment response.
     * 
* * Protobuf type {@code google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse) com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponseOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_SaaEnrollmentResponse_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_SaaEnrollmentResponse_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.class, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.Builder.class); } // Construct using // com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.newBuilder() private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; setupStatus_ = 0; setupErrors_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000002); return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_SaaEnrollmentResponse_descriptor; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse getDefaultInstanceForType() { return com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse .getDefaultInstance(); } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse build() { com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse buildPartial() { com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse result = new com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse(this); buildPartialRepeatedFields(result); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartialRepeatedFields( com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse result) { if (((bitField0_ & 0x00000002) != 0)) { setupErrors_ = java.util.Collections.unmodifiableList(setupErrors_); bitField0_ = (bitField0_ & ~0x00000002); } result.setupErrors_ = setupErrors_; } private void buildPartial0( com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse result) { int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (((from_bitField0_ & 0x00000001) != 0)) { result.setupStatus_ = setupStatus_; to_bitField0_ |= 0x00000001; } result.bitField0_ |= to_bitField0_; } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse) { return mergeFrom( (com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom( com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse other) { if (other == com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse .getDefaultInstance()) return this; if (other.hasSetupStatus()) { setSetupStatus(other.getSetupStatus()); } if (!other.setupErrors_.isEmpty()) { if (setupErrors_.isEmpty()) { setupErrors_ = other.setupErrors_; bitField0_ = (bitField0_ & ~0x00000002); } else { ensureSetupErrorsIsMutable(); setupErrors_.addAll(other.setupErrors_); } onChanged(); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 8: { setupStatus_ = input.readEnum(); bitField0_ |= 0x00000001; break; } // case 8 case 16: { int tmpRaw = input.readEnum(); ensureSetupErrorsIsMutable(); setupErrors_.add(tmpRaw); break; } // case 16 case 18: { int length = input.readRawVarint32(); int oldLimit = input.pushLimit(length); while (input.getBytesUntilLimit() > 0) { int tmpRaw = input.readEnum(); ensureSetupErrorsIsMutable(); setupErrors_.add(tmpRaw); } input.popLimit(oldLimit); break; } // case 18 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private int setupStatus_ = 0; /** * * *
       * Indicates SAA enrollment status of a given workload.
       * 
* * * optional .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState setup_status = 1; * * * @return Whether the setupStatus field is set. */ @java.lang.Override public boolean hasSetupStatus() { return ((bitField0_ & 0x00000001) != 0); } /** * * *
       * Indicates SAA enrollment status of a given workload.
       * 
* * * optional .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState setup_status = 1; * * * @return The enum numeric value on the wire for setupStatus. */ @java.lang.Override public int getSetupStatusValue() { return setupStatus_; } /** * * *
       * Indicates SAA enrollment status of a given workload.
       * 
* * * optional .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState setup_status = 1; * * * @param value The enum numeric value on the wire for setupStatus to set. * @return This builder for chaining. */ public Builder setSetupStatusValue(int value) { setupStatus_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
       * Indicates SAA enrollment status of a given workload.
       * 
* * * optional .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState setup_status = 1; * * * @return The setupStatus. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState getSetupStatus() { com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState result = com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState .forNumber(setupStatus_); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState .UNRECOGNIZED : result; } /** * * *
       * Indicates SAA enrollment status of a given workload.
       * 
* * * optional .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState setup_status = 1; * * * @param value The setupStatus to set. * @return This builder for chaining. */ public Builder setSetupStatus( com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000001; setupStatus_ = value.getNumber(); onChanged(); return this; } /** * * *
       * Indicates SAA enrollment status of a given workload.
       * 
* * * optional .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupState setup_status = 1; * * * @return This builder for chaining. */ public Builder clearSetupStatus() { bitField0_ = (bitField0_ & ~0x00000001); setupStatus_ = 0; onChanged(); return this; } private java.util.List setupErrors_ = java.util.Collections.emptyList(); private void ensureSetupErrorsIsMutable() { if (!((bitField0_ & 0x00000002) != 0)) { setupErrors_ = new java.util.ArrayList(setupErrors_); bitField0_ |= 0x00000002; } } /** * * *
       * Indicates SAA enrollment setup error if any.
       * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @return A list containing the setupErrors. */ public java.util.List< com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError> getSetupErrorsList() { return new com.google.protobuf.Internal.ListAdapter< java.lang.Integer, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError>( setupErrors_, setupErrors_converter_); } /** * * *
       * Indicates SAA enrollment setup error if any.
       * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @return The count of setupErrors. */ public int getSetupErrorsCount() { return setupErrors_.size(); } /** * * *
       * Indicates SAA enrollment setup error if any.
       * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @param index The index of the element to return. * @return The setupErrors at the given index. */ public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError getSetupErrors(int index) { return setupErrors_converter_.convert(setupErrors_.get(index)); } /** * * *
       * Indicates SAA enrollment setup error if any.
       * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @param index The index to set the value at. * @param value The setupErrors to set. * @return This builder for chaining. */ public Builder setSetupErrors( int index, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError value) { if (value == null) { throw new NullPointerException(); } ensureSetupErrorsIsMutable(); setupErrors_.set(index, value.getNumber()); onChanged(); return this; } /** * * *
       * Indicates SAA enrollment setup error if any.
       * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @param value The setupErrors to add. * @return This builder for chaining. */ public Builder addSetupErrors( com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError value) { if (value == null) { throw new NullPointerException(); } ensureSetupErrorsIsMutable(); setupErrors_.add(value.getNumber()); onChanged(); return this; } /** * * *
       * Indicates SAA enrollment setup error if any.
       * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @param values The setupErrors to add. * @return This builder for chaining. */ public Builder addAllSetupErrors( java.lang.Iterable< ? extends com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse .SetupError> values) { ensureSetupErrorsIsMutable(); for (com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError value : values) { setupErrors_.add(value.getNumber()); } onChanged(); return this; } /** * * *
       * Indicates SAA enrollment setup error if any.
       * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @return This builder for chaining. */ public Builder clearSetupErrors() { setupErrors_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000002); onChanged(); return this; } /** * * *
       * Indicates SAA enrollment setup error if any.
       * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @return A list containing the enum numeric values on the wire for setupErrors. */ public java.util.List getSetupErrorsValueList() { return java.util.Collections.unmodifiableList(setupErrors_); } /** * * *
       * Indicates SAA enrollment setup error if any.
       * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @param index The index of the value to return. * @return The enum numeric value on the wire of setupErrors at the given index. */ public int getSetupErrorsValue(int index) { return setupErrors_.get(index); } /** * * *
       * Indicates SAA enrollment setup error if any.
       * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @param index The index to set the value at. * @param value The enum numeric value on the wire for setupErrors to set. * @return This builder for chaining. */ public Builder setSetupErrorsValue(int index, int value) { ensureSetupErrorsIsMutable(); setupErrors_.set(index, value); onChanged(); return this; } /** * * *
       * Indicates SAA enrollment setup error if any.
       * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @param value The enum numeric value on the wire for setupErrors to add. * @return This builder for chaining. */ public Builder addSetupErrorsValue(int value) { ensureSetupErrorsIsMutable(); setupErrors_.add(value); onChanged(); return this; } /** * * *
       * Indicates SAA enrollment setup error if any.
       * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.SetupError setup_errors = 2; * * * @param values The enum numeric values on the wire for setupErrors to add. * @return This builder for chaining. */ public Builder addAllSetupErrorsValue(java.lang.Iterable values) { ensureSetupErrorsIsMutable(); for (int value : values) { setupErrors_.add(value); } onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse) } // @@protoc_insertion_point(class_scope:google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse) private static final com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse(); } public static com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public SaaEnrollmentResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException() .setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } private int bitField0_; public static final int NAME_FIELD_NUMBER = 1; @SuppressWarnings("serial") private volatile java.lang.Object name_ = ""; /** * * *
   * Optional. The resource name of the workload.
   * Format:
   * organizations/{organization}/locations/{location}/workloads/{workload}
   *
   * Read-only.
   * 
* * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; * * @return The name. */ @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** * * *
   * Optional. The resource name of the workload.
   * Format:
   * organizations/{organization}/locations/{location}/workloads/{workload}
   *
   * Read-only.
   * 
* * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; * * @return The bytes for name. */ @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int DISPLAY_NAME_FIELD_NUMBER = 2; @SuppressWarnings("serial") private volatile java.lang.Object displayName_ = ""; /** * * *
   * Required. The user-assigned display name of the Workload.
   * When present it must be between 4 to 30 characters.
   * Allowed characters are: lowercase and uppercase letters, numbers,
   * hyphen, and spaces.
   *
   * Example: My Workload
   * 
* * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; * * @return The displayName. */ @java.lang.Override public java.lang.String getDisplayName() { java.lang.Object ref = displayName_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); displayName_ = s; return s; } } /** * * *
   * Required. The user-assigned display name of the Workload.
   * When present it must be between 4 to 30 characters.
   * Allowed characters are: lowercase and uppercase letters, numbers,
   * hyphen, and spaces.
   *
   * Example: My Workload
   * 
* * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; * * @return The bytes for displayName. */ @java.lang.Override public com.google.protobuf.ByteString getDisplayNameBytes() { java.lang.Object ref = displayName_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); displayName_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int RESOURCES_FIELD_NUMBER = 3; @SuppressWarnings("serial") private java.util.List resources_; /** * * *
   * Output only. The resources associated with this workload.
   * These resources will be created when creating the workload.
   * If any of the projects already exist, the workload creation will fail.
   * Always read only.
   * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public java.util.List getResourcesList() { return resources_; } /** * * *
   * Output only. The resources associated with this workload.
   * These resources will be created when creating the workload.
   * If any of the projects already exist, the workload creation will fail.
   * Always read only.
   * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public java.util.List< ? extends com.google.cloud.assuredworkloads.v1.Workload.ResourceInfoOrBuilder> getResourcesOrBuilderList() { return resources_; } /** * * *
   * Output only. The resources associated with this workload.
   * These resources will be created when creating the workload.
   * If any of the projects already exist, the workload creation will fail.
   * Always read only.
   * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public int getResourcesCount() { return resources_.size(); } /** * * *
   * Output only. The resources associated with this workload.
   * These resources will be created when creating the workload.
   * If any of the projects already exist, the workload creation will fail.
   * Always read only.
   * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo getResources(int index) { return resources_.get(index); } /** * * *
   * Output only. The resources associated with this workload.
   * These resources will be created when creating the workload.
   * If any of the projects already exist, the workload creation will fail.
   * Always read only.
   * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfoOrBuilder getResourcesOrBuilder( int index) { return resources_.get(index); } public static final int COMPLIANCE_REGIME_FIELD_NUMBER = 4; private int complianceRegime_ = 0; /** * * *
   * Required. Immutable. Compliance Regime associated with this workload.
   * 
* * * .google.cloud.assuredworkloads.v1.Workload.ComplianceRegime compliance_regime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The enum numeric value on the wire for complianceRegime. */ @java.lang.Override public int getComplianceRegimeValue() { return complianceRegime_; } /** * * *
   * Required. Immutable. Compliance Regime associated with this workload.
   * 
* * * .google.cloud.assuredworkloads.v1.Workload.ComplianceRegime compliance_regime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The complianceRegime. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ComplianceRegime getComplianceRegime() { com.google.cloud.assuredworkloads.v1.Workload.ComplianceRegime result = com.google.cloud.assuredworkloads.v1.Workload.ComplianceRegime.forNumber(complianceRegime_); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.ComplianceRegime.UNRECOGNIZED : result; } public static final int CREATE_TIME_FIELD_NUMBER = 5; private com.google.protobuf.Timestamp createTime_; /** * * *
   * Output only. Immutable. The Workload creation timestamp.
   * 
* * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return Whether the createTime field is set. */ @java.lang.Override public boolean hasCreateTime() { return ((bitField0_ & 0x00000001) != 0); } /** * * *
   * Output only. Immutable. The Workload creation timestamp.
   * 
* * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The createTime. */ @java.lang.Override public com.google.protobuf.Timestamp getCreateTime() { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } /** * * *
   * Output only. Immutable. The Workload creation timestamp.
   * 
* * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } public static final int BILLING_ACCOUNT_FIELD_NUMBER = 6; @SuppressWarnings("serial") private volatile java.lang.Object billingAccount_ = ""; /** * * *
   * Optional. The billing account used for the resources which are
   * direct children of workload. This billing account is initially associated
   * with the resources created as part of Workload creation.
   * After the initial creation of these resources, the customer can change
   * the assigned billing account.
   * The resource name has the form
   * `billingAccounts/{billing_account_id}`. For example,
   * `billingAccounts/012345-567890-ABCDEF`.
   * 
* * string billing_account = 6 [(.google.api.field_behavior) = OPTIONAL]; * * @return The billingAccount. */ @java.lang.Override public java.lang.String getBillingAccount() { java.lang.Object ref = billingAccount_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); billingAccount_ = s; return s; } } /** * * *
   * Optional. The billing account used for the resources which are
   * direct children of workload. This billing account is initially associated
   * with the resources created as part of Workload creation.
   * After the initial creation of these resources, the customer can change
   * the assigned billing account.
   * The resource name has the form
   * `billingAccounts/{billing_account_id}`. For example,
   * `billingAccounts/012345-567890-ABCDEF`.
   * 
* * string billing_account = 6 [(.google.api.field_behavior) = OPTIONAL]; * * @return The bytes for billingAccount. */ @java.lang.Override public com.google.protobuf.ByteString getBillingAccountBytes() { java.lang.Object ref = billingAccount_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); billingAccount_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int ETAG_FIELD_NUMBER = 9; @SuppressWarnings("serial") private volatile java.lang.Object etag_ = ""; /** * * *
   * Optional. ETag of the workload, it is calculated on the basis
   * of the Workload contents. It will be used in Update & Delete operations.
   * 
* * string etag = 9 [(.google.api.field_behavior) = OPTIONAL]; * * @return The etag. */ @java.lang.Override public java.lang.String getEtag() { java.lang.Object ref = etag_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); etag_ = s; return s; } } /** * * *
   * Optional. ETag of the workload, it is calculated on the basis
   * of the Workload contents. It will be used in Update & Delete operations.
   * 
* * string etag = 9 [(.google.api.field_behavior) = OPTIONAL]; * * @return The bytes for etag. */ @java.lang.Override public com.google.protobuf.ByteString getEtagBytes() { java.lang.Object ref = etag_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); etag_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int LABELS_FIELD_NUMBER = 10; private static final class LabelsDefaultEntryHolder { static final com.google.protobuf.MapEntry defaultEntry = com.google.protobuf.MapEntry.newDefaultInstance( com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_LabelsEntry_descriptor, com.google.protobuf.WireFormat.FieldType.STRING, "", com.google.protobuf.WireFormat.FieldType.STRING, ""); } @SuppressWarnings("serial") private com.google.protobuf.MapField labels_; private com.google.protobuf.MapField internalGetLabels() { if (labels_ == null) { return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); } return labels_; } public int getLabelsCount() { return internalGetLabels().getMap().size(); } /** * * *
   * Optional. Labels applied to the workload.
   * 
* * map<string, string> labels = 10 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override public boolean containsLabels(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetLabels().getMap().containsKey(key); } /** Use {@link #getLabelsMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); } /** * * *
   * Optional. Labels applied to the workload.
   * 
* * map<string, string> labels = 10 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } /** * * *
   * Optional. Labels applied to the workload.
   * 
* * map<string, string> labels = 10 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override public /* nullable */ java.lang.String getLabelsOrDefault( java.lang.String key, /* nullable */ java.lang.String defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetLabels().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** * * *
   * Optional. Labels applied to the workload.
   * 
* * map<string, string> labels = 10 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override public java.lang.String getLabelsOrThrow(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetLabels().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public static final int PROVISIONED_RESOURCES_PARENT_FIELD_NUMBER = 13; @SuppressWarnings("serial") private volatile java.lang.Object provisionedResourcesParent_ = ""; /** * * *
   * Input only. The parent resource for the resources managed by this Assured Workload. May
   * be either empty or a folder resource which is a child of the
   * Workload parent. If not specified all resources are created under the
   * parent organization.
   * Format:
   * folders/{folder_id}
   * 
* * string provisioned_resources_parent = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The provisionedResourcesParent. */ @java.lang.Override public java.lang.String getProvisionedResourcesParent() { java.lang.Object ref = provisionedResourcesParent_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); provisionedResourcesParent_ = s; return s; } } /** * * *
   * Input only. The parent resource for the resources managed by this Assured Workload. May
   * be either empty or a folder resource which is a child of the
   * Workload parent. If not specified all resources are created under the
   * parent organization.
   * Format:
   * folders/{folder_id}
   * 
* * string provisioned_resources_parent = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The bytes for provisionedResourcesParent. */ @java.lang.Override public com.google.protobuf.ByteString getProvisionedResourcesParentBytes() { java.lang.Object ref = provisionedResourcesParent_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); provisionedResourcesParent_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int KMS_SETTINGS_FIELD_NUMBER = 14; private com.google.cloud.assuredworkloads.v1.Workload.KMSSettings kmsSettings_; /** * * *
   * Input only. Settings used to create a CMEK crypto key. When set, a project with a KMS
   * CMEK key is provisioned.
   * This field is deprecated as of Feb 28, 2022.
   * In order to create a Keyring, callers should specify,
   * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
   * 
* * * .google.cloud.assuredworkloads.v1.Workload.KMSSettings kms_settings = 14 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY]; * * * @deprecated google.cloud.assuredworkloads.v1.Workload.kms_settings is deprecated. See * google/cloud/assuredworkloads/v1/assuredworkloads.proto;l=484 * @return Whether the kmsSettings field is set. */ @java.lang.Override @java.lang.Deprecated public boolean hasKmsSettings() { return ((bitField0_ & 0x00000002) != 0); } /** * * *
   * Input only. Settings used to create a CMEK crypto key. When set, a project with a KMS
   * CMEK key is provisioned.
   * This field is deprecated as of Feb 28, 2022.
   * In order to create a Keyring, callers should specify,
   * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
   * 
* * * .google.cloud.assuredworkloads.v1.Workload.KMSSettings kms_settings = 14 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY]; * * * @deprecated google.cloud.assuredworkloads.v1.Workload.kms_settings is deprecated. See * google/cloud/assuredworkloads/v1/assuredworkloads.proto;l=484 * @return The kmsSettings. */ @java.lang.Override @java.lang.Deprecated public com.google.cloud.assuredworkloads.v1.Workload.KMSSettings getKmsSettings() { return kmsSettings_ == null ? com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.getDefaultInstance() : kmsSettings_; } /** * * *
   * Input only. Settings used to create a CMEK crypto key. When set, a project with a KMS
   * CMEK key is provisioned.
   * This field is deprecated as of Feb 28, 2022.
   * In order to create a Keyring, callers should specify,
   * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
   * 
* * * .google.cloud.assuredworkloads.v1.Workload.KMSSettings kms_settings = 14 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY]; * */ @java.lang.Override @java.lang.Deprecated public com.google.cloud.assuredworkloads.v1.Workload.KMSSettingsOrBuilder getKmsSettingsOrBuilder() { return kmsSettings_ == null ? com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.getDefaultInstance() : kmsSettings_; } public static final int RESOURCE_SETTINGS_FIELD_NUMBER = 15; @SuppressWarnings("serial") private java.util.List resourceSettings_; /** * * *
   * Input only. Resource properties that are used to customize workload resources.
   * These properties (such as custom project id) will be used to create
   * workload resources if possible. This field is optional.
   * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ @java.lang.Override public java.util.List getResourceSettingsList() { return resourceSettings_; } /** * * *
   * Input only. Resource properties that are used to customize workload resources.
   * These properties (such as custom project id) will be used to create
   * workload resources if possible. This field is optional.
   * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ @java.lang.Override public java.util.List< ? extends com.google.cloud.assuredworkloads.v1.Workload.ResourceSettingsOrBuilder> getResourceSettingsOrBuilderList() { return resourceSettings_; } /** * * *
   * Input only. Resource properties that are used to customize workload resources.
   * These properties (such as custom project id) will be used to create
   * workload resources if possible. This field is optional.
   * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ @java.lang.Override public int getResourceSettingsCount() { return resourceSettings_.size(); } /** * * *
   * Input only. Resource properties that are used to customize workload resources.
   * These properties (such as custom project id) will be used to create
   * workload resources if possible. This field is optional.
   * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings getResourceSettings( int index) { return resourceSettings_.get(index); } /** * * *
   * Input only. Resource properties that are used to customize workload resources.
   * These properties (such as custom project id) will be used to create
   * workload resources if possible. This field is optional.
   * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ResourceSettingsOrBuilder getResourceSettingsOrBuilder(int index) { return resourceSettings_.get(index); } public static final int KAJ_ENROLLMENT_STATE_FIELD_NUMBER = 17; private int kajEnrollmentState_ = 0; /** * * *
   * Output only. Represents the KAJ enrollment state of the given workload.
   * 
* * * .google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState kaj_enrollment_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The enum numeric value on the wire for kajEnrollmentState. */ @java.lang.Override public int getKajEnrollmentStateValue() { return kajEnrollmentState_; } /** * * *
   * Output only. Represents the KAJ enrollment state of the given workload.
   * 
* * * .google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState kaj_enrollment_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The kajEnrollmentState. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState getKajEnrollmentState() { com.google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState result = com.google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState.forNumber( kajEnrollmentState_); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState.UNRECOGNIZED : result; } public static final int ENABLE_SOVEREIGN_CONTROLS_FIELD_NUMBER = 18; private boolean enableSovereignControls_ = false; /** * * *
   * Optional. Indicates the sovereignty status of the given workload.
   * Currently meant to be used by Europe/Canada customers.
   * 
* * bool enable_sovereign_controls = 18 [(.google.api.field_behavior) = OPTIONAL]; * * @return The enableSovereignControls. */ @java.lang.Override public boolean getEnableSovereignControls() { return enableSovereignControls_; } public static final int SAA_ENROLLMENT_RESPONSE_FIELD_NUMBER = 20; private com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saaEnrollmentResponse_; /** * * *
   * Output only. Represents the SAA enrollment response of the given workload.
   * SAA enrollment response is queried during GetWorkload call.
   * In failure cases, user friendly error message is shown in SAA details page.
   * 
* * * .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saa_enrollment_response = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return Whether the saaEnrollmentResponse field is set. */ @java.lang.Override public boolean hasSaaEnrollmentResponse() { return ((bitField0_ & 0x00000004) != 0); } /** * * *
   * Output only. Represents the SAA enrollment response of the given workload.
   * SAA enrollment response is queried during GetWorkload call.
   * In failure cases, user friendly error message is shown in SAA details page.
   * 
* * * .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saa_enrollment_response = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The saaEnrollmentResponse. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse getSaaEnrollmentResponse() { return saaEnrollmentResponse_ == null ? com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.getDefaultInstance() : saaEnrollmentResponse_; } /** * * *
   * Output only. Represents the SAA enrollment response of the given workload.
   * SAA enrollment response is queried during GetWorkload call.
   * In failure cases, user friendly error message is shown in SAA details page.
   * 
* * * .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saa_enrollment_response = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponseOrBuilder getSaaEnrollmentResponseOrBuilder() { return saaEnrollmentResponse_ == null ? com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.getDefaultInstance() : saaEnrollmentResponse_; } public static final int COMPLIANT_BUT_DISALLOWED_SERVICES_FIELD_NUMBER = 24; @SuppressWarnings("serial") private com.google.protobuf.LazyStringArrayList compliantButDisallowedServices_ = com.google.protobuf.LazyStringArrayList.emptyList(); /** * * *
   * Output only. Urls for services which are compliant for this Assured Workload, but which
   * are currently disallowed by the ResourceUsageRestriction org policy.
   * Invoke RestrictAllowedResources endpoint to allow your project developers
   * to use these services in their environment."
   * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return A list containing the compliantButDisallowedServices. */ public com.google.protobuf.ProtocolStringList getCompliantButDisallowedServicesList() { return compliantButDisallowedServices_; } /** * * *
   * Output only. Urls for services which are compliant for this Assured Workload, but which
   * are currently disallowed by the ResourceUsageRestriction org policy.
   * Invoke RestrictAllowedResources endpoint to allow your project developers
   * to use these services in their environment."
   * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The count of compliantButDisallowedServices. */ public int getCompliantButDisallowedServicesCount() { return compliantButDisallowedServices_.size(); } /** * * *
   * Output only. Urls for services which are compliant for this Assured Workload, but which
   * are currently disallowed by the ResourceUsageRestriction org policy.
   * Invoke RestrictAllowedResources endpoint to allow your project developers
   * to use these services in their environment."
   * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. * @return The compliantButDisallowedServices at the given index. */ public java.lang.String getCompliantButDisallowedServices(int index) { return compliantButDisallowedServices_.get(index); } /** * * *
   * Output only. Urls for services which are compliant for this Assured Workload, but which
   * are currently disallowed by the ResourceUsageRestriction org policy.
   * Invoke RestrictAllowedResources endpoint to allow your project developers
   * to use these services in their environment."
   * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. * @return The bytes of the compliantButDisallowedServices at the given index. */ public com.google.protobuf.ByteString getCompliantButDisallowedServicesBytes(int index) { return compliantButDisallowedServices_.getByteString(index); } public static final int PARTNER_FIELD_NUMBER = 25; private int partner_ = 0; /** * * *
   * Optional. Compliance Regime associated with this workload.
   * 
* * * .google.cloud.assuredworkloads.v1.Workload.Partner partner = 25 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The enum numeric value on the wire for partner. */ @java.lang.Override public int getPartnerValue() { return partner_; } /** * * *
   * Optional. Compliance Regime associated with this workload.
   * 
* * * .google.cloud.assuredworkloads.v1.Workload.Partner partner = 25 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The partner. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.Partner getPartner() { com.google.cloud.assuredworkloads.v1.Workload.Partner result = com.google.cloud.assuredworkloads.v1.Workload.Partner.forNumber(partner_); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.Partner.UNRECOGNIZED : result; } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, displayName_); } for (int i = 0; i < resources_.size(); i++) { output.writeMessage(3, resources_.get(i)); } if (complianceRegime_ != com.google.cloud.assuredworkloads.v1.Workload.ComplianceRegime .COMPLIANCE_REGIME_UNSPECIFIED .getNumber()) { output.writeEnum(4, complianceRegime_); } if (((bitField0_ & 0x00000001) != 0)) { output.writeMessage(5, getCreateTime()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(billingAccount_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 6, billingAccount_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 9, etag_); } com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 10); if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(provisionedResourcesParent_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 13, provisionedResourcesParent_); } if (((bitField0_ & 0x00000002) != 0)) { output.writeMessage(14, getKmsSettings()); } for (int i = 0; i < resourceSettings_.size(); i++) { output.writeMessage(15, resourceSettings_.get(i)); } if (kajEnrollmentState_ != com.google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState .KAJ_ENROLLMENT_STATE_UNSPECIFIED .getNumber()) { output.writeEnum(17, kajEnrollmentState_); } if (enableSovereignControls_ != false) { output.writeBool(18, enableSovereignControls_); } if (((bitField0_ & 0x00000004) != 0)) { output.writeMessage(20, getSaaEnrollmentResponse()); } for (int i = 0; i < compliantButDisallowedServices_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString( output, 24, compliantButDisallowedServices_.getRaw(i)); } if (partner_ != com.google.cloud.assuredworkloads.v1.Workload.Partner.PARTNER_UNSPECIFIED.getNumber()) { output.writeEnum(25, partner_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, displayName_); } for (int i = 0; i < resources_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, resources_.get(i)); } if (complianceRegime_ != com.google.cloud.assuredworkloads.v1.Workload.ComplianceRegime .COMPLIANCE_REGIME_UNSPECIFIED .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, complianceRegime_); } if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(billingAccount_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, billingAccount_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(9, etag_); } for (java.util.Map.Entry entry : internalGetLabels().getMap().entrySet()) { com.google.protobuf.MapEntry labels__ = LabelsDefaultEntryHolder.defaultEntry .newBuilderForType() .setKey(entry.getKey()) .setValue(entry.getValue()) .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, labels__); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(provisionedResourcesParent_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(13, provisionedResourcesParent_); } if (((bitField0_ & 0x00000002) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(14, getKmsSettings()); } for (int i = 0; i < resourceSettings_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(15, resourceSettings_.get(i)); } if (kajEnrollmentState_ != com.google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState .KAJ_ENROLLMENT_STATE_UNSPECIFIED .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(17, kajEnrollmentState_); } if (enableSovereignControls_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(18, enableSovereignControls_); } if (((bitField0_ & 0x00000004) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(20, getSaaEnrollmentResponse()); } { int dataSize = 0; for (int i = 0; i < compliantButDisallowedServices_.size(); i++) { dataSize += computeStringSizeNoTag(compliantButDisallowedServices_.getRaw(i)); } size += dataSize; size += 2 * getCompliantButDisallowedServicesList().size(); } if (partner_ != com.google.cloud.assuredworkloads.v1.Workload.Partner.PARTNER_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(25, partner_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.assuredworkloads.v1.Workload)) { return super.equals(obj); } com.google.cloud.assuredworkloads.v1.Workload other = (com.google.cloud.assuredworkloads.v1.Workload) obj; if (!getName().equals(other.getName())) return false; if (!getDisplayName().equals(other.getDisplayName())) return false; if (!getResourcesList().equals(other.getResourcesList())) return false; if (complianceRegime_ != other.complianceRegime_) return false; if (hasCreateTime() != other.hasCreateTime()) return false; if (hasCreateTime()) { if (!getCreateTime().equals(other.getCreateTime())) return false; } if (!getBillingAccount().equals(other.getBillingAccount())) return false; if (!getEtag().equals(other.getEtag())) return false; if (!internalGetLabels().equals(other.internalGetLabels())) return false; if (!getProvisionedResourcesParent().equals(other.getProvisionedResourcesParent())) return false; if (hasKmsSettings() != other.hasKmsSettings()) return false; if (hasKmsSettings()) { if (!getKmsSettings().equals(other.getKmsSettings())) return false; } if (!getResourceSettingsList().equals(other.getResourceSettingsList())) return false; if (kajEnrollmentState_ != other.kajEnrollmentState_) return false; if (getEnableSovereignControls() != other.getEnableSovereignControls()) return false; if (hasSaaEnrollmentResponse() != other.hasSaaEnrollmentResponse()) return false; if (hasSaaEnrollmentResponse()) { if (!getSaaEnrollmentResponse().equals(other.getSaaEnrollmentResponse())) return false; } if (!getCompliantButDisallowedServicesList() .equals(other.getCompliantButDisallowedServicesList())) return false; if (partner_ != other.partner_) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; hash = (53 * hash) + getDisplayName().hashCode(); if (getResourcesCount() > 0) { hash = (37 * hash) + RESOURCES_FIELD_NUMBER; hash = (53 * hash) + getResourcesList().hashCode(); } hash = (37 * hash) + COMPLIANCE_REGIME_FIELD_NUMBER; hash = (53 * hash) + complianceRegime_; if (hasCreateTime()) { hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; hash = (53 * hash) + getCreateTime().hashCode(); } hash = (37 * hash) + BILLING_ACCOUNT_FIELD_NUMBER; hash = (53 * hash) + getBillingAccount().hashCode(); hash = (37 * hash) + ETAG_FIELD_NUMBER; hash = (53 * hash) + getEtag().hashCode(); if (!internalGetLabels().getMap().isEmpty()) { hash = (37 * hash) + LABELS_FIELD_NUMBER; hash = (53 * hash) + internalGetLabels().hashCode(); } hash = (37 * hash) + PROVISIONED_RESOURCES_PARENT_FIELD_NUMBER; hash = (53 * hash) + getProvisionedResourcesParent().hashCode(); if (hasKmsSettings()) { hash = (37 * hash) + KMS_SETTINGS_FIELD_NUMBER; hash = (53 * hash) + getKmsSettings().hashCode(); } if (getResourceSettingsCount() > 0) { hash = (37 * hash) + RESOURCE_SETTINGS_FIELD_NUMBER; hash = (53 * hash) + getResourceSettingsList().hashCode(); } hash = (37 * hash) + KAJ_ENROLLMENT_STATE_FIELD_NUMBER; hash = (53 * hash) + kajEnrollmentState_; hash = (37 * hash) + ENABLE_SOVEREIGN_CONTROLS_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getEnableSovereignControls()); if (hasSaaEnrollmentResponse()) { hash = (37 * hash) + SAA_ENROLLMENT_RESPONSE_FIELD_NUMBER; hash = (53 * hash) + getSaaEnrollmentResponse().hashCode(); } if (getCompliantButDisallowedServicesCount() > 0) { hash = (37 * hash) + COMPLIANT_BUT_DISALLOWED_SERVICES_FIELD_NUMBER; hash = (53 * hash) + getCompliantButDisallowedServicesList().hashCode(); } hash = (37 * hash) + PARTNER_FIELD_NUMBER; hash = (53 * hash) + partner_; hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.assuredworkloads.v1.Workload parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.assuredworkloads.v1.Workload parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.assuredworkloads.v1.Workload parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.assuredworkloads.v1.Workload parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(com.google.cloud.assuredworkloads.v1.Workload prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
   * A Workload object for managing highly regulated workloads of cloud
   * customers.
   * 
* * Protobuf type {@code google.cloud.assuredworkloads.v1.Workload} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.assuredworkloads.v1.Workload) com.google.cloud.assuredworkloads.v1.WorkloadOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_descriptor; } @SuppressWarnings({"rawtypes"}) protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( int number) { switch (number) { case 10: return internalGetLabels(); default: throw new RuntimeException("Invalid map field number: " + number); } } @SuppressWarnings({"rawtypes"}) protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( int number) { switch (number) { case 10: return internalGetMutableLabels(); default: throw new RuntimeException("Invalid map field number: " + number); } } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.assuredworkloads.v1.Workload.class, com.google.cloud.assuredworkloads.v1.Workload.Builder.class); } // Construct using com.google.cloud.assuredworkloads.v1.Workload.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { getResourcesFieldBuilder(); getCreateTimeFieldBuilder(); getKmsSettingsFieldBuilder(); getResourceSettingsFieldBuilder(); getSaaEnrollmentResponseFieldBuilder(); } } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; name_ = ""; displayName_ = ""; if (resourcesBuilder_ == null) { resources_ = java.util.Collections.emptyList(); } else { resources_ = null; resourcesBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00000004); complianceRegime_ = 0; createTime_ = null; if (createTimeBuilder_ != null) { createTimeBuilder_.dispose(); createTimeBuilder_ = null; } billingAccount_ = ""; etag_ = ""; internalGetMutableLabels().clear(); provisionedResourcesParent_ = ""; kmsSettings_ = null; if (kmsSettingsBuilder_ != null) { kmsSettingsBuilder_.dispose(); kmsSettingsBuilder_ = null; } if (resourceSettingsBuilder_ == null) { resourceSettings_ = java.util.Collections.emptyList(); } else { resourceSettings_ = null; resourceSettingsBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00000400); kajEnrollmentState_ = 0; enableSovereignControls_ = false; saaEnrollmentResponse_ = null; if (saaEnrollmentResponseBuilder_ != null) { saaEnrollmentResponseBuilder_.dispose(); saaEnrollmentResponseBuilder_ = null; } compliantButDisallowedServices_ = com.google.protobuf.LazyStringArrayList.emptyList(); partner_ = 0; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.assuredworkloads.v1.AssuredworkloadsProto .internal_static_google_cloud_assuredworkloads_v1_Workload_descriptor; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload getDefaultInstanceForType() { return com.google.cloud.assuredworkloads.v1.Workload.getDefaultInstance(); } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload build() { com.google.cloud.assuredworkloads.v1.Workload result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload buildPartial() { com.google.cloud.assuredworkloads.v1.Workload result = new com.google.cloud.assuredworkloads.v1.Workload(this); buildPartialRepeatedFields(result); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartialRepeatedFields(com.google.cloud.assuredworkloads.v1.Workload result) { if (resourcesBuilder_ == null) { if (((bitField0_ & 0x00000004) != 0)) { resources_ = java.util.Collections.unmodifiableList(resources_); bitField0_ = (bitField0_ & ~0x00000004); } result.resources_ = resources_; } else { result.resources_ = resourcesBuilder_.build(); } if (resourceSettingsBuilder_ == null) { if (((bitField0_ & 0x00000400) != 0)) { resourceSettings_ = java.util.Collections.unmodifiableList(resourceSettings_); bitField0_ = (bitField0_ & ~0x00000400); } result.resourceSettings_ = resourceSettings_; } else { result.resourceSettings_ = resourceSettingsBuilder_.build(); } } private void buildPartial0(com.google.cloud.assuredworkloads.v1.Workload result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.name_ = name_; } if (((from_bitField0_ & 0x00000002) != 0)) { result.displayName_ = displayName_; } if (((from_bitField0_ & 0x00000008) != 0)) { result.complianceRegime_ = complianceRegime_; } int to_bitField0_ = 0; if (((from_bitField0_ & 0x00000010) != 0)) { result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); to_bitField0_ |= 0x00000001; } if (((from_bitField0_ & 0x00000020) != 0)) { result.billingAccount_ = billingAccount_; } if (((from_bitField0_ & 0x00000040) != 0)) { result.etag_ = etag_; } if (((from_bitField0_ & 0x00000080) != 0)) { result.labels_ = internalGetLabels(); result.labels_.makeImmutable(); } if (((from_bitField0_ & 0x00000100) != 0)) { result.provisionedResourcesParent_ = provisionedResourcesParent_; } if (((from_bitField0_ & 0x00000200) != 0)) { result.kmsSettings_ = kmsSettingsBuilder_ == null ? kmsSettings_ : kmsSettingsBuilder_.build(); to_bitField0_ |= 0x00000002; } if (((from_bitField0_ & 0x00000800) != 0)) { result.kajEnrollmentState_ = kajEnrollmentState_; } if (((from_bitField0_ & 0x00001000) != 0)) { result.enableSovereignControls_ = enableSovereignControls_; } if (((from_bitField0_ & 0x00002000) != 0)) { result.saaEnrollmentResponse_ = saaEnrollmentResponseBuilder_ == null ? saaEnrollmentResponse_ : saaEnrollmentResponseBuilder_.build(); to_bitField0_ |= 0x00000004; } if (((from_bitField0_ & 0x00004000) != 0)) { compliantButDisallowedServices_.makeImmutable(); result.compliantButDisallowedServices_ = compliantButDisallowedServices_; } if (((from_bitField0_ & 0x00008000) != 0)) { result.partner_ = partner_; } result.bitField0_ |= to_bitField0_; } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.assuredworkloads.v1.Workload) { return mergeFrom((com.google.cloud.assuredworkloads.v1.Workload) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.assuredworkloads.v1.Workload other) { if (other == com.google.cloud.assuredworkloads.v1.Workload.getDefaultInstance()) return this; if (!other.getName().isEmpty()) { name_ = other.name_; bitField0_ |= 0x00000001; onChanged(); } if (!other.getDisplayName().isEmpty()) { displayName_ = other.displayName_; bitField0_ |= 0x00000002; onChanged(); } if (resourcesBuilder_ == null) { if (!other.resources_.isEmpty()) { if (resources_.isEmpty()) { resources_ = other.resources_; bitField0_ = (bitField0_ & ~0x00000004); } else { ensureResourcesIsMutable(); resources_.addAll(other.resources_); } onChanged(); } } else { if (!other.resources_.isEmpty()) { if (resourcesBuilder_.isEmpty()) { resourcesBuilder_.dispose(); resourcesBuilder_ = null; resources_ = other.resources_; bitField0_ = (bitField0_ & ~0x00000004); resourcesBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getResourcesFieldBuilder() : null; } else { resourcesBuilder_.addAllMessages(other.resources_); } } } if (other.complianceRegime_ != 0) { setComplianceRegimeValue(other.getComplianceRegimeValue()); } if (other.hasCreateTime()) { mergeCreateTime(other.getCreateTime()); } if (!other.getBillingAccount().isEmpty()) { billingAccount_ = other.billingAccount_; bitField0_ |= 0x00000020; onChanged(); } if (!other.getEtag().isEmpty()) { etag_ = other.etag_; bitField0_ |= 0x00000040; onChanged(); } internalGetMutableLabels().mergeFrom(other.internalGetLabels()); bitField0_ |= 0x00000080; if (!other.getProvisionedResourcesParent().isEmpty()) { provisionedResourcesParent_ = other.provisionedResourcesParent_; bitField0_ |= 0x00000100; onChanged(); } if (other.hasKmsSettings()) { mergeKmsSettings(other.getKmsSettings()); } if (resourceSettingsBuilder_ == null) { if (!other.resourceSettings_.isEmpty()) { if (resourceSettings_.isEmpty()) { resourceSettings_ = other.resourceSettings_; bitField0_ = (bitField0_ & ~0x00000400); } else { ensureResourceSettingsIsMutable(); resourceSettings_.addAll(other.resourceSettings_); } onChanged(); } } else { if (!other.resourceSettings_.isEmpty()) { if (resourceSettingsBuilder_.isEmpty()) { resourceSettingsBuilder_.dispose(); resourceSettingsBuilder_ = null; resourceSettings_ = other.resourceSettings_; bitField0_ = (bitField0_ & ~0x00000400); resourceSettingsBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getResourceSettingsFieldBuilder() : null; } else { resourceSettingsBuilder_.addAllMessages(other.resourceSettings_); } } } if (other.kajEnrollmentState_ != 0) { setKajEnrollmentStateValue(other.getKajEnrollmentStateValue()); } if (other.getEnableSovereignControls() != false) { setEnableSovereignControls(other.getEnableSovereignControls()); } if (other.hasSaaEnrollmentResponse()) { mergeSaaEnrollmentResponse(other.getSaaEnrollmentResponse()); } if (!other.compliantButDisallowedServices_.isEmpty()) { if (compliantButDisallowedServices_.isEmpty()) { compliantButDisallowedServices_ = other.compliantButDisallowedServices_; bitField0_ |= 0x00004000; } else { ensureCompliantButDisallowedServicesIsMutable(); compliantButDisallowedServices_.addAll(other.compliantButDisallowedServices_); } onChanged(); } if (other.partner_ != 0) { setPartnerValue(other.getPartnerValue()); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { name_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 10 case 18: { displayName_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000002; break; } // case 18 case 26: { com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo m = input.readMessage( com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.parser(), extensionRegistry); if (resourcesBuilder_ == null) { ensureResourcesIsMutable(); resources_.add(m); } else { resourcesBuilder_.addMessage(m); } break; } // case 26 case 32: { complianceRegime_ = input.readEnum(); bitField0_ |= 0x00000008; break; } // case 32 case 42: { input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000010; break; } // case 42 case 50: { billingAccount_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000020; break; } // case 50 case 74: { etag_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000040; break; } // case 74 case 82: { com.google.protobuf.MapEntry labels__ = input.readMessage( LabelsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); internalGetMutableLabels() .getMutableMap() .put(labels__.getKey(), labels__.getValue()); bitField0_ |= 0x00000080; break; } // case 82 case 106: { provisionedResourcesParent_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000100; break; } // case 106 case 114: { input.readMessage(getKmsSettingsFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000200; break; } // case 114 case 122: { com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings m = input.readMessage( com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.parser(), extensionRegistry); if (resourceSettingsBuilder_ == null) { ensureResourceSettingsIsMutable(); resourceSettings_.add(m); } else { resourceSettingsBuilder_.addMessage(m); } break; } // case 122 case 136: { kajEnrollmentState_ = input.readEnum(); bitField0_ |= 0x00000800; break; } // case 136 case 144: { enableSovereignControls_ = input.readBool(); bitField0_ |= 0x00001000; break; } // case 144 case 162: { input.readMessage( getSaaEnrollmentResponseFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00002000; break; } // case 162 case 194: { java.lang.String s = input.readStringRequireUtf8(); ensureCompliantButDisallowedServicesIsMutable(); compliantButDisallowedServices_.add(s); break; } // case 194 case 200: { partner_ = input.readEnum(); bitField0_ |= 0x00008000; break; } // case 200 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private java.lang.Object name_ = ""; /** * * *
     * Optional. The resource name of the workload.
     * Format:
     * organizations/{organization}/locations/{location}/workloads/{workload}
     *
     * Read-only.
     * 
* * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Optional. The resource name of the workload.
     * Format:
     * organizations/{organization}/locations/{location}/workloads/{workload}
     *
     * Read-only.
     * 
* * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; * * @return The bytes for name. */ public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Optional. The resource name of the workload.
     * Format:
     * organizations/{organization}/locations/{location}/workloads/{workload}
     *
     * Read-only.
     * 
* * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; * * @param value The name to set. * @return This builder for chaining. */ public Builder setName(java.lang.String value) { if (value == null) { throw new NullPointerException(); } name_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
     * Optional. The resource name of the workload.
     * Format:
     * organizations/{organization}/locations/{location}/workloads/{workload}
     *
     * Read-only.
     * 
* * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; * * @return This builder for chaining. */ public Builder clearName() { name_ = getDefaultInstance().getName(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** * * *
     * Optional. The resource name of the workload.
     * Format:
     * organizations/{organization}/locations/{location}/workloads/{workload}
     *
     * Read-only.
     * 
* * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; * * @param value The bytes for name to set. * @return This builder for chaining. */ public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); name_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } private java.lang.Object displayName_ = ""; /** * * *
     * Required. The user-assigned display name of the Workload.
     * When present it must be between 4 to 30 characters.
     * Allowed characters are: lowercase and uppercase letters, numbers,
     * hyphen, and spaces.
     *
     * Example: My Workload
     * 
* * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; * * @return The displayName. */ public java.lang.String getDisplayName() { java.lang.Object ref = displayName_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); displayName_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Required. The user-assigned display name of the Workload.
     * When present it must be between 4 to 30 characters.
     * Allowed characters are: lowercase and uppercase letters, numbers,
     * hyphen, and spaces.
     *
     * Example: My Workload
     * 
* * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; * * @return The bytes for displayName. */ public com.google.protobuf.ByteString getDisplayNameBytes() { java.lang.Object ref = displayName_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); displayName_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Required. The user-assigned display name of the Workload.
     * When present it must be between 4 to 30 characters.
     * Allowed characters are: lowercase and uppercase letters, numbers,
     * hyphen, and spaces.
     *
     * Example: My Workload
     * 
* * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; * * @param value The displayName to set. * @return This builder for chaining. */ public Builder setDisplayName(java.lang.String value) { if (value == null) { throw new NullPointerException(); } displayName_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** * * *
     * Required. The user-assigned display name of the Workload.
     * When present it must be between 4 to 30 characters.
     * Allowed characters are: lowercase and uppercase letters, numbers,
     * hyphen, and spaces.
     *
     * Example: My Workload
     * 
* * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; * * @return This builder for chaining. */ public Builder clearDisplayName() { displayName_ = getDefaultInstance().getDisplayName(); bitField0_ = (bitField0_ & ~0x00000002); onChanged(); return this; } /** * * *
     * Required. The user-assigned display name of the Workload.
     * When present it must be between 4 to 30 characters.
     * Allowed characters are: lowercase and uppercase letters, numbers,
     * hyphen, and spaces.
     *
     * Example: My Workload
     * 
* * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; * * @param value The bytes for displayName to set. * @return This builder for chaining. */ public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); displayName_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } private java.util.List resources_ = java.util.Collections.emptyList(); private void ensureResourcesIsMutable() { if (!((bitField0_ & 0x00000004) != 0)) { resources_ = new java.util.ArrayList( resources_); bitField0_ |= 0x00000004; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.Builder, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfoOrBuilder> resourcesBuilder_; /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public java.util.List getResourcesList() { if (resourcesBuilder_ == null) { return java.util.Collections.unmodifiableList(resources_); } else { return resourcesBuilder_.getMessageList(); } } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public int getResourcesCount() { if (resourcesBuilder_ == null) { return resources_.size(); } else { return resourcesBuilder_.getCount(); } } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo getResources(int index) { if (resourcesBuilder_ == null) { return resources_.get(index); } else { return resourcesBuilder_.getMessage(index); } } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setResources( int index, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo value) { if (resourcesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureResourcesIsMutable(); resources_.set(index, value); onChanged(); } else { resourcesBuilder_.setMessage(index, value); } return this; } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setResources( int index, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.Builder builderForValue) { if (resourcesBuilder_ == null) { ensureResourcesIsMutable(); resources_.set(index, builderForValue.build()); onChanged(); } else { resourcesBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addResources(com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo value) { if (resourcesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureResourcesIsMutable(); resources_.add(value); onChanged(); } else { resourcesBuilder_.addMessage(value); } return this; } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addResources( int index, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo value) { if (resourcesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureResourcesIsMutable(); resources_.add(index, value); onChanged(); } else { resourcesBuilder_.addMessage(index, value); } return this; } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addResources( com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.Builder builderForValue) { if (resourcesBuilder_ == null) { ensureResourcesIsMutable(); resources_.add(builderForValue.build()); onChanged(); } else { resourcesBuilder_.addMessage(builderForValue.build()); } return this; } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addResources( int index, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.Builder builderForValue) { if (resourcesBuilder_ == null) { ensureResourcesIsMutable(); resources_.add(index, builderForValue.build()); onChanged(); } else { resourcesBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addAllResources( java.lang.Iterable values) { if (resourcesBuilder_ == null) { ensureResourcesIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, resources_); onChanged(); } else { resourcesBuilder_.addAllMessages(values); } return this; } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder clearResources() { if (resourcesBuilder_ == null) { resources_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000004); onChanged(); } else { resourcesBuilder_.clear(); } return this; } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder removeResources(int index) { if (resourcesBuilder_ == null) { ensureResourcesIsMutable(); resources_.remove(index); onChanged(); } else { resourcesBuilder_.remove(index); } return this; } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.Builder getResourcesBuilder( int index) { return getResourcesFieldBuilder().getBuilder(index); } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfoOrBuilder getResourcesOrBuilder(int index) { if (resourcesBuilder_ == null) { return resources_.get(index); } else { return resourcesBuilder_.getMessageOrBuilder(index); } } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public java.util.List< ? extends com.google.cloud.assuredworkloads.v1.Workload.ResourceInfoOrBuilder> getResourcesOrBuilderList() { if (resourcesBuilder_ != null) { return resourcesBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(resources_); } } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.Builder addResourcesBuilder() { return getResourcesFieldBuilder() .addBuilder( com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.getDefaultInstance()); } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.Builder addResourcesBuilder( int index) { return getResourcesFieldBuilder() .addBuilder( index, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.getDefaultInstance()); } /** * * *
     * Output only. The resources associated with this workload.
     * These resources will be created when creating the workload.
     * If any of the projects already exist, the workload creation will fail.
     * Always read only.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceInfo resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public java.util.List getResourcesBuilderList() { return getResourcesFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.Builder, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfoOrBuilder> getResourcesFieldBuilder() { if (resourcesBuilder_ == null) { resourcesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfo.Builder, com.google.cloud.assuredworkloads.v1.Workload.ResourceInfoOrBuilder>( resources_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); resources_ = null; } return resourcesBuilder_; } private int complianceRegime_ = 0; /** * * *
     * Required. Immutable. Compliance Regime associated with this workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.ComplianceRegime compliance_regime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The enum numeric value on the wire for complianceRegime. */ @java.lang.Override public int getComplianceRegimeValue() { return complianceRegime_; } /** * * *
     * Required. Immutable. Compliance Regime associated with this workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.ComplianceRegime compliance_regime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @param value The enum numeric value on the wire for complianceRegime to set. * @return This builder for chaining. */ public Builder setComplianceRegimeValue(int value) { complianceRegime_ = value; bitField0_ |= 0x00000008; onChanged(); return this; } /** * * *
     * Required. Immutable. Compliance Regime associated with this workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.ComplianceRegime compliance_regime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The complianceRegime. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.ComplianceRegime getComplianceRegime() { com.google.cloud.assuredworkloads.v1.Workload.ComplianceRegime result = com.google.cloud.assuredworkloads.v1.Workload.ComplianceRegime.forNumber( complianceRegime_); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.ComplianceRegime.UNRECOGNIZED : result; } /** * * *
     * Required. Immutable. Compliance Regime associated with this workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.ComplianceRegime compliance_regime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @param value The complianceRegime to set. * @return This builder for chaining. */ public Builder setComplianceRegime( com.google.cloud.assuredworkloads.v1.Workload.ComplianceRegime value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000008; complianceRegime_ = value.getNumber(); onChanged(); return this; } /** * * *
     * Required. Immutable. Compliance Regime associated with this workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.ComplianceRegime compliance_regime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return This builder for chaining. */ public Builder clearComplianceRegime() { bitField0_ = (bitField0_ & ~0x00000008); complianceRegime_ = 0; onChanged(); return this; } private com.google.protobuf.Timestamp createTime_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createTimeBuilder_; /** * * *
     * Output only. Immutable. The Workload creation timestamp.
     * 
* * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return Whether the createTime field is set. */ public boolean hasCreateTime() { return ((bitField0_ & 0x00000010) != 0); } /** * * *
     * Output only. Immutable. The Workload creation timestamp.
     * 
* * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The createTime. */ public com.google.protobuf.Timestamp getCreateTime() { if (createTimeBuilder_ == null) { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } else { return createTimeBuilder_.getMessage(); } } /** * * *
     * Output only. Immutable. The Workload creation timestamp.
     * 
* * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public Builder setCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { if (value == null) { throw new NullPointerException(); } createTime_ = value; } else { createTimeBuilder_.setMessage(value); } bitField0_ |= 0x00000010; onChanged(); return this; } /** * * *
     * Output only. Immutable. The Workload creation timestamp.
     * 
* * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (createTimeBuilder_ == null) { createTime_ = builderForValue.build(); } else { createTimeBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000010; onChanged(); return this; } /** * * *
     * Output only. Immutable. The Workload creation timestamp.
     * 
* * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { if (((bitField0_ & 0x00000010) != 0) && createTime_ != null && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getCreateTimeBuilder().mergeFrom(value); } else { createTime_ = value; } } else { createTimeBuilder_.mergeFrom(value); } if (createTime_ != null) { bitField0_ |= 0x00000010; onChanged(); } return this; } /** * * *
     * Output only. Immutable. The Workload creation timestamp.
     * 
* * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public Builder clearCreateTime() { bitField0_ = (bitField0_ & ~0x00000010); createTime_ = null; if (createTimeBuilder_ != null) { createTimeBuilder_.dispose(); createTimeBuilder_ = null; } onChanged(); return this; } /** * * *
     * Output only. Immutable. The Workload creation timestamp.
     * 
* * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { bitField0_ |= 0x00000010; onChanged(); return getCreateTimeFieldBuilder().getBuilder(); } /** * * *
     * Output only. Immutable. The Workload creation timestamp.
     * 
* * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { if (createTimeBuilder_ != null) { return createTimeBuilder_.getMessageOrBuilder(); } else { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } } /** * * *
     * Output only. Immutable. The Workload creation timestamp.
     * 
* * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE]; * */ private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> getCreateTimeFieldBuilder() { if (createTimeBuilder_ == null) { createTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( getCreateTime(), getParentForChildren(), isClean()); createTime_ = null; } return createTimeBuilder_; } private java.lang.Object billingAccount_ = ""; /** * * *
     * Optional. The billing account used for the resources which are
     * direct children of workload. This billing account is initially associated
     * with the resources created as part of Workload creation.
     * After the initial creation of these resources, the customer can change
     * the assigned billing account.
     * The resource name has the form
     * `billingAccounts/{billing_account_id}`. For example,
     * `billingAccounts/012345-567890-ABCDEF`.
     * 
* * string billing_account = 6 [(.google.api.field_behavior) = OPTIONAL]; * * @return The billingAccount. */ public java.lang.String getBillingAccount() { java.lang.Object ref = billingAccount_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); billingAccount_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Optional. The billing account used for the resources which are
     * direct children of workload. This billing account is initially associated
     * with the resources created as part of Workload creation.
     * After the initial creation of these resources, the customer can change
     * the assigned billing account.
     * The resource name has the form
     * `billingAccounts/{billing_account_id}`. For example,
     * `billingAccounts/012345-567890-ABCDEF`.
     * 
* * string billing_account = 6 [(.google.api.field_behavior) = OPTIONAL]; * * @return The bytes for billingAccount. */ public com.google.protobuf.ByteString getBillingAccountBytes() { java.lang.Object ref = billingAccount_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); billingAccount_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Optional. The billing account used for the resources which are
     * direct children of workload. This billing account is initially associated
     * with the resources created as part of Workload creation.
     * After the initial creation of these resources, the customer can change
     * the assigned billing account.
     * The resource name has the form
     * `billingAccounts/{billing_account_id}`. For example,
     * `billingAccounts/012345-567890-ABCDEF`.
     * 
* * string billing_account = 6 [(.google.api.field_behavior) = OPTIONAL]; * * @param value The billingAccount to set. * @return This builder for chaining. */ public Builder setBillingAccount(java.lang.String value) { if (value == null) { throw new NullPointerException(); } billingAccount_ = value; bitField0_ |= 0x00000020; onChanged(); return this; } /** * * *
     * Optional. The billing account used for the resources which are
     * direct children of workload. This billing account is initially associated
     * with the resources created as part of Workload creation.
     * After the initial creation of these resources, the customer can change
     * the assigned billing account.
     * The resource name has the form
     * `billingAccounts/{billing_account_id}`. For example,
     * `billingAccounts/012345-567890-ABCDEF`.
     * 
* * string billing_account = 6 [(.google.api.field_behavior) = OPTIONAL]; * * @return This builder for chaining. */ public Builder clearBillingAccount() { billingAccount_ = getDefaultInstance().getBillingAccount(); bitField0_ = (bitField0_ & ~0x00000020); onChanged(); return this; } /** * * *
     * Optional. The billing account used for the resources which are
     * direct children of workload. This billing account is initially associated
     * with the resources created as part of Workload creation.
     * After the initial creation of these resources, the customer can change
     * the assigned billing account.
     * The resource name has the form
     * `billingAccounts/{billing_account_id}`. For example,
     * `billingAccounts/012345-567890-ABCDEF`.
     * 
* * string billing_account = 6 [(.google.api.field_behavior) = OPTIONAL]; * * @param value The bytes for billingAccount to set. * @return This builder for chaining. */ public Builder setBillingAccountBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); billingAccount_ = value; bitField0_ |= 0x00000020; onChanged(); return this; } private java.lang.Object etag_ = ""; /** * * *
     * Optional. ETag of the workload, it is calculated on the basis
     * of the Workload contents. It will be used in Update & Delete operations.
     * 
* * string etag = 9 [(.google.api.field_behavior) = OPTIONAL]; * * @return The etag. */ public java.lang.String getEtag() { java.lang.Object ref = etag_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); etag_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Optional. ETag of the workload, it is calculated on the basis
     * of the Workload contents. It will be used in Update & Delete operations.
     * 
* * string etag = 9 [(.google.api.field_behavior) = OPTIONAL]; * * @return The bytes for etag. */ public com.google.protobuf.ByteString getEtagBytes() { java.lang.Object ref = etag_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); etag_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Optional. ETag of the workload, it is calculated on the basis
     * of the Workload contents. It will be used in Update & Delete operations.
     * 
* * string etag = 9 [(.google.api.field_behavior) = OPTIONAL]; * * @param value The etag to set. * @return This builder for chaining. */ public Builder setEtag(java.lang.String value) { if (value == null) { throw new NullPointerException(); } etag_ = value; bitField0_ |= 0x00000040; onChanged(); return this; } /** * * *
     * Optional. ETag of the workload, it is calculated on the basis
     * of the Workload contents. It will be used in Update & Delete operations.
     * 
* * string etag = 9 [(.google.api.field_behavior) = OPTIONAL]; * * @return This builder for chaining. */ public Builder clearEtag() { etag_ = getDefaultInstance().getEtag(); bitField0_ = (bitField0_ & ~0x00000040); onChanged(); return this; } /** * * *
     * Optional. ETag of the workload, it is calculated on the basis
     * of the Workload contents. It will be used in Update & Delete operations.
     * 
* * string etag = 9 [(.google.api.field_behavior) = OPTIONAL]; * * @param value The bytes for etag to set. * @return This builder for chaining. */ public Builder setEtagBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); etag_ = value; bitField0_ |= 0x00000040; onChanged(); return this; } private com.google.protobuf.MapField labels_; private com.google.protobuf.MapField internalGetLabels() { if (labels_ == null) { return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); } return labels_; } private com.google.protobuf.MapField internalGetMutableLabels() { if (labels_ == null) { labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); } if (!labels_.isMutable()) { labels_ = labels_.copy(); } bitField0_ |= 0x00000080; onChanged(); return labels_; } public int getLabelsCount() { return internalGetLabels().getMap().size(); } /** * * *
     * Optional. Labels applied to the workload.
     * 
* * map<string, string> labels = 10 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override public boolean containsLabels(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } return internalGetLabels().getMap().containsKey(key); } /** Use {@link #getLabelsMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); } /** * * *
     * Optional. Labels applied to the workload.
     * 
* * map<string, string> labels = 10 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } /** * * *
     * Optional. Labels applied to the workload.
     * 
* * map<string, string> labels = 10 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override public /* nullable */ java.lang.String getLabelsOrDefault( java.lang.String key, /* nullable */ java.lang.String defaultValue) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetLabels().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** * * *
     * Optional. Labels applied to the workload.
     * 
* * map<string, string> labels = 10 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override public java.lang.String getLabelsOrThrow(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } java.util.Map map = internalGetLabels().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } return map.get(key); } public Builder clearLabels() { bitField0_ = (bitField0_ & ~0x00000080); internalGetMutableLabels().getMutableMap().clear(); return this; } /** * * *
     * Optional. Labels applied to the workload.
     * 
* * map<string, string> labels = 10 [(.google.api.field_behavior) = OPTIONAL]; */ public Builder removeLabels(java.lang.String key) { if (key == null) { throw new NullPointerException("map key"); } internalGetMutableLabels().getMutableMap().remove(key); return this; } /** Use alternate mutation accessors instead. */ @java.lang.Deprecated public java.util.Map getMutableLabels() { bitField0_ |= 0x00000080; return internalGetMutableLabels().getMutableMap(); } /** * * *
     * Optional. Labels applied to the workload.
     * 
* * map<string, string> labels = 10 [(.google.api.field_behavior) = OPTIONAL]; */ public Builder putLabels(java.lang.String key, java.lang.String value) { if (key == null) { throw new NullPointerException("map key"); } if (value == null) { throw new NullPointerException("map value"); } internalGetMutableLabels().getMutableMap().put(key, value); bitField0_ |= 0x00000080; return this; } /** * * *
     * Optional. Labels applied to the workload.
     * 
* * map<string, string> labels = 10 [(.google.api.field_behavior) = OPTIONAL]; */ public Builder putAllLabels(java.util.Map values) { internalGetMutableLabels().getMutableMap().putAll(values); bitField0_ |= 0x00000080; return this; } private java.lang.Object provisionedResourcesParent_ = ""; /** * * *
     * Input only. The parent resource for the resources managed by this Assured Workload. May
     * be either empty or a folder resource which is a child of the
     * Workload parent. If not specified all resources are created under the
     * parent organization.
     * Format:
     * folders/{folder_id}
     * 
* * string provisioned_resources_parent = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The provisionedResourcesParent. */ public java.lang.String getProvisionedResourcesParent() { java.lang.Object ref = provisionedResourcesParent_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); provisionedResourcesParent_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * Input only. The parent resource for the resources managed by this Assured Workload. May
     * be either empty or a folder resource which is a child of the
     * Workload parent. If not specified all resources are created under the
     * parent organization.
     * Format:
     * folders/{folder_id}
     * 
* * string provisioned_resources_parent = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return The bytes for provisionedResourcesParent. */ public com.google.protobuf.ByteString getProvisionedResourcesParentBytes() { java.lang.Object ref = provisionedResourcesParent_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); provisionedResourcesParent_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * Input only. The parent resource for the resources managed by this Assured Workload. May
     * be either empty or a folder resource which is a child of the
     * Workload parent. If not specified all resources are created under the
     * parent organization.
     * Format:
     * folders/{folder_id}
     * 
* * string provisioned_resources_parent = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @param value The provisionedResourcesParent to set. * @return This builder for chaining. */ public Builder setProvisionedResourcesParent(java.lang.String value) { if (value == null) { throw new NullPointerException(); } provisionedResourcesParent_ = value; bitField0_ |= 0x00000100; onChanged(); return this; } /** * * *
     * Input only. The parent resource for the resources managed by this Assured Workload. May
     * be either empty or a folder resource which is a child of the
     * Workload parent. If not specified all resources are created under the
     * parent organization.
     * Format:
     * folders/{folder_id}
     * 
* * string provisioned_resources_parent = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @return This builder for chaining. */ public Builder clearProvisionedResourcesParent() { provisionedResourcesParent_ = getDefaultInstance().getProvisionedResourcesParent(); bitField0_ = (bitField0_ & ~0x00000100); onChanged(); return this; } /** * * *
     * Input only. The parent resource for the resources managed by this Assured Workload. May
     * be either empty or a folder resource which is a child of the
     * Workload parent. If not specified all resources are created under the
     * parent organization.
     * Format:
     * folders/{folder_id}
     * 
* * string provisioned_resources_parent = 13 [(.google.api.field_behavior) = INPUT_ONLY]; * * * @param value The bytes for provisionedResourcesParent to set. * @return This builder for chaining. */ public Builder setProvisionedResourcesParentBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); provisionedResourcesParent_ = value; bitField0_ |= 0x00000100; onChanged(); return this; } private com.google.cloud.assuredworkloads.v1.Workload.KMSSettings kmsSettings_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.assuredworkloads.v1.Workload.KMSSettings, com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.Builder, com.google.cloud.assuredworkloads.v1.Workload.KMSSettingsOrBuilder> kmsSettingsBuilder_; /** * * *
     * Input only. Settings used to create a CMEK crypto key. When set, a project with a KMS
     * CMEK key is provisioned.
     * This field is deprecated as of Feb 28, 2022.
     * In order to create a Keyring, callers should specify,
     * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KMSSettings kms_settings = 14 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY]; * * * @deprecated google.cloud.assuredworkloads.v1.Workload.kms_settings is deprecated. See * google/cloud/assuredworkloads/v1/assuredworkloads.proto;l=484 * @return Whether the kmsSettings field is set. */ @java.lang.Deprecated public boolean hasKmsSettings() { return ((bitField0_ & 0x00000200) != 0); } /** * * *
     * Input only. Settings used to create a CMEK crypto key. When set, a project with a KMS
     * CMEK key is provisioned.
     * This field is deprecated as of Feb 28, 2022.
     * In order to create a Keyring, callers should specify,
     * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KMSSettings kms_settings = 14 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY]; * * * @deprecated google.cloud.assuredworkloads.v1.Workload.kms_settings is deprecated. See * google/cloud/assuredworkloads/v1/assuredworkloads.proto;l=484 * @return The kmsSettings. */ @java.lang.Deprecated public com.google.cloud.assuredworkloads.v1.Workload.KMSSettings getKmsSettings() { if (kmsSettingsBuilder_ == null) { return kmsSettings_ == null ? com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.getDefaultInstance() : kmsSettings_; } else { return kmsSettingsBuilder_.getMessage(); } } /** * * *
     * Input only. Settings used to create a CMEK crypto key. When set, a project with a KMS
     * CMEK key is provisioned.
     * This field is deprecated as of Feb 28, 2022.
     * In order to create a Keyring, callers should specify,
     * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KMSSettings kms_settings = 14 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY]; * */ @java.lang.Deprecated public Builder setKmsSettings(com.google.cloud.assuredworkloads.v1.Workload.KMSSettings value) { if (kmsSettingsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } kmsSettings_ = value; } else { kmsSettingsBuilder_.setMessage(value); } bitField0_ |= 0x00000200; onChanged(); return this; } /** * * *
     * Input only. Settings used to create a CMEK crypto key. When set, a project with a KMS
     * CMEK key is provisioned.
     * This field is deprecated as of Feb 28, 2022.
     * In order to create a Keyring, callers should specify,
     * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KMSSettings kms_settings = 14 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY]; * */ @java.lang.Deprecated public Builder setKmsSettings( com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.Builder builderForValue) { if (kmsSettingsBuilder_ == null) { kmsSettings_ = builderForValue.build(); } else { kmsSettingsBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000200; onChanged(); return this; } /** * * *
     * Input only. Settings used to create a CMEK crypto key. When set, a project with a KMS
     * CMEK key is provisioned.
     * This field is deprecated as of Feb 28, 2022.
     * In order to create a Keyring, callers should specify,
     * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KMSSettings kms_settings = 14 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY]; * */ @java.lang.Deprecated public Builder mergeKmsSettings( com.google.cloud.assuredworkloads.v1.Workload.KMSSettings value) { if (kmsSettingsBuilder_ == null) { if (((bitField0_ & 0x00000200) != 0) && kmsSettings_ != null && kmsSettings_ != com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.getDefaultInstance()) { getKmsSettingsBuilder().mergeFrom(value); } else { kmsSettings_ = value; } } else { kmsSettingsBuilder_.mergeFrom(value); } if (kmsSettings_ != null) { bitField0_ |= 0x00000200; onChanged(); } return this; } /** * * *
     * Input only. Settings used to create a CMEK crypto key. When set, a project with a KMS
     * CMEK key is provisioned.
     * This field is deprecated as of Feb 28, 2022.
     * In order to create a Keyring, callers should specify,
     * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KMSSettings kms_settings = 14 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY]; * */ @java.lang.Deprecated public Builder clearKmsSettings() { bitField0_ = (bitField0_ & ~0x00000200); kmsSettings_ = null; if (kmsSettingsBuilder_ != null) { kmsSettingsBuilder_.dispose(); kmsSettingsBuilder_ = null; } onChanged(); return this; } /** * * *
     * Input only. Settings used to create a CMEK crypto key. When set, a project with a KMS
     * CMEK key is provisioned.
     * This field is deprecated as of Feb 28, 2022.
     * In order to create a Keyring, callers should specify,
     * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KMSSettings kms_settings = 14 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY]; * */ @java.lang.Deprecated public com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.Builder getKmsSettingsBuilder() { bitField0_ |= 0x00000200; onChanged(); return getKmsSettingsFieldBuilder().getBuilder(); } /** * * *
     * Input only. Settings used to create a CMEK crypto key. When set, a project with a KMS
     * CMEK key is provisioned.
     * This field is deprecated as of Feb 28, 2022.
     * In order to create a Keyring, callers should specify,
     * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KMSSettings kms_settings = 14 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY]; * */ @java.lang.Deprecated public com.google.cloud.assuredworkloads.v1.Workload.KMSSettingsOrBuilder getKmsSettingsOrBuilder() { if (kmsSettingsBuilder_ != null) { return kmsSettingsBuilder_.getMessageOrBuilder(); } else { return kmsSettings_ == null ? com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.getDefaultInstance() : kmsSettings_; } } /** * * *
     * Input only. Settings used to create a CMEK crypto key. When set, a project with a KMS
     * CMEK key is provisioned.
     * This field is deprecated as of Feb 28, 2022.
     * In order to create a Keyring, callers should specify,
     * ENCRYPTION_KEYS_PROJECT or KEYRING in ResourceSettings.resource_type field.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KMSSettings kms_settings = 14 [deprecated = true, (.google.api.field_behavior) = INPUT_ONLY]; * */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.assuredworkloads.v1.Workload.KMSSettings, com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.Builder, com.google.cloud.assuredworkloads.v1.Workload.KMSSettingsOrBuilder> getKmsSettingsFieldBuilder() { if (kmsSettingsBuilder_ == null) { kmsSettingsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.assuredworkloads.v1.Workload.KMSSettings, com.google.cloud.assuredworkloads.v1.Workload.KMSSettings.Builder, com.google.cloud.assuredworkloads.v1.Workload.KMSSettingsOrBuilder>( getKmsSettings(), getParentForChildren(), isClean()); kmsSettings_ = null; } return kmsSettingsBuilder_; } private java.util.List resourceSettings_ = java.util.Collections.emptyList(); private void ensureResourceSettingsIsMutable() { if (!((bitField0_ & 0x00000400) != 0)) { resourceSettings_ = new java.util.ArrayList( resourceSettings_); bitField0_ |= 0x00000400; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.Builder, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettingsOrBuilder> resourceSettingsBuilder_; /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public java.util.List getResourceSettingsList() { if (resourceSettingsBuilder_ == null) { return java.util.Collections.unmodifiableList(resourceSettings_); } else { return resourceSettingsBuilder_.getMessageList(); } } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public int getResourceSettingsCount() { if (resourceSettingsBuilder_ == null) { return resourceSettings_.size(); } else { return resourceSettingsBuilder_.getCount(); } } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings getResourceSettings( int index) { if (resourceSettingsBuilder_ == null) { return resourceSettings_.get(index); } else { return resourceSettingsBuilder_.getMessage(index); } } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public Builder setResourceSettings( int index, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings value) { if (resourceSettingsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureResourceSettingsIsMutable(); resourceSettings_.set(index, value); onChanged(); } else { resourceSettingsBuilder_.setMessage(index, value); } return this; } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public Builder setResourceSettings( int index, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.Builder builderForValue) { if (resourceSettingsBuilder_ == null) { ensureResourceSettingsIsMutable(); resourceSettings_.set(index, builderForValue.build()); onChanged(); } else { resourceSettingsBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public Builder addResourceSettings( com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings value) { if (resourceSettingsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureResourceSettingsIsMutable(); resourceSettings_.add(value); onChanged(); } else { resourceSettingsBuilder_.addMessage(value); } return this; } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public Builder addResourceSettings( int index, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings value) { if (resourceSettingsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureResourceSettingsIsMutable(); resourceSettings_.add(index, value); onChanged(); } else { resourceSettingsBuilder_.addMessage(index, value); } return this; } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public Builder addResourceSettings( com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.Builder builderForValue) { if (resourceSettingsBuilder_ == null) { ensureResourceSettingsIsMutable(); resourceSettings_.add(builderForValue.build()); onChanged(); } else { resourceSettingsBuilder_.addMessage(builderForValue.build()); } return this; } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public Builder addResourceSettings( int index, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.Builder builderForValue) { if (resourceSettingsBuilder_ == null) { ensureResourceSettingsIsMutable(); resourceSettings_.add(index, builderForValue.build()); onChanged(); } else { resourceSettingsBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public Builder addAllResourceSettings( java.lang.Iterable values) { if (resourceSettingsBuilder_ == null) { ensureResourceSettingsIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, resourceSettings_); onChanged(); } else { resourceSettingsBuilder_.addAllMessages(values); } return this; } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public Builder clearResourceSettings() { if (resourceSettingsBuilder_ == null) { resourceSettings_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000400); onChanged(); } else { resourceSettingsBuilder_.clear(); } return this; } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public Builder removeResourceSettings(int index) { if (resourceSettingsBuilder_ == null) { ensureResourceSettingsIsMutable(); resourceSettings_.remove(index); onChanged(); } else { resourceSettingsBuilder_.remove(index); } return this; } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.Builder getResourceSettingsBuilder(int index) { return getResourceSettingsFieldBuilder().getBuilder(index); } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public com.google.cloud.assuredworkloads.v1.Workload.ResourceSettingsOrBuilder getResourceSettingsOrBuilder(int index) { if (resourceSettingsBuilder_ == null) { return resourceSettings_.get(index); } else { return resourceSettingsBuilder_.getMessageOrBuilder(index); } } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public java.util.List< ? extends com.google.cloud.assuredworkloads.v1.Workload.ResourceSettingsOrBuilder> getResourceSettingsOrBuilderList() { if (resourceSettingsBuilder_ != null) { return resourceSettingsBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(resourceSettings_); } } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.Builder addResourceSettingsBuilder() { return getResourceSettingsFieldBuilder() .addBuilder( com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.getDefaultInstance()); } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.Builder addResourceSettingsBuilder(int index) { return getResourceSettingsFieldBuilder() .addBuilder( index, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.getDefaultInstance()); } /** * * *
     * Input only. Resource properties that are used to customize workload resources.
     * These properties (such as custom project id) will be used to create
     * workload resources if possible. This field is optional.
     * 
* * * repeated .google.cloud.assuredworkloads.v1.Workload.ResourceSettings resource_settings = 15 [(.google.api.field_behavior) = INPUT_ONLY]; * */ public java.util.List getResourceSettingsBuilderList() { return getResourceSettingsFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.Builder, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettingsOrBuilder> getResourceSettingsFieldBuilder() { if (resourceSettingsBuilder_ == null) { resourceSettingsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettings.Builder, com.google.cloud.assuredworkloads.v1.Workload.ResourceSettingsOrBuilder>( resourceSettings_, ((bitField0_ & 0x00000400) != 0), getParentForChildren(), isClean()); resourceSettings_ = null; } return resourceSettingsBuilder_; } private int kajEnrollmentState_ = 0; /** * * *
     * Output only. Represents the KAJ enrollment state of the given workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState kaj_enrollment_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The enum numeric value on the wire for kajEnrollmentState. */ @java.lang.Override public int getKajEnrollmentStateValue() { return kajEnrollmentState_; } /** * * *
     * Output only. Represents the KAJ enrollment state of the given workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState kaj_enrollment_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param value The enum numeric value on the wire for kajEnrollmentState to set. * @return This builder for chaining. */ public Builder setKajEnrollmentStateValue(int value) { kajEnrollmentState_ = value; bitField0_ |= 0x00000800; onChanged(); return this; } /** * * *
     * Output only. Represents the KAJ enrollment state of the given workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState kaj_enrollment_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The kajEnrollmentState. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState getKajEnrollmentState() { com.google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState result = com.google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState.forNumber( kajEnrollmentState_); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState.UNRECOGNIZED : result; } /** * * *
     * Output only. Represents the KAJ enrollment state of the given workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState kaj_enrollment_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param value The kajEnrollmentState to set. * @return This builder for chaining. */ public Builder setKajEnrollmentState( com.google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000800; kajEnrollmentState_ = value.getNumber(); onChanged(); return this; } /** * * *
     * Output only. Represents the KAJ enrollment state of the given workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.KajEnrollmentState kaj_enrollment_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return This builder for chaining. */ public Builder clearKajEnrollmentState() { bitField0_ = (bitField0_ & ~0x00000800); kajEnrollmentState_ = 0; onChanged(); return this; } private boolean enableSovereignControls_; /** * * *
     * Optional. Indicates the sovereignty status of the given workload.
     * Currently meant to be used by Europe/Canada customers.
     * 
* * bool enable_sovereign_controls = 18 [(.google.api.field_behavior) = OPTIONAL]; * * @return The enableSovereignControls. */ @java.lang.Override public boolean getEnableSovereignControls() { return enableSovereignControls_; } /** * * *
     * Optional. Indicates the sovereignty status of the given workload.
     * Currently meant to be used by Europe/Canada customers.
     * 
* * bool enable_sovereign_controls = 18 [(.google.api.field_behavior) = OPTIONAL]; * * @param value The enableSovereignControls to set. * @return This builder for chaining. */ public Builder setEnableSovereignControls(boolean value) { enableSovereignControls_ = value; bitField0_ |= 0x00001000; onChanged(); return this; } /** * * *
     * Optional. Indicates the sovereignty status of the given workload.
     * Currently meant to be used by Europe/Canada customers.
     * 
* * bool enable_sovereign_controls = 18 [(.google.api.field_behavior) = OPTIONAL]; * * @return This builder for chaining. */ public Builder clearEnableSovereignControls() { bitField0_ = (bitField0_ & ~0x00001000); enableSovereignControls_ = false; onChanged(); return this; } private com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saaEnrollmentResponse_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.Builder, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponseOrBuilder> saaEnrollmentResponseBuilder_; /** * * *
     * Output only. Represents the SAA enrollment response of the given workload.
     * SAA enrollment response is queried during GetWorkload call.
     * In failure cases, user friendly error message is shown in SAA details page.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saa_enrollment_response = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return Whether the saaEnrollmentResponse field is set. */ public boolean hasSaaEnrollmentResponse() { return ((bitField0_ & 0x00002000) != 0); } /** * * *
     * Output only. Represents the SAA enrollment response of the given workload.
     * SAA enrollment response is queried during GetWorkload call.
     * In failure cases, user friendly error message is shown in SAA details page.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saa_enrollment_response = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The saaEnrollmentResponse. */ public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse getSaaEnrollmentResponse() { if (saaEnrollmentResponseBuilder_ == null) { return saaEnrollmentResponse_ == null ? com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse .getDefaultInstance() : saaEnrollmentResponse_; } else { return saaEnrollmentResponseBuilder_.getMessage(); } } /** * * *
     * Output only. Represents the SAA enrollment response of the given workload.
     * SAA enrollment response is queried during GetWorkload call.
     * In failure cases, user friendly error message is shown in SAA details page.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saa_enrollment_response = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setSaaEnrollmentResponse( com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse value) { if (saaEnrollmentResponseBuilder_ == null) { if (value == null) { throw new NullPointerException(); } saaEnrollmentResponse_ = value; } else { saaEnrollmentResponseBuilder_.setMessage(value); } bitField0_ |= 0x00002000; onChanged(); return this; } /** * * *
     * Output only. Represents the SAA enrollment response of the given workload.
     * SAA enrollment response is queried during GetWorkload call.
     * In failure cases, user friendly error message is shown in SAA details page.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saa_enrollment_response = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setSaaEnrollmentResponse( com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.Builder builderForValue) { if (saaEnrollmentResponseBuilder_ == null) { saaEnrollmentResponse_ = builderForValue.build(); } else { saaEnrollmentResponseBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00002000; onChanged(); return this; } /** * * *
     * Output only. Represents the SAA enrollment response of the given workload.
     * SAA enrollment response is queried during GetWorkload call.
     * In failure cases, user friendly error message is shown in SAA details page.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saa_enrollment_response = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder mergeSaaEnrollmentResponse( com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse value) { if (saaEnrollmentResponseBuilder_ == null) { if (((bitField0_ & 0x00002000) != 0) && saaEnrollmentResponse_ != null && saaEnrollmentResponse_ != com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse .getDefaultInstance()) { getSaaEnrollmentResponseBuilder().mergeFrom(value); } else { saaEnrollmentResponse_ = value; } } else { saaEnrollmentResponseBuilder_.mergeFrom(value); } if (saaEnrollmentResponse_ != null) { bitField0_ |= 0x00002000; onChanged(); } return this; } /** * * *
     * Output only. Represents the SAA enrollment response of the given workload.
     * SAA enrollment response is queried during GetWorkload call.
     * In failure cases, user friendly error message is shown in SAA details page.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saa_enrollment_response = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder clearSaaEnrollmentResponse() { bitField0_ = (bitField0_ & ~0x00002000); saaEnrollmentResponse_ = null; if (saaEnrollmentResponseBuilder_ != null) { saaEnrollmentResponseBuilder_.dispose(); saaEnrollmentResponseBuilder_ = null; } onChanged(); return this; } /** * * *
     * Output only. Represents the SAA enrollment response of the given workload.
     * SAA enrollment response is queried during GetWorkload call.
     * In failure cases, user friendly error message is shown in SAA details page.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saa_enrollment_response = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.Builder getSaaEnrollmentResponseBuilder() { bitField0_ |= 0x00002000; onChanged(); return getSaaEnrollmentResponseFieldBuilder().getBuilder(); } /** * * *
     * Output only. Represents the SAA enrollment response of the given workload.
     * SAA enrollment response is queried during GetWorkload call.
     * In failure cases, user friendly error message is shown in SAA details page.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saa_enrollment_response = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponseOrBuilder getSaaEnrollmentResponseOrBuilder() { if (saaEnrollmentResponseBuilder_ != null) { return saaEnrollmentResponseBuilder_.getMessageOrBuilder(); } else { return saaEnrollmentResponse_ == null ? com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse .getDefaultInstance() : saaEnrollmentResponse_; } } /** * * *
     * Output only. Represents the SAA enrollment response of the given workload.
     * SAA enrollment response is queried during GetWorkload call.
     * In failure cases, user friendly error message is shown in SAA details page.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse saa_enrollment_response = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.Builder, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponseOrBuilder> getSaaEnrollmentResponseFieldBuilder() { if (saaEnrollmentResponseBuilder_ == null) { saaEnrollmentResponseBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponse.Builder, com.google.cloud.assuredworkloads.v1.Workload.SaaEnrollmentResponseOrBuilder>( getSaaEnrollmentResponse(), getParentForChildren(), isClean()); saaEnrollmentResponse_ = null; } return saaEnrollmentResponseBuilder_; } private com.google.protobuf.LazyStringArrayList compliantButDisallowedServices_ = com.google.protobuf.LazyStringArrayList.emptyList(); private void ensureCompliantButDisallowedServicesIsMutable() { if (!compliantButDisallowedServices_.isModifiable()) { compliantButDisallowedServices_ = new com.google.protobuf.LazyStringArrayList(compliantButDisallowedServices_); } bitField0_ |= 0x00004000; } /** * * *
     * Output only. Urls for services which are compliant for this Assured Workload, but which
     * are currently disallowed by the ResourceUsageRestriction org policy.
     * Invoke RestrictAllowedResources endpoint to allow your project developers
     * to use these services in their environment."
     * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return A list containing the compliantButDisallowedServices. */ public com.google.protobuf.ProtocolStringList getCompliantButDisallowedServicesList() { compliantButDisallowedServices_.makeImmutable(); return compliantButDisallowedServices_; } /** * * *
     * Output only. Urls for services which are compliant for this Assured Workload, but which
     * are currently disallowed by the ResourceUsageRestriction org policy.
     * Invoke RestrictAllowedResources endpoint to allow your project developers
     * to use these services in their environment."
     * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The count of compliantButDisallowedServices. */ public int getCompliantButDisallowedServicesCount() { return compliantButDisallowedServices_.size(); } /** * * *
     * Output only. Urls for services which are compliant for this Assured Workload, but which
     * are currently disallowed by the ResourceUsageRestriction org policy.
     * Invoke RestrictAllowedResources endpoint to allow your project developers
     * to use these services in their environment."
     * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. * @return The compliantButDisallowedServices at the given index. */ public java.lang.String getCompliantButDisallowedServices(int index) { return compliantButDisallowedServices_.get(index); } /** * * *
     * Output only. Urls for services which are compliant for this Assured Workload, but which
     * are currently disallowed by the ResourceUsageRestriction org policy.
     * Invoke RestrictAllowedResources endpoint to allow your project developers
     * to use these services in their environment."
     * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. * @return The bytes of the compliantButDisallowedServices at the given index. */ public com.google.protobuf.ByteString getCompliantButDisallowedServicesBytes(int index) { return compliantButDisallowedServices_.getByteString(index); } /** * * *
     * Output only. Urls for services which are compliant for this Assured Workload, but which
     * are currently disallowed by the ResourceUsageRestriction org policy.
     * Invoke RestrictAllowedResources endpoint to allow your project developers
     * to use these services in their environment."
     * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index to set the value at. * @param value The compliantButDisallowedServices to set. * @return This builder for chaining. */ public Builder setCompliantButDisallowedServices(int index, java.lang.String value) { if (value == null) { throw new NullPointerException(); } ensureCompliantButDisallowedServicesIsMutable(); compliantButDisallowedServices_.set(index, value); bitField0_ |= 0x00004000; onChanged(); return this; } /** * * *
     * Output only. Urls for services which are compliant for this Assured Workload, but which
     * are currently disallowed by the ResourceUsageRestriction org policy.
     * Invoke RestrictAllowedResources endpoint to allow your project developers
     * to use these services in their environment."
     * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param value The compliantButDisallowedServices to add. * @return This builder for chaining. */ public Builder addCompliantButDisallowedServices(java.lang.String value) { if (value == null) { throw new NullPointerException(); } ensureCompliantButDisallowedServicesIsMutable(); compliantButDisallowedServices_.add(value); bitField0_ |= 0x00004000; onChanged(); return this; } /** * * *
     * Output only. Urls for services which are compliant for this Assured Workload, but which
     * are currently disallowed by the ResourceUsageRestriction org policy.
     * Invoke RestrictAllowedResources endpoint to allow your project developers
     * to use these services in their environment."
     * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param values The compliantButDisallowedServices to add. * @return This builder for chaining. */ public Builder addAllCompliantButDisallowedServices( java.lang.Iterable values) { ensureCompliantButDisallowedServicesIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll( values, compliantButDisallowedServices_); bitField0_ |= 0x00004000; onChanged(); return this; } /** * * *
     * Output only. Urls for services which are compliant for this Assured Workload, but which
     * are currently disallowed by the ResourceUsageRestriction org policy.
     * Invoke RestrictAllowedResources endpoint to allow your project developers
     * to use these services in their environment."
     * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return This builder for chaining. */ public Builder clearCompliantButDisallowedServices() { compliantButDisallowedServices_ = com.google.protobuf.LazyStringArrayList.emptyList(); bitField0_ = (bitField0_ & ~0x00004000); ; onChanged(); return this; } /** * * *
     * Output only. Urls for services which are compliant for this Assured Workload, but which
     * are currently disallowed by the ResourceUsageRestriction org policy.
     * Invoke RestrictAllowedResources endpoint to allow your project developers
     * to use these services in their environment."
     * 
* * * repeated string compliant_but_disallowed_services = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param value The bytes of the compliantButDisallowedServices to add. * @return This builder for chaining. */ public Builder addCompliantButDisallowedServicesBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); ensureCompliantButDisallowedServicesIsMutable(); compliantButDisallowedServices_.add(value); bitField0_ |= 0x00004000; onChanged(); return this; } private int partner_ = 0; /** * * *
     * Optional. Compliance Regime associated with this workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.Partner partner = 25 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The enum numeric value on the wire for partner. */ @java.lang.Override public int getPartnerValue() { return partner_; } /** * * *
     * Optional. Compliance Regime associated with this workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.Partner partner = 25 [(.google.api.field_behavior) = OPTIONAL]; * * * @param value The enum numeric value on the wire for partner to set. * @return This builder for chaining. */ public Builder setPartnerValue(int value) { partner_ = value; bitField0_ |= 0x00008000; onChanged(); return this; } /** * * *
     * Optional. Compliance Regime associated with this workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.Partner partner = 25 [(.google.api.field_behavior) = OPTIONAL]; * * * @return The partner. */ @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload.Partner getPartner() { com.google.cloud.assuredworkloads.v1.Workload.Partner result = com.google.cloud.assuredworkloads.v1.Workload.Partner.forNumber(partner_); return result == null ? com.google.cloud.assuredworkloads.v1.Workload.Partner.UNRECOGNIZED : result; } /** * * *
     * Optional. Compliance Regime associated with this workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.Partner partner = 25 [(.google.api.field_behavior) = OPTIONAL]; * * * @param value The partner to set. * @return This builder for chaining. */ public Builder setPartner(com.google.cloud.assuredworkloads.v1.Workload.Partner value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00008000; partner_ = value.getNumber(); onChanged(); return this; } /** * * *
     * Optional. Compliance Regime associated with this workload.
     * 
* * * .google.cloud.assuredworkloads.v1.Workload.Partner partner = 25 [(.google.api.field_behavior) = OPTIONAL]; * * * @return This builder for chaining. */ public Builder clearPartner() { bitField0_ = (bitField0_ & ~0x00008000); partner_ = 0; onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.assuredworkloads.v1.Workload) } // @@protoc_insertion_point(class_scope:google.cloud.assuredworkloads.v1.Workload) private static final com.google.cloud.assuredworkloads.v1.Workload DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.assuredworkloads.v1.Workload(); } public static com.google.cloud.assuredworkloads.v1.Workload getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public Workload parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.assuredworkloads.v1.Workload getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy