diff --git a/google-api-grpc/grpc-google-cloud-securitycenter-v1beta1/pom.xml b/google-api-grpc/grpc-google-cloud-securitycenter-v1beta1/pom.xml
new file mode 100644
index 000000000000..64011f63211a
--- /dev/null
+++ b/google-api-grpc/grpc-google-cloud-securitycenter-v1beta1/pom.xml
@@ -0,0 +1,31 @@
+
+ * V1 Beta APIs for Security Center service. + *+ */ +@javax.annotation.Generated( + value = "by gRPC proto compiler (version 1.10.0)", + comments = "Source: google/cloud/securitycenter/v1beta1/securitycenter_service.proto") +public final class SecurityCenterGrpc { + + private SecurityCenterGrpc() {} + + public static final String SERVICE_NAME = "google.cloud.securitycenter.v1beta1.SecurityCenter"; + + // Static method descriptors that strictly reflect the proto. + @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") + @java.lang.Deprecated // Use {@link #getCreateSourceMethod()} instead. + public static final io.grpc.MethodDescriptor
+ * V1 Beta APIs for Security Center service. + *+ */ + public static abstract class SecurityCenterImplBase implements io.grpc.BindableService { + + /** + *
+ * Creates a source. + *+ */ + public void createSource(com.google.cloud.securitycenter.v1beta1.CreateSourceRequest request, + io.grpc.stub.StreamObserver
+ * Creates a finding. The corresponding source must exist for finding creation + * to succeed. + *+ */ + public void createFinding(com.google.cloud.securitycenter.v1beta1.CreateFindingRequest request, + io.grpc.stub.StreamObserver
+ * Gets the access control policy on the specified Source. + *+ */ + public void getIamPolicy(com.google.iam.v1.GetIamPolicyRequest request, + io.grpc.stub.StreamObserver
+ * Gets the settings for an organization. + *+ */ + public void getOrganizationSettings(com.google.cloud.securitycenter.v1beta1.GetOrganizationSettingsRequest request, + io.grpc.stub.StreamObserver
+ * Gets a source. + *+ */ + public void getSource(com.google.cloud.securitycenter.v1beta1.GetSourceRequest request, + io.grpc.stub.StreamObserver
+ * Filters an organization's assets and groups them by their specified + * properties. + *+ */ + public void groupAssets(com.google.cloud.securitycenter.v1beta1.GroupAssetsRequest request, + io.grpc.stub.StreamObserver
+ * Filters an organization or source's findings and groups them by their + * specified properties. + * To group across all sources provide a `-` as the source id. + * Example: /v1beta1/organizations/123/sources/-/findings + *+ */ + public void groupFindings(com.google.cloud.securitycenter.v1beta1.GroupFindingsRequest request, + io.grpc.stub.StreamObserver
+ * Lists an organization's assets. + *+ */ + public void listAssets(com.google.cloud.securitycenter.v1beta1.ListAssetsRequest request, + io.grpc.stub.StreamObserver
+ * Lists an organization or source's findings. + * To list across all sources provide a `-` as the source id. + * Example: /v1beta1/organizations/123/sources/-/findings + *+ */ + public void listFindings(com.google.cloud.securitycenter.v1beta1.ListFindingsRequest request, + io.grpc.stub.StreamObserver
+ * Lists all sources belonging to an organization. + *+ */ + public void listSources(com.google.cloud.securitycenter.v1beta1.ListSourcesRequest request, + io.grpc.stub.StreamObserver
+ * Runs asset discovery. The discovery is tracked with a long-running + * operation. + * This API can only be called with limited frequency for an organization. If + * it is called too frequently the caller will receive a TOO_MANY_REQUESTS + * error. + *+ */ + public void runAssetDiscovery(com.google.cloud.securitycenter.v1beta1.RunAssetDiscoveryRequest request, + io.grpc.stub.StreamObserver
+ * Updates the state of a finding. + *+ */ + public void setFindingState(com.google.cloud.securitycenter.v1beta1.SetFindingStateRequest request, + io.grpc.stub.StreamObserver
+ * Sets the access control policy on the specified Source. + *+ */ + public void setIamPolicy(com.google.iam.v1.SetIamPolicyRequest request, + io.grpc.stub.StreamObserver
+ * Returns the permissions that a caller has on the specified source. + *+ */ + public void testIamPermissions(com.google.iam.v1.TestIamPermissionsRequest request, + io.grpc.stub.StreamObserver
+ * Creates or updates a finding. The corresponding source must exist for a + * finding creation to succeed. + *+ */ + public void updateFinding(com.google.cloud.securitycenter.v1beta1.UpdateFindingRequest request, + io.grpc.stub.StreamObserver
+ * Updates an organization's settings. + *+ */ + public void updateOrganizationSettings(com.google.cloud.securitycenter.v1beta1.UpdateOrganizationSettingsRequest request, + io.grpc.stub.StreamObserver
+ * Updates a source. + *+ */ + public void updateSource(com.google.cloud.securitycenter.v1beta1.UpdateSourceRequest request, + io.grpc.stub.StreamObserver
+ * Updates security marks. + *+ */ + public void updateSecurityMarks(com.google.cloud.securitycenter.v1beta1.UpdateSecurityMarksRequest request, + io.grpc.stub.StreamObserver
+ * V1 Beta APIs for Security Center service. + *+ */ + public static final class SecurityCenterStub extends io.grpc.stub.AbstractStub
+ * Creates a source. + *+ */ + public void createSource(com.google.cloud.securitycenter.v1beta1.CreateSourceRequest request, + io.grpc.stub.StreamObserver
+ * Creates a finding. The corresponding source must exist for finding creation + * to succeed. + *+ */ + public void createFinding(com.google.cloud.securitycenter.v1beta1.CreateFindingRequest request, + io.grpc.stub.StreamObserver
+ * Gets the access control policy on the specified Source. + *+ */ + public void getIamPolicy(com.google.iam.v1.GetIamPolicyRequest request, + io.grpc.stub.StreamObserver
+ * Gets the settings for an organization. + *+ */ + public void getOrganizationSettings(com.google.cloud.securitycenter.v1beta1.GetOrganizationSettingsRequest request, + io.grpc.stub.StreamObserver
+ * Gets a source. + *+ */ + public void getSource(com.google.cloud.securitycenter.v1beta1.GetSourceRequest request, + io.grpc.stub.StreamObserver
+ * Filters an organization's assets and groups them by their specified + * properties. + *+ */ + public void groupAssets(com.google.cloud.securitycenter.v1beta1.GroupAssetsRequest request, + io.grpc.stub.StreamObserver
+ * Filters an organization or source's findings and groups them by their + * specified properties. + * To group across all sources provide a `-` as the source id. + * Example: /v1beta1/organizations/123/sources/-/findings + *+ */ + public void groupFindings(com.google.cloud.securitycenter.v1beta1.GroupFindingsRequest request, + io.grpc.stub.StreamObserver
+ * Lists an organization's assets. + *+ */ + public void listAssets(com.google.cloud.securitycenter.v1beta1.ListAssetsRequest request, + io.grpc.stub.StreamObserver
+ * Lists an organization or source's findings. + * To list across all sources provide a `-` as the source id. + * Example: /v1beta1/organizations/123/sources/-/findings + *+ */ + public void listFindings(com.google.cloud.securitycenter.v1beta1.ListFindingsRequest request, + io.grpc.stub.StreamObserver
+ * Lists all sources belonging to an organization. + *+ */ + public void listSources(com.google.cloud.securitycenter.v1beta1.ListSourcesRequest request, + io.grpc.stub.StreamObserver
+ * Runs asset discovery. The discovery is tracked with a long-running + * operation. + * This API can only be called with limited frequency for an organization. If + * it is called too frequently the caller will receive a TOO_MANY_REQUESTS + * error. + *+ */ + public void runAssetDiscovery(com.google.cloud.securitycenter.v1beta1.RunAssetDiscoveryRequest request, + io.grpc.stub.StreamObserver
+ * Updates the state of a finding. + *+ */ + public void setFindingState(com.google.cloud.securitycenter.v1beta1.SetFindingStateRequest request, + io.grpc.stub.StreamObserver
+ * Sets the access control policy on the specified Source. + *+ */ + public void setIamPolicy(com.google.iam.v1.SetIamPolicyRequest request, + io.grpc.stub.StreamObserver
+ * Returns the permissions that a caller has on the specified source. + *+ */ + public void testIamPermissions(com.google.iam.v1.TestIamPermissionsRequest request, + io.grpc.stub.StreamObserver
+ * Creates or updates a finding. The corresponding source must exist for a + * finding creation to succeed. + *+ */ + public void updateFinding(com.google.cloud.securitycenter.v1beta1.UpdateFindingRequest request, + io.grpc.stub.StreamObserver
+ * Updates an organization's settings. + *+ */ + public void updateOrganizationSettings(com.google.cloud.securitycenter.v1beta1.UpdateOrganizationSettingsRequest request, + io.grpc.stub.StreamObserver
+ * Updates a source. + *+ */ + public void updateSource(com.google.cloud.securitycenter.v1beta1.UpdateSourceRequest request, + io.grpc.stub.StreamObserver
+ * Updates security marks. + *+ */ + public void updateSecurityMarks(com.google.cloud.securitycenter.v1beta1.UpdateSecurityMarksRequest request, + io.grpc.stub.StreamObserver
+ * V1 Beta APIs for Security Center service. + *+ */ + public static final class SecurityCenterBlockingStub extends io.grpc.stub.AbstractStub
+ * Creates a source. + *+ */ + public com.google.cloud.securitycenter.v1beta1.Source createSource(com.google.cloud.securitycenter.v1beta1.CreateSourceRequest request) { + return blockingUnaryCall( + getChannel(), getCreateSourceMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Creates a finding. The corresponding source must exist for finding creation + * to succeed. + *+ */ + public com.google.cloud.securitycenter.v1beta1.Finding createFinding(com.google.cloud.securitycenter.v1beta1.CreateFindingRequest request) { + return blockingUnaryCall( + getChannel(), getCreateFindingMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Gets the access control policy on the specified Source. + *+ */ + public com.google.iam.v1.Policy getIamPolicy(com.google.iam.v1.GetIamPolicyRequest request) { + return blockingUnaryCall( + getChannel(), getGetIamPolicyMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Gets the settings for an organization. + *+ */ + public com.google.cloud.securitycenter.v1beta1.OrganizationSettings getOrganizationSettings(com.google.cloud.securitycenter.v1beta1.GetOrganizationSettingsRequest request) { + return blockingUnaryCall( + getChannel(), getGetOrganizationSettingsMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Gets a source. + *+ */ + public com.google.cloud.securitycenter.v1beta1.Source getSource(com.google.cloud.securitycenter.v1beta1.GetSourceRequest request) { + return blockingUnaryCall( + getChannel(), getGetSourceMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Filters an organization's assets and groups them by their specified + * properties. + *+ */ + public com.google.cloud.securitycenter.v1beta1.GroupAssetsResponse groupAssets(com.google.cloud.securitycenter.v1beta1.GroupAssetsRequest request) { + return blockingUnaryCall( + getChannel(), getGroupAssetsMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Filters an organization or source's findings and groups them by their + * specified properties. + * To group across all sources provide a `-` as the source id. + * Example: /v1beta1/organizations/123/sources/-/findings + *+ */ + public com.google.cloud.securitycenter.v1beta1.GroupFindingsResponse groupFindings(com.google.cloud.securitycenter.v1beta1.GroupFindingsRequest request) { + return blockingUnaryCall( + getChannel(), getGroupFindingsMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Lists an organization's assets. + *+ */ + public com.google.cloud.securitycenter.v1beta1.ListAssetsResponse listAssets(com.google.cloud.securitycenter.v1beta1.ListAssetsRequest request) { + return blockingUnaryCall( + getChannel(), getListAssetsMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Lists an organization or source's findings. + * To list across all sources provide a `-` as the source id. + * Example: /v1beta1/organizations/123/sources/-/findings + *+ */ + public com.google.cloud.securitycenter.v1beta1.ListFindingsResponse listFindings(com.google.cloud.securitycenter.v1beta1.ListFindingsRequest request) { + return blockingUnaryCall( + getChannel(), getListFindingsMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Lists all sources belonging to an organization. + *+ */ + public com.google.cloud.securitycenter.v1beta1.ListSourcesResponse listSources(com.google.cloud.securitycenter.v1beta1.ListSourcesRequest request) { + return blockingUnaryCall( + getChannel(), getListSourcesMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Runs asset discovery. The discovery is tracked with a long-running + * operation. + * This API can only be called with limited frequency for an organization. If + * it is called too frequently the caller will receive a TOO_MANY_REQUESTS + * error. + *+ */ + public com.google.longrunning.Operation runAssetDiscovery(com.google.cloud.securitycenter.v1beta1.RunAssetDiscoveryRequest request) { + return blockingUnaryCall( + getChannel(), getRunAssetDiscoveryMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Updates the state of a finding. + *+ */ + public com.google.cloud.securitycenter.v1beta1.Finding setFindingState(com.google.cloud.securitycenter.v1beta1.SetFindingStateRequest request) { + return blockingUnaryCall( + getChannel(), getSetFindingStateMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Sets the access control policy on the specified Source. + *+ */ + public com.google.iam.v1.Policy setIamPolicy(com.google.iam.v1.SetIamPolicyRequest request) { + return blockingUnaryCall( + getChannel(), getSetIamPolicyMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Returns the permissions that a caller has on the specified source. + *+ */ + public com.google.iam.v1.TestIamPermissionsResponse testIamPermissions(com.google.iam.v1.TestIamPermissionsRequest request) { + return blockingUnaryCall( + getChannel(), getTestIamPermissionsMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Creates or updates a finding. The corresponding source must exist for a + * finding creation to succeed. + *+ */ + public com.google.cloud.securitycenter.v1beta1.Finding updateFinding(com.google.cloud.securitycenter.v1beta1.UpdateFindingRequest request) { + return blockingUnaryCall( + getChannel(), getUpdateFindingMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Updates an organization's settings. + *+ */ + public com.google.cloud.securitycenter.v1beta1.OrganizationSettings updateOrganizationSettings(com.google.cloud.securitycenter.v1beta1.UpdateOrganizationSettingsRequest request) { + return blockingUnaryCall( + getChannel(), getUpdateOrganizationSettingsMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Updates a source. + *+ */ + public com.google.cloud.securitycenter.v1beta1.Source updateSource(com.google.cloud.securitycenter.v1beta1.UpdateSourceRequest request) { + return blockingUnaryCall( + getChannel(), getUpdateSourceMethodHelper(), getCallOptions(), request); + } + + /** + *
+ * Updates security marks. + *+ */ + public com.google.cloud.securitycenter.v1beta1.SecurityMarks updateSecurityMarks(com.google.cloud.securitycenter.v1beta1.UpdateSecurityMarksRequest request) { + return blockingUnaryCall( + getChannel(), getUpdateSecurityMarksMethodHelper(), getCallOptions(), request); + } + } + + /** + *
+ * V1 Beta APIs for Security Center service. + *+ */ + public static final class SecurityCenterFutureStub extends io.grpc.stub.AbstractStub
+ * Creates a source. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Creates a finding. The corresponding source must exist for finding creation + * to succeed. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Gets the access control policy on the specified Source. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Gets the settings for an organization. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Gets a source. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Filters an organization's assets and groups them by their specified + * properties. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Filters an organization or source's findings and groups them by their + * specified properties. + * To group across all sources provide a `-` as the source id. + * Example: /v1beta1/organizations/123/sources/-/findings + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Lists an organization's assets. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Lists an organization or source's findings. + * To list across all sources provide a `-` as the source id. + * Example: /v1beta1/organizations/123/sources/-/findings + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Lists all sources belonging to an organization. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Runs asset discovery. The discovery is tracked with a long-running + * operation. + * This API can only be called with limited frequency for an organization. If + * it is called too frequently the caller will receive a TOO_MANY_REQUESTS + * error. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Updates the state of a finding. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Sets the access control policy on the specified Source. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Returns the permissions that a caller has on the specified source. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Creates or updates a finding. The corresponding source must exist for a + * finding creation to succeed. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Updates an organization's settings. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Updates a source. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Updates security marks. + *+ */ + public com.google.common.util.concurrent.ListenableFuture
+ * Cloud Security Command Center's (Cloud SCC) representation of a Google Cloud + * Platform (GCP) resource. + * The Asset is a Cloud SCC resource that captures information about a single GCP + * resource. All modifications to an Asset are only within the context of Cloud + * SCC and don't affect the referenced GCP resource. + *+ * + * Protobuf type {@code google.cloud.securitycenter.v1beta1.Asset} + */ +public final class Asset extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.securitycenter.v1beta1.Asset) + AssetOrBuilder { +private static final long serialVersionUID = 0L; + // Use Asset.newBuilder() to construct. + private Asset(com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + private Asset() { + name_ = ""; + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private Asset( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + case 18: { + com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.Builder subBuilder = null; + if (securityCenterProperties_ != null) { + subBuilder = securityCenterProperties_.toBuilder(); + } + securityCenterProperties_ = input.readMessage(com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(securityCenterProperties_); + securityCenterProperties_ = subBuilder.buildPartial(); + } + + break; + } + case 58: { + if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { + resourceProperties_ = com.google.protobuf.MapField.newMapField( + ResourcePropertiesDefaultEntryHolder.defaultEntry); + mutable_bitField0_ |= 0x00000004; + } + com.google.protobuf.MapEntry
+ * The full resource name of the GCP resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_name = 1;
+ */
+ java.lang.String getResourceName();
+ /**
+ * + * The full resource name of the GCP resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_name = 1;
+ */
+ com.google.protobuf.ByteString
+ getResourceNameBytes();
+
+ /**
+ * + * The type of the GCP resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Cloud SCC and/or the producer of the resource and is immutable + * after create time. + *+ * + *
string resource_type = 2;
+ */
+ java.lang.String getResourceType();
+ /**
+ * + * The type of the GCP resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Cloud SCC and/or the producer of the resource and is immutable + * after create time. + *+ * + *
string resource_type = 2;
+ */
+ com.google.protobuf.ByteString
+ getResourceTypeBytes();
+
+ /**
+ * + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_parent = 3;
+ */
+ java.lang.String getResourceParent();
+ /**
+ * + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_parent = 3;
+ */
+ com.google.protobuf.ByteString
+ getResourceParentBytes();
+
+ /**
+ * + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_project = 4;
+ */
+ java.lang.String getResourceProject();
+ /**
+ * + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_project = 4;
+ */
+ com.google.protobuf.ByteString
+ getResourceProjectBytes();
+
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ java.util.List+ * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ int getResourceOwnersCount();
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ java.lang.String getResourceOwners(int index);
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ com.google.protobuf.ByteString
+ getResourceOwnersBytes(int index);
+ }
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by Cloud SCC and + * cannot be modified by the user. + *+ * + * Protobuf type {@code google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties} + */ + public static final class SecurityCenterProperties extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties) + SecurityCenterPropertiesOrBuilder { + private static final long serialVersionUID = 0L; + // Use SecurityCenterProperties.newBuilder() to construct. + private SecurityCenterProperties(com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + private SecurityCenterProperties() { + resourceName_ = ""; + resourceType_ = ""; + resourceParent_ = ""; + resourceProject_ = ""; + resourceOwners_ = com.google.protobuf.LazyStringArrayList.EMPTY; + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private SecurityCenterProperties( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: { + java.lang.String s = input.readStringRequireUtf8(); + + resourceName_ = s; + break; + } + case 18: { + java.lang.String s = input.readStringRequireUtf8(); + + resourceType_ = s; + break; + } + case 26: { + java.lang.String s = input.readStringRequireUtf8(); + + resourceParent_ = s; + break; + } + case 34: { + java.lang.String s = input.readStringRequireUtf8(); + + resourceProject_ = s; + break; + } + case 42: { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000010) == 0x00000010)) { + resourceOwners_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000010; + } + resourceOwners_.add(s); + break; + } + default: { + if (!parseUnknownFieldProto3( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException( + e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000010) == 0x00000010)) { + resourceOwners_ = resourceOwners_.getUnmodifiableView(); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.securitycenter.v1beta1.AssetOuterClass.internal_static_google_cloud_securitycenter_v1beta1_Asset_SecurityCenterProperties_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.securitycenter.v1beta1.AssetOuterClass.internal_static_google_cloud_securitycenter_v1beta1_Asset_SecurityCenterProperties_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.class, com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.Builder.class); + } + + private int bitField0_; + public static final int RESOURCE_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object resourceName_; + /** + *
+ * The full resource name of the GCP resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_name = 1;
+ */
+ public java.lang.String getResourceName() {
+ java.lang.Object ref = resourceName_;
+ 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();
+ resourceName_ = s;
+ return s;
+ }
+ }
+ /**
+ * + * The full resource name of the GCP resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_name = 1;
+ */
+ public com.google.protobuf.ByteString
+ getResourceNameBytes() {
+ java.lang.Object ref = resourceName_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ resourceName_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int RESOURCE_TYPE_FIELD_NUMBER = 2;
+ private volatile java.lang.Object resourceType_;
+ /**
+ * + * The type of the GCP resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Cloud SCC and/or the producer of the resource and is immutable + * after create time. + *+ * + *
string resource_type = 2;
+ */
+ public java.lang.String getResourceType() {
+ java.lang.Object ref = resourceType_;
+ 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();
+ resourceType_ = s;
+ return s;
+ }
+ }
+ /**
+ * + * The type of the GCP resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Cloud SCC and/or the producer of the resource and is immutable + * after create time. + *+ * + *
string resource_type = 2;
+ */
+ public com.google.protobuf.ByteString
+ getResourceTypeBytes() {
+ java.lang.Object ref = resourceType_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ resourceType_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int RESOURCE_PARENT_FIELD_NUMBER = 3;
+ private volatile java.lang.Object resourceParent_;
+ /**
+ * + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_parent = 3;
+ */
+ public java.lang.String getResourceParent() {
+ java.lang.Object ref = resourceParent_;
+ 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();
+ resourceParent_ = s;
+ return s;
+ }
+ }
+ /**
+ * + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_parent = 3;
+ */
+ public com.google.protobuf.ByteString
+ getResourceParentBytes() {
+ java.lang.Object ref = resourceParent_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ resourceParent_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int RESOURCE_PROJECT_FIELD_NUMBER = 4;
+ private volatile java.lang.Object resourceProject_;
+ /**
+ * + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_project = 4;
+ */
+ public java.lang.String getResourceProject() {
+ java.lang.Object ref = resourceProject_;
+ 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();
+ resourceProject_ = s;
+ return s;
+ }
+ }
+ /**
+ * + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_project = 4;
+ */
+ public com.google.protobuf.ByteString
+ getResourceProjectBytes() {
+ java.lang.Object ref = resourceProject_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ resourceProject_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int RESOURCE_OWNERS_FIELD_NUMBER = 5;
+ private com.google.protobuf.LazyStringList resourceOwners_;
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public com.google.protobuf.ProtocolStringList
+ getResourceOwnersList() {
+ return resourceOwners_;
+ }
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public int getResourceOwnersCount() {
+ return resourceOwners_.size();
+ }
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public java.lang.String getResourceOwners(int index) {
+ return resourceOwners_.get(index);
+ }
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public com.google.protobuf.ByteString
+ getResourceOwnersBytes(int index) {
+ return resourceOwners_.getByteString(index);
+ }
+
+ 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 (!getResourceNameBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resourceName_);
+ }
+ if (!getResourceTypeBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 2, resourceType_);
+ }
+ if (!getResourceParentBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 3, resourceParent_);
+ }
+ if (!getResourceProjectBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 4, resourceProject_);
+ }
+ for (int i = 0; i < resourceOwners_.size(); i++) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 5, resourceOwners_.getRaw(i));
+ }
+ unknownFields.writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (!getResourceNameBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, resourceName_);
+ }
+ if (!getResourceTypeBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, resourceType_);
+ }
+ if (!getResourceParentBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, resourceParent_);
+ }
+ if (!getResourceProjectBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, resourceProject_);
+ }
+ {
+ int dataSize = 0;
+ for (int i = 0; i < resourceOwners_.size(); i++) {
+ dataSize += computeStringSizeNoTag(resourceOwners_.getRaw(i));
+ }
+ size += dataSize;
+ size += 1 * getResourceOwnersList().size();
+ }
+ size += unknownFields.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.securitycenter.v1beta1.Asset.SecurityCenterProperties)) {
+ return super.equals(obj);
+ }
+ com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties other = (com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties) obj;
+
+ boolean result = true;
+ result = result && getResourceName()
+ .equals(other.getResourceName());
+ result = result && getResourceType()
+ .equals(other.getResourceType());
+ result = result && getResourceParent()
+ .equals(other.getResourceParent());
+ result = result && getResourceProject()
+ .equals(other.getResourceProject());
+ result = result && getResourceOwnersList()
+ .equals(other.getResourceOwnersList());
+ result = result && unknownFields.equals(other.unknownFields);
+ return result;
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ if (memoizedHashCode != 0) {
+ return memoizedHashCode;
+ }
+ int hash = 41;
+ hash = (19 * hash) + getDescriptor().hashCode();
+ hash = (37 * hash) + RESOURCE_NAME_FIELD_NUMBER;
+ hash = (53 * hash) + getResourceName().hashCode();
+ hash = (37 * hash) + RESOURCE_TYPE_FIELD_NUMBER;
+ hash = (53 * hash) + getResourceType().hashCode();
+ hash = (37 * hash) + RESOURCE_PARENT_FIELD_NUMBER;
+ hash = (53 * hash) + getResourceParent().hashCode();
+ hash = (37 * hash) + RESOURCE_PROJECT_FIELD_NUMBER;
+ hash = (53 * hash) + getResourceProject().hashCode();
+ if (getResourceOwnersCount() > 0) {
+ hash = (37 * hash) + RESOURCE_OWNERS_FIELD_NUMBER;
+ hash = (53 * hash) + getResourceOwnersList().hashCode();
+ }
+ hash = (29 * hash) + unknownFields.hashCode();
+ memoizedHashCode = hash;
+ return hash;
+ }
+
+ public static com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties parseFrom(
+ java.nio.ByteBuffer data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties 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.securitycenter.v1beta1.Asset.SecurityCenterProperties parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties 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.securitycenter.v1beta1.Asset.SecurityCenterProperties parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties parseFrom(
+ byte[] data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties parseFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3
+ .parseWithIOException(PARSER, input);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties 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.securitycenter.v1beta1.Asset.SecurityCenterProperties parseDelimitedFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3
+ .parseDelimitedWithIOException(PARSER, input);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties 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.securitycenter.v1beta1.Asset.SecurityCenterProperties parseFrom(
+ com.google.protobuf.CodedInputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3
+ .parseWithIOException(PARSER, input);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties 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.securitycenter.v1beta1.Asset.SecurityCenterProperties 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;
+ }
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by Cloud SCC and + * cannot be modified by the user. + *+ * + * Protobuf type {@code google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder
+ * The full resource name of the GCP resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_name = 1;
+ */
+ public java.lang.String getResourceName() {
+ java.lang.Object ref = resourceName_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs =
+ (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ resourceName_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ * + * The full resource name of the GCP resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_name = 1;
+ */
+ public com.google.protobuf.ByteString
+ getResourceNameBytes() {
+ java.lang.Object ref = resourceName_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ resourceName_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ * + * The full resource name of the GCP resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_name = 1;
+ */
+ public Builder setResourceName(
+ java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ resourceName_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ * + * The full resource name of the GCP resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_name = 1;
+ */
+ public Builder clearResourceName() {
+
+ resourceName_ = getDefaultInstance().getResourceName();
+ onChanged();
+ return this;
+ }
+ /**
+ * + * The full resource name of the GCP resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_name = 1;
+ */
+ public Builder setResourceNameBytes(
+ com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ resourceName_ = value;
+ onChanged();
+ return this;
+ }
+
+ private java.lang.Object resourceType_ = "";
+ /**
+ * + * The type of the GCP resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Cloud SCC and/or the producer of the resource and is immutable + * after create time. + *+ * + *
string resource_type = 2;
+ */
+ public java.lang.String getResourceType() {
+ java.lang.Object ref = resourceType_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs =
+ (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ resourceType_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ * + * The type of the GCP resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Cloud SCC and/or the producer of the resource and is immutable + * after create time. + *+ * + *
string resource_type = 2;
+ */
+ public com.google.protobuf.ByteString
+ getResourceTypeBytes() {
+ java.lang.Object ref = resourceType_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ resourceType_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ * + * The type of the GCP resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Cloud SCC and/or the producer of the resource and is immutable + * after create time. + *+ * + *
string resource_type = 2;
+ */
+ public Builder setResourceType(
+ java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ resourceType_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ * + * The type of the GCP resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Cloud SCC and/or the producer of the resource and is immutable + * after create time. + *+ * + *
string resource_type = 2;
+ */
+ public Builder clearResourceType() {
+
+ resourceType_ = getDefaultInstance().getResourceType();
+ onChanged();
+ return this;
+ }
+ /**
+ * + * The type of the GCP resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Cloud SCC and/or the producer of the resource and is immutable + * after create time. + *+ * + *
string resource_type = 2;
+ */
+ public Builder setResourceTypeBytes(
+ com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ resourceType_ = value;
+ onChanged();
+ return this;
+ }
+
+ private java.lang.Object resourceParent_ = "";
+ /**
+ * + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_parent = 3;
+ */
+ public java.lang.String getResourceParent() {
+ java.lang.Object ref = resourceParent_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs =
+ (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ resourceParent_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ * + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_parent = 3;
+ */
+ public com.google.protobuf.ByteString
+ getResourceParentBytes() {
+ java.lang.Object ref = resourceParent_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ resourceParent_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ * + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_parent = 3;
+ */
+ public Builder setResourceParent(
+ java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ resourceParent_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ * + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_parent = 3;
+ */
+ public Builder clearResourceParent() {
+
+ resourceParent_ = getDefaultInstance().getResourceParent();
+ onChanged();
+ return this;
+ }
+ /**
+ * + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_parent = 3;
+ */
+ public Builder setResourceParentBytes(
+ com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ resourceParent_ = value;
+ onChanged();
+ return this;
+ }
+
+ private java.lang.Object resourceProject_ = "";
+ /**
+ * + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_project = 4;
+ */
+ public java.lang.String getResourceProject() {
+ java.lang.Object ref = resourceProject_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs =
+ (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ resourceProject_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ * + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_project = 4;
+ */
+ public com.google.protobuf.ByteString
+ getResourceProjectBytes() {
+ java.lang.Object ref = resourceProject_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ resourceProject_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ * + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_project = 4;
+ */
+ public Builder setResourceProject(
+ java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ resourceProject_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ * + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_project = 4;
+ */
+ public Builder clearResourceProject() {
+
+ resourceProject_ = getDefaultInstance().getResourceProject();
+ onChanged();
+ return this;
+ }
+ /**
+ * + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + *+ * + *
string resource_project = 4;
+ */
+ public Builder setResourceProjectBytes(
+ com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ resourceProject_ = value;
+ onChanged();
+ return this;
+ }
+
+ private com.google.protobuf.LazyStringList resourceOwners_ = com.google.protobuf.LazyStringArrayList.EMPTY;
+ private void ensureResourceOwnersIsMutable() {
+ if (!((bitField0_ & 0x00000010) == 0x00000010)) {
+ resourceOwners_ = new com.google.protobuf.LazyStringArrayList(resourceOwners_);
+ bitField0_ |= 0x00000010;
+ }
+ }
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public com.google.protobuf.ProtocolStringList
+ getResourceOwnersList() {
+ return resourceOwners_.getUnmodifiableView();
+ }
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public int getResourceOwnersCount() {
+ return resourceOwners_.size();
+ }
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public java.lang.String getResourceOwners(int index) {
+ return resourceOwners_.get(index);
+ }
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public com.google.protobuf.ByteString
+ getResourceOwnersBytes(int index) {
+ return resourceOwners_.getByteString(index);
+ }
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public Builder setResourceOwners(
+ int index, java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureResourceOwnersIsMutable();
+ resourceOwners_.set(index, value);
+ onChanged();
+ return this;
+ }
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public Builder addResourceOwners(
+ java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureResourceOwnersIsMutable();
+ resourceOwners_.add(value);
+ onChanged();
+ return this;
+ }
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public Builder addAllResourceOwners(
+ java.lang.Iterable+ * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public Builder clearResourceOwners() {
+ resourceOwners_ = com.google.protobuf.LazyStringArrayList.EMPTY;
+ bitField0_ = (bitField0_ & ~0x00000010);
+ onChanged();
+ return this;
+ }
+ /**
+ * + * Owners of the Google Cloud resource. + *+ * + *
repeated string resource_owners = 5;
+ */
+ public Builder addResourceOwnersBytes(
+ com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+ ensureResourceOwnersIsMutable();
+ resourceOwners_.add(value);
+ onChanged();
+ return this;
+ }
+ @java.lang.Override
+ public final Builder setUnknownFields(
+ final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.setUnknownFieldsProto3(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.securitycenter.v1beta1.Asset.SecurityCenterProperties)
+ }
+
+ // @@protoc_insertion_point(class_scope:google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties)
+ private static final com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties DEFAULT_INSTANCE;
+ static {
+ DEFAULT_INSTANCE = new com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties();
+ }
+
+ public static com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties getDefaultInstance() {
+ return DEFAULT_INSTANCE;
+ }
+
+ private static final com.google.protobuf.Parser+ * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/123/assets/456". + *+ * + *
string name = 1;
+ */
+ 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;
+ }
+ }
+ /**
+ * + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/123/assets/456". + *+ * + *
string name = 1;
+ */
+ 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 SECURITY_CENTER_PROPERTIES_FIELD_NUMBER = 2;
+ private com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties securityCenterProperties_;
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ public boolean hasSecurityCenterProperties() {
+ return securityCenterProperties_ != null;
+ }
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ public com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties getSecurityCenterProperties() {
+ return securityCenterProperties_ == null ? com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.getDefaultInstance() : securityCenterProperties_;
+ }
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ public com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterPropertiesOrBuilder getSecurityCenterPropertiesOrBuilder() {
+ return getSecurityCenterProperties();
+ }
+
+ public static final int RESOURCE_PROPERTIES_FIELD_NUMBER = 7;
+ private static final class ResourcePropertiesDefaultEntryHolder {
+ static final com.google.protobuf.MapEntry<
+ java.lang.String, com.google.protobuf.Value> defaultEntry =
+ com.google.protobuf.MapEntry
+ .+ * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+
+ public boolean containsResourceProperties(
+ java.lang.String key) {
+ if (key == null) { throw new java.lang.NullPointerException(); }
+ return internalGetResourceProperties().getMap().containsKey(key);
+ }
+ /**
+ * Use {@link #getResourcePropertiesMap()} instead.
+ */
+ @java.lang.Deprecated
+ public java.util.Map+ * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+
+ public java.util.Map+ * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+
+ public com.google.protobuf.Value getResourcePropertiesOrDefault(
+ java.lang.String key,
+ com.google.protobuf.Value defaultValue) {
+ if (key == null) { throw new java.lang.NullPointerException(); }
+ java.util.Map+ * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+
+ public com.google.protobuf.Value getResourcePropertiesOrThrow(
+ java.lang.String key) {
+ if (key == null) { throw new java.lang.NullPointerException(); }
+ java.util.Map+ * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public boolean hasSecurityMarks() {
+ return securityMarks_ != null;
+ }
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public com.google.cloud.securitycenter.v1beta1.SecurityMarks getSecurityMarks() {
+ return securityMarks_ == null ? com.google.cloud.securitycenter.v1beta1.SecurityMarks.getDefaultInstance() : securityMarks_;
+ }
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public com.google.cloud.securitycenter.v1beta1.SecurityMarksOrBuilder getSecurityMarksOrBuilder() {
+ return getSecurityMarks();
+ }
+
+ public static final int CREATE_TIME_FIELD_NUMBER = 9;
+ private com.google.protobuf.Timestamp createTime_;
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ public boolean hasCreateTime() {
+ return createTime_ != null;
+ }
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ public com.google.protobuf.Timestamp getCreateTime() {
+ return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_;
+ }
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() {
+ return getCreateTime();
+ }
+
+ public static final int UPDATE_TIME_FIELD_NUMBER = 10;
+ private com.google.protobuf.Timestamp updateTime_;
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ public boolean hasUpdateTime() {
+ return updateTime_ != null;
+ }
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ public com.google.protobuf.Timestamp getUpdateTime() {
+ return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_;
+ }
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() {
+ return getUpdateTime();
+ }
+
+ 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 (!getNameBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_);
+ }
+ if (securityCenterProperties_ != null) {
+ output.writeMessage(2, getSecurityCenterProperties());
+ }
+ com.google.protobuf.GeneratedMessageV3
+ .serializeStringMapTo(
+ output,
+ internalGetResourceProperties(),
+ ResourcePropertiesDefaultEntryHolder.defaultEntry,
+ 7);
+ if (securityMarks_ != null) {
+ output.writeMessage(8, getSecurityMarks());
+ }
+ if (createTime_ != null) {
+ output.writeMessage(9, getCreateTime());
+ }
+ if (updateTime_ != null) {
+ output.writeMessage(10, getUpdateTime());
+ }
+ unknownFields.writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (!getNameBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_);
+ }
+ if (securityCenterProperties_ != null) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(2, getSecurityCenterProperties());
+ }
+ for (java.util.Map.Entry+ * Cloud Security Command Center's (Cloud SCC) representation of a Google Cloud + * Platform (GCP) resource. + * The Asset is a Cloud SCC resource that captures information about a single GCP + * resource. All modifications to an Asset are only within the context of Cloud + * SCC and don't affect the referenced GCP resource. + *+ * + * Protobuf type {@code google.cloud.securitycenter.v1beta1.Asset} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder
+ * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/123/assets/456". + *+ * + *
string name = 1;
+ */
+ 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;
+ }
+ }
+ /**
+ * + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/123/assets/456". + *+ * + *
string name = 1;
+ */
+ 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;
+ }
+ }
+ /**
+ * + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/123/assets/456". + *+ * + *
string name = 1;
+ */
+ public Builder setName(
+ java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ name_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ * + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/123/assets/456". + *+ * + *
string name = 1;
+ */
+ public Builder clearName() {
+
+ name_ = getDefaultInstance().getName();
+ onChanged();
+ return this;
+ }
+ /**
+ * + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/123/assets/456". + *+ * + *
string name = 1;
+ */
+ public Builder setNameBytes(
+ com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ name_ = value;
+ onChanged();
+ return this;
+ }
+
+ private com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties securityCenterProperties_ = null;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties, com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.Builder, com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterPropertiesOrBuilder> securityCenterPropertiesBuilder_;
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ public boolean hasSecurityCenterProperties() {
+ return securityCenterPropertiesBuilder_ != null || securityCenterProperties_ != null;
+ }
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ public com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties getSecurityCenterProperties() {
+ if (securityCenterPropertiesBuilder_ == null) {
+ return securityCenterProperties_ == null ? com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.getDefaultInstance() : securityCenterProperties_;
+ } else {
+ return securityCenterPropertiesBuilder_.getMessage();
+ }
+ }
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ public Builder setSecurityCenterProperties(com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties value) {
+ if (securityCenterPropertiesBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ securityCenterProperties_ = value;
+ onChanged();
+ } else {
+ securityCenterPropertiesBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ public Builder setSecurityCenterProperties(
+ com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.Builder builderForValue) {
+ if (securityCenterPropertiesBuilder_ == null) {
+ securityCenterProperties_ = builderForValue.build();
+ onChanged();
+ } else {
+ securityCenterPropertiesBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ public Builder mergeSecurityCenterProperties(com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties value) {
+ if (securityCenterPropertiesBuilder_ == null) {
+ if (securityCenterProperties_ != null) {
+ securityCenterProperties_ =
+ com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.newBuilder(securityCenterProperties_).mergeFrom(value).buildPartial();
+ } else {
+ securityCenterProperties_ = value;
+ }
+ onChanged();
+ } else {
+ securityCenterPropertiesBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ public Builder clearSecurityCenterProperties() {
+ if (securityCenterPropertiesBuilder_ == null) {
+ securityCenterProperties_ = null;
+ onChanged();
+ } else {
+ securityCenterProperties_ = null;
+ securityCenterPropertiesBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ public com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.Builder getSecurityCenterPropertiesBuilder() {
+
+ onChanged();
+ return getSecurityCenterPropertiesFieldBuilder().getBuilder();
+ }
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ public com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterPropertiesOrBuilder getSecurityCenterPropertiesOrBuilder() {
+ if (securityCenterPropertiesBuilder_ != null) {
+ return securityCenterPropertiesBuilder_.getMessageOrBuilder();
+ } else {
+ return securityCenterProperties_ == null ?
+ com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.getDefaultInstance() : securityCenterProperties_;
+ }
+ }
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties, com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.Builder, com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterPropertiesOrBuilder>
+ getSecurityCenterPropertiesFieldBuilder() {
+ if (securityCenterPropertiesBuilder_ == null) {
+ securityCenterPropertiesBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties, com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties.Builder, com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterPropertiesOrBuilder>(
+ getSecurityCenterProperties(),
+ getParentForChildren(),
+ isClean());
+ securityCenterProperties_ = null;
+ }
+ return securityCenterPropertiesBuilder_;
+ }
+
+ private com.google.protobuf.MapField<
+ java.lang.String, com.google.protobuf.Value> resourceProperties_;
+ private com.google.protobuf.MapField+ * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+
+ public boolean containsResourceProperties(
+ java.lang.String key) {
+ if (key == null) { throw new java.lang.NullPointerException(); }
+ return internalGetResourceProperties().getMap().containsKey(key);
+ }
+ /**
+ * Use {@link #getResourcePropertiesMap()} instead.
+ */
+ @java.lang.Deprecated
+ public java.util.Map+ * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+
+ public java.util.Map+ * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+
+ public com.google.protobuf.Value getResourcePropertiesOrDefault(
+ java.lang.String key,
+ com.google.protobuf.Value defaultValue) {
+ if (key == null) { throw new java.lang.NullPointerException(); }
+ java.util.Map+ * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+
+ public com.google.protobuf.Value getResourcePropertiesOrThrow(
+ java.lang.String key) {
+ if (key == null) { throw new java.lang.NullPointerException(); }
+ java.util.Map+ * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+
+ public Builder removeResourceProperties(
+ java.lang.String key) {
+ if (key == null) { throw new java.lang.NullPointerException(); }
+ internalGetMutableResourceProperties().getMutableMap()
+ .remove(key);
+ return this;
+ }
+ /**
+ * Use alternate mutation accessors instead.
+ */
+ @java.lang.Deprecated
+ public java.util.Map+ * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+ public Builder putResourceProperties(
+ java.lang.String key,
+ com.google.protobuf.Value value) {
+ if (key == null) { throw new java.lang.NullPointerException(); }
+ if (value == null) { throw new java.lang.NullPointerException(); }
+ internalGetMutableResourceProperties().getMutableMap()
+ .put(key, value);
+ return this;
+ }
+ /**
+ * + * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+
+ public Builder putAllResourceProperties(
+ java.util.Map+ * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public boolean hasSecurityMarks() {
+ return securityMarksBuilder_ != null || securityMarks_ != null;
+ }
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public com.google.cloud.securitycenter.v1beta1.SecurityMarks getSecurityMarks() {
+ if (securityMarksBuilder_ == null) {
+ return securityMarks_ == null ? com.google.cloud.securitycenter.v1beta1.SecurityMarks.getDefaultInstance() : securityMarks_;
+ } else {
+ return securityMarksBuilder_.getMessage();
+ }
+ }
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public Builder setSecurityMarks(com.google.cloud.securitycenter.v1beta1.SecurityMarks value) {
+ if (securityMarksBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ securityMarks_ = value;
+ onChanged();
+ } else {
+ securityMarksBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public Builder setSecurityMarks(
+ com.google.cloud.securitycenter.v1beta1.SecurityMarks.Builder builderForValue) {
+ if (securityMarksBuilder_ == null) {
+ securityMarks_ = builderForValue.build();
+ onChanged();
+ } else {
+ securityMarksBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public Builder mergeSecurityMarks(com.google.cloud.securitycenter.v1beta1.SecurityMarks value) {
+ if (securityMarksBuilder_ == null) {
+ if (securityMarks_ != null) {
+ securityMarks_ =
+ com.google.cloud.securitycenter.v1beta1.SecurityMarks.newBuilder(securityMarks_).mergeFrom(value).buildPartial();
+ } else {
+ securityMarks_ = value;
+ }
+ onChanged();
+ } else {
+ securityMarksBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public Builder clearSecurityMarks() {
+ if (securityMarksBuilder_ == null) {
+ securityMarks_ = null;
+ onChanged();
+ } else {
+ securityMarks_ = null;
+ securityMarksBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public com.google.cloud.securitycenter.v1beta1.SecurityMarks.Builder getSecurityMarksBuilder() {
+
+ onChanged();
+ return getSecurityMarksFieldBuilder().getBuilder();
+ }
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public com.google.cloud.securitycenter.v1beta1.SecurityMarksOrBuilder getSecurityMarksOrBuilder() {
+ if (securityMarksBuilder_ != null) {
+ return securityMarksBuilder_.getMessageOrBuilder();
+ } else {
+ return securityMarks_ == null ?
+ com.google.cloud.securitycenter.v1beta1.SecurityMarks.getDefaultInstance() : securityMarks_;
+ }
+ }
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.securitycenter.v1beta1.SecurityMarks, com.google.cloud.securitycenter.v1beta1.SecurityMarks.Builder, com.google.cloud.securitycenter.v1beta1.SecurityMarksOrBuilder>
+ getSecurityMarksFieldBuilder() {
+ if (securityMarksBuilder_ == null) {
+ securityMarksBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.securitycenter.v1beta1.SecurityMarks, com.google.cloud.securitycenter.v1beta1.SecurityMarks.Builder, com.google.cloud.securitycenter.v1beta1.SecurityMarksOrBuilder>(
+ getSecurityMarks(),
+ getParentForChildren(),
+ isClean());
+ securityMarks_ = null;
+ }
+ return securityMarksBuilder_;
+ }
+
+ private com.google.protobuf.Timestamp createTime_ = null;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createTimeBuilder_;
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ public boolean hasCreateTime() {
+ return createTimeBuilder_ != null || createTime_ != null;
+ }
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ public com.google.protobuf.Timestamp getCreateTime() {
+ if (createTimeBuilder_ == null) {
+ return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_;
+ } else {
+ return createTimeBuilder_.getMessage();
+ }
+ }
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ public Builder setCreateTime(com.google.protobuf.Timestamp value) {
+ if (createTimeBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ createTime_ = value;
+ onChanged();
+ } else {
+ createTimeBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ public Builder setCreateTime(
+ com.google.protobuf.Timestamp.Builder builderForValue) {
+ if (createTimeBuilder_ == null) {
+ createTime_ = builderForValue.build();
+ onChanged();
+ } else {
+ createTimeBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) {
+ if (createTimeBuilder_ == null) {
+ if (createTime_ != null) {
+ createTime_ =
+ com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial();
+ } else {
+ createTime_ = value;
+ }
+ onChanged();
+ } else {
+ createTimeBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ public Builder clearCreateTime() {
+ if (createTimeBuilder_ == null) {
+ createTime_ = null;
+ onChanged();
+ } else {
+ createTime_ = null;
+ createTimeBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() {
+
+ onChanged();
+ return getCreateTimeFieldBuilder().getBuilder();
+ }
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() {
+ if (createTimeBuilder_ != null) {
+ return createTimeBuilder_.getMessageOrBuilder();
+ } else {
+ return createTime_ == null ?
+ com.google.protobuf.Timestamp.getDefaultInstance() : createTime_;
+ }
+ }
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ 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 com.google.protobuf.Timestamp updateTime_ = null;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> updateTimeBuilder_;
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ public boolean hasUpdateTime() {
+ return updateTimeBuilder_ != null || updateTime_ != null;
+ }
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ public com.google.protobuf.Timestamp getUpdateTime() {
+ if (updateTimeBuilder_ == null) {
+ return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_;
+ } else {
+ return updateTimeBuilder_.getMessage();
+ }
+ }
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ public Builder setUpdateTime(com.google.protobuf.Timestamp value) {
+ if (updateTimeBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ updateTime_ = value;
+ onChanged();
+ } else {
+ updateTimeBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ public Builder setUpdateTime(
+ com.google.protobuf.Timestamp.Builder builderForValue) {
+ if (updateTimeBuilder_ == null) {
+ updateTime_ = builderForValue.build();
+ onChanged();
+ } else {
+ updateTimeBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) {
+ if (updateTimeBuilder_ == null) {
+ if (updateTime_ != null) {
+ updateTime_ =
+ com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial();
+ } else {
+ updateTime_ = value;
+ }
+ onChanged();
+ } else {
+ updateTimeBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ public Builder clearUpdateTime() {
+ if (updateTimeBuilder_ == null) {
+ updateTime_ = null;
+ onChanged();
+ } else {
+ updateTime_ = null;
+ updateTimeBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() {
+
+ onChanged();
+ return getUpdateTimeFieldBuilder().getBuilder();
+ }
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() {
+ if (updateTimeBuilder_ != null) {
+ return updateTimeBuilder_.getMessageOrBuilder();
+ } else {
+ return updateTime_ == null ?
+ com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_;
+ }
+ }
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>
+ getUpdateTimeFieldBuilder() {
+ if (updateTimeBuilder_ == null) {
+ updateTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>(
+ getUpdateTime(),
+ getParentForChildren(),
+ isClean());
+ updateTime_ = null;
+ }
+ return updateTimeBuilder_;
+ }
+ @java.lang.Override
+ public final Builder setUnknownFields(
+ final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.setUnknownFieldsProto3(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.securitycenter.v1beta1.Asset)
+ }
+
+ // @@protoc_insertion_point(class_scope:google.cloud.securitycenter.v1beta1.Asset)
+ private static final com.google.cloud.securitycenter.v1beta1.Asset DEFAULT_INSTANCE;
+ static {
+ DEFAULT_INSTANCE = new com.google.cloud.securitycenter.v1beta1.Asset();
+ }
+
+ public static com.google.cloud.securitycenter.v1beta1.Asset getDefaultInstance() {
+ return DEFAULT_INSTANCE;
+ }
+
+ private static final com.google.protobuf.Parser+ * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/123/assets/456". + *+ * + *
string name = 1;
+ */
+ java.lang.String getName();
+ /**
+ * + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/123/assets/456". + *+ * + *
string name = 1;
+ */
+ com.google.protobuf.ByteString
+ getNameBytes();
+
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ boolean hasSecurityCenterProperties();
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties getSecurityCenterProperties();
+ /**
+ * + * Cloud SCC managed properties. These properties are managed by + * Cloud SCC and cannot be modified by the user. + *+ * + *
.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterProperties security_center_properties = 2;
+ */
+ com.google.cloud.securitycenter.v1beta1.Asset.SecurityCenterPropertiesOrBuilder getSecurityCenterPropertiesOrBuilder();
+
+ /**
+ * + * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+ int getResourcePropertiesCount();
+ /**
+ * + * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+ boolean containsResourceProperties(
+ java.lang.String key);
+ /**
+ * Use {@link #getResourcePropertiesMap()} instead.
+ */
+ @java.lang.Deprecated
+ java.util.Map+ * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+ java.util.Map+ * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+
+ com.google.protobuf.Value getResourcePropertiesOrDefault(
+ java.lang.String key,
+ com.google.protobuf.Value defaultValue);
+ /**
+ * + * Resource managed properties. These properties are managed and defined by + * the GCP resource and cannot be modified by the user. + *+ * + *
map<string, .google.protobuf.Value> resource_properties = 7;
+ */
+
+ com.google.protobuf.Value getResourcePropertiesOrThrow(
+ java.lang.String key);
+
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ boolean hasSecurityMarks();
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ com.google.cloud.securitycenter.v1beta1.SecurityMarks getSecurityMarks();
+ /**
+ * + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ com.google.cloud.securitycenter.v1beta1.SecurityMarksOrBuilder getSecurityMarksOrBuilder();
+
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ boolean hasCreateTime();
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ com.google.protobuf.Timestamp getCreateTime();
+ /**
+ * + * The time at which the asset was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 9;
+ */
+ com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder();
+
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ boolean hasUpdateTime();
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ com.google.protobuf.Timestamp getUpdateTime();
+ /**
+ * + * The time at which the asset was last updated, added, or deleted in Cloud + * SCC. + *+ * + *
.google.protobuf.Timestamp update_time = 10;
+ */
+ com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder();
+}
diff --git a/google-api-grpc/proto-google-cloud-securitycenter-v1beta1/src/main/java/com/google/cloud/securitycenter/v1beta1/AssetOuterClass.java b/google-api-grpc/proto-google-cloud-securitycenter-v1beta1/src/main/java/com/google/cloud/securitycenter/v1beta1/AssetOuterClass.java
new file mode 100644
index 000000000000..10c009b6c287
--- /dev/null
+++ b/google-api-grpc/proto-google-cloud-securitycenter-v1beta1/src/main/java/com/google/cloud/securitycenter/v1beta1/AssetOuterClass.java
@@ -0,0 +1,109 @@
+// Generated by the protocol buffer compiler. DO NOT EDIT!
+// source: google/cloud/securitycenter/v1beta1/asset.proto
+
+package com.google.cloud.securitycenter.v1beta1;
+
+public final class AssetOuterClass {
+ private AssetOuterClass() {}
+ public static void registerAllExtensions(
+ com.google.protobuf.ExtensionRegistryLite registry) {
+ }
+
+ public static void registerAllExtensions(
+ com.google.protobuf.ExtensionRegistry registry) {
+ registerAllExtensions(
+ (com.google.protobuf.ExtensionRegistryLite) registry);
+ }
+ static final com.google.protobuf.Descriptors.Descriptor
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_descriptor;
+ static final
+ com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_fieldAccessorTable;
+ static final com.google.protobuf.Descriptors.Descriptor
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_SecurityCenterProperties_descriptor;
+ static final
+ com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_SecurityCenterProperties_fieldAccessorTable;
+ static final com.google.protobuf.Descriptors.Descriptor
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_ResourcePropertiesEntry_descriptor;
+ static final
+ com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_ResourcePropertiesEntry_fieldAccessorTable;
+
+ public static com.google.protobuf.Descriptors.FileDescriptor
+ getDescriptor() {
+ return descriptor;
+ }
+ private static com.google.protobuf.Descriptors.FileDescriptor
+ descriptor;
+ static {
+ java.lang.String[] descriptorData = {
+ "\n/google/cloud/securitycenter/v1beta1/as" +
+ "set.proto\022#google.cloud.securitycenter.v" +
+ "1beta1\032\034google/api/annotations.proto\0328go" +
+ "ogle/cloud/securitycenter/v1beta1/securi" +
+ "ty_marks.proto\032\034google/protobuf/struct.p" +
+ "roto\032\037google/protobuf/timestamp.proto\"\367\004" +
+ "\n\005Asset\022\014\n\004name\030\001 \001(\t\022g\n\032security_center" +
+ "_properties\030\002 \001(\0132C.google.cloud.securit" +
+ "ycenter.v1beta1.Asset.SecurityCenterProp" +
+ "erties\022_\n\023resource_properties\030\007 \003(\0132B.go" +
+ "ogle.cloud.securitycenter.v1beta1.Asset." +
+ "ResourcePropertiesEntry\022J\n\016security_mark" +
+ "s\030\010 \001(\01322.google.cloud.securitycenter.v1" +
+ "beta1.SecurityMarks\022/\n\013create_time\030\t \001(\013" +
+ "2\032.google.protobuf.Timestamp\022/\n\013update_t" +
+ "ime\030\n \001(\0132\032.google.protobuf.Timestamp\032\224\001" +
+ "\n\030SecurityCenterProperties\022\025\n\rresource_n" +
+ "ame\030\001 \001(\t\022\025\n\rresource_type\030\002 \001(\t\022\027\n\017reso" +
+ "urce_parent\030\003 \001(\t\022\030\n\020resource_project\030\004 " +
+ "\001(\t\022\027\n\017resource_owners\030\005 \003(\t\032Q\n\027Resource" +
+ "PropertiesEntry\022\013\n\003key\030\001 \001(\t\022%\n\005value\030\002 " +
+ "\001(\0132\026.google.protobuf.Value:\0028\001B~\n\'com.g" +
+ "oogle.cloud.securitycenter.v1beta1P\001ZQgo" +
+ "ogle.golang.org/genproto/googleapis/clou" +
+ "d/securitycenter/v1beta1;securitycenterb" +
+ "\006proto3"
+ };
+ com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
+ new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() {
+ public com.google.protobuf.ExtensionRegistry assignDescriptors(
+ com.google.protobuf.Descriptors.FileDescriptor root) {
+ descriptor = root;
+ return null;
+ }
+ };
+ com.google.protobuf.Descriptors.FileDescriptor
+ .internalBuildGeneratedFileFrom(descriptorData,
+ new com.google.protobuf.Descriptors.FileDescriptor[] {
+ com.google.api.AnnotationsProto.getDescriptor(),
+ com.google.cloud.securitycenter.v1beta1.SecurityMarksOuterClass.getDescriptor(),
+ com.google.protobuf.StructProto.getDescriptor(),
+ com.google.protobuf.TimestampProto.getDescriptor(),
+ }, assigner);
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_descriptor =
+ getDescriptor().getMessageTypes().get(0);
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_fieldAccessorTable = new
+ com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_descriptor,
+ new java.lang.String[] { "Name", "SecurityCenterProperties", "ResourceProperties", "SecurityMarks", "CreateTime", "UpdateTime", });
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_SecurityCenterProperties_descriptor =
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_descriptor.getNestedTypes().get(0);
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_SecurityCenterProperties_fieldAccessorTable = new
+ com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_SecurityCenterProperties_descriptor,
+ new java.lang.String[] { "ResourceName", "ResourceType", "ResourceParent", "ResourceProject", "ResourceOwners", });
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_ResourcePropertiesEntry_descriptor =
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_descriptor.getNestedTypes().get(1);
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_ResourcePropertiesEntry_fieldAccessorTable = new
+ com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
+ internal_static_google_cloud_securitycenter_v1beta1_Asset_ResourcePropertiesEntry_descriptor,
+ new java.lang.String[] { "Key", "Value", });
+ com.google.api.AnnotationsProto.getDescriptor();
+ com.google.cloud.securitycenter.v1beta1.SecurityMarksOuterClass.getDescriptor();
+ com.google.protobuf.StructProto.getDescriptor();
+ com.google.protobuf.TimestampProto.getDescriptor();
+ }
+
+ // @@protoc_insertion_point(outer_class_scope)
+}
diff --git a/google-api-grpc/proto-google-cloud-securitycenter-v1beta1/src/main/java/com/google/cloud/securitycenter/v1beta1/AssetSecurityMarksName.java b/google-api-grpc/proto-google-cloud-securitycenter-v1beta1/src/main/java/com/google/cloud/securitycenter/v1beta1/AssetSecurityMarksName.java
new file mode 100644
index 000000000000..136ddaadc217
--- /dev/null
+++ b/google-api-grpc/proto-google-cloud-securitycenter-v1beta1/src/main/java/com/google/cloud/securitycenter/v1beta1/AssetSecurityMarksName.java
@@ -0,0 +1,189 @@
+/*
+ * Copyright 2018 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
+ *
+ * http://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.
+ */
+
+package com.google.cloud.securitycenter.v1beta1;
+
+import com.google.common.base.Preconditions;
+import com.google.common.collect.ImmutableMap;
+import com.google.api.pathtemplate.PathTemplate;
+import com.google.api.resourcenames.ResourceName;
+import java.util.Map;
+import java.util.ArrayList;
+import java.util.List;
+
+// AUTO-GENERATED DOCUMENTATION AND CLASS
+@javax.annotation.Generated("by GAPIC protoc plugin")
+public class AssetSecurityMarksName extends SecuritymarksName {
+
+ private static final PathTemplate PATH_TEMPLATE =
+ PathTemplate.createWithoutUrlEncoding("organizations/{organization}/assets/{asset}/securityMarks");
+
+ private volatile Map+ * Request message for creating a finding. + *+ * + * Protobuf type {@code google.cloud.securitycenter.v1beta1.CreateFindingRequest} + */ +public final class CreateFindingRequest extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.securitycenter.v1beta1.CreateFindingRequest) + CreateFindingRequestOrBuilder { +private static final long serialVersionUID = 0L; + // Use CreateFindingRequest.newBuilder() to construct. + private CreateFindingRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + private CreateFindingRequest() { + parent_ = ""; + findingId_ = ""; + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private CreateFindingRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: { + java.lang.String s = input.readStringRequireUtf8(); + + parent_ = s; + break; + } + case 18: { + java.lang.String s = input.readStringRequireUtf8(); + + findingId_ = s; + break; + } + case 26: { + com.google.cloud.securitycenter.v1beta1.Finding.Builder subBuilder = null; + if (finding_ != null) { + subBuilder = finding_.toBuilder(); + } + finding_ = input.readMessage(com.google.cloud.securitycenter.v1beta1.Finding.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(finding_); + finding_ = subBuilder.buildPartial(); + } + + break; + } + default: { + if (!parseUnknownFieldProto3( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException( + e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.securitycenter.v1beta1.SecuritycenterService.internal_static_google_cloud_securitycenter_v1beta1_CreateFindingRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.securitycenter.v1beta1.SecuritycenterService.internal_static_google_cloud_securitycenter_v1beta1_CreateFindingRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.securitycenter.v1beta1.CreateFindingRequest.class, com.google.cloud.securitycenter.v1beta1.CreateFindingRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + *
+ * Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + *+ * + *
string parent = 1;
+ */
+ public java.lang.String getParent() {
+ java.lang.Object ref = parent_;
+ 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();
+ parent_ = s;
+ return s;
+ }
+ }
+ /**
+ * + * Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + *+ * + *
string parent = 1;
+ */
+ public com.google.protobuf.ByteString
+ getParentBytes() {
+ java.lang.Object ref = parent_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ parent_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int FINDING_ID_FIELD_NUMBER = 2;
+ private volatile java.lang.Object findingId_;
+ /**
+ * + * Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + *+ * + *
string finding_id = 2;
+ */
+ public java.lang.String getFindingId() {
+ java.lang.Object ref = findingId_;
+ 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();
+ findingId_ = s;
+ return s;
+ }
+ }
+ /**
+ * + * Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + *+ * + *
string finding_id = 2;
+ */
+ public com.google.protobuf.ByteString
+ getFindingIdBytes() {
+ java.lang.Object ref = findingId_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ findingId_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int FINDING_FIELD_NUMBER = 3;
+ private com.google.cloud.securitycenter.v1beta1.Finding finding_;
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ public boolean hasFinding() {
+ return finding_ != null;
+ }
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ public com.google.cloud.securitycenter.v1beta1.Finding getFinding() {
+ return finding_ == null ? com.google.cloud.securitycenter.v1beta1.Finding.getDefaultInstance() : finding_;
+ }
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ public com.google.cloud.securitycenter.v1beta1.FindingOrBuilder getFindingOrBuilder() {
+ return getFinding();
+ }
+
+ 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 (!getParentBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_);
+ }
+ if (!getFindingIdBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 2, findingId_);
+ }
+ if (finding_ != null) {
+ output.writeMessage(3, getFinding());
+ }
+ unknownFields.writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (!getParentBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_);
+ }
+ if (!getFindingIdBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, findingId_);
+ }
+ if (finding_ != null) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(3, getFinding());
+ }
+ size += unknownFields.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.securitycenter.v1beta1.CreateFindingRequest)) {
+ return super.equals(obj);
+ }
+ com.google.cloud.securitycenter.v1beta1.CreateFindingRequest other = (com.google.cloud.securitycenter.v1beta1.CreateFindingRequest) obj;
+
+ boolean result = true;
+ result = result && getParent()
+ .equals(other.getParent());
+ result = result && getFindingId()
+ .equals(other.getFindingId());
+ result = result && (hasFinding() == other.hasFinding());
+ if (hasFinding()) {
+ result = result && getFinding()
+ .equals(other.getFinding());
+ }
+ result = result && unknownFields.equals(other.unknownFields);
+ return result;
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ if (memoizedHashCode != 0) {
+ return memoizedHashCode;
+ }
+ int hash = 41;
+ hash = (19 * hash) + getDescriptor().hashCode();
+ hash = (37 * hash) + PARENT_FIELD_NUMBER;
+ hash = (53 * hash) + getParent().hashCode();
+ hash = (37 * hash) + FINDING_ID_FIELD_NUMBER;
+ hash = (53 * hash) + getFindingId().hashCode();
+ if (hasFinding()) {
+ hash = (37 * hash) + FINDING_FIELD_NUMBER;
+ hash = (53 * hash) + getFinding().hashCode();
+ }
+ hash = (29 * hash) + unknownFields.hashCode();
+ memoizedHashCode = hash;
+ return hash;
+ }
+
+ public static com.google.cloud.securitycenter.v1beta1.CreateFindingRequest parseFrom(
+ java.nio.ByteBuffer data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateFindingRequest 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.securitycenter.v1beta1.CreateFindingRequest parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateFindingRequest 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.securitycenter.v1beta1.CreateFindingRequest parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateFindingRequest parseFrom(
+ byte[] data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateFindingRequest parseFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3
+ .parseWithIOException(PARSER, input);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateFindingRequest 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.securitycenter.v1beta1.CreateFindingRequest parseDelimitedFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3
+ .parseDelimitedWithIOException(PARSER, input);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateFindingRequest 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.securitycenter.v1beta1.CreateFindingRequest parseFrom(
+ com.google.protobuf.CodedInputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3
+ .parseWithIOException(PARSER, input);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateFindingRequest 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.securitycenter.v1beta1.CreateFindingRequest 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;
+ }
+ /**
+ * + * Request message for creating a finding. + *+ * + * Protobuf type {@code google.cloud.securitycenter.v1beta1.CreateFindingRequest} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder
+ * Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + *+ * + *
string parent = 1;
+ */
+ public java.lang.String getParent() {
+ java.lang.Object ref = parent_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs =
+ (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ parent_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ * + * Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + *+ * + *
string parent = 1;
+ */
+ public com.google.protobuf.ByteString
+ getParentBytes() {
+ java.lang.Object ref = parent_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ parent_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ * + * Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + *+ * + *
string parent = 1;
+ */
+ public Builder setParent(
+ java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ parent_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ * + * Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + *+ * + *
string parent = 1;
+ */
+ public Builder clearParent() {
+
+ parent_ = getDefaultInstance().getParent();
+ onChanged();
+ return this;
+ }
+ /**
+ * + * Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + *+ * + *
string parent = 1;
+ */
+ public Builder setParentBytes(
+ com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ parent_ = value;
+ onChanged();
+ return this;
+ }
+
+ private java.lang.Object findingId_ = "";
+ /**
+ * + * Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + *+ * + *
string finding_id = 2;
+ */
+ public java.lang.String getFindingId() {
+ java.lang.Object ref = findingId_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs =
+ (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ findingId_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ * + * Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + *+ * + *
string finding_id = 2;
+ */
+ public com.google.protobuf.ByteString
+ getFindingIdBytes() {
+ java.lang.Object ref = findingId_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ findingId_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ * + * Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + *+ * + *
string finding_id = 2;
+ */
+ public Builder setFindingId(
+ java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ findingId_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ * + * Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + *+ * + *
string finding_id = 2;
+ */
+ public Builder clearFindingId() {
+
+ findingId_ = getDefaultInstance().getFindingId();
+ onChanged();
+ return this;
+ }
+ /**
+ * + * Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + *+ * + *
string finding_id = 2;
+ */
+ public Builder setFindingIdBytes(
+ com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ findingId_ = value;
+ onChanged();
+ return this;
+ }
+
+ private com.google.cloud.securitycenter.v1beta1.Finding finding_ = null;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.securitycenter.v1beta1.Finding, com.google.cloud.securitycenter.v1beta1.Finding.Builder, com.google.cloud.securitycenter.v1beta1.FindingOrBuilder> findingBuilder_;
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ public boolean hasFinding() {
+ return findingBuilder_ != null || finding_ != null;
+ }
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ public com.google.cloud.securitycenter.v1beta1.Finding getFinding() {
+ if (findingBuilder_ == null) {
+ return finding_ == null ? com.google.cloud.securitycenter.v1beta1.Finding.getDefaultInstance() : finding_;
+ } else {
+ return findingBuilder_.getMessage();
+ }
+ }
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ public Builder setFinding(com.google.cloud.securitycenter.v1beta1.Finding value) {
+ if (findingBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ finding_ = value;
+ onChanged();
+ } else {
+ findingBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ public Builder setFinding(
+ com.google.cloud.securitycenter.v1beta1.Finding.Builder builderForValue) {
+ if (findingBuilder_ == null) {
+ finding_ = builderForValue.build();
+ onChanged();
+ } else {
+ findingBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ public Builder mergeFinding(com.google.cloud.securitycenter.v1beta1.Finding value) {
+ if (findingBuilder_ == null) {
+ if (finding_ != null) {
+ finding_ =
+ com.google.cloud.securitycenter.v1beta1.Finding.newBuilder(finding_).mergeFrom(value).buildPartial();
+ } else {
+ finding_ = value;
+ }
+ onChanged();
+ } else {
+ findingBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ public Builder clearFinding() {
+ if (findingBuilder_ == null) {
+ finding_ = null;
+ onChanged();
+ } else {
+ finding_ = null;
+ findingBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ public com.google.cloud.securitycenter.v1beta1.Finding.Builder getFindingBuilder() {
+
+ onChanged();
+ return getFindingFieldBuilder().getBuilder();
+ }
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ public com.google.cloud.securitycenter.v1beta1.FindingOrBuilder getFindingOrBuilder() {
+ if (findingBuilder_ != null) {
+ return findingBuilder_.getMessageOrBuilder();
+ } else {
+ return finding_ == null ?
+ com.google.cloud.securitycenter.v1beta1.Finding.getDefaultInstance() : finding_;
+ }
+ }
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.securitycenter.v1beta1.Finding, com.google.cloud.securitycenter.v1beta1.Finding.Builder, com.google.cloud.securitycenter.v1beta1.FindingOrBuilder>
+ getFindingFieldBuilder() {
+ if (findingBuilder_ == null) {
+ findingBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.securitycenter.v1beta1.Finding, com.google.cloud.securitycenter.v1beta1.Finding.Builder, com.google.cloud.securitycenter.v1beta1.FindingOrBuilder>(
+ getFinding(),
+ getParentForChildren(),
+ isClean());
+ finding_ = null;
+ }
+ return findingBuilder_;
+ }
+ @java.lang.Override
+ public final Builder setUnknownFields(
+ final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.setUnknownFieldsProto3(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.securitycenter.v1beta1.CreateFindingRequest)
+ }
+
+ // @@protoc_insertion_point(class_scope:google.cloud.securitycenter.v1beta1.CreateFindingRequest)
+ private static final com.google.cloud.securitycenter.v1beta1.CreateFindingRequest DEFAULT_INSTANCE;
+ static {
+ DEFAULT_INSTANCE = new com.google.cloud.securitycenter.v1beta1.CreateFindingRequest();
+ }
+
+ public static com.google.cloud.securitycenter.v1beta1.CreateFindingRequest getDefaultInstance() {
+ return DEFAULT_INSTANCE;
+ }
+
+ private static final com.google.protobuf.Parser+ * Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + *+ * + *
string parent = 1;
+ */
+ java.lang.String getParent();
+ /**
+ * + * Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + *+ * + *
string parent = 1;
+ */
+ com.google.protobuf.ByteString
+ getParentBytes();
+
+ /**
+ * + * Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + *+ * + *
string finding_id = 2;
+ */
+ java.lang.String getFindingId();
+ /**
+ * + * Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + *+ * + *
string finding_id = 2;
+ */
+ com.google.protobuf.ByteString
+ getFindingIdBytes();
+
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ boolean hasFinding();
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ com.google.cloud.securitycenter.v1beta1.Finding getFinding();
+ /**
+ * + * The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding finding = 3;
+ */
+ com.google.cloud.securitycenter.v1beta1.FindingOrBuilder getFindingOrBuilder();
+}
diff --git a/google-api-grpc/proto-google-cloud-securitycenter-v1beta1/src/main/java/com/google/cloud/securitycenter/v1beta1/CreateSourceRequest.java b/google-api-grpc/proto-google-cloud-securitycenter-v1beta1/src/main/java/com/google/cloud/securitycenter/v1beta1/CreateSourceRequest.java
new file mode 100644
index 000000000000..36618e04ee1d
--- /dev/null
+++ b/google-api-grpc/proto-google-cloud-securitycenter-v1beta1/src/main/java/com/google/cloud/securitycenter/v1beta1/CreateSourceRequest.java
@@ -0,0 +1,825 @@
+// Generated by the protocol buffer compiler. DO NOT EDIT!
+// source: google/cloud/securitycenter/v1beta1/securitycenter_service.proto
+
+package com.google.cloud.securitycenter.v1beta1;
+
+/**
+ * + * Request message for creating a source. + *+ * + * Protobuf type {@code google.cloud.securitycenter.v1beta1.CreateSourceRequest} + */ +public final class CreateSourceRequest extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.securitycenter.v1beta1.CreateSourceRequest) + CreateSourceRequestOrBuilder { +private static final long serialVersionUID = 0L; + // Use CreateSourceRequest.newBuilder() to construct. + private CreateSourceRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + private CreateSourceRequest() { + parent_ = ""; + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private CreateSourceRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: { + java.lang.String s = input.readStringRequireUtf8(); + + parent_ = s; + break; + } + case 18: { + com.google.cloud.securitycenter.v1beta1.Source.Builder subBuilder = null; + if (source_ != null) { + subBuilder = source_.toBuilder(); + } + source_ = input.readMessage(com.google.cloud.securitycenter.v1beta1.Source.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(source_); + source_ = subBuilder.buildPartial(); + } + + break; + } + default: { + if (!parseUnknownFieldProto3( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException( + e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.securitycenter.v1beta1.SecuritycenterService.internal_static_google_cloud_securitycenter_v1beta1_CreateSourceRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.securitycenter.v1beta1.SecuritycenterService.internal_static_google_cloud_securitycenter_v1beta1_CreateSourceRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.securitycenter.v1beta1.CreateSourceRequest.class, com.google.cloud.securitycenter.v1beta1.CreateSourceRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + *
+ * Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + *+ * + *
string parent = 1;
+ */
+ public java.lang.String getParent() {
+ java.lang.Object ref = parent_;
+ 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();
+ parent_ = s;
+ return s;
+ }
+ }
+ /**
+ * + * Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + *+ * + *
string parent = 1;
+ */
+ public com.google.protobuf.ByteString
+ getParentBytes() {
+ java.lang.Object ref = parent_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ parent_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int SOURCE_FIELD_NUMBER = 2;
+ private com.google.cloud.securitycenter.v1beta1.Source source_;
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ public boolean hasSource() {
+ return source_ != null;
+ }
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ public com.google.cloud.securitycenter.v1beta1.Source getSource() {
+ return source_ == null ? com.google.cloud.securitycenter.v1beta1.Source.getDefaultInstance() : source_;
+ }
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ public com.google.cloud.securitycenter.v1beta1.SourceOrBuilder getSourceOrBuilder() {
+ return getSource();
+ }
+
+ 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 (!getParentBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_);
+ }
+ if (source_ != null) {
+ output.writeMessage(2, getSource());
+ }
+ unknownFields.writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (!getParentBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_);
+ }
+ if (source_ != null) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(2, getSource());
+ }
+ size += unknownFields.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.securitycenter.v1beta1.CreateSourceRequest)) {
+ return super.equals(obj);
+ }
+ com.google.cloud.securitycenter.v1beta1.CreateSourceRequest other = (com.google.cloud.securitycenter.v1beta1.CreateSourceRequest) obj;
+
+ boolean result = true;
+ result = result && getParent()
+ .equals(other.getParent());
+ result = result && (hasSource() == other.hasSource());
+ if (hasSource()) {
+ result = result && getSource()
+ .equals(other.getSource());
+ }
+ result = result && unknownFields.equals(other.unknownFields);
+ return result;
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ if (memoizedHashCode != 0) {
+ return memoizedHashCode;
+ }
+ int hash = 41;
+ hash = (19 * hash) + getDescriptor().hashCode();
+ hash = (37 * hash) + PARENT_FIELD_NUMBER;
+ hash = (53 * hash) + getParent().hashCode();
+ if (hasSource()) {
+ hash = (37 * hash) + SOURCE_FIELD_NUMBER;
+ hash = (53 * hash) + getSource().hashCode();
+ }
+ hash = (29 * hash) + unknownFields.hashCode();
+ memoizedHashCode = hash;
+ return hash;
+ }
+
+ public static com.google.cloud.securitycenter.v1beta1.CreateSourceRequest parseFrom(
+ java.nio.ByteBuffer data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateSourceRequest 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.securitycenter.v1beta1.CreateSourceRequest parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateSourceRequest 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.securitycenter.v1beta1.CreateSourceRequest parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateSourceRequest parseFrom(
+ byte[] data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateSourceRequest parseFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3
+ .parseWithIOException(PARSER, input);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateSourceRequest 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.securitycenter.v1beta1.CreateSourceRequest parseDelimitedFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3
+ .parseDelimitedWithIOException(PARSER, input);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateSourceRequest 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.securitycenter.v1beta1.CreateSourceRequest parseFrom(
+ com.google.protobuf.CodedInputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3
+ .parseWithIOException(PARSER, input);
+ }
+ public static com.google.cloud.securitycenter.v1beta1.CreateSourceRequest 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.securitycenter.v1beta1.CreateSourceRequest 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;
+ }
+ /**
+ * + * Request message for creating a source. + *+ * + * Protobuf type {@code google.cloud.securitycenter.v1beta1.CreateSourceRequest} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder
+ * Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + *+ * + *
string parent = 1;
+ */
+ public java.lang.String getParent() {
+ java.lang.Object ref = parent_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs =
+ (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ parent_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ * + * Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + *+ * + *
string parent = 1;
+ */
+ public com.google.protobuf.ByteString
+ getParentBytes() {
+ java.lang.Object ref = parent_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ parent_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ * + * Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + *+ * + *
string parent = 1;
+ */
+ public Builder setParent(
+ java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ parent_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ * + * Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + *+ * + *
string parent = 1;
+ */
+ public Builder clearParent() {
+
+ parent_ = getDefaultInstance().getParent();
+ onChanged();
+ return this;
+ }
+ /**
+ * + * Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + *+ * + *
string parent = 1;
+ */
+ public Builder setParentBytes(
+ com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ parent_ = value;
+ onChanged();
+ return this;
+ }
+
+ private com.google.cloud.securitycenter.v1beta1.Source source_ = null;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.securitycenter.v1beta1.Source, com.google.cloud.securitycenter.v1beta1.Source.Builder, com.google.cloud.securitycenter.v1beta1.SourceOrBuilder> sourceBuilder_;
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ public boolean hasSource() {
+ return sourceBuilder_ != null || source_ != null;
+ }
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ public com.google.cloud.securitycenter.v1beta1.Source getSource() {
+ if (sourceBuilder_ == null) {
+ return source_ == null ? com.google.cloud.securitycenter.v1beta1.Source.getDefaultInstance() : source_;
+ } else {
+ return sourceBuilder_.getMessage();
+ }
+ }
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ public Builder setSource(com.google.cloud.securitycenter.v1beta1.Source value) {
+ if (sourceBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ source_ = value;
+ onChanged();
+ } else {
+ sourceBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ public Builder setSource(
+ com.google.cloud.securitycenter.v1beta1.Source.Builder builderForValue) {
+ if (sourceBuilder_ == null) {
+ source_ = builderForValue.build();
+ onChanged();
+ } else {
+ sourceBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ public Builder mergeSource(com.google.cloud.securitycenter.v1beta1.Source value) {
+ if (sourceBuilder_ == null) {
+ if (source_ != null) {
+ source_ =
+ com.google.cloud.securitycenter.v1beta1.Source.newBuilder(source_).mergeFrom(value).buildPartial();
+ } else {
+ source_ = value;
+ }
+ onChanged();
+ } else {
+ sourceBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ public Builder clearSource() {
+ if (sourceBuilder_ == null) {
+ source_ = null;
+ onChanged();
+ } else {
+ source_ = null;
+ sourceBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ public com.google.cloud.securitycenter.v1beta1.Source.Builder getSourceBuilder() {
+
+ onChanged();
+ return getSourceFieldBuilder().getBuilder();
+ }
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ public com.google.cloud.securitycenter.v1beta1.SourceOrBuilder getSourceOrBuilder() {
+ if (sourceBuilder_ != null) {
+ return sourceBuilder_.getMessageOrBuilder();
+ } else {
+ return source_ == null ?
+ com.google.cloud.securitycenter.v1beta1.Source.getDefaultInstance() : source_;
+ }
+ }
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.securitycenter.v1beta1.Source, com.google.cloud.securitycenter.v1beta1.Source.Builder, com.google.cloud.securitycenter.v1beta1.SourceOrBuilder>
+ getSourceFieldBuilder() {
+ if (sourceBuilder_ == null) {
+ sourceBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.securitycenter.v1beta1.Source, com.google.cloud.securitycenter.v1beta1.Source.Builder, com.google.cloud.securitycenter.v1beta1.SourceOrBuilder>(
+ getSource(),
+ getParentForChildren(),
+ isClean());
+ source_ = null;
+ }
+ return sourceBuilder_;
+ }
+ @java.lang.Override
+ public final Builder setUnknownFields(
+ final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.setUnknownFieldsProto3(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.securitycenter.v1beta1.CreateSourceRequest)
+ }
+
+ // @@protoc_insertion_point(class_scope:google.cloud.securitycenter.v1beta1.CreateSourceRequest)
+ private static final com.google.cloud.securitycenter.v1beta1.CreateSourceRequest DEFAULT_INSTANCE;
+ static {
+ DEFAULT_INSTANCE = new com.google.cloud.securitycenter.v1beta1.CreateSourceRequest();
+ }
+
+ public static com.google.cloud.securitycenter.v1beta1.CreateSourceRequest getDefaultInstance() {
+ return DEFAULT_INSTANCE;
+ }
+
+ private static final com.google.protobuf.Parser+ * Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + *+ * + *
string parent = 1;
+ */
+ java.lang.String getParent();
+ /**
+ * + * Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + *+ * + *
string parent = 1;
+ */
+ com.google.protobuf.ByteString
+ getParentBytes();
+
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ boolean hasSource();
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ com.google.cloud.securitycenter.v1beta1.Source getSource();
+ /**
+ * + * The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + *+ * + *
.google.cloud.securitycenter.v1beta1.Source source = 2;
+ */
+ com.google.cloud.securitycenter.v1beta1.SourceOrBuilder getSourceOrBuilder();
+}
diff --git a/google-api-grpc/proto-google-cloud-securitycenter-v1beta1/src/main/java/com/google/cloud/securitycenter/v1beta1/Finding.java b/google-api-grpc/proto-google-cloud-securitycenter-v1beta1/src/main/java/com/google/cloud/securitycenter/v1beta1/Finding.java
new file mode 100644
index 000000000000..5a062bb68bb9
--- /dev/null
+++ b/google-api-grpc/proto-google-cloud-securitycenter-v1beta1/src/main/java/com/google/cloud/securitycenter/v1beta1/Finding.java
@@ -0,0 +1,2621 @@
+// Generated by the protocol buffer compiler. DO NOT EDIT!
+// source: google/cloud/securitycenter/v1beta1/finding.proto
+
+package com.google.cloud.securitycenter.v1beta1;
+
+/**
+ * + * Cloud Security Command Center (Cloud SCC) finding. + * A finding is a record of assessment data (security, risk, health or privacy) + * ingested into Cloud SCC for presentation, notification, analysis, + * policy testing, and enforcement. For example, an XSS vulnerability in an + * App Engine application is a finding. + *+ * + * Protobuf type {@code google.cloud.securitycenter.v1beta1.Finding} + */ +public final class Finding extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.securitycenter.v1beta1.Finding) + FindingOrBuilder { +private static final long serialVersionUID = 0L; + // Use Finding.newBuilder() to construct. + private Finding(com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + private Finding() { + name_ = ""; + parent_ = ""; + resourceName_ = ""; + state_ = 0; + category_ = ""; + externalUri_ = ""; + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private Finding( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + case 18: { + java.lang.String s = input.readStringRequireUtf8(); + + parent_ = s; + break; + } + case 26: { + java.lang.String s = input.readStringRequireUtf8(); + + resourceName_ = s; + break; + } + case 32: { + int rawValue = input.readEnum(); + + state_ = rawValue; + break; + } + case 42: { + java.lang.String s = input.readStringRequireUtf8(); + + category_ = s; + break; + } + case 50: { + java.lang.String s = input.readStringRequireUtf8(); + + externalUri_ = s; + break; + } + case 58: { + if (!((mutable_bitField0_ & 0x00000040) == 0x00000040)) { + sourceProperties_ = com.google.protobuf.MapField.newMapField( + SourcePropertiesDefaultEntryHolder.defaultEntry); + mutable_bitField0_ |= 0x00000040; + } + com.google.protobuf.MapEntry
+ * The state of the finding. + *+ * + * Protobuf enum {@code google.cloud.securitycenter.v1beta1.Finding.State} + */ + public enum State + implements com.google.protobuf.ProtocolMessageEnum { + /** + *
+ * Unspecified state. + *+ * + *
STATE_UNSPECIFIED = 0;
+ */
+ STATE_UNSPECIFIED(0),
+ /**
+ * + * The finding requires attention and has not been addressed yet. + *+ * + *
ACTIVE = 1;
+ */
+ ACTIVE(1),
+ /**
+ * + * The finding has been fixed, triaged as a non-issue or otherwise addressed + * and is no longer active. + *+ * + *
INACTIVE = 2;
+ */
+ INACTIVE(2),
+ UNRECOGNIZED(-1),
+ ;
+
+ /**
+ * + * Unspecified state. + *+ * + *
STATE_UNSPECIFIED = 0;
+ */
+ public static final int STATE_UNSPECIFIED_VALUE = 0;
+ /**
+ * + * The finding requires attention and has not been addressed yet. + *+ * + *
ACTIVE = 1;
+ */
+ public static final int ACTIVE_VALUE = 1;
+ /**
+ * + * The finding has been fixed, triaged as a non-issue or otherwise addressed + * and is no longer active. + *+ * + *
INACTIVE = 2;
+ */
+ public static final int INACTIVE_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;
+ }
+
+ /**
+ * @deprecated Use {@link #forNumber(int)} instead.
+ */
+ @java.lang.Deprecated
+ public static State valueOf(int value) {
+ return forNumber(value);
+ }
+
+ public static State forNumber(int value) {
+ switch (value) {
+ case 0: return STATE_UNSPECIFIED;
+ case 1: return ACTIVE;
+ case 2: return INACTIVE;
+ default: return null;
+ }
+ }
+
+ public static com.google.protobuf.Internal.EnumLiteMap+ * The relative resource name of this finding. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/123/sources/456/findings/789" + *+ * + *
string name = 1;
+ */
+ 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;
+ }
+ }
+ /**
+ * + * The relative resource name of this finding. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/123/sources/456/findings/789" + *+ * + *
string name = 1;
+ */
+ 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 PARENT_FIELD_NUMBER = 2;
+ private volatile java.lang.Object parent_;
+ /**
+ * + * The relative resource name of the source the finding belongs to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. + * For example: + * "organizations/123/sources/456" + *+ * + *
string parent = 2;
+ */
+ public java.lang.String getParent() {
+ java.lang.Object ref = parent_;
+ 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();
+ parent_ = s;
+ return s;
+ }
+ }
+ /**
+ * + * The relative resource name of the source the finding belongs to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. + * For example: + * "organizations/123/sources/456" + *+ * + *
string parent = 2;
+ */
+ public com.google.protobuf.ByteString
+ getParentBytes() {
+ java.lang.Object ref = parent_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ parent_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int RESOURCE_NAME_FIELD_NUMBER = 3;
+ private volatile java.lang.Object resourceName_;
+ /**
+ * + * The full resource name of the Google Cloud Platform (GCP) resource this + * finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * This field is immutable after creation time. + *+ * + *
string resource_name = 3;
+ */
+ public java.lang.String getResourceName() {
+ java.lang.Object ref = resourceName_;
+ 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();
+ resourceName_ = s;
+ return s;
+ }
+ }
+ /**
+ * + * The full resource name of the Google Cloud Platform (GCP) resource this + * finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * This field is immutable after creation time. + *+ * + *
string resource_name = 3;
+ */
+ public com.google.protobuf.ByteString
+ getResourceNameBytes() {
+ java.lang.Object ref = resourceName_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ resourceName_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int STATE_FIELD_NUMBER = 4;
+ private int state_;
+ /**
+ * + * The state of the finding. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding.State state = 4;
+ */
+ public int getStateValue() {
+ return state_;
+ }
+ /**
+ * + * The state of the finding. + *+ * + *
.google.cloud.securitycenter.v1beta1.Finding.State state = 4;
+ */
+ public com.google.cloud.securitycenter.v1beta1.Finding.State getState() {
+ @SuppressWarnings("deprecation")
+ com.google.cloud.securitycenter.v1beta1.Finding.State result = com.google.cloud.securitycenter.v1beta1.Finding.State.valueOf(state_);
+ return result == null ? com.google.cloud.securitycenter.v1beta1.Finding.State.UNRECOGNIZED : result;
+ }
+
+ public static final int CATEGORY_FIELD_NUMBER = 5;
+ private volatile java.lang.Object category_;
+ /**
+ * + * The additional taxonomy group within findings from a give source. + * This field is immutable after creation time. + * Example: "XSS_FLASH_INJECTION" + *+ * + *
string category = 5;
+ */
+ public java.lang.String getCategory() {
+ java.lang.Object ref = category_;
+ 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();
+ category_ = s;
+ return s;
+ }
+ }
+ /**
+ * + * The additional taxonomy group within findings from a give source. + * This field is immutable after creation time. + * Example: "XSS_FLASH_INJECTION" + *+ * + *
string category = 5;
+ */
+ public com.google.protobuf.ByteString
+ getCategoryBytes() {
+ java.lang.Object ref = category_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ category_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int EXTERNAL_URI_FIELD_NUMBER = 6;
+ private volatile java.lang.Object externalUri_;
+ /**
+ * + * The URI that, if available, points to a web page outside of Cloud SCC + * where additional information about the finding can be found. This field is + * guaranteed to be either empty or a well formed URL. + *+ * + *
string external_uri = 6;
+ */
+ public java.lang.String getExternalUri() {
+ java.lang.Object ref = externalUri_;
+ 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();
+ externalUri_ = s;
+ return s;
+ }
+ }
+ /**
+ * + * The URI that, if available, points to a web page outside of Cloud SCC + * where additional information about the finding can be found. This field is + * guaranteed to be either empty or a well formed URL. + *+ * + *
string external_uri = 6;
+ */
+ public com.google.protobuf.ByteString
+ getExternalUriBytes() {
+ java.lang.Object ref = externalUri_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8(
+ (java.lang.String) ref);
+ externalUri_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int SOURCE_PROPERTIES_FIELD_NUMBER = 7;
+ private static final class SourcePropertiesDefaultEntryHolder {
+ static final com.google.protobuf.MapEntry<
+ java.lang.String, com.google.protobuf.Value> defaultEntry =
+ com.google.protobuf.MapEntry
+ .+ * Source specific properties. These properties are managed by the source + * that writes the finding. + *+ * + *
map<string, .google.protobuf.Value> source_properties = 7;
+ */
+
+ public boolean containsSourceProperties(
+ java.lang.String key) {
+ if (key == null) { throw new java.lang.NullPointerException(); }
+ return internalGetSourceProperties().getMap().containsKey(key);
+ }
+ /**
+ * Use {@link #getSourcePropertiesMap()} instead.
+ */
+ @java.lang.Deprecated
+ public java.util.Map+ * Source specific properties. These properties are managed by the source + * that writes the finding. + *+ * + *
map<string, .google.protobuf.Value> source_properties = 7;
+ */
+
+ public java.util.Map+ * Source specific properties. These properties are managed by the source + * that writes the finding. + *+ * + *
map<string, .google.protobuf.Value> source_properties = 7;
+ */
+
+ public com.google.protobuf.Value getSourcePropertiesOrDefault(
+ java.lang.String key,
+ com.google.protobuf.Value defaultValue) {
+ if (key == null) { throw new java.lang.NullPointerException(); }
+ java.util.Map+ * Source specific properties. These properties are managed by the source + * that writes the finding. + *+ * + *
map<string, .google.protobuf.Value> source_properties = 7;
+ */
+
+ public com.google.protobuf.Value getSourcePropertiesOrThrow(
+ java.lang.String key) {
+ if (key == null) { throw new java.lang.NullPointerException(); }
+ java.util.Map+ * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public boolean hasSecurityMarks() {
+ return securityMarks_ != null;
+ }
+ /**
+ * + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public com.google.cloud.securitycenter.v1beta1.SecurityMarks getSecurityMarks() {
+ return securityMarks_ == null ? com.google.cloud.securitycenter.v1beta1.SecurityMarks.getDefaultInstance() : securityMarks_;
+ }
+ /**
+ * + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + *+ * + *
.google.cloud.securitycenter.v1beta1.SecurityMarks security_marks = 8;
+ */
+ public com.google.cloud.securitycenter.v1beta1.SecurityMarksOrBuilder getSecurityMarksOrBuilder() {
+ return getSecurityMarks();
+ }
+
+ public static final int EVENT_TIME_FIELD_NUMBER = 9;
+ private com.google.protobuf.Timestamp eventTime_;
+ /**
+ * + * The time at which the event took place. For example, if the finding + * represents an open firewall it would capture the time the open firewall was + * detected. + *+ * + *
.google.protobuf.Timestamp event_time = 9;
+ */
+ public boolean hasEventTime() {
+ return eventTime_ != null;
+ }
+ /**
+ * + * The time at which the event took place. For example, if the finding + * represents an open firewall it would capture the time the open firewall was + * detected. + *+ * + *
.google.protobuf.Timestamp event_time = 9;
+ */
+ public com.google.protobuf.Timestamp getEventTime() {
+ return eventTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : eventTime_;
+ }
+ /**
+ * + * The time at which the event took place. For example, if the finding + * represents an open firewall it would capture the time the open firewall was + * detected. + *+ * + *
.google.protobuf.Timestamp event_time = 9;
+ */
+ public com.google.protobuf.TimestampOrBuilder getEventTimeOrBuilder() {
+ return getEventTime();
+ }
+
+ public static final int CREATE_TIME_FIELD_NUMBER = 10;
+ private com.google.protobuf.Timestamp createTime_;
+ /**
+ * + * The time at which the finding was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 10;
+ */
+ public boolean hasCreateTime() {
+ return createTime_ != null;
+ }
+ /**
+ * + * The time at which the finding was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 10;
+ */
+ public com.google.protobuf.Timestamp getCreateTime() {
+ return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_;
+ }
+ /**
+ * + * The time at which the finding was created in Cloud SCC. + *+ * + *
.google.protobuf.Timestamp create_time = 10;
+ */
+ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() {
+ return getCreateTime();
+ }
+
+ 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 (!getNameBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_);
+ }
+ if (!getParentBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 2, parent_);
+ }
+ if (!getResourceNameBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 3, resourceName_);
+ }
+ if (state_ != com.google.cloud.securitycenter.v1beta1.Finding.State.STATE_UNSPECIFIED.getNumber()) {
+ output.writeEnum(4, state_);
+ }
+ if (!getCategoryBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 5, category_);
+ }
+ if (!getExternalUriBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 6, externalUri_);
+ }
+ com.google.protobuf.GeneratedMessageV3
+ .serializeStringMapTo(
+ output,
+ internalGetSourceProperties(),
+ SourcePropertiesDefaultEntryHolder.defaultEntry,
+ 7);
+ if (securityMarks_ != null) {
+ output.writeMessage(8, getSecurityMarks());
+ }
+ if (eventTime_ != null) {
+ output.writeMessage(9, getEventTime());
+ }
+ if (createTime_ != null) {
+ output.writeMessage(10, getCreateTime());
+ }
+ unknownFields.writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (!getNameBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_);
+ }
+ if (!getParentBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, parent_);
+ }
+ if (!getResourceNameBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, resourceName_);
+ }
+ if (state_ != com.google.cloud.securitycenter.v1beta1.Finding.State.STATE_UNSPECIFIED.getNumber()) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeEnumSize(4, state_);
+ }
+ if (!getCategoryBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, category_);
+ }
+ if (!getExternalUriBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, externalUri_);
+ }
+ for (java.util.Map.Entry