From ceda307047f38657b1966037adc9ee72aae52130 Mon Sep 17 00:00:00 2001 From: Cody Oss <6331106+codyoss@users.noreply.github.com> Date: Mon, 4 Nov 2019 10:47:46 -0700 Subject: [PATCH] feat: make repo releasable, add parent/bom (#1) --- .github/ISSUE_TEMPLATE/bug_report.md | 51 + .github/ISSUE_TEMPLATE/feature_request.md | 21 + .github/ISSUE_TEMPLATE/support_request.md | 7 + .github/PULL_REQUEST_TEMPLATE.md | 1 + .github/release-please.yml | 1 + .gitignore | 45 + .kokoro/build.bat | 3 + .kokoro/build.sh | 60 + .kokoro/coerce_logs.sh | 38 + .kokoro/common.cfg | 13 + .kokoro/continuous/common.cfg | 25 + .kokoro/continuous/dependencies.cfg | 12 + .kokoro/continuous/integration.cfg | 7 + .kokoro/continuous/java11.cfg | 7 + .kokoro/continuous/java7.cfg | 7 + .kokoro/continuous/java8-osx.cfg | 3 + .kokoro/continuous/java8-win.cfg | 3 + .kokoro/continuous/java8.cfg | 7 + .kokoro/continuous/lint.cfg | 13 + .kokoro/continuous/propose_release.cfg | 53 + .kokoro/continuous/propose_release.sh | 29 + .kokoro/dependencies.sh | 27 + .kokoro/linkage-monitor.sh | 33 + .kokoro/nightly/common.cfg | 25 + .kokoro/nightly/dependencies.cfg | 12 + .kokoro/nightly/integration.cfg | 7 + .kokoro/nightly/java11.cfg | 7 + .kokoro/nightly/java7.cfg | 7 + .kokoro/nightly/java8-osx.cfg | 3 + .kokoro/nightly/java8-win.cfg | 3 + .kokoro/nightly/java8.cfg | 7 + .kokoro/nightly/lint.cfg | 13 + .kokoro/presubmit/clirr.cfg | 13 + .kokoro/presubmit/common.cfg | 34 + .kokoro/presubmit/dependencies.cfg | 12 + .kokoro/presubmit/integration.cfg | 31 + .kokoro/presubmit/java11.cfg | 7 + .kokoro/presubmit/java7.cfg | 7 + .kokoro/presubmit/java8-osx.cfg | 3 + .kokoro/presubmit/java8-win.cfg | 3 + .kokoro/presubmit/java8.cfg | 7 + .kokoro/presubmit/linkage-monitor.cfg | 12 + .kokoro/presubmit/lint.cfg | 13 + .kokoro/release/bump_snapshot.cfg | 53 + .kokoro/release/bump_snapshot.sh | 30 + .kokoro/release/common.cfg | 49 + .kokoro/release/common.sh | 50 + .kokoro/release/drop.cfg | 9 + .kokoro/release/drop.sh | 32 + .kokoro/release/promote.cfg | 10 + .kokoro/release/promote.sh | 34 + .kokoro/release/publish_javadoc.cfg | 19 + .kokoro/release/publish_javadoc.sh | 55 + .kokoro/release/snapshot.cfg | 6 + .kokoro/release/snapshot.sh | 33 + .kokoro/release/stage.cfg | 44 + .kokoro/release/stage.sh | 42 + .kokoro/trampoline.sh | 24 + ....repo-metadata.json => .repo-metadata.json | 4 +- CODE_OF_CONDUCT.md | 93 + CONTRIBUTING.md | 28 + LICENSE | 5 +- google-cloud-container/README.md => README.md | 0 codecov.yaml | 4 + google-cloud-container-bom/pom.xml | 92 + google-cloud-container/pom.xml | 97 +- .../.repo-metadata.json | 13 - google-cloud-containeranalysis/README.md | 97 - google-cloud-containeranalysis/pom.xml | 99 - .../v1/ContainerAnalysisClient.java | 576 -- .../v1/ContainerAnalysisSettings.java | 203 - .../containeranalysis/v1/GrafeasUtils.java | 41 - .../containeranalysis/v1/package-info.java | 51 - .../v1/stub/ContainerAnalysisStub.java | 53 - .../stub/ContainerAnalysisStubSettings.java | 318 -- .../GrpcContainerAnalysisCallableFactory.java | 115 - .../v1/stub/GrpcContainerAnalysisStub.java | 221 - .../ContainerAnalysisV1Beta1Client.java | 1001 ---- .../ContainerAnalysisV1Beta1Settings.java | 248 - .../v1beta1/GrafeasV1Beta1Client.java | 2117 -------- .../v1beta1/GrafeasV1Beta1Settings.java | 370 -- .../v1beta1/package-info.java | 77 - .../stub/ContainerAnalysisV1Beta1Stub.java | 77 - .../ContainerAnalysisV1Beta1StubSettings.java | 473 -- .../v1beta1/stub/GrafeasV1Beta1Stub.java | 142 - .../stub/GrafeasV1Beta1StubSettings.java | 847 --- ...ntainerAnalysisV1Beta1CallableFactory.java | 115 - .../GrpcContainerAnalysisV1Beta1Stub.java | 337 -- .../GrpcGrafeasV1Beta1CallableFactory.java | 115 - .../v1beta1/stub/GrpcGrafeasV1Beta1Stub.java | 661 --- .../v1/ContainerAnalysisClientTest.java | 209 - .../v1/ITGrafeasInteropTest.java | 51 - .../v1/MockContainerAnalysis.java | 57 - .../v1/MockContainerAnalysisImpl.java | 107 - .../ContainerAnalysisV1Beta1ClientTest.java | 368 -- .../v1beta1/GrafeasV1Beta1ClientTest.java | 810 --- .../v1beta1/MockContainerAnalysisV1Beta1.java | 57 - .../MockContainerAnalysisV1Beta1Impl.java | 157 - .../v1beta1/MockGrafeasV1Beta1.java | 57 - .../v1beta1/MockGrafeasV1Beta1Impl.java | 306 -- google-cloud-containeranalysis/synth.metadata | 42 - google-cloud-containeranalysis/synth.py | 67 - grpc-google-cloud-container-v1/pom.xml | 60 +- .../container/v1/ClusterManagerGrpc.java | 16 + .../pom.xml | 52 - .../v1/ContainerAnalysisGrpc.java | 702 --- .../pom.xml | 52 - .../v1beta1/ContainerAnalysisV1Beta1Grpc.java | 1108 ---- .../grafeas/v1beta1/GrafeasV1Beta1Grpc.java | 2104 -------- java.header | 15 + license-checks.xml | 10 + pom.xml | 294 ++ proto-google-cloud-container-v1/pom.xml | 14 +- .../container/v1/AcceleratorConfig.java | 15 + .../v1/AcceleratorConfigOrBuilder.java | 15 + .../com/google/container/v1/AddonsConfig.java | 15 + .../container/v1/AddonsConfigOrBuilder.java | 15 + .../container/v1/AutoUpgradeOptions.java | 15 + .../v1/AutoUpgradeOptionsOrBuilder.java | 15 + .../container/v1/CancelOperationRequest.java | 15 + .../v1/CancelOperationRequestOrBuilder.java | 15 + .../container/v1/ClientCertificateConfig.java | 15 + .../v1/ClientCertificateConfigOrBuilder.java | 15 + .../java/com/google/container/v1/Cluster.java | 15 + .../google/container/v1/ClusterOrBuilder.java | 15 + .../container/v1/ClusterServiceProto.java | 15 + .../google/container/v1/ClusterUpdate.java | 15 + .../container/v1/ClusterUpdateOrBuilder.java | 15 + .../v1/CompleteIPRotationRequest.java | 15 + .../CompleteIPRotationRequestOrBuilder.java | 15 + .../container/v1/CreateClusterRequest.java | 15 + .../v1/CreateClusterRequestOrBuilder.java | 15 + .../container/v1/CreateNodePoolRequest.java | 15 + .../v1/CreateNodePoolRequestOrBuilder.java | 15 + .../container/v1/DailyMaintenanceWindow.java | 15 + .../v1/DailyMaintenanceWindowOrBuilder.java | 15 + .../container/v1/DeleteClusterRequest.java | 15 + .../v1/DeleteClusterRequestOrBuilder.java | 15 + .../container/v1/DeleteNodePoolRequest.java | 15 + .../v1/DeleteNodePoolRequestOrBuilder.java | 15 + .../container/v1/GetClusterRequest.java | 15 + .../v1/GetClusterRequestOrBuilder.java | 15 + .../container/v1/GetNodePoolRequest.java | 15 + .../v1/GetNodePoolRequestOrBuilder.java | 15 + .../container/v1/GetOperationRequest.java | 15 + .../v1/GetOperationRequestOrBuilder.java | 15 + .../container/v1/GetServerConfigRequest.java | 15 + .../v1/GetServerConfigRequestOrBuilder.java | 15 + .../v1/HorizontalPodAutoscaling.java | 15 + .../v1/HorizontalPodAutoscalingOrBuilder.java | 15 + .../container/v1/HttpLoadBalancing.java | 15 + .../v1/HttpLoadBalancingOrBuilder.java | 15 + .../container/v1/IPAllocationPolicy.java | 15 + .../v1/IPAllocationPolicyOrBuilder.java | 15 + .../container/v1/KubernetesDashboard.java | 15 + .../v1/KubernetesDashboardOrBuilder.java | 15 + .../com/google/container/v1/LegacyAbac.java | 15 + .../container/v1/LegacyAbacOrBuilder.java | 15 + .../container/v1/ListClustersRequest.java | 15 + .../v1/ListClustersRequestOrBuilder.java | 15 + .../container/v1/ListClustersResponse.java | 15 + .../v1/ListClustersResponseOrBuilder.java | 15 + .../container/v1/ListNodePoolsRequest.java | 15 + .../v1/ListNodePoolsRequestOrBuilder.java | 15 + .../container/v1/ListNodePoolsResponse.java | 15 + .../v1/ListNodePoolsResponseOrBuilder.java | 15 + .../container/v1/ListOperationsRequest.java | 15 + .../v1/ListOperationsRequestOrBuilder.java | 15 + .../container/v1/ListOperationsResponse.java | 15 + .../v1/ListOperationsResponseOrBuilder.java | 15 + .../container/v1/MaintenancePolicy.java | 15 + .../v1/MaintenancePolicyOrBuilder.java | 15 + .../container/v1/MaintenanceWindow.java | 15 + .../v1/MaintenanceWindowOrBuilder.java | 15 + .../com/google/container/v1/MasterAuth.java | 15 + .../container/v1/MasterAuthOrBuilder.java | 15 + .../v1/MasterAuthorizedNetworksConfig.java | 15 + ...sterAuthorizedNetworksConfigOrBuilder.java | 15 + .../google/container/v1/NetworkConfig.java | 15 + .../container/v1/NetworkConfigOrBuilder.java | 15 + .../google/container/v1/NetworkPolicy.java | 15 + .../container/v1/NetworkPolicyConfig.java | 15 + .../v1/NetworkPolicyConfigOrBuilder.java | 15 + .../container/v1/NetworkPolicyOrBuilder.java | 15 + .../com/google/container/v1/NodeConfig.java | 15 + .../container/v1/NodeConfigOrBuilder.java | 15 + .../google/container/v1/NodeManagement.java | 15 + .../container/v1/NodeManagementOrBuilder.java | 15 + .../com/google/container/v1/NodePool.java | 15 + .../container/v1/NodePoolAutoscaling.java | 15 + .../v1/NodePoolAutoscalingOrBuilder.java | 15 + .../container/v1/NodePoolOrBuilder.java | 15 + .../com/google/container/v1/Operation.java | 15 + .../container/v1/OperationOrBuilder.java | 15 + .../container/v1/PrivateClusterConfig.java | 15 + .../v1/PrivateClusterConfigOrBuilder.java | 15 + .../v1/RollbackNodePoolUpgradeRequest.java | 15 + ...llbackNodePoolUpgradeRequestOrBuilder.java | 15 + .../com/google/container/v1/ServerConfig.java | 15 + .../container/v1/ServerConfigOrBuilder.java | 15 + .../container/v1/SetAddonsConfigRequest.java | 15 + .../v1/SetAddonsConfigRequestOrBuilder.java | 15 + .../google/container/v1/SetLabelsRequest.java | 15 + .../v1/SetLabelsRequestOrBuilder.java | 15 + .../container/v1/SetLegacyAbacRequest.java | 15 + .../v1/SetLegacyAbacRequestOrBuilder.java | 15 + .../container/v1/SetLocationsRequest.java | 15 + .../v1/SetLocationsRequestOrBuilder.java | 15 + .../v1/SetLoggingServiceRequest.java | 15 + .../v1/SetLoggingServiceRequestOrBuilder.java | 15 + .../v1/SetMaintenancePolicyRequest.java | 15 + .../SetMaintenancePolicyRequestOrBuilder.java | 15 + .../container/v1/SetMasterAuthRequest.java | 15 + .../v1/SetMasterAuthRequestOrBuilder.java | 15 + .../v1/SetMonitoringServiceRequest.java | 15 + .../SetMonitoringServiceRequestOrBuilder.java | 15 + .../container/v1/SetNetworkPolicyRequest.java | 15 + .../v1/SetNetworkPolicyRequestOrBuilder.java | 15 + .../v1/SetNodePoolAutoscalingRequest.java | 15 + ...etNodePoolAutoscalingRequestOrBuilder.java | 15 + .../v1/SetNodePoolManagementRequest.java | 15 + ...SetNodePoolManagementRequestOrBuilder.java | 15 + .../container/v1/SetNodePoolSizeRequest.java | 15 + .../v1/SetNodePoolSizeRequestOrBuilder.java | 15 + .../container/v1/StartIPRotationRequest.java | 15 + .../v1/StartIPRotationRequestOrBuilder.java | 15 + .../container/v1/UpdateClusterRequest.java | 15 + .../v1/UpdateClusterRequestOrBuilder.java | 15 + .../container/v1/UpdateMasterRequest.java | 15 + .../v1/UpdateMasterRequestOrBuilder.java | 15 + .../container/v1/UpdateNodePoolRequest.java | 15 + .../v1/UpdateNodePoolRequestOrBuilder.java | 15 + .../pom.xml | 36 - .../v1/Containeranalysis.java | 81 - .../containeranalysis/v1/IamResourceName.java | 23 - .../v1/IamResourceNames.java | 31 - .../google/containeranalysis/v1/NoteName.java | 179 - .../containeranalysis/v1/OccurrenceName.java | 179 - .../containeranalysis/v1/ProjectName.java | 160 - .../v1/UntypedIamResourceName.java | 99 - .../v1/containeranalysis.proto | 101 - .../pom.xml | 36 - .../v1beta1/Containeranalysis.java | 170 - .../v1beta1/GetScanConfigRequest.java | 606 --- .../GetScanConfigRequestOrBuilder.java | 33 - .../v1beta1/IamResourceName.java | 23 - .../v1beta1/IamResourceNames.java | 31 - .../v1beta1/ListScanConfigsRequest.java | 1007 ---- .../ListScanConfigsRequestOrBuilder.java | 86 - .../v1beta1/ListScanConfigsResponse.java | 1114 ---- .../ListScanConfigsResponseOrBuilder.java | 87 - .../containeranalysis/v1beta1/NoteName.java | 179 - .../v1beta1/OccurrenceName.java | 179 - .../v1beta1/ProjectName.java | 160 - .../containeranalysis/v1beta1/ScanConfig.java | 1377 ----- .../v1beta1/ScanConfigName.java | 180 - .../v1beta1/ScanConfigOrBuilder.java | 129 - .../v1beta1/UntypedIamResourceName.java | 99 - .../v1beta1/UpdateScanConfigRequest.java | 876 --- .../UpdateScanConfigRequestOrBuilder.java | 64 - .../v1beta1/BatchCreateNotesRequest.java | 924 ---- .../BatchCreateNotesRequestOrBuilder.java | 88 - .../v1beta1/BatchCreateNotesResponse.java | 910 ---- .../BatchCreateNotesResponseOrBuilder.java | 61 - .../BatchCreateOccurrencesRequest.java | 1091 ---- ...atchCreateOccurrencesRequestOrBuilder.java | 84 - .../BatchCreateOccurrencesResponse.java | 922 ---- ...tchCreateOccurrencesResponseOrBuilder.java | 61 - .../io/grafeas/v1beta1/CreateNoteRequest.java | 1014 ---- .../v1beta1/CreateNoteRequestOrBuilder.java | 85 - .../v1beta1/CreateOccurrenceRequest.java | 864 --- .../CreateOccurrenceRequestOrBuilder.java | 64 - .../io/grafeas/v1beta1/DeleteNoteRequest.java | 599 --- .../v1beta1/DeleteNoteRequestOrBuilder.java | 33 - .../v1beta1/DeleteOccurrenceRequest.java | 603 --- .../DeleteOccurrenceRequestOrBuilder.java | 33 - .../io/grafeas/v1beta1/GetNoteRequest.java | 597 --- .../v1beta1/GetNoteRequestOrBuilder.java | 33 - .../v1beta1/GetOccurrenceNoteRequest.java | 603 --- .../GetOccurrenceNoteRequestOrBuilder.java | 33 - .../grafeas/v1beta1/GetOccurrenceRequest.java | 602 --- .../GetOccurrenceRequestOrBuilder.java | 33 - ...ulnerabilityOccurrencesSummaryRequest.java | 773 --- ...ityOccurrencesSummaryRequestOrBuilder.java | 54 - .../main/java/io/grafeas/v1beta1/Grafeas.java | 583 -- .../io/grafeas/v1beta1/IamResourceName.java | 23 - .../io/grafeas/v1beta1/IamResourceNames.java | 31 - .../v1beta1/ListNoteOccurrencesRequest.java | 1004 ---- .../ListNoteOccurrencesRequestOrBuilder.java | 86 - .../v1beta1/ListNoteOccurrencesResponse.java | 1083 ---- .../ListNoteOccurrencesResponseOrBuilder.java | 82 - .../io/grafeas/v1beta1/ListNotesRequest.java | 998 ---- .../v1beta1/ListNotesRequestOrBuilder.java | 86 - .../io/grafeas/v1beta1/ListNotesResponse.java | 1084 ---- .../v1beta1/ListNotesResponseOrBuilder.java | 86 - .../v1beta1/ListOccurrencesRequest.java | 1004 ---- .../ListOccurrencesRequestOrBuilder.java | 86 - .../v1beta1/ListOccurrencesResponse.java | 1097 ---- .../ListOccurrencesResponseOrBuilder.java | 86 - .../main/java/io/grafeas/v1beta1/Note.java | 4674 ----------------- .../java/io/grafeas/v1beta1/NoteName.java | 179 - .../io/grafeas/v1beta1/NoteOrBuilder.java | 509 -- .../java/io/grafeas/v1beta1/Occurrence.java | 3946 -------------- .../io/grafeas/v1beta1/OccurrenceName.java | 179 - .../grafeas/v1beta1/OccurrenceOrBuilder.java | 417 -- .../java/io/grafeas/v1beta1/ProjectName.java | 160 - .../java/io/grafeas/v1beta1/Resource.java | 1026 ---- .../io/grafeas/v1beta1/ResourceOrBuilder.java | 87 - .../io/grafeas/v1beta1/ScanConfigName.java | 180 - .../v1beta1/UntypedIamResourceName.java | 99 - .../io/grafeas/v1beta1/UpdateNoteRequest.java | 1114 ---- .../v1beta1/UpdateNoteRequestOrBuilder.java | 95 - .../v1beta1/UpdateOccurrenceRequest.java | 1125 ---- .../UpdateOccurrenceRequestOrBuilder.java | 95 - .../VulnerabilityOccurrencesSummary.java | 2099 -------- ...nerabilityOccurrencesSummaryOrBuilder.java | 76 - .../v1beta1/attestation/Attestation.java | 815 --- .../attestation/AttestationOrBuilder.java | 43 - .../attestation/AttestationOuterClass.java | 118 - .../v1beta1/attestation/Authority.java | 1349 ----- .../attestation/AuthorityOrBuilder.java | 41 - .../grafeas/v1beta1/attestation/Details.java | 700 --- .../v1beta1/attestation/DetailsOrBuilder.java | 41 - .../v1beta1/attestation/IamResourceName.java | 23 - .../v1beta1/attestation/IamResourceNames.java | 31 - .../grafeas/v1beta1/attestation/NoteName.java | 179 - .../v1beta1/attestation/OccurrenceName.java | 179 - .../attestation/PgpSignedAttestation.java | 1309 ----- .../PgpSignedAttestationOrBuilder.java | 127 - .../v1beta1/attestation/ProjectName.java | 160 - .../v1beta1/attestation/ScanConfigName.java | 180 - .../attestation/UntypedIamResourceName.java | 99 - .../java/io/grafeas/v1beta1/build/Build.java | 871 --- .../grafeas/v1beta1/build/BuildOrBuilder.java | 65 - .../v1beta1/build/BuildOuterClass.java | 97 - .../grafeas/v1beta1/build/BuildSignature.java | 1217 ----- .../build/BuildSignatureOrBuilder.java | 113 - .../io/grafeas/v1beta1/build/Details.java | 922 ---- .../v1beta1/build/DetailsOrBuilder.java | 80 - .../v1beta1/build/IamResourceName.java | 23 - .../v1beta1/build/IamResourceNames.java | 31 - .../io/grafeas/v1beta1/build/NoteName.java | 179 - .../grafeas/v1beta1/build/OccurrenceName.java | 179 - .../io/grafeas/v1beta1/build/ProjectName.java | 160 - .../grafeas/v1beta1/build/ScanConfigName.java | 180 - .../v1beta1/build/UntypedIamResourceName.java | 99 - .../io/grafeas/v1beta1/common/Common.java | 60 - .../v1beta1/common/IamResourceName.java | 23 - .../v1beta1/common/IamResourceNames.java | 31 - .../io/grafeas/v1beta1/common/NoteKind.java | 259 - .../io/grafeas/v1beta1/common/NoteName.java | 179 - .../v1beta1/common/OccurrenceName.java | 179 - .../grafeas/v1beta1/common/ProjectName.java | 160 - .../io/grafeas/v1beta1/common/RelatedUrl.java | 751 --- .../v1beta1/common/RelatedUrlOrBuilder.java | 52 - .../v1beta1/common/ScanConfigName.java | 180 - .../common/UntypedIamResourceName.java | 99 - .../v1beta1/deployment/Deployable.java | 678 --- .../deployment/DeployableOrBuilder.java | 51 - .../v1beta1/deployment/Deployment.java | 2003 ------- .../deployment/DeploymentOrBuilder.java | 201 - .../deployment/DeploymentOuterClass.java | 103 - .../grafeas/v1beta1/deployment/Details.java | 698 --- .../v1beta1/deployment/DetailsOrBuilder.java | 41 - .../v1beta1/deployment/IamResourceName.java | 23 - .../v1beta1/deployment/IamResourceNames.java | 31 - .../grafeas/v1beta1/deployment/NoteName.java | 179 - .../v1beta1/deployment/OccurrenceName.java | 179 - .../v1beta1/deployment/ProjectName.java | 160 - .../v1beta1/deployment/ScanConfigName.java | 180 - .../deployment/UntypedIamResourceName.java | 99 - .../io/grafeas/v1beta1/discovery/Details.java | 697 --- .../v1beta1/discovery/DetailsOrBuilder.java | 41 - .../grafeas/v1beta1/discovery/Discovered.java | 1628 ------ .../discovery/DiscoveredOrBuilder.java | 120 - .../grafeas/v1beta1/discovery/Discovery.java | 567 -- .../v1beta1/discovery/DiscoveryOrBuilder.java | 31 - .../discovery/DiscoveryOuterClass.java | 109 - .../v1beta1/discovery/IamResourceName.java | 23 - .../v1beta1/discovery/IamResourceNames.java | 31 - .../grafeas/v1beta1/discovery/NoteName.java | 179 - .../v1beta1/discovery/OccurrenceName.java | 179 - .../v1beta1/discovery/ProjectName.java | 160 - .../v1beta1/discovery/ScanConfigName.java | 180 - .../discovery/UntypedIamResourceName.java | 99 - .../java/io/grafeas/v1beta1/image/Basis.java | 869 --- .../grafeas/v1beta1/image/BasisOrBuilder.java | 64 - .../io/grafeas/v1beta1/image/Derived.java | 1482 ------ .../v1beta1/image/DerivedOrBuilder.java | 137 - .../io/grafeas/v1beta1/image/Details.java | 694 --- .../v1beta1/image/DetailsOrBuilder.java | 41 - .../io/grafeas/v1beta1/image/Fingerprint.java | 1022 ---- .../v1beta1/image/FingerprintOrBuilder.java | 99 - .../v1beta1/image/IamResourceName.java | 23 - .../v1beta1/image/IamResourceNames.java | 31 - .../java/io/grafeas/v1beta1/image/Image.java | 122 - .../java/io/grafeas/v1beta1/image/Layer.java | 1192 ----- .../grafeas/v1beta1/image/LayerOrBuilder.java | 52 - .../io/grafeas/v1beta1/image/NoteName.java | 179 - .../grafeas/v1beta1/image/OccurrenceName.java | 179 - .../io/grafeas/v1beta1/image/ProjectName.java | 160 - .../grafeas/v1beta1/image/ScanConfigName.java | 180 - .../v1beta1/image/UntypedIamResourceName.java | 99 - .../io/grafeas/v1beta1/pkg/Architecture.java | 149 - .../java/io/grafeas/v1beta1/pkg/Details.java | 695 --- .../grafeas/v1beta1/pkg/DetailsOrBuilder.java | 41 - .../io/grafeas/v1beta1/pkg/Distribution.java | 1498 ------ .../v1beta1/pkg/DistributionOrBuilder.java | 153 - .../grafeas/v1beta1/pkg/IamResourceName.java | 23 - .../grafeas/v1beta1/pkg/IamResourceNames.java | 31 - .../io/grafeas/v1beta1/pkg/Installation.java | 1103 ---- .../v1beta1/pkg/InstallationOrBuilder.java | 87 - .../java/io/grafeas/v1beta1/pkg/Location.java | 1018 ---- .../v1beta1/pkg/LocationOrBuilder.java | 85 - .../java/io/grafeas/v1beta1/pkg/NoteName.java | 179 - .../grafeas/v1beta1/pkg/OccurrenceName.java | 179 - .../java/io/grafeas/v1beta1/pkg/Package.java | 1084 ---- .../grafeas/v1beta1/pkg/PackageOrBuilder.java | 83 - .../v1beta1/pkg/PackageOuterClass.java | 136 - .../io/grafeas/v1beta1/pkg/ProjectName.java | 160 - .../grafeas/v1beta1/pkg/ScanConfigName.java | 180 - .../v1beta1/pkg/UntypedIamResourceName.java | 99 - .../java/io/grafeas/v1beta1/pkg/Version.java | 1138 ---- .../grafeas/v1beta1/pkg/VersionOrBuilder.java | 86 - .../grafeas/v1beta1/provenance/Artifact.java | 1069 ---- .../v1beta1/provenance/ArtifactOrBuilder.java | 113 - .../v1beta1/provenance/BuildProvenance.java | 3763 ------------- .../provenance/BuildProvenanceOrBuilder.java | 427 -- .../grafeas/v1beta1/provenance/Command.java | 1665 ------ .../v1beta1/provenance/CommandOrBuilder.java | 202 - .../v1beta1/provenance/FileHashes.java | 921 ---- .../provenance/FileHashesOrBuilder.java | 61 - .../io/grafeas/v1beta1/provenance/Hash.java | 767 --- .../v1beta1/provenance/HashOrBuilder.java | 42 - .../v1beta1/provenance/IamResourceName.java | 23 - .../v1beta1/provenance/IamResourceNames.java | 31 - .../grafeas/v1beta1/provenance/NoteName.java | 179 - .../v1beta1/provenance/OccurrenceName.java | 179 - .../v1beta1/provenance/ProjectName.java | 160 - .../v1beta1/provenance/Provenance.java | 196 - .../v1beta1/provenance/ScanConfigName.java | 180 - .../io/grafeas/v1beta1/provenance/Source.java | 1824 ------- .../v1beta1/provenance/SourceOrBuilder.java | 211 - .../provenance/UntypedIamResourceName.java | 99 - .../grafeas/v1beta1/source/AliasContext.java | 893 ---- .../v1beta1/source/AliasContextOrBuilder.java | 52 - .../source/CloudRepoSourceContext.java | 1241 ----- .../CloudRepoSourceContextOrBuilder.java | 95 - .../v1beta1/source/GerritSourceContext.java | 1318 ----- .../source/GerritSourceContextOrBuilder.java | 110 - .../v1beta1/source/GitSourceContext.java | 759 --- .../source/GitSourceContextOrBuilder.java | 52 - .../v1beta1/source/IamResourceName.java | 23 - .../v1beta1/source/IamResourceNames.java | 31 - .../io/grafeas/v1beta1/source/NoteName.java | 179 - .../v1beta1/source/OccurrenceName.java | 179 - .../grafeas/v1beta1/source/ProjectName.java | 160 - .../grafeas/v1beta1/source/ProjectRepoId.java | 758 --- .../source/ProjectRepoIdOrBuilder.java | 52 - .../io/grafeas/v1beta1/source/RepoId.java | 975 ---- .../v1beta1/source/RepoIdOrBuilder.java | 64 - .../v1beta1/source/ScanConfigName.java | 180 - .../io/grafeas/v1beta1/source/Source.java | 166 - .../grafeas/v1beta1/source/SourceContext.java | 1693 ------ .../source/SourceContextOrBuilder.java | 159 - .../source/UntypedIamResourceName.java | 99 - .../v1beta1/vulnerability/Details.java | 2140 -------- .../vulnerability/DetailsOrBuilder.java | 218 - .../vulnerability/IamResourceName.java | 23 - .../vulnerability/IamResourceNames.java | 31 - .../v1beta1/vulnerability/NoteName.java | 179 - .../v1beta1/vulnerability/OccurrenceName.java | 179 - .../v1beta1/vulnerability/PackageIssue.java | 1143 ---- .../vulnerability/PackageIssueOrBuilder.java | 93 - .../v1beta1/vulnerability/ProjectName.java | 160 - .../v1beta1/vulnerability/ScanConfigName.java | 180 - .../v1beta1/vulnerability/Severity.java | 217 - .../vulnerability/UntypedIamResourceName.java | 99 - .../v1beta1/vulnerability/Vulnerability.java | 3571 ------------- .../vulnerability/VulnerabilityLocation.java | 1024 ---- .../VulnerabilityLocationOrBuilder.java | 85 - .../vulnerability/VulnerabilityOrBuilder.java | 104 - .../VulnerabilityOuterClass.java | 161 - .../v1beta1/attestation/attestation.proto | 132 - .../v1beta1/build/build.proto | 96 - .../v1beta1/common/common.proto | 50 - .../v1beta1/containeranalysis.proto | 190 - .../v1beta1/deployment/deployment.proto | 74 - .../v1beta1/discovery/discovery.proto | 85 - .../v1beta1/grafeas/grafeas.proto | 502 -- .../v1beta1/image/image.proto | 144 - .../v1beta1/package/package.proto | 127 - .../v1beta1/provenance/provenance.proto | 164 - .../v1beta1/source/source.proto | 134 - .../v1beta1/vulnerability/vulnerability.proto | 145 - renovate.json | 27 + .../synth.metadata => synth.metadata | 0 google-cloud-container/synth.py => synth.py | 22 +- versions.txt | 11 + 499 files changed, 3675 insertions(+), 123610 deletions(-) create mode 100644 .github/ISSUE_TEMPLATE/bug_report.md create mode 100644 .github/ISSUE_TEMPLATE/feature_request.md create mode 100644 .github/ISSUE_TEMPLATE/support_request.md create mode 100644 .github/PULL_REQUEST_TEMPLATE.md create mode 100644 .github/release-please.yml create mode 100644 .gitignore create mode 100644 .kokoro/build.bat create mode 100755 .kokoro/build.sh create mode 100755 .kokoro/coerce_logs.sh create mode 100644 .kokoro/common.cfg create mode 100644 .kokoro/continuous/common.cfg create mode 100644 .kokoro/continuous/dependencies.cfg create mode 100644 .kokoro/continuous/integration.cfg create mode 100644 .kokoro/continuous/java11.cfg create mode 100644 .kokoro/continuous/java7.cfg create mode 100644 .kokoro/continuous/java8-osx.cfg create mode 100644 .kokoro/continuous/java8-win.cfg create mode 100644 .kokoro/continuous/java8.cfg create mode 100644 .kokoro/continuous/lint.cfg create mode 100644 .kokoro/continuous/propose_release.cfg create mode 100755 .kokoro/continuous/propose_release.sh create mode 100755 .kokoro/dependencies.sh create mode 100755 .kokoro/linkage-monitor.sh create mode 100644 .kokoro/nightly/common.cfg create mode 100644 .kokoro/nightly/dependencies.cfg create mode 100644 .kokoro/nightly/integration.cfg create mode 100644 .kokoro/nightly/java11.cfg create mode 100644 .kokoro/nightly/java7.cfg create mode 100644 .kokoro/nightly/java8-osx.cfg create mode 100644 .kokoro/nightly/java8-win.cfg create mode 100644 .kokoro/nightly/java8.cfg create mode 100644 .kokoro/nightly/lint.cfg create mode 100644 .kokoro/presubmit/clirr.cfg create mode 100644 .kokoro/presubmit/common.cfg create mode 100644 .kokoro/presubmit/dependencies.cfg create mode 100644 .kokoro/presubmit/integration.cfg create mode 100644 .kokoro/presubmit/java11.cfg create mode 100644 .kokoro/presubmit/java7.cfg create mode 100644 .kokoro/presubmit/java8-osx.cfg create mode 100644 .kokoro/presubmit/java8-win.cfg create mode 100644 .kokoro/presubmit/java8.cfg create mode 100644 .kokoro/presubmit/linkage-monitor.cfg create mode 100644 .kokoro/presubmit/lint.cfg create mode 100644 .kokoro/release/bump_snapshot.cfg create mode 100755 .kokoro/release/bump_snapshot.sh create mode 100644 .kokoro/release/common.cfg create mode 100755 .kokoro/release/common.sh create mode 100644 .kokoro/release/drop.cfg create mode 100755 .kokoro/release/drop.sh create mode 100644 .kokoro/release/promote.cfg create mode 100755 .kokoro/release/promote.sh create mode 100644 .kokoro/release/publish_javadoc.cfg create mode 100755 .kokoro/release/publish_javadoc.sh create mode 100644 .kokoro/release/snapshot.cfg create mode 100755 .kokoro/release/snapshot.sh create mode 100644 .kokoro/release/stage.cfg create mode 100755 .kokoro/release/stage.sh create mode 100644 .kokoro/trampoline.sh rename google-cloud-container/.repo-metadata.json => .repo-metadata.json (86%) create mode 100644 CODE_OF_CONDUCT.md create mode 100644 CONTRIBUTING.md rename google-cloud-container/README.md => README.md (100%) create mode 100644 codecov.yaml create mode 100644 google-cloud-container-bom/pom.xml delete mode 100644 google-cloud-containeranalysis/.repo-metadata.json delete mode 100644 google-cloud-containeranalysis/README.md delete mode 100644 google-cloud-containeranalysis/pom.xml delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/ContainerAnalysisClient.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/ContainerAnalysisSettings.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/GrafeasUtils.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/package-info.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/ContainerAnalysisStub.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/ContainerAnalysisStubSettings.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/GrpcContainerAnalysisCallableFactory.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/GrpcContainerAnalysisStub.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/ContainerAnalysisV1Beta1Client.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/ContainerAnalysisV1Beta1Settings.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/GrafeasV1Beta1Client.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/GrafeasV1Beta1Settings.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/package-info.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/ContainerAnalysisV1Beta1Stub.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/ContainerAnalysisV1Beta1StubSettings.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrafeasV1Beta1Stub.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrafeasV1Beta1StubSettings.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcContainerAnalysisV1Beta1CallableFactory.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcContainerAnalysisV1Beta1Stub.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcGrafeasV1Beta1CallableFactory.java delete mode 100644 google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcGrafeasV1Beta1Stub.java delete mode 100644 google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/ContainerAnalysisClientTest.java delete mode 100644 google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/ITGrafeasInteropTest.java delete mode 100644 google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/MockContainerAnalysis.java delete mode 100644 google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/MockContainerAnalysisImpl.java delete mode 100644 google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/ContainerAnalysisV1Beta1ClientTest.java delete mode 100644 google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/GrafeasV1Beta1ClientTest.java delete mode 100644 google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockContainerAnalysisV1Beta1.java delete mode 100644 google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockContainerAnalysisV1Beta1Impl.java delete mode 100644 google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockGrafeasV1Beta1.java delete mode 100644 google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockGrafeasV1Beta1Impl.java delete mode 100644 google-cloud-containeranalysis/synth.metadata delete mode 100644 google-cloud-containeranalysis/synth.py delete mode 100644 grpc-google-cloud-containeranalysis-v1/pom.xml delete mode 100644 grpc-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/ContainerAnalysisGrpc.java delete mode 100644 grpc-google-cloud-containeranalysis-v1beta1/pom.xml delete mode 100644 grpc-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ContainerAnalysisV1Beta1Grpc.java delete mode 100644 grpc-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GrafeasV1Beta1Grpc.java create mode 100644 java.header create mode 100644 license-checks.xml create mode 100644 pom.xml delete mode 100644 proto-google-cloud-containeranalysis-v1/pom.xml delete mode 100644 proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/Containeranalysis.java delete mode 100644 proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1/src/main/proto/google/devtools/containeranalysis/v1/containeranalysis.proto delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/pom.xml delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/Containeranalysis.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/GetScanConfigRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/GetScanConfigRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsResponse.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsResponseOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ScanConfig.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ScanConfigName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ScanConfigOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/UpdateScanConfigRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/UpdateScanConfigRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesResponse.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesResponseOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesResponse.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesResponseOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateNoteRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateNoteRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateOccurrenceRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateOccurrenceRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteNoteRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteNoteRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteOccurrenceRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteOccurrenceRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetNoteRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetNoteRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceNoteRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceNoteRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetVulnerabilityOccurrencesSummaryRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetVulnerabilityOccurrencesSummaryRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Grafeas.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesResponse.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesResponseOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesResponse.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesResponseOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesResponse.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesResponseOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Note.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/NoteOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Occurrence.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/OccurrenceOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Resource.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ResourceOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ScanConfigName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateNoteRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateNoteRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateOccurrenceRequest.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateOccurrenceRequestOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/VulnerabilityOccurrencesSummary.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/VulnerabilityOccurrencesSummaryOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/Attestation.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/AttestationOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/AttestationOuterClass.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/Authority.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/AuthorityOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/Details.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/DetailsOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/PgpSignedAttestation.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/PgpSignedAttestationOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/ScanConfigName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/Build.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildOuterClass.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildSignature.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildSignatureOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/Details.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/DetailsOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/ScanConfigName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/Common.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/NoteKind.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/RelatedUrl.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/RelatedUrlOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/ScanConfigName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/Deployable.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DeployableOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/Deployment.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DeploymentOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DeploymentOuterClass.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/Details.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DetailsOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/ScanConfigName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/Details.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DetailsOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/Discovered.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DiscoveredOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/Discovery.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DiscoveryOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DiscoveryOuterClass.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/ScanConfigName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Basis.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/BasisOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Derived.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/DerivedOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Details.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/DetailsOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Fingerprint.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/FingerprintOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Image.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Layer.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/LayerOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/ScanConfigName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Architecture.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Details.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/DetailsOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Distribution.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/DistributionOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Installation.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/InstallationOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Location.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/LocationOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Package.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/PackageOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/PackageOuterClass.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/ScanConfigName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Version.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/VersionOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Artifact.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/ArtifactOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/BuildProvenance.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/BuildProvenanceOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Command.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/CommandOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/FileHashes.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/FileHashesOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Hash.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/HashOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Provenance.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/ScanConfigName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Source.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/SourceOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/AliasContext.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/AliasContextOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/CloudRepoSourceContext.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/CloudRepoSourceContextOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GerritSourceContext.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GerritSourceContextOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GitSourceContext.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GitSourceContextOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ProjectRepoId.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ProjectRepoIdOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/RepoId.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/RepoIdOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ScanConfigName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/Source.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/SourceContext.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/SourceContextOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/Details.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/DetailsOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/IamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/IamResourceNames.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/NoteName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/OccurrenceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/PackageIssue.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/PackageIssueOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/ProjectName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/ScanConfigName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/Severity.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/UntypedIamResourceName.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/Vulnerability.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityLocation.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityLocationOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityOrBuilder.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityOuterClass.java delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/attestation/attestation.proto delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/build/build.proto delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/common/common.proto delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/containeranalysis.proto delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/deployment/deployment.proto delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/discovery/discovery.proto delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/image/image.proto delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/package/package.proto delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/provenance/provenance.proto delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/source/source.proto delete mode 100644 proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto create mode 100644 renovate.json rename google-cloud-container/synth.metadata => synth.metadata (100%) rename google-cloud-container/synth.py => synth.py (65%) create mode 100644 versions.txt diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 00000000..a0296d4a --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,51 @@ +--- +name: Bug report +about: Create a report to help us improve + +--- + +Thanks for stopping by to let us know something could be better! + +**PLEASE READ**: If you have a support contract with Google, please create an issue in the [support console](https://cloud.google.com/support/) instead of filing on GitHub. This will ensure a timely response. + +Please run down the following list and make sure you've tried the usual "quick fixes": + + - Search the issues already opened: https://github.com/googleapis/java-container/issues + - Check for answers on StackOverflow: http://stackoverflow.com/questions/tagged/google-cloud-platform + +If you are still having issues, please include as much information as possible: + +#### Environment details + +1. Specify the API at the beginning of the title. For example, "BigQuery: ..."). + General, Core, and Other are also allowed as types +2. OS type and version: +3. Java version: +4. container version(s): + +#### Steps to reproduce + + 1. ? + 2. ? + +#### Code example + +```java +// example +``` + +#### Stack trace +``` +Any relevant stacktrace here. +``` + +#### External references such as API reference guides + +- ? + +#### Any additional information below + + +Following these steps guarantees the quickest resolution possible. + +Thanks! diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 00000000..754e30c6 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,21 @@ +--- +name: Feature request +about: Suggest an idea for this library + +--- + +Thanks for stopping by to let us know something could be better! + +**PLEASE READ**: If you have a support contract with Google, please create an issue in the [support console](https://cloud.google.com/support/) instead of filing on GitHub. This will ensure a timely response. + +**Is your feature request related to a problem? Please describe.** +What the problem is. Example: I'm always frustrated when [...] + +**Describe the solution you'd like** +What you want to happen. + +**Describe alternatives you've considered** +Any alternative solutions or features you've considered. + +**Additional context** +Any other context or screenshots about the feature request. diff --git a/.github/ISSUE_TEMPLATE/support_request.md b/.github/ISSUE_TEMPLATE/support_request.md new file mode 100644 index 00000000..99586903 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/support_request.md @@ -0,0 +1,7 @@ +--- +name: Support request +about: If you have a support contract with Google, please create an issue in the Google Cloud Support console. + +--- + +**PLEASE READ**: If you have a support contract with Google, please create an issue in the [support console](https://cloud.google.com/support/) instead of filing on GitHub. This will ensure a timely response. diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md new file mode 100644 index 00000000..0bd0ee06 --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1 @@ +Fixes # (it's a good idea to open an issue first for context and/or discussion) \ No newline at end of file diff --git a/.github/release-please.yml b/.github/release-please.yml new file mode 100644 index 00000000..82744682 --- /dev/null +++ b/.github/release-please.yml @@ -0,0 +1 @@ +releaseType: java-yoshi diff --git a/.gitignore b/.gitignore new file mode 100644 index 00000000..dc2d514c --- /dev/null +++ b/.gitignore @@ -0,0 +1,45 @@ +.gitignore + +# Packages +dist +bin +var +sdist +target + +# Unit test / coverage reports +.coverage +.tox +nosetests.xml + +# Translations +*.mo + +# Mr Developer +.mr.developer.cfg + +.metadata +.project +.pydevproject +*.iml +.idea +.settings +.DS_Store +.classpath + +# Built documentation +docs/ + + +# Wheel directory used in Travis builds. +gcloud-java-wheels/ +src/test/resources/gcd-head.zip +src/test/resources/gcd-v1beta2-rev1-2.1.1.zip + +# API key file containing value of GOOGLE_API_KEY for integration tests +api_key + +# Python utilities +*.pyc +artman-genfiles +venv \ No newline at end of file diff --git a/.kokoro/build.bat b/.kokoro/build.bat new file mode 100644 index 00000000..2d6621f4 --- /dev/null +++ b/.kokoro/build.bat @@ -0,0 +1,3 @@ +:: See documentation in type-shell-output.bat + +"C:\Program Files\Git\bin\bash.exe" github/java-container/.kokoro/build.sh diff --git a/.kokoro/build.sh b/.kokoro/build.sh new file mode 100755 index 00000000..fa132f41 --- /dev/null +++ b/.kokoro/build.sh @@ -0,0 +1,60 @@ +#!/bin/bash +# Copyright 2019 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. + +set -eo pipefail + +## Get the directory of the build script +scriptDir=$(realpath $(dirname "${BASH_SOURCE[0]}")) +## cd to the parent directory, i.e. the root of the git repo +cd ${scriptDir}/.. + +# Print out Java version +java -version +echo ${JOB_TYPE} + +mvn install -B -V \ + -DskipTests=true \ + -Dclirr.skip=true \ + -Dmaven.javadoc.skip=true \ + -Dgcloud.download.skip=true \ + -T 1C + +# if GOOGLE_APPLICATION_CREDIENTIALS is specified as a relative path prepend Kokoro root directory onto it +if [[ ! -z "${GOOGLE_APPLICATION_CREDENTIALS}" && "${GOOGLE_APPLICATION_CREDENTIALS}" != /* ]]; then + export GOOGLE_APPLICATION_CREDENTIALS=$(realpath ${KOKORO_ROOT}/src/${GOOGLE_APPLICATION_CREDENTIALS}) +fi + +case ${JOB_TYPE} in +test) + mvn test -B -Dclirr.skip=true + bash ${KOKORO_GFILE_DIR}/codecov.sh + bash .kokoro/coerce_logs.sh + ;; +lint) + mvn com.coveo:fmt-maven-plugin:check + ;; +javadoc) + mvn javadoc:javadoc javadoc:test-javadoc + ;; +integration) + mvn -B ${INTEGRATION_TEST_ARGS} -DtrimStackTrace=false -Dclirr.skip=true -fae verify + bash .kokoro/coerce_logs.sh + ;; +clirr) + mvn -B clirr:check + ;; +*) + ;; +esac \ No newline at end of file diff --git a/.kokoro/coerce_logs.sh b/.kokoro/coerce_logs.sh new file mode 100755 index 00000000..5cf7ba49 --- /dev/null +++ b/.kokoro/coerce_logs.sh @@ -0,0 +1,38 @@ +#!/bin/bash +# Copyright 2019 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. + +# This script finds and moves sponge logs so that they can be found by placer +# and are not flagged as flaky by sponge. + +set -eo pipefail + +## Get the directory of the build script +scriptDir=$(realpath $(dirname "${BASH_SOURCE[0]}")) +## cd to the parent directory, i.e. the root of the git repo +cd ${scriptDir}/.. + +job=$(basename ${KOKORO_JOB_NAME}) + +echo "coercing sponge logs..." +for xml in `find . -name *-sponge_log.xml` +do + echo "processing ${xml}" + class=$(basename ${xml} | cut -d- -f2) + dir=$(dirname ${xml})/${job}/${class} + text=$(dirname ${xml})/${class}-sponge_log.txt + mkdir -p ${dir} + mv ${xml} ${dir}/sponge_log.xml + mv ${text} ${dir}/sponge_log.txt +done diff --git a/.kokoro/common.cfg b/.kokoro/common.cfg new file mode 100644 index 00000000..047eed5a --- /dev/null +++ b/.kokoro/common.cfg @@ -0,0 +1,13 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Download trampoline resources. These will be in ${KOKORO_GFILE_DIR} +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" + +# All builds use the trampoline script to run in docker. +build_file: "java-container/.kokoro/trampoline.sh" + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/build.sh" +} diff --git a/.kokoro/continuous/common.cfg b/.kokoro/continuous/common.cfg new file mode 100644 index 00000000..518a1974 --- /dev/null +++ b/.kokoro/continuous/common.cfg @@ -0,0 +1,25 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Build logs will be here +action { + define_artifacts { + regex: "**/*sponge_log.xml" + regex: "**/*sponge_log.txt" + } +} + +# Download trampoline resources. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" + +# Use the trampoline script to run in docker. +build_file: "java-container/.kokoro/trampoline.sh" + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/build.sh" +} + +env_vars: { + key: "JOB_TYPE" + value: "test" +} diff --git a/.kokoro/continuous/dependencies.cfg b/.kokoro/continuous/dependencies.cfg new file mode 100644 index 00000000..1a5bf99a --- /dev/null +++ b/.kokoro/continuous/dependencies.cfg @@ -0,0 +1,12 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/dependencies.sh" +} diff --git a/.kokoro/continuous/integration.cfg b/.kokoro/continuous/integration.cfg new file mode 100644 index 00000000..3b017fc8 --- /dev/null +++ b/.kokoro/continuous/integration.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} diff --git a/.kokoro/continuous/java11.cfg b/.kokoro/continuous/java11.cfg new file mode 100644 index 00000000..709f2b4c --- /dev/null +++ b/.kokoro/continuous/java11.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java11" +} diff --git a/.kokoro/continuous/java7.cfg b/.kokoro/continuous/java7.cfg new file mode 100644 index 00000000..cb24f44e --- /dev/null +++ b/.kokoro/continuous/java7.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java7" +} diff --git a/.kokoro/continuous/java8-osx.cfg b/.kokoro/continuous/java8-osx.cfg new file mode 100644 index 00000000..c14ec2e7 --- /dev/null +++ b/.kokoro/continuous/java8-osx.cfg @@ -0,0 +1,3 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +build_file: "java-container/.kokoro/build.sh" diff --git a/.kokoro/continuous/java8-win.cfg b/.kokoro/continuous/java8-win.cfg new file mode 100644 index 00000000..6b638557 --- /dev/null +++ b/.kokoro/continuous/java8-win.cfg @@ -0,0 +1,3 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +build_file: "java-container/.kokoro/build.bat" diff --git a/.kokoro/continuous/java8.cfg b/.kokoro/continuous/java8.cfg new file mode 100644 index 00000000..3b017fc8 --- /dev/null +++ b/.kokoro/continuous/java8.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} diff --git a/.kokoro/continuous/lint.cfg b/.kokoro/continuous/lint.cfg new file mode 100644 index 00000000..6d323c8a --- /dev/null +++ b/.kokoro/continuous/lint.cfg @@ -0,0 +1,13 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. + +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} + +env_vars: { + key: "JOB_TYPE" + value: "lint" +} \ No newline at end of file diff --git a/.kokoro/continuous/propose_release.cfg b/.kokoro/continuous/propose_release.cfg new file mode 100644 index 00000000..d6aed0de --- /dev/null +++ b/.kokoro/continuous/propose_release.cfg @@ -0,0 +1,53 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Build logs will be here +action { + define_artifacts { + regex: "**/*sponge_log.xml" + } +} + +# Download trampoline resources. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" + +# Use the trampoline script to run in docker. +build_file: "java-container/.kokoro/trampoline.sh" + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/node:10-user" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/continuous/propose_release.sh" +} + +# tokens used by release-please to keep an up-to-date release PR. +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "github-magic-proxy-key-release-please" + } + } +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "github-magic-proxy-token-release-please" + } + } +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "github-magic-proxy-url-release-please" + } + } +} diff --git a/.kokoro/continuous/propose_release.sh b/.kokoro/continuous/propose_release.sh new file mode 100755 index 00000000..b375c8d3 --- /dev/null +++ b/.kokoro/continuous/propose_release.sh @@ -0,0 +1,29 @@ +#!/bin/bash + +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +set -eo pipefail + +export NPM_CONFIG_PREFIX=/home/node/.npm-global + +if [ -f ${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-url-release-please ]; then + # Groom the release PR as new commits are merged. + npx release-please release-pr --token=${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-token-release-please \ + --repo-url=googleapis/java-container \ + --package-name="container" \ + --api-url=${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-url-release-please \ + --proxy-key=${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-key-release-please \ + --release-type=java-yoshi +fi diff --git a/.kokoro/dependencies.sh b/.kokoro/dependencies.sh new file mode 100755 index 00000000..4c920c11 --- /dev/null +++ b/.kokoro/dependencies.sh @@ -0,0 +1,27 @@ +#!/bin/bash +# Copyright 2019 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. + +set -eo pipefail + +cd github/java-container/ + +# Print out Java +java -version +echo $JOB_TYPE + +export MAVEN_OPTS="-Xmx1024m -XX:MaxPermSize=128m" + +mvn install -DskipTests=true -B -V +mvn -B dependency:analyze -DfailOnWarning=true diff --git a/.kokoro/linkage-monitor.sh b/.kokoro/linkage-monitor.sh new file mode 100755 index 00000000..90a5dd28 --- /dev/null +++ b/.kokoro/linkage-monitor.sh @@ -0,0 +1,33 @@ +#!/bin/bash +# Copyright 2019 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. + +set -eo pipefail +# Display commands being run. +set -x + +cd github/java-container/ + +# Print out Java version +java -version +echo ${JOB_TYPE} + +mvn install -DskipTests=true -Dmaven.javadoc.skip=true -Dgcloud.download.skip=true -B -V + +# Kokoro job cloud-opensource-java/ubuntu/linkage-monitor-gcs creates this JAR +JAR=linkage-monitor-latest-all-deps.jar +curl -v -O "https://storage.googleapis.com/cloud-opensource-java-linkage-monitor/${JAR}" + +# Fails if there's new linkage errors compared with baseline +java -jar ${JAR} com.google.cloud:libraries-bom diff --git a/.kokoro/nightly/common.cfg b/.kokoro/nightly/common.cfg new file mode 100644 index 00000000..518a1974 --- /dev/null +++ b/.kokoro/nightly/common.cfg @@ -0,0 +1,25 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Build logs will be here +action { + define_artifacts { + regex: "**/*sponge_log.xml" + regex: "**/*sponge_log.txt" + } +} + +# Download trampoline resources. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" + +# Use the trampoline script to run in docker. +build_file: "java-container/.kokoro/trampoline.sh" + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/build.sh" +} + +env_vars: { + key: "JOB_TYPE" + value: "test" +} diff --git a/.kokoro/nightly/dependencies.cfg b/.kokoro/nightly/dependencies.cfg new file mode 100644 index 00000000..1a5bf99a --- /dev/null +++ b/.kokoro/nightly/dependencies.cfg @@ -0,0 +1,12 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/dependencies.sh" +} diff --git a/.kokoro/nightly/integration.cfg b/.kokoro/nightly/integration.cfg new file mode 100644 index 00000000..3b017fc8 --- /dev/null +++ b/.kokoro/nightly/integration.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} diff --git a/.kokoro/nightly/java11.cfg b/.kokoro/nightly/java11.cfg new file mode 100644 index 00000000..709f2b4c --- /dev/null +++ b/.kokoro/nightly/java11.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java11" +} diff --git a/.kokoro/nightly/java7.cfg b/.kokoro/nightly/java7.cfg new file mode 100644 index 00000000..cb24f44e --- /dev/null +++ b/.kokoro/nightly/java7.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java7" +} diff --git a/.kokoro/nightly/java8-osx.cfg b/.kokoro/nightly/java8-osx.cfg new file mode 100644 index 00000000..c14ec2e7 --- /dev/null +++ b/.kokoro/nightly/java8-osx.cfg @@ -0,0 +1,3 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +build_file: "java-container/.kokoro/build.sh" diff --git a/.kokoro/nightly/java8-win.cfg b/.kokoro/nightly/java8-win.cfg new file mode 100644 index 00000000..6b638557 --- /dev/null +++ b/.kokoro/nightly/java8-win.cfg @@ -0,0 +1,3 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +build_file: "java-container/.kokoro/build.bat" diff --git a/.kokoro/nightly/java8.cfg b/.kokoro/nightly/java8.cfg new file mode 100644 index 00000000..3b017fc8 --- /dev/null +++ b/.kokoro/nightly/java8.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} diff --git a/.kokoro/nightly/lint.cfg b/.kokoro/nightly/lint.cfg new file mode 100644 index 00000000..6d323c8a --- /dev/null +++ b/.kokoro/nightly/lint.cfg @@ -0,0 +1,13 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. + +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} + +env_vars: { + key: "JOB_TYPE" + value: "lint" +} \ No newline at end of file diff --git a/.kokoro/presubmit/clirr.cfg b/.kokoro/presubmit/clirr.cfg new file mode 100644 index 00000000..ec572442 --- /dev/null +++ b/.kokoro/presubmit/clirr.cfg @@ -0,0 +1,13 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. + +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} + +env_vars: { + key: "JOB_TYPE" + value: "clirr" +} \ No newline at end of file diff --git a/.kokoro/presubmit/common.cfg b/.kokoro/presubmit/common.cfg new file mode 100644 index 00000000..828ed806 --- /dev/null +++ b/.kokoro/presubmit/common.cfg @@ -0,0 +1,34 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Build logs will be here +action { + define_artifacts { + regex: "**/*sponge_log.xml" + regex: "**/*sponge_log.txt" + } +} + +# Download trampoline resources. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" + +# Use the trampoline script to run in docker. +build_file: "java-container/.kokoro/trampoline.sh" + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/build.sh" +} + +env_vars: { + key: "JOB_TYPE" + value: "test" +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "dpebot_codecov_token" + } + } +} diff --git a/.kokoro/presubmit/dependencies.cfg b/.kokoro/presubmit/dependencies.cfg new file mode 100644 index 00000000..1a5bf99a --- /dev/null +++ b/.kokoro/presubmit/dependencies.cfg @@ -0,0 +1,12 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/dependencies.sh" +} diff --git a/.kokoro/presubmit/integration.cfg b/.kokoro/presubmit/integration.cfg new file mode 100644 index 00000000..141f90c1 --- /dev/null +++ b/.kokoro/presubmit/integration.cfg @@ -0,0 +1,31 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} + +env_vars: { + key: "JOB_TYPE" + value: "integration" +} + +env_vars: { + key: "GCLOUD_PROJECT" + value: "gcloud-devel" +} + +env_vars: { + key: "GOOGLE_APPLICATION_CREDENTIALS" + value: "keystore/73713_java_it_service_account" +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "java_it_service_account" + } + } +} diff --git a/.kokoro/presubmit/java11.cfg b/.kokoro/presubmit/java11.cfg new file mode 100644 index 00000000..709f2b4c --- /dev/null +++ b/.kokoro/presubmit/java11.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java11" +} diff --git a/.kokoro/presubmit/java7.cfg b/.kokoro/presubmit/java7.cfg new file mode 100644 index 00000000..cb24f44e --- /dev/null +++ b/.kokoro/presubmit/java7.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java7" +} diff --git a/.kokoro/presubmit/java8-osx.cfg b/.kokoro/presubmit/java8-osx.cfg new file mode 100644 index 00000000..c14ec2e7 --- /dev/null +++ b/.kokoro/presubmit/java8-osx.cfg @@ -0,0 +1,3 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +build_file: "java-container/.kokoro/build.sh" diff --git a/.kokoro/presubmit/java8-win.cfg b/.kokoro/presubmit/java8-win.cfg new file mode 100644 index 00000000..6b638557 --- /dev/null +++ b/.kokoro/presubmit/java8-win.cfg @@ -0,0 +1,3 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +build_file: "java-container/.kokoro/build.bat" diff --git a/.kokoro/presubmit/java8.cfg b/.kokoro/presubmit/java8.cfg new file mode 100644 index 00000000..3b017fc8 --- /dev/null +++ b/.kokoro/presubmit/java8.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} diff --git a/.kokoro/presubmit/linkage-monitor.cfg b/.kokoro/presubmit/linkage-monitor.cfg new file mode 100644 index 00000000..555f496e --- /dev/null +++ b/.kokoro/presubmit/linkage-monitor.cfg @@ -0,0 +1,12 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/linkage-monitor.sh" +} \ No newline at end of file diff --git a/.kokoro/presubmit/lint.cfg b/.kokoro/presubmit/lint.cfg new file mode 100644 index 00000000..6d323c8a --- /dev/null +++ b/.kokoro/presubmit/lint.cfg @@ -0,0 +1,13 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. + +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} + +env_vars: { + key: "JOB_TYPE" + value: "lint" +} \ No newline at end of file diff --git a/.kokoro/release/bump_snapshot.cfg b/.kokoro/release/bump_snapshot.cfg new file mode 100644 index 00000000..045db081 --- /dev/null +++ b/.kokoro/release/bump_snapshot.cfg @@ -0,0 +1,53 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Build logs will be here +action { + define_artifacts { + regex: "**/*sponge_log.xml" + } +} + +# Download trampoline resources. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" + +# Use the trampoline script to run in docker. +build_file: "java-container/.kokoro/trampoline.sh" + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/node:10-user" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/release/bump_snapshot.sh" +} + +# tokens used by release-please to keep an up-to-date release PR. +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "github-magic-proxy-key-release-please" + } + } +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "github-magic-proxy-token-release-please" + } + } +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "github-magic-proxy-url-release-please" + } + } +} diff --git a/.kokoro/release/bump_snapshot.sh b/.kokoro/release/bump_snapshot.sh new file mode 100755 index 00000000..d064ad88 --- /dev/null +++ b/.kokoro/release/bump_snapshot.sh @@ -0,0 +1,30 @@ +#!/bin/bash + +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +set -eo pipefail + +export NPM_CONFIG_PREFIX=/home/node/.npm-global + +if [ -f ${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-url-release-please ]; then + # Groom the snapshot release PR immediately after publishing a release + npx release-please release-pr --token=${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-token-release-please \ + --repo-url=googleapis/java-container \ + --package-name="container" \ + --api-url=${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-url-release-please \ + --proxy-key=${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-key-release-please \ + --snapshot \ + --release-type=java-auth-yoshi +fi diff --git a/.kokoro/release/common.cfg b/.kokoro/release/common.cfg new file mode 100644 index 00000000..dd1cdd8f --- /dev/null +++ b/.kokoro/release/common.cfg @@ -0,0 +1,49 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Download trampoline resources. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" + +# Use the trampoline script to run in docker. +build_file: "java-container/.kokoro/trampoline.sh" + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/java8" +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 70247 + keyname: "maven-gpg-keyring" + } + } +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 70247 + keyname: "maven-gpg-passphrase" + } + } +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 70247 + keyname: "maven-gpg-pubkeyring" + } + } +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 70247 + keyname: "sonatype-credentials" + } + } +} diff --git a/.kokoro/release/common.sh b/.kokoro/release/common.sh new file mode 100755 index 00000000..6e3f6599 --- /dev/null +++ b/.kokoro/release/common.sh @@ -0,0 +1,50 @@ +#!/bin/bash +# Copyright 2018 Google Inc. +# +# 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. + +set -eo pipefail + +# Get secrets from keystore and set and environment variables +setup_environment_secrets() { + export GPG_PASSPHRASE=$(cat ${KOKORO_KEYSTORE_DIR}/70247_maven-gpg-passphrase) + export GPG_TTY=$(tty) + export GPG_HOMEDIR=/gpg + mkdir $GPG_HOMEDIR + mv ${KOKORO_KEYSTORE_DIR}/70247_maven-gpg-pubkeyring $GPG_HOMEDIR/pubring.gpg + mv ${KOKORO_KEYSTORE_DIR}/70247_maven-gpg-keyring $GPG_HOMEDIR/secring.gpg + export SONATYPE_USERNAME=$(cat ${KOKORO_KEYSTORE_DIR}/70247_sonatype-credentials | cut -f1 -d'|') + export SONATYPE_PASSWORD=$(cat ${KOKORO_KEYSTORE_DIR}/70247_sonatype-credentials | cut -f2 -d'|') +} + +create_settings_xml_file() { + echo " + + + ossrh + ${SONATYPE_USERNAME} + ${SONATYPE_PASSWORD} + + + sonatype-nexus-staging + ${SONATYPE_USERNAME} + ${SONATYPE_PASSWORD} + + + sonatype-nexus-snapshots + ${SONATYPE_USERNAME} + ${SONATYPE_PASSWORD} + + +" > $1 +} \ No newline at end of file diff --git a/.kokoro/release/drop.cfg b/.kokoro/release/drop.cfg new file mode 100644 index 00000000..002e2c21 --- /dev/null +++ b/.kokoro/release/drop.cfg @@ -0,0 +1,9 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/release/drop.sh" +} + +# Download staging properties file. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/java/releases/java-container" \ No newline at end of file diff --git a/.kokoro/release/drop.sh b/.kokoro/release/drop.sh new file mode 100755 index 00000000..5c4551ef --- /dev/null +++ b/.kokoro/release/drop.sh @@ -0,0 +1,32 @@ +#!/bin/bash +# Copyright 2018 Google Inc. +# +# 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. + +set -eo pipefail + +# STAGING_REPOSITORY_ID must be set +if [ -z "${STAGING_REPOSITORY_ID}" ]; then + echo "Missing STAGING_REPOSITORY_ID environment variable" + exit 1 +fi + +source $(dirname "$0")/common.sh +pushd $(dirname "$0")/../../ + +setup_environment_secrets +create_settings_xml_file "settings.xml" + +mvn nexus-staging:drop -B \ + --settings=settings.xml \ + -DstagingRepositoryId=${STAGING_REPOSITORY_ID} diff --git a/.kokoro/release/promote.cfg b/.kokoro/release/promote.cfg new file mode 100644 index 00000000..b93d5b45 --- /dev/null +++ b/.kokoro/release/promote.cfg @@ -0,0 +1,10 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/release/promote.sh" +} + +# Download staging properties file. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/java/releases/java-container" + diff --git a/.kokoro/release/promote.sh b/.kokoro/release/promote.sh new file mode 100755 index 00000000..1fa95fa5 --- /dev/null +++ b/.kokoro/release/promote.sh @@ -0,0 +1,34 @@ +#!/bin/bash +# Copyright 2018 Google Inc. +# +# 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. + +set -eo pipefail + +# STAGING_REPOSITORY_ID must be set +if [ -z "${STAGING_REPOSITORY_ID}" ]; then + echo "Missing STAGING_REPOSITORY_ID environment variable" + exit 1 +fi + +source $(dirname "$0")/common.sh + +pushd $(dirname "$0")/../../ + +setup_environment_secrets +create_settings_xml_file "settings.xml" + +mvn nexus-staging:release -B \ + -DperformRelease=true \ + --settings=settings.xml \ + -DstagingRepositoryId=${STAGING_REPOSITORY_ID} diff --git a/.kokoro/release/publish_javadoc.cfg b/.kokoro/release/publish_javadoc.cfg new file mode 100644 index 00000000..a2d9365c --- /dev/null +++ b/.kokoro/release/publish_javadoc.cfg @@ -0,0 +1,19 @@ +# Format: //devtools/kokoro/config/proto/build.proto +env_vars: { + key: "STAGING_BUCKET" + value: "docs-staging" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/release/publish_javadoc.sh" +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "docuploader_service_account" + } + } +} diff --git a/.kokoro/release/publish_javadoc.sh b/.kokoro/release/publish_javadoc.sh new file mode 100755 index 00000000..87303003 --- /dev/null +++ b/.kokoro/release/publish_javadoc.sh @@ -0,0 +1,55 @@ +#!/bin/bash +# Copyright 2019 Google Inc. +# +# 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. + +set -eo pipefail + +if [[ -z "${CREDENTIALS}" ]]; then + CREDENTIALS=${KOKORO_KEYSTORE_DIR}/73713_docuploader_service_account +fi + +if [[ -z "${STAGING_BUCKET}" ]]; then + echo "Need to set STAGING_BUCKET environment variable" + exit 1 +fi + +# work from the git root directory +pushd $(dirname "$0")/../../ + +# install docuploader package +python3 -m pip install gcp-docuploader + +# compile all packages +mvn clean install -B -DskipTests=true + +NAME=container +VERSION=$(grep ${NAME}: versions.txt | cut -d: -f3) + +# build the docs +mvn site -B + +pushd target/site/apidocs + +# create metadata +python3 -m docuploader create-metadata \ + --name ${NAME} \ + --version ${VERSION} \ + --language java + +# upload docs +python3 -m docuploader upload . \ + --credentials ${CREDENTIALS} \ + --staging-bucket ${STAGING_BUCKET} + +popd diff --git a/.kokoro/release/snapshot.cfg b/.kokoro/release/snapshot.cfg new file mode 100644 index 00000000..49c2f9e6 --- /dev/null +++ b/.kokoro/release/snapshot.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/release/snapshot.sh" +} \ No newline at end of file diff --git a/.kokoro/release/snapshot.sh b/.kokoro/release/snapshot.sh new file mode 100755 index 00000000..098168a7 --- /dev/null +++ b/.kokoro/release/snapshot.sh @@ -0,0 +1,33 @@ +#!/bin/bash +# Copyright 2019 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. + +set -eo pipefail + +source $(dirname "$0")/common.sh +MAVEN_SETTINGS_FILE=$(realpath $(dirname "$0")/../../)/settings.xml +pushd $(dirname "$0")/../../ + +# ensure we're trying to push a snapshot (no-result returns non-zero exit code) +grep SNAPSHOT versions.txt + +setup_environment_secrets +create_settings_xml_file "settings.xml" + +mvn clean install deploy -B \ + --settings ${MAVEN_SETTINGS_FILE} \ + -DperformRelease=true \ + -Dgpg.executable=gpg \ + -Dgpg.passphrase=${GPG_PASSPHRASE} \ + -Dgpg.homedir=${GPG_HOMEDIR} diff --git a/.kokoro/release/stage.cfg b/.kokoro/release/stage.cfg new file mode 100644 index 00000000..dca2b4b5 --- /dev/null +++ b/.kokoro/release/stage.cfg @@ -0,0 +1,44 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-container/.kokoro/release/stage.sh" +} + +# Need to save the properties file +action { + define_artifacts { + regex: "github/java-container/target/nexus-staging/staging/*.properties" + strip_prefix: "github/java-container" + } +} + +# Fetch the token needed for reporting release status to GitHub +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "yoshi-automation-github-key" + } + } +} + +# Fetch magictoken to use with Magic Github Proxy +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "releasetool-magictoken" + } + } +} + +# Fetch api key to use with Magic Github Proxy +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "magic-github-proxy-api-key" + } + } +} diff --git a/.kokoro/release/stage.sh b/.kokoro/release/stage.sh new file mode 100755 index 00000000..3c482cbc --- /dev/null +++ b/.kokoro/release/stage.sh @@ -0,0 +1,42 @@ +#!/bin/bash +# Copyright 2018 Google Inc. +# +# 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. + +set -eo pipefail + +# Start the releasetool reporter +python3 -m pip install gcp-releasetool +python3 -m releasetool publish-reporter-script > /tmp/publisher-script; source /tmp/publisher-script + +source $(dirname "$0")/common.sh +MAVEN_SETTINGS_FILE=$(realpath $(dirname "$0")/../../)/settings.xml +pushd $(dirname "$0")/../../ + +setup_environment_secrets +create_settings_xml_file "settings.xml" + +mvn clean install deploy -B \ + --settings ${MAVEN_SETTINGS_FILE} \ + -DskipTests=true \ + -DperformRelease=true \ + -Dgpg.executable=gpg \ + -Dgpg.passphrase=${GPG_PASSPHRASE} \ + -Dgpg.homedir=${GPG_HOMEDIR} + +if [[ -n "${AUTORELEASE_PR}" ]] +then + mvn nexus-staging:release -B \ + -DperformRelease=true \ + --settings=settings.xml +fi \ No newline at end of file diff --git a/.kokoro/trampoline.sh b/.kokoro/trampoline.sh new file mode 100644 index 00000000..ba17ce01 --- /dev/null +++ b/.kokoro/trampoline.sh @@ -0,0 +1,24 @@ +#!/bin/bash +# Copyright 2018 Google Inc. +# +# 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. +set -eo pipefail +# Always run the cleanup script, regardless of the success of bouncing into +# the container. +function cleanup() { + chmod +x ${KOKORO_GFILE_DIR}/trampoline_cleanup.sh + ${KOKORO_GFILE_DIR}/trampoline_cleanup.sh + echo "cleanup"; +} +trap cleanup EXIT +python3 "${KOKORO_GFILE_DIR}/trampoline_v1.py" diff --git a/google-cloud-container/.repo-metadata.json b/.repo-metadata.json similarity index 86% rename from google-cloud-container/.repo-metadata.json rename to .repo-metadata.json index f66cca07..0e5b50af 100644 --- a/google-cloud-container/.repo-metadata.json +++ b/.repo-metadata.json @@ -6,8 +6,8 @@ "issue_tracker": "https://issuetracker.google.com/savedsearches/559777", "release_level": "beta", "language": "java", - "repo": "googleapis/google-cloud-java", - "repo_short": "google-cloud-java", + "repo": "googleapis/java-container", + "repo_short": "java-container", "distribution_name": "com.google.cloud:google-cloud-container", "api_id": "container.googleapis.com" } diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md new file mode 100644 index 00000000..6b2238bb --- /dev/null +++ b/CODE_OF_CONDUCT.md @@ -0,0 +1,93 @@ +# Code of Conduct + +## Our Pledge + +In the interest of fostering an open and welcoming environment, we as +contributors and maintainers pledge to making participation in our project and +our community a harassment-free experience for everyone, regardless of age, body +size, disability, ethnicity, gender identity and expression, level of +experience, education, socio-economic status, nationality, personal appearance, +race, religion, or sexual identity and orientation. + +## Our Standards + +Examples of behavior that contributes to creating a positive environment +include: + +* Using welcoming and inclusive language +* Being respectful of differing viewpoints and experiences +* Gracefully accepting constructive criticism +* Focusing on what is best for the community +* Showing empathy towards other community members + +Examples of unacceptable behavior by participants include: + +* The use of sexualized language or imagery and unwelcome sexual attention or + advances +* Trolling, insulting/derogatory comments, and personal or political attacks +* Public or private harassment +* Publishing others' private information, such as a physical or electronic + address, without explicit permission +* Other conduct which could reasonably be considered inappropriate in a + professional setting + +## Our Responsibilities + +Project maintainers are responsible for clarifying the standards of acceptable +behavior and are expected to take appropriate and fair corrective action in +response to any instances of unacceptable behavior. + +Project maintainers have the right and responsibility to remove, edit, or reject +comments, commits, code, wiki edits, issues, and other contributions that are +not aligned to this Code of Conduct, or to ban temporarily or permanently any +contributor for other behaviors that they deem inappropriate, threatening, +offensive, or harmful. + +## Scope + +This Code of Conduct applies both within project spaces and in public spaces +when an individual is representing the project or its community. Examples of +representing a project or community include using an official project e-mail +address, posting via an official social media account, or acting as an appointed +representative at an online or offline event. Representation of a project may be +further defined and clarified by project maintainers. + +This Code of Conduct also applies outside the project spaces when the Project +Steward has a reasonable belief that an individual's behavior may have a +negative impact on the project or its community. + +## Conflict Resolution + +We do not believe that all conflict is bad; healthy debate and disagreement +often yield positive results. However, it is never okay to be disrespectful or +to engage in behavior that violates the project’s code of conduct. + +If you see someone violating the code of conduct, you are encouraged to address +the behavior directly with those involved. Many issues can be resolved quickly +and easily, and this gives people more control over the outcome of their +dispute. If you are unable to resolve the matter for any reason, or if the +behavior is threatening or harassing, report it. We are dedicated to providing +an environment where participants feel welcome and safe. + +Reports should be directed to *[PROJECT STEWARD NAME(s) AND EMAIL(s)]*, the +Project Steward(s) for *[PROJECT NAME]*. It is the Project Steward’s duty to +receive and address reported violations of the code of conduct. They will then +work with a committee consisting of representatives from the Open Source +Programs Office and the Google Open Source Strategy team. If for any reason you +are uncomfortable reaching out the Project Steward, please email +opensource@google.com. + +We will investigate every complaint, but you may not receive a direct response. +We will use our discretion in determining when and how to follow up on reported +incidents, which may range from not taking action to permanent expulsion from +the project and project-sponsored spaces. We will notify the accused of the +report and provide them an opportunity to discuss it before any action is taken. +The identity of the reporter will be omitted from the details of the report +supplied to the accused. In potentially harmful situations, such as ongoing +harassment or threats to anyone's safety, we may take action without notice. + +## Attribution + +This Code of Conduct is adapted from the Contributor Covenant, version 1.4, +available at +https://www.contributor-covenant.org/version/1/4/code-of-conduct.html \ No newline at end of file diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 00000000..ebbb59e5 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,28 @@ +# How to Contribute + +We'd love to accept your patches and contributions to this project. There are +just a few small guidelines you need to follow. + +## Contributor License Agreement + +Contributions to this project must be accompanied by a Contributor License +Agreement. You (or your employer) retain the copyright to your contribution; +this simply gives us permission to use and redistribute your contributions as +part of the project. Head over to to see +your current agreements on file or to sign a new one. + +You generally only need to submit a CLA once, so if you've already submitted one +(even if it was for a different project), you probably don't need to do it +again. + +## Code reviews + +All submissions, including submissions by project members, require review. We +use GitHub pull requests for this purpose. Consult +[GitHub Help](https://help.github.com/articles/about-pull-requests/) for more +information on using pull requests. + +## Community Guidelines + +This project follows +[Google's Open Source Community Guidelines](https://opensource.google.com/conduct/). \ No newline at end of file diff --git a/LICENSE b/LICENSE index 4eedc011..d6456956 100644 --- a/LICENSE +++ b/LICENSE @@ -1,4 +1,5 @@ -Apache License + + Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ @@ -178,7 +179,7 @@ Apache License APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "{}" + boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a diff --git a/google-cloud-container/README.md b/README.md similarity index 100% rename from google-cloud-container/README.md rename to README.md diff --git a/codecov.yaml b/codecov.yaml new file mode 100644 index 00000000..5724ea94 --- /dev/null +++ b/codecov.yaml @@ -0,0 +1,4 @@ +--- +codecov: + ci: + - source.cloud.google.com diff --git a/google-cloud-container-bom/pom.xml b/google-cloud-container-bom/pom.xml new file mode 100644 index 00000000..82dc35c2 --- /dev/null +++ b/google-cloud-container-bom/pom.xml @@ -0,0 +1,92 @@ + + + 4.0.0 + com.google.cloud + google-cloud-container-bom + 0.117.0-beta + pom + + com.google.cloud + google-cloud-shared-config + 0.2.1 + + + Google Cloud container BOM + https://github.com/googleapis/java-container + + BOM for Google Cloud Container + + + + Google LLC + + + + + chingor13 + Jeff Ching + chingor@google.com + Google LLC + + Developer + + + + + + scm:git:https://github.com/googleapis/java-container.git + scm:git:git@github.com:googleapis/java-container.git + https://github.com/googleapis/java-container + + + + + sonatype-nexus-snapshots + https://oss.sonatype.org/content/repositories/snapshots + + + sonatype-nexus-staging + https://oss.sonatype.org/service/local/staging/deploy/maven2/ + + + + + + The Apache Software License, Version 2.0 + http://www.apache.org/licenses/LICENSE-2.0.txt + repo + + + + + + + com.google.api.grpc + grpc-google-cloud-container-v1 + 0.82.0 + + + com.google.api.grpc + proto-google-cloud-container-v1 + 0.82.0 + + + com.google.cloud + google-cloud-container + 0.117.0-beta + + + + + + + + org.apache.maven.plugins + maven-checkstyle-plugin + + true + + + + + \ No newline at end of file diff --git a/google-cloud-container/pom.xml b/google-cloud-container/pom.xml index 59386929..db36c58c 100644 --- a/google-cloud-container/pom.xml +++ b/google-cloud-container/pom.xml @@ -1,35 +1,65 @@ 4.0.0 + com.google.cloud google-cloud-container 0.117.0-beta jar Google Cloud Container - https://github.com/googleapis/google-cloud-java/tree/master/google-cloud-clients/google-cloud-container - - Java idiomatic client for Google Cloud Container. - + https://github.com/googleapis/java-container + Java idiomatic client for Google Cloud Container com.google.cloud - google-cloud-clients - 0.117.0-alpha + google-cloud-container-parent + 0.117.0-beta google-cloud-container - ${project.version} - ${project.groupId} - google-cloud-core-grpc + io.grpc + grpc-api + + + io.grpc + grpc-stub + + + io.grpc + grpc-protobuf + + + com.google.api + api-common + + + com.google.protobuf + protobuf-java com.google.api.grpc - proto-google-cloud-container-v1 + proto-google-common-protos com.google.api.grpc - grpc-google-cloud-container-v1 + proto-google-cloud-container-v1 + + + com.google.guava + guava + + + com.google.api + gax + + + com.google.api + gax-grpc + + + org.threeten + threetenbp @@ -38,6 +68,12 @@ junit test + + + com.google.api.grpc + grpc-google-cloud-container-v1 + test + com.google.api @@ -47,29 +83,18 @@ - - - - org.apache.maven.plugins - maven-javadoc-plugin - 3.1.1 - - protected - true - none - true - - - ${project.javadoc.protobufBaseURL} - ../../../../../google-api-grpc/proto-google-cloud-container-v1/target/site/apidocs/ - - - ${project.javadoc.protobufBaseURL} - ../../../../../google-api-grpc/grpc-google-cloud-container-v1/target/site/apidocs/ - - - - - - + + + java9 + + [9,) + + + + javax.annotation + javax.annotation-api + + + + \ No newline at end of file diff --git a/google-cloud-containeranalysis/.repo-metadata.json b/google-cloud-containeranalysis/.repo-metadata.json deleted file mode 100644 index 34ab2890..00000000 --- a/google-cloud-containeranalysis/.repo-metadata.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "name": "containeranalysis", - "name_pretty": "Cloud Container Analysis", - "product_documentation": "https://cloud.google.com/container-registry/docs/container-analysis", - "client_documentation": "https://googleapis.dev/java/google-cloud-clients/latest/index.html?com/google/cloud/devtools/containeranalysis/v1/package-summary.html", - "issue_tracker": "https://issuetracker.google.com/savedsearches/559777", - "release_level": "beta", - "language": "java", - "repo": "googleapis/google-cloud-java", - "repo_short": "google-cloud-java", - "distribution_name": "com.google.cloud:google-cloud-containeranalysis", - "api_id": "containeranalysis.googleapis.com" -} \ No newline at end of file diff --git a/google-cloud-containeranalysis/README.md b/google-cloud-containeranalysis/README.md deleted file mode 100644 index c0818b11..00000000 --- a/google-cloud-containeranalysis/README.md +++ /dev/null @@ -1,97 +0,0 @@ -Google Cloud Java Client for Container Analysis -====================================== - -Java idiomatic client for [Google Cloud Container Analysis][cloud-containeranalysis]. - -[![Kokoro CI](http://storage.googleapis.com/cloud-devrel-public/java/badges/google-cloud-java/master.svg)](http://storage.googleapis.com/cloud-devrel-public/java/badges/google-cloud-java/master.html) -[![Maven](https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-containeranalysis.svg)](https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-containeranalysis.svg) -[![Codacy Badge](https://api.codacy.com/project/badge/grade/9da006ad7c3a4fe1abd142e77c003917)](https://www.codacy.com/app/mziccard/google-cloud-java) - -- [Product Documentation][containeranalysis-product-docs] -- [Client Library Documentation][containeranalysis-client-lib-docs] - -Quickstart ----------- - -[//]: # ({x-version-update-start:google-cloud-containeranalysis:released}) -If you are using Maven, add this to your pom.xml file -```xml - - com.google.cloud - google-cloud-containeranalysis - 0.117.0-beta - -``` -If you are using Gradle, add this to your dependencies -```Groovy -compile 'com.google.cloud:google-cloud-containeranalysis:0.117.0-beta' -``` -If you are using SBT, add this to your dependencies -```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-containeranalysis" % "0.117.0-beta" -``` -[//]: # ({x-version-update-end}) - -Authentication --------------- - -See the [Authentication](https://github.com/googleapis/google-cloud-java#authentication) section in the base directory's README. - -About Google Cloud Container Analysis ----------------------------- - -Google [Cloud Container Analysis API][cloud-containeranalysis] is an implementation of the Grafeas API, which stores, and enables querying and retrieval of critical metadata about all of your software artifacts. - -See the [Container Analysis client library docs][containeranalysis-client-lib-docs] to learn how to use this Cloud Container Analysis API Client Library. - -Getting Started ---------------- -#### Prerequisites -You will need a [Google Developers Console](https://console.developers.google.com/) project with the Container Analysis API enabled. [Follow these instructions](https://cloud.google.com/resource-manager/docs/creating-managing-projects) to get your project set up. You will also need to set up the local development environment by [installing the Google Cloud SDK](https://cloud.google.com/sdk/) and running the following commands in command line: `gcloud auth login` and `gcloud config set project [YOUR PROJECT ID]`. - -#### Installation and setup -You'll need to obtain the `google-cloud-containeranalysis` library. See the [Quickstart](#quickstart) section to add `google-cloud-containeranalysis` as a dependency in your code. - -Troubleshooting ---------------- - -To get help, follow the instructions in the [shared Troubleshooting document](https://github.com/googleapis/google-cloud-common/blob/master/troubleshooting/readme.md#troubleshooting). - -Transport ---------- -Container Analysis uses gRPC for the transport layer. - -Java Versions -------------- - -Java 7 or above is required for using this client. - -Versioning ----------- - -This library follows [Semantic Versioning](http://semver.org/). - -It is currently in major version one (``1.y.z``), which means that the public API should be considered stable. - -Contributing ------------- - -Contributions to this library are always welcome and highly encouraged. - -See `google-cloud`'s [CONTRIBUTING] documentation and the [shared documentation](https://github.com/googleapis/google-cloud-common/blob/master/contributing/readme.md#how-to-contribute-to-gcloud) for more information on how to get started. - -Please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms. See [Code of Conduct][code-of-conduct] for more information. - -License -------- - -Apache 2.0 - See [LICENSE] for more information. - - -[CONTRIBUTING]:https://github.com/googleapis/google-cloud-java/blob/master/CONTRIBUTING.md -[code-of-conduct]:https://github.com/googleapis/google-cloud-java/blob/master/CODE_OF_CONDUCT.md#contributor-code-of-conduct -[LICENSE]: https://github.com/googleapis/google-cloud-java/blob/master/LICENSE -[cloud-platform]: https://cloud.google.com/ -[cloud-containeranalysis]: https://cloud.google.com/container-registry/docs/container-analysis -[containeranalysis-product-docs]: https://cloud.google.com/container-registry/docs/container-analysis -[containeranalysis-client-lib-docs]: https://googleapis.dev/java/google-cloud-clients/latest/index.html?com/google/cloud/devtools/containeranalysis/v1beta1/package-summary.html diff --git a/google-cloud-containeranalysis/pom.xml b/google-cloud-containeranalysis/pom.xml deleted file mode 100644 index 08f92d90..00000000 --- a/google-cloud-containeranalysis/pom.xml +++ /dev/null @@ -1,99 +0,0 @@ - - - 4.0.0 - google-cloud-containeranalysis - 0.117.0-beta - jar - Google Cloud Container Analysis - https://github.com/googleapis/google-cloud-java/tree/master/google-cloud-clients/google-cloud-containeranalysis - - - Java idiomatic client for Google Cloud Container Analysis. - - - com.google.cloud - google-cloud-clients - 0.117.0-alpha - - - google-cloud-containeranalysis - - - - ${project.groupId} - google-cloud-core-grpc - - - com.google.api.grpc - proto-google-cloud-containeranalysis-v1 - - - com.google.api.grpc - proto-google-cloud-containeranalysis-v1beta1 - - - io.grafeas - grafeas - - - - - junit - junit - test - - - com.google.api.grpc - grpc-google-cloud-containeranalysis-v1 - test - - - com.google.api.grpc - grpc-google-cloud-containeranalysis-v1beta1 - test - - - - com.google.api - gax-grpc - testlib - test - - - - - - - org.apache.maven.plugins - maven-javadoc-plugin - 3.1.1 - - protected - true - none - true - - - ${project.javadoc.protobufBaseURL} - ../../../../../google-api-grpc/proto-google-cloud-containeranalysis-v1/target/site/apidocs/ - - - ${project.javadoc.protobufBaseURL} - ../../../../../google-api-grpc/grpc-google-cloud-containeranalysis-v1/target/site/apidocs/ - - - ${project.javadoc.protobufBaseURL} - ../../../../../google-api-grpc/proto-google-cloud-containeranalysis-v1beta1/target/site/apidocs/ - - - ${project.javadoc.protobufBaseURL} - ../../../../../google-api-grpc/grpc-google-cloud-containeranalysis-v1beta1/target/site/apidocs/ - - - - - - - \ No newline at end of file diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/ContainerAnalysisClient.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/ContainerAnalysisClient.java deleted file mode 100644 index aaaa2525..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/ContainerAnalysisClient.java +++ /dev/null @@ -1,576 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1; - -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.cloud.devtools.containeranalysis.v1.stub.ContainerAnalysisStub; -import com.google.cloud.devtools.containeranalysis.v1.stub.ContainerAnalysisStubSettings; -import com.google.containeranalysis.v1.IamResourceName; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import io.grafeas.v1.GrafeasClient; -import java.io.IOException; -import java.util.List; -import java.util.concurrent.TimeUnit; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND SERVICE -/** - * Service Description: Retrieves analysis results of Cloud components such as Docker container - * images. The Container Analysis API is an implementation of the [Grafeas](https://grafeas.io) API. - * - *

Analysis results are stored as a series of occurrences. An `Occurrence` contains information - * about a specific analysis instance on a resource. An occurrence refers to a `Note`. A note - * contains details describing the analysis and is generally stored in a separate project, called a - * `Provider`. Multiple occurrences can refer to the same note. - * - *

For example, an SSL vulnerability could affect multiple images. In this case, there would be - * one note for the vulnerability and an occurrence for each image with the vulnerability referring - * to that note. - * - *

This class provides the ability to make remote calls to the backing service through method - * calls that map to API methods. Sample code to get started: - * - *

- * 
- * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
- *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
- *   Policy policy = Policy.newBuilder().build();
- *   Policy response = containerAnalysisClient.setIamPolicy(resource, policy);
- * }
- * 
- * 
- * - *

Note: close() needs to be called on the containerAnalysisClient object to clean up resources - * such as threads. In the example above, try-with-resources is used, which automatically calls - * close(). - * - *

The surface of this class includes several types of Java methods for each of the API's - * methods: - * - *

    - *
  1. A "flattened" method. With this type of method, the fields of the request type have been - * converted into function parameters. It may be the case that not all fields are available as - * parameters, and not every API method will have a flattened method entry point. - *
  2. A "request object" method. This type of method only takes one parameter, a request object, - * which must be constructed before the call. Not every API method will have a request object - * method. - *
  3. A "callable" method. This type of method takes no parameters and returns an immutable API - * callable object, which can be used to initiate calls to the service. - *
- * - *

See the individual methods for example code. - * - *

Many parameters require resource names to be formatted in a particular way. To assist with - * these names, this class includes a format method for each type of name, and additionally a parse - * method to extract the individual identifiers contained within names that are returned. - * - *

This class can be customized by passing in a custom instance of ContainerAnalysisSettings to - * create(). For example: - * - *

To customize credentials: - * - *

- * 
- * ContainerAnalysisSettings containerAnalysisSettings =
- *     ContainerAnalysisSettings.newBuilder()
- *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
- *         .build();
- * ContainerAnalysisClient containerAnalysisClient =
- *     ContainerAnalysisClient.create(containerAnalysisSettings);
- * 
- * 
- * - * To customize the endpoint: - * - *
- * 
- * ContainerAnalysisSettings containerAnalysisSettings =
- *     ContainerAnalysisSettings.newBuilder().setEndpoint(myEndpoint).build();
- * ContainerAnalysisClient containerAnalysisClient =
- *     ContainerAnalysisClient.create(containerAnalysisSettings);
- * 
- * 
- */ -@Generated("by gapic-generator") -@BetaApi -public class ContainerAnalysisClient implements BackgroundResource { - private final ContainerAnalysisSettings settings; - private final ContainerAnalysisStub stub; - /** - * Returns a new GrafeasClient with the same configured settings. - * - * @throws IOException - */ - public GrafeasClient getGrafeasClient() throws IOException { - return GrafeasClient.create(GrafeasUtils.transformSettings(settings)); - } - - /** Constructs an instance of ContainerAnalysisClient with default settings. */ - public static final ContainerAnalysisClient create() throws IOException { - return create(ContainerAnalysisSettings.newBuilder().build()); - } - - /** - * Constructs an instance of ContainerAnalysisClient, using the given settings. The channels are - * created based on the settings passed in, or defaults for any settings that are not set. - */ - public static final ContainerAnalysisClient create(ContainerAnalysisSettings settings) - throws IOException { - return new ContainerAnalysisClient(settings); - } - - /** - * Constructs an instance of ContainerAnalysisClient, using the given stub for making calls. This - * is for advanced usage - prefer to use ContainerAnalysisSettings}. - */ - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - public static final ContainerAnalysisClient create(ContainerAnalysisStub stub) { - return new ContainerAnalysisClient(stub); - } - - /** - * Constructs an instance of ContainerAnalysisClient, using the given settings. This is protected - * so that it is easy to make a subclass, but otherwise, the static factory methods should be - * preferred. - */ - protected ContainerAnalysisClient(ContainerAnalysisSettings settings) throws IOException { - this.settings = settings; - this.stub = ((ContainerAnalysisStubSettings) settings.getStubSettings()).createStub(); - } - - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - protected ContainerAnalysisClient(ContainerAnalysisStub stub) { - this.settings = null; - this.stub = stub; - } - - public final ContainerAnalysisSettings getSettings() { - return settings; - } - - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - public ContainerAnalysisStub getStub() { - return stub; - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Sets the access control policy on the specified note or occurrence. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or an occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Policy policy = Policy.newBuilder().build();
-   *   Policy response = containerAnalysisClient.setIamPolicy(resource, policy);
-   * }
-   * 
- * - * @param resource REQUIRED: The resource for which the policy is being specified. See the - * operation documentation for the appropriate value for this field. - * @param policy REQUIRED: The complete policy to be applied to the `resource`. The size of the - * policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud - * Platform services (such as Projects) might reject them. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Policy setIamPolicy(IamResourceName resource, Policy policy) { - - SetIamPolicyRequest request = - SetIamPolicyRequest.newBuilder() - .setResource(resource == null ? null : resource.toString()) - .setPolicy(policy) - .build(); - return setIamPolicy(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Sets the access control policy on the specified note or occurrence. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or an occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Policy policy = Policy.newBuilder().build();
-   *   Policy response = containerAnalysisClient.setIamPolicy(resource.toString(), policy);
-   * }
-   * 
- * - * @param resource REQUIRED: The resource for which the policy is being specified. See the - * operation documentation for the appropriate value for this field. - * @param policy REQUIRED: The complete policy to be applied to the `resource`. The size of the - * policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud - * Platform services (such as Projects) might reject them. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Policy setIamPolicy(String resource, Policy policy) { - - SetIamPolicyRequest request = - SetIamPolicyRequest.newBuilder().setResource(resource).setPolicy(policy).build(); - return setIamPolicy(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Sets the access control policy on the specified note or occurrence. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or an occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
-   *   ResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Policy policy = Policy.newBuilder().build();
-   *   SetIamPolicyRequest request = SetIamPolicyRequest.newBuilder()
-   *     .setResource(resource.toString())
-   *     .setPolicy(policy)
-   *     .build();
-   *   Policy response = containerAnalysisClient.setIamPolicy(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Policy setIamPolicy(SetIamPolicyRequest request) { - return setIamPolicyCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Sets the access control policy on the specified note or occurrence. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or an occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
-   *   ResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Policy policy = Policy.newBuilder().build();
-   *   SetIamPolicyRequest request = SetIamPolicyRequest.newBuilder()
-   *     .setResource(resource.toString())
-   *     .setPolicy(policy)
-   *     .build();
-   *   ApiFuture<Policy> future = containerAnalysisClient.setIamPolicyCallable().futureCall(request);
-   *   // Do something
-   *   Policy response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable setIamPolicyCallable() { - return stub.setIamPolicyCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the access control policy for a note or an occurrence resource. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Policy response = containerAnalysisClient.getIamPolicy(resource);
-   * }
-   * 
- * - * @param resource REQUIRED: The resource for which the policy is being requested. See the - * operation documentation for the appropriate value for this field. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Policy getIamPolicy(IamResourceName resource) { - - GetIamPolicyRequest request = - GetIamPolicyRequest.newBuilder() - .setResource(resource == null ? null : resource.toString()) - .build(); - return getIamPolicy(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the access control policy for a note or an occurrence resource. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Policy response = containerAnalysisClient.getIamPolicy(resource.toString());
-   * }
-   * 
- * - * @param resource REQUIRED: The resource for which the policy is being requested. See the - * operation documentation for the appropriate value for this field. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Policy getIamPolicy(String resource) { - - GetIamPolicyRequest request = GetIamPolicyRequest.newBuilder().setResource(resource).build(); - return getIamPolicy(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the access control policy for a note or an occurrence resource. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
-   *   ResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   GetIamPolicyRequest request = GetIamPolicyRequest.newBuilder()
-   *     .setResource(resource.toString())
-   *     .build();
-   *   Policy response = containerAnalysisClient.getIamPolicy(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Policy getIamPolicy(GetIamPolicyRequest request) { - return getIamPolicyCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the access control policy for a note or an occurrence resource. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
-   *   ResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   GetIamPolicyRequest request = GetIamPolicyRequest.newBuilder()
-   *     .setResource(resource.toString())
-   *     .build();
-   *   ApiFuture<Policy> future = containerAnalysisClient.getIamPolicyCallable().futureCall(request);
-   *   // Do something
-   *   Policy response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable getIamPolicyCallable() { - return stub.getIamPolicyCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns the permissions that a caller has on the specified note or occurrence. Requires list - * permission on the project (for example, `containeranalysis.notes.list`). - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   List<String> permissions = new ArrayList<>();
-   *   TestIamPermissionsResponse response = containerAnalysisClient.testIamPermissions(resource, permissions);
-   * }
-   * 
- * - * @param resource REQUIRED: The resource for which the policy detail is being requested. See the - * operation documentation for the appropriate value for this field. - * @param permissions The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final TestIamPermissionsResponse testIamPermissions( - IamResourceName resource, List permissions) { - - TestIamPermissionsRequest request = - TestIamPermissionsRequest.newBuilder() - .setResource(resource == null ? null : resource.toString()) - .addAllPermissions(permissions) - .build(); - return testIamPermissions(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns the permissions that a caller has on the specified note or occurrence. Requires list - * permission on the project (for example, `containeranalysis.notes.list`). - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   List<String> permissions = new ArrayList<>();
-   *   TestIamPermissionsResponse response = containerAnalysisClient.testIamPermissions(resource.toString(), permissions);
-   * }
-   * 
- * - * @param resource REQUIRED: The resource for which the policy detail is being requested. See the - * operation documentation for the appropriate value for this field. - * @param permissions The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final TestIamPermissionsResponse testIamPermissions( - String resource, List permissions) { - - TestIamPermissionsRequest request = - TestIamPermissionsRequest.newBuilder() - .setResource(resource) - .addAllPermissions(permissions) - .build(); - return testIamPermissions(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns the permissions that a caller has on the specified note or occurrence. Requires list - * permission on the project (for example, `containeranalysis.notes.list`). - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
-   *   ResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   List<String> permissions = new ArrayList<>();
-   *   TestIamPermissionsRequest request = TestIamPermissionsRequest.newBuilder()
-   *     .setResource(resource.toString())
-   *     .addAllPermissions(permissions)
-   *     .build();
-   *   TestIamPermissionsResponse response = containerAnalysisClient.testIamPermissions(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final TestIamPermissionsResponse testIamPermissions(TestIamPermissionsRequest request) { - return testIamPermissionsCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns the permissions that a caller has on the specified note or occurrence. Requires list - * permission on the project (for example, `containeranalysis.notes.list`). - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
-   *   ResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   List<String> permissions = new ArrayList<>();
-   *   TestIamPermissionsRequest request = TestIamPermissionsRequest.newBuilder()
-   *     .setResource(resource.toString())
-   *     .addAllPermissions(permissions)
-   *     .build();
-   *   ApiFuture<TestIamPermissionsResponse> future = containerAnalysisClient.testIamPermissionsCallable().futureCall(request);
-   *   // Do something
-   *   TestIamPermissionsResponse response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable - testIamPermissionsCallable() { - return stub.testIamPermissionsCallable(); - } - - @Override - public final void close() { - stub.close(); - } - - @Override - public void shutdown() { - stub.shutdown(); - } - - @Override - public boolean isShutdown() { - return stub.isShutdown(); - } - - @Override - public boolean isTerminated() { - return stub.isTerminated(); - } - - @Override - public void shutdownNow() { - stub.shutdownNow(); - } - - @Override - public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { - return stub.awaitTermination(duration, unit); - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/ContainerAnalysisSettings.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/ContainerAnalysisSettings.java deleted file mode 100644 index 0d6917b2..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/ContainerAnalysisSettings.java +++ /dev/null @@ -1,203 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1; - -import com.google.api.core.ApiFunction; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.GoogleCredentialsProvider; -import com.google.api.gax.core.InstantiatingExecutorProvider; -import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.ClientSettings; -import com.google.api.gax.rpc.TransportChannelProvider; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.cloud.devtools.containeranalysis.v1.stub.ContainerAnalysisStubSettings; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import java.io.IOException; -import java.util.List; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * Settings class to configure an instance of {@link ContainerAnalysisClient}. - * - *

The default instance has everything set to sensible defaults: - * - *

    - *
  • The default service address (containeranalysis.googleapis.com) and default port (443) are - * used. - *
  • Credentials are acquired automatically through Application Default Credentials. - *
  • Retries are configured for idempotent methods but not for non-idempotent methods. - *
- * - *

The builder of this class is recursive, so contained classes are themselves builders. When - * build() is called, the tree of builders is called to create the complete settings object. - * - *

For example, to set the total timeout of setIamPolicy to 30 seconds: - * - *

- * 
- * ContainerAnalysisSettings.Builder containerAnalysisSettingsBuilder =
- *     ContainerAnalysisSettings.newBuilder();
- * containerAnalysisSettingsBuilder.setIamPolicySettings().getRetrySettings().toBuilder()
- *     .setTotalTimeout(Duration.ofSeconds(30));
- * ContainerAnalysisSettings containerAnalysisSettings = containerAnalysisSettingsBuilder.build();
- * 
- * 
- */ -@Generated("by gapic-generator") -@BetaApi -public class ContainerAnalysisSettings extends ClientSettings { - /** Returns the object with the settings used for calls to setIamPolicy. */ - public UnaryCallSettings setIamPolicySettings() { - return ((ContainerAnalysisStubSettings) getStubSettings()).setIamPolicySettings(); - } - - /** Returns the object with the settings used for calls to getIamPolicy. */ - public UnaryCallSettings getIamPolicySettings() { - return ((ContainerAnalysisStubSettings) getStubSettings()).getIamPolicySettings(); - } - - /** Returns the object with the settings used for calls to testIamPermissions. */ - public UnaryCallSettings - testIamPermissionsSettings() { - return ((ContainerAnalysisStubSettings) getStubSettings()).testIamPermissionsSettings(); - } - - public static final ContainerAnalysisSettings create(ContainerAnalysisStubSettings stub) - throws IOException { - return new ContainerAnalysisSettings.Builder(stub.toBuilder()).build(); - } - - /** Returns a builder for the default ExecutorProvider for this service. */ - public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { - return ContainerAnalysisStubSettings.defaultExecutorProviderBuilder(); - } - - /** Returns the default service endpoint. */ - public static String getDefaultEndpoint() { - return ContainerAnalysisStubSettings.getDefaultEndpoint(); - } - - /** Returns the default service scopes. */ - public static List getDefaultServiceScopes() { - return ContainerAnalysisStubSettings.getDefaultServiceScopes(); - } - - /** Returns a builder for the default credentials for this service. */ - public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { - return ContainerAnalysisStubSettings.defaultCredentialsProviderBuilder(); - } - - /** Returns a builder for the default ChannelProvider for this service. */ - public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { - return ContainerAnalysisStubSettings.defaultGrpcTransportProviderBuilder(); - } - - public static TransportChannelProvider defaultTransportChannelProvider() { - return ContainerAnalysisStubSettings.defaultTransportChannelProvider(); - } - - @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") - public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { - return ContainerAnalysisStubSettings.defaultApiClientHeaderProviderBuilder(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder() { - return Builder.createDefault(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder(ClientContext clientContext) { - return new Builder(clientContext); - } - - /** Returns a builder containing all the values of this settings class. */ - public Builder toBuilder() { - return new Builder(this); - } - - protected ContainerAnalysisSettings(Builder settingsBuilder) throws IOException { - super(settingsBuilder); - } - - /** Builder for ContainerAnalysisSettings. */ - public static class Builder extends ClientSettings.Builder { - protected Builder() throws IOException { - this((ClientContext) null); - } - - protected Builder(ClientContext clientContext) { - super(ContainerAnalysisStubSettings.newBuilder(clientContext)); - } - - private static Builder createDefault() { - return new Builder(ContainerAnalysisStubSettings.newBuilder()); - } - - protected Builder(ContainerAnalysisSettings settings) { - super(settings.getStubSettings().toBuilder()); - } - - protected Builder(ContainerAnalysisStubSettings.Builder stubSettings) { - super(stubSettings); - } - - public ContainerAnalysisStubSettings.Builder getStubSettingsBuilder() { - return ((ContainerAnalysisStubSettings.Builder) getStubSettings()); - } - - // NEXT_MAJOR_VER: remove 'throws Exception' - /** - * Applies the given settings updater function to all of the unary API methods in this service. - * - *

Note: This method does not support applying settings to streaming methods. - */ - public Builder applyToAllUnaryMethods( - ApiFunction, Void> settingsUpdater) throws Exception { - super.applyToAllUnaryMethods( - getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); - return this; - } - - /** Returns the builder for the settings used for calls to setIamPolicy. */ - public UnaryCallSettings.Builder setIamPolicySettings() { - return getStubSettingsBuilder().setIamPolicySettings(); - } - - /** Returns the builder for the settings used for calls to getIamPolicy. */ - public UnaryCallSettings.Builder getIamPolicySettings() { - return getStubSettingsBuilder().getIamPolicySettings(); - } - - /** Returns the builder for the settings used for calls to testIamPermissions. */ - public UnaryCallSettings.Builder - testIamPermissionsSettings() { - return getStubSettingsBuilder().testIamPermissionsSettings(); - } - - @Override - public ContainerAnalysisSettings build() throws IOException { - return new ContainerAnalysisSettings(this); - } - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/GrafeasUtils.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/GrafeasUtils.java deleted file mode 100644 index d21869d5..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/GrafeasUtils.java +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1; - -import io.grafeas.v1.GrafeasSettings; -import java.io.IOException; - -/** - * This internal class is used to link the ContainerAnalysisClient to GrafeasClient implementations. - * Given a ContainerAnalysisClient, we need to instantiate a GrafeasClient with the same - * configuration. - */ -class GrafeasUtils { - - /** Converts ContainerAnalysisSettings to GrafeasSettings using the same configuration. */ - static GrafeasSettings transformSettings(ContainerAnalysisSettings settings) throws IOException { - return GrafeasSettings.newBuilder() - .setClock(settings.getClock()) - .setCredentialsProvider(settings.getCredentialsProvider()) - .setEndpoint(settings.getEndpoint()) - .setExecutorProvider(settings.getExecutorProvider()) - .setHeaderProvider(settings.getHeaderProvider()) - .setTransportChannelProvider(settings.getTransportChannelProvider()) - .setWatchdogCheckInterval(settings.getWatchdogCheckInterval()) - .setWatchdogProvider(settings.getWatchdogProvider()) - .build(); - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/package-info.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/package-info.java deleted file mode 100644 index 450fd4c9..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/package-info.java +++ /dev/null @@ -1,51 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * A client to Container Analysis API. - * - *

The interfaces provided are listed below, along with usage samples. - * - *

======================= ContainerAnalysisClient ======================= - * - *

Service Description: Retrieves analysis results of Cloud components such as Docker container - * images. The Container Analysis API is an implementation of the [Grafeas](https://grafeas.io) API. - * - *

Analysis results are stored as a series of occurrences. An `Occurrence` contains information - * about a specific analysis instance on a resource. An occurrence refers to a `Note`. A note - * contains details describing the analysis and is generally stored in a separate project, called a - * `Provider`. Multiple occurrences can refer to the same note. - * - *

For example, an SSL vulnerability could affect multiple images. In this case, there would be - * one note for the vulnerability and an occurrence for each image with the vulnerability referring - * to that note. - * - *

Sample for ContainerAnalysisClient: - * - *

- * 
- * try (ContainerAnalysisClient containerAnalysisClient = ContainerAnalysisClient.create()) {
- *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
- *   Policy policy = Policy.newBuilder().build();
- *   Policy response = containerAnalysisClient.setIamPolicy(resource, policy);
- * }
- * 
- * 
- */ -@Generated("by gapic-generator") -package com.google.cloud.devtools.containeranalysis.v1; - -import javax.annotation.Generated; diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/ContainerAnalysisStub.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/ContainerAnalysisStub.java deleted file mode 100644 index c2a6025d..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/ContainerAnalysisStub.java +++ /dev/null @@ -1,53 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1.stub; - -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * Base stub class for Container Analysis API. - * - *

This class is for advanced usage and reflects the underlying API directly. - */ -@Generated("by gapic-generator") -@BetaApi("A restructuring of stub classes is planned, so this may break in the future") -public abstract class ContainerAnalysisStub implements BackgroundResource { - - public UnaryCallable setIamPolicyCallable() { - throw new UnsupportedOperationException("Not implemented: setIamPolicyCallable()"); - } - - public UnaryCallable getIamPolicyCallable() { - throw new UnsupportedOperationException("Not implemented: getIamPolicyCallable()"); - } - - public UnaryCallable - testIamPermissionsCallable() { - throw new UnsupportedOperationException("Not implemented: testIamPermissionsCallable()"); - } - - @Override - public abstract void close(); -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/ContainerAnalysisStubSettings.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/ContainerAnalysisStubSettings.java deleted file mode 100644 index c2f4d493..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/ContainerAnalysisStubSettings.java +++ /dev/null @@ -1,318 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1.stub; - -import com.google.api.core.ApiFunction; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.GaxProperties; -import com.google.api.gax.core.GoogleCredentialsProvider; -import com.google.api.gax.core.InstantiatingExecutorProvider; -import com.google.api.gax.grpc.GaxGrpcProperties; -import com.google.api.gax.grpc.GrpcTransportChannel; -import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; -import com.google.api.gax.retrying.RetrySettings; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.StatusCode; -import com.google.api.gax.rpc.StubSettings; -import com.google.api.gax.rpc.TransportChannelProvider; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.common.collect.ImmutableList; -import com.google.common.collect.ImmutableMap; -import com.google.common.collect.ImmutableSet; -import com.google.common.collect.Lists; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import java.io.IOException; -import java.util.List; -import javax.annotation.Generated; -import org.threeten.bp.Duration; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * Settings class to configure an instance of {@link ContainerAnalysisStub}. - * - *

The default instance has everything set to sensible defaults: - * - *

    - *
  • The default service address (containeranalysis.googleapis.com) and default port (443) are - * used. - *
  • Credentials are acquired automatically through Application Default Credentials. - *
  • Retries are configured for idempotent methods but not for non-idempotent methods. - *
- * - *

The builder of this class is recursive, so contained classes are themselves builders. When - * build() is called, the tree of builders is called to create the complete settings object. - * - *

For example, to set the total timeout of setIamPolicy to 30 seconds: - * - *

- * 
- * ContainerAnalysisStubSettings.Builder containerAnalysisSettingsBuilder =
- *     ContainerAnalysisStubSettings.newBuilder();
- * containerAnalysisSettingsBuilder.setIamPolicySettings().getRetrySettings().toBuilder()
- *     .setTotalTimeout(Duration.ofSeconds(30));
- * ContainerAnalysisStubSettings containerAnalysisSettings = containerAnalysisSettingsBuilder.build();
- * 
- * 
- */ -@Generated("by gapic-generator") -@BetaApi -public class ContainerAnalysisStubSettings extends StubSettings { - /** The default scopes of the service. */ - private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); - - private final UnaryCallSettings setIamPolicySettings; - private final UnaryCallSettings getIamPolicySettings; - private final UnaryCallSettings - testIamPermissionsSettings; - - /** Returns the object with the settings used for calls to setIamPolicy. */ - public UnaryCallSettings setIamPolicySettings() { - return setIamPolicySettings; - } - - /** Returns the object with the settings used for calls to getIamPolicy. */ - public UnaryCallSettings getIamPolicySettings() { - return getIamPolicySettings; - } - - /** Returns the object with the settings used for calls to testIamPermissions. */ - public UnaryCallSettings - testIamPermissionsSettings() { - return testIamPermissionsSettings; - } - - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - public ContainerAnalysisStub createStub() throws IOException { - if (getTransportChannelProvider() - .getTransportName() - .equals(GrpcTransportChannel.getGrpcTransportName())) { - return GrpcContainerAnalysisStub.create(this); - } else { - throw new UnsupportedOperationException( - "Transport not supported: " + getTransportChannelProvider().getTransportName()); - } - } - - /** Returns a builder for the default ExecutorProvider for this service. */ - public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { - return InstantiatingExecutorProvider.newBuilder(); - } - - /** Returns the default service endpoint. */ - public static String getDefaultEndpoint() { - return "containeranalysis.googleapis.com:443"; - } - - /** Returns the default service scopes. */ - public static List getDefaultServiceScopes() { - return DEFAULT_SERVICE_SCOPES; - } - - /** Returns a builder for the default credentials for this service. */ - public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { - return GoogleCredentialsProvider.newBuilder().setScopesToApply(DEFAULT_SERVICE_SCOPES); - } - - /** Returns a builder for the default ChannelProvider for this service. */ - public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { - return InstantiatingGrpcChannelProvider.newBuilder() - .setMaxInboundMessageSize(Integer.MAX_VALUE); - } - - public static TransportChannelProvider defaultTransportChannelProvider() { - return defaultGrpcTransportProviderBuilder().build(); - } - - @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") - public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { - return ApiClientHeaderProvider.newBuilder() - .setGeneratedLibToken( - "gapic", GaxProperties.getLibraryVersion(ContainerAnalysisStubSettings.class)) - .setTransportToken( - GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder() { - return Builder.createDefault(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder(ClientContext clientContext) { - return new Builder(clientContext); - } - - /** Returns a builder containing all the values of this settings class. */ - public Builder toBuilder() { - return new Builder(this); - } - - protected ContainerAnalysisStubSettings(Builder settingsBuilder) throws IOException { - super(settingsBuilder); - - setIamPolicySettings = settingsBuilder.setIamPolicySettings().build(); - getIamPolicySettings = settingsBuilder.getIamPolicySettings().build(); - testIamPermissionsSettings = settingsBuilder.testIamPermissionsSettings().build(); - } - - /** Builder for ContainerAnalysisStubSettings. */ - public static class Builder extends StubSettings.Builder { - private final ImmutableList> unaryMethodSettingsBuilders; - - private final UnaryCallSettings.Builder setIamPolicySettings; - private final UnaryCallSettings.Builder getIamPolicySettings; - private final UnaryCallSettings.Builder - testIamPermissionsSettings; - - private static final ImmutableMap> - RETRYABLE_CODE_DEFINITIONS; - - static { - ImmutableMap.Builder> definitions = - ImmutableMap.builder(); - definitions.put( - "idempotent", - ImmutableSet.copyOf( - Lists.newArrayList( - StatusCode.Code.DEADLINE_EXCEEDED, StatusCode.Code.UNAVAILABLE))); - definitions.put("non_idempotent", ImmutableSet.copyOf(Lists.newArrayList())); - RETRYABLE_CODE_DEFINITIONS = definitions.build(); - } - - private static final ImmutableMap RETRY_PARAM_DEFINITIONS; - - static { - ImmutableMap.Builder definitions = ImmutableMap.builder(); - RetrySettings settings = null; - settings = - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(100L)) - .setRetryDelayMultiplier(1.3) - .setMaxRetryDelay(Duration.ofMillis(60000L)) - .setInitialRpcTimeout(Duration.ofMillis(20000L)) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ofMillis(20000L)) - .setTotalTimeout(Duration.ofMillis(600000L)) - .build(); - definitions.put("default", settings); - RETRY_PARAM_DEFINITIONS = definitions.build(); - } - - protected Builder() { - this((ClientContext) null); - } - - protected Builder(ClientContext clientContext) { - super(clientContext); - - setIamPolicySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - getIamPolicySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - testIamPermissionsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - unaryMethodSettingsBuilders = - ImmutableList.>of( - setIamPolicySettings, getIamPolicySettings, testIamPermissionsSettings); - - initDefaults(this); - } - - private static Builder createDefault() { - Builder builder = new Builder((ClientContext) null); - builder.setTransportChannelProvider(defaultTransportChannelProvider()); - builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); - builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); - builder.setEndpoint(getDefaultEndpoint()); - return initDefaults(builder); - } - - private static Builder initDefaults(Builder builder) { - - builder - .setIamPolicySettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .getIamPolicySettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .testIamPermissionsSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - return builder; - } - - protected Builder(ContainerAnalysisStubSettings settings) { - super(settings); - - setIamPolicySettings = settings.setIamPolicySettings.toBuilder(); - getIamPolicySettings = settings.getIamPolicySettings.toBuilder(); - testIamPermissionsSettings = settings.testIamPermissionsSettings.toBuilder(); - - unaryMethodSettingsBuilders = - ImmutableList.>of( - setIamPolicySettings, getIamPolicySettings, testIamPermissionsSettings); - } - - // NEXT_MAJOR_VER: remove 'throws Exception' - /** - * Applies the given settings updater function to all of the unary API methods in this service. - * - *

Note: This method does not support applying settings to streaming methods. - */ - public Builder applyToAllUnaryMethods( - ApiFunction, Void> settingsUpdater) throws Exception { - super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); - return this; - } - - public ImmutableList> unaryMethodSettingsBuilders() { - return unaryMethodSettingsBuilders; - } - - /** Returns the builder for the settings used for calls to setIamPolicy. */ - public UnaryCallSettings.Builder setIamPolicySettings() { - return setIamPolicySettings; - } - - /** Returns the builder for the settings used for calls to getIamPolicy. */ - public UnaryCallSettings.Builder getIamPolicySettings() { - return getIamPolicySettings; - } - - /** Returns the builder for the settings used for calls to testIamPermissions. */ - public UnaryCallSettings.Builder - testIamPermissionsSettings() { - return testIamPermissionsSettings; - } - - @Override - public ContainerAnalysisStubSettings build() throws IOException { - return new ContainerAnalysisStubSettings(this); - } - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/GrpcContainerAnalysisCallableFactory.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/GrpcContainerAnalysisCallableFactory.java deleted file mode 100644 index dc0209d1..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/GrpcContainerAnalysisCallableFactory.java +++ /dev/null @@ -1,115 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1.stub; - -import com.google.api.core.BetaApi; -import com.google.api.gax.grpc.GrpcCallSettings; -import com.google.api.gax.grpc.GrpcCallableFactory; -import com.google.api.gax.grpc.GrpcStubCallableFactory; -import com.google.api.gax.rpc.BatchingCallSettings; -import com.google.api.gax.rpc.BidiStreamingCallable; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.ClientStreamingCallable; -import com.google.api.gax.rpc.OperationCallSettings; -import com.google.api.gax.rpc.OperationCallable; -import com.google.api.gax.rpc.PagedCallSettings; -import com.google.api.gax.rpc.ServerStreamingCallSettings; -import com.google.api.gax.rpc.ServerStreamingCallable; -import com.google.api.gax.rpc.StreamingCallSettings; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.longrunning.stub.OperationsStub; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * gRPC callable factory implementation for Container Analysis API. - * - *

This class is for advanced usage. - */ -@Generated("by gapic-generator") -@BetaApi("The surface for use by generated code is not stable yet and may change in the future.") -public class GrpcContainerAnalysisCallableFactory implements GrpcStubCallableFactory { - @Override - public UnaryCallable createUnaryCallable( - GrpcCallSettings grpcCallSettings, - UnaryCallSettings callSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createUnaryCallable(grpcCallSettings, callSettings, clientContext); - } - - @Override - public - UnaryCallable createPagedCallable( - GrpcCallSettings grpcCallSettings, - PagedCallSettings pagedCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createPagedCallable( - grpcCallSettings, pagedCallSettings, clientContext); - } - - @Override - public UnaryCallable createBatchingCallable( - GrpcCallSettings grpcCallSettings, - BatchingCallSettings batchingCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createBatchingCallable( - grpcCallSettings, batchingCallSettings, clientContext); - } - - @BetaApi( - "The surface for long-running operations is not stable yet and may change in the future.") - @Override - public - OperationCallable createOperationCallable( - GrpcCallSettings grpcCallSettings, - OperationCallSettings operationCallSettings, - ClientContext clientContext, - OperationsStub operationsStub) { - return GrpcCallableFactory.createOperationCallable( - grpcCallSettings, operationCallSettings, clientContext, operationsStub); - } - - @Override - public - BidiStreamingCallable createBidiStreamingCallable( - GrpcCallSettings grpcCallSettings, - StreamingCallSettings streamingCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createBidiStreamingCallable( - grpcCallSettings, streamingCallSettings, clientContext); - } - - @Override - public - ServerStreamingCallable createServerStreamingCallable( - GrpcCallSettings grpcCallSettings, - ServerStreamingCallSettings streamingCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createServerStreamingCallable( - grpcCallSettings, streamingCallSettings, clientContext); - } - - @Override - public - ClientStreamingCallable createClientStreamingCallable( - GrpcCallSettings grpcCallSettings, - StreamingCallSettings streamingCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createClientStreamingCallable( - grpcCallSettings, streamingCallSettings, clientContext); - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/GrpcContainerAnalysisStub.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/GrpcContainerAnalysisStub.java deleted file mode 100644 index aab940b9..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1/stub/GrpcContainerAnalysisStub.java +++ /dev/null @@ -1,221 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1.stub; - -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.core.BackgroundResourceAggregation; -import com.google.api.gax.grpc.GrpcCallSettings; -import com.google.api.gax.grpc.GrpcStubCallableFactory; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.RequestParamsExtractor; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.common.collect.ImmutableMap; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import io.grpc.MethodDescriptor; -import io.grpc.protobuf.ProtoUtils; -import java.io.IOException; -import java.util.Map; -import java.util.concurrent.TimeUnit; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * gRPC stub implementation for Container Analysis API. - * - *

This class is for advanced usage and reflects the underlying API directly. - */ -@Generated("by gapic-generator") -@BetaApi("A restructuring of stub classes is planned, so this may break in the future") -public class GrpcContainerAnalysisStub extends ContainerAnalysisStub { - - private static final MethodDescriptor setIamPolicyMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.containeranalysis.v1.ContainerAnalysis/SetIamPolicy") - .setRequestMarshaller(ProtoUtils.marshaller(SetIamPolicyRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Policy.getDefaultInstance())) - .build(); - private static final MethodDescriptor getIamPolicyMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.containeranalysis.v1.ContainerAnalysis/GetIamPolicy") - .setRequestMarshaller(ProtoUtils.marshaller(GetIamPolicyRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Policy.getDefaultInstance())) - .build(); - private static final MethodDescriptor - testIamPermissionsMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - "google.devtools.containeranalysis.v1.ContainerAnalysis/TestIamPermissions") - .setRequestMarshaller( - ProtoUtils.marshaller(TestIamPermissionsRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(TestIamPermissionsResponse.getDefaultInstance())) - .build(); - - private final BackgroundResource backgroundResources; - - private final UnaryCallable setIamPolicyCallable; - private final UnaryCallable getIamPolicyCallable; - private final UnaryCallable - testIamPermissionsCallable; - - private final GrpcStubCallableFactory callableFactory; - - public static final GrpcContainerAnalysisStub create(ContainerAnalysisStubSettings settings) - throws IOException { - return new GrpcContainerAnalysisStub(settings, ClientContext.create(settings)); - } - - public static final GrpcContainerAnalysisStub create(ClientContext clientContext) - throws IOException { - return new GrpcContainerAnalysisStub( - ContainerAnalysisStubSettings.newBuilder().build(), clientContext); - } - - public static final GrpcContainerAnalysisStub create( - ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { - return new GrpcContainerAnalysisStub( - ContainerAnalysisStubSettings.newBuilder().build(), clientContext, callableFactory); - } - - /** - * Constructs an instance of GrpcContainerAnalysisStub, using the given settings. This is - * protected so that it is easy to make a subclass, but otherwise, the static factory methods - * should be preferred. - */ - protected GrpcContainerAnalysisStub( - ContainerAnalysisStubSettings settings, ClientContext clientContext) throws IOException { - this(settings, clientContext, new GrpcContainerAnalysisCallableFactory()); - } - - /** - * Constructs an instance of GrpcContainerAnalysisStub, using the given settings. This is - * protected so that it is easy to make a subclass, but otherwise, the static factory methods - * should be preferred. - */ - protected GrpcContainerAnalysisStub( - ContainerAnalysisStubSettings settings, - ClientContext clientContext, - GrpcStubCallableFactory callableFactory) - throws IOException { - this.callableFactory = callableFactory; - - GrpcCallSettings setIamPolicyTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(setIamPolicyMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(SetIamPolicyRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("resource", String.valueOf(request.getResource())); - return params.build(); - } - }) - .build(); - GrpcCallSettings getIamPolicyTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(getIamPolicyMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(GetIamPolicyRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("resource", String.valueOf(request.getResource())); - return params.build(); - } - }) - .build(); - GrpcCallSettings - testIamPermissionsTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(testIamPermissionsMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(TestIamPermissionsRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("resource", String.valueOf(request.getResource())); - return params.build(); - } - }) - .build(); - - this.setIamPolicyCallable = - callableFactory.createUnaryCallable( - setIamPolicyTransportSettings, settings.setIamPolicySettings(), clientContext); - this.getIamPolicyCallable = - callableFactory.createUnaryCallable( - getIamPolicyTransportSettings, settings.getIamPolicySettings(), clientContext); - this.testIamPermissionsCallable = - callableFactory.createUnaryCallable( - testIamPermissionsTransportSettings, - settings.testIamPermissionsSettings(), - clientContext); - - backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); - } - - public UnaryCallable setIamPolicyCallable() { - return setIamPolicyCallable; - } - - public UnaryCallable getIamPolicyCallable() { - return getIamPolicyCallable; - } - - public UnaryCallable - testIamPermissionsCallable() { - return testIamPermissionsCallable; - } - - @Override - public final void close() { - shutdown(); - } - - @Override - public void shutdown() { - backgroundResources.shutdown(); - } - - @Override - public boolean isShutdown() { - return backgroundResources.isShutdown(); - } - - @Override - public boolean isTerminated() { - return backgroundResources.isTerminated(); - } - - @Override - public void shutdownNow() { - backgroundResources.shutdownNow(); - } - - @Override - public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { - return backgroundResources.awaitTermination(duration, unit); - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/ContainerAnalysisV1Beta1Client.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/ContainerAnalysisV1Beta1Client.java deleted file mode 100644 index 041781c9..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/ContainerAnalysisV1Beta1Client.java +++ /dev/null @@ -1,1001 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1; - -import com.google.api.core.ApiFunction; -import com.google.api.core.ApiFuture; -import com.google.api.core.ApiFutures; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.paging.AbstractFixedSizeCollection; -import com.google.api.gax.paging.AbstractPage; -import com.google.api.gax.paging.AbstractPagedListResponse; -import com.google.api.gax.rpc.PageContext; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.cloud.devtools.containeranalysis.v1beta1.stub.ContainerAnalysisV1Beta1Stub; -import com.google.cloud.devtools.containeranalysis.v1beta1.stub.ContainerAnalysisV1Beta1StubSettings; -import com.google.common.util.concurrent.MoreExecutors; -import com.google.containeranalysis.v1beta1.GetScanConfigRequest; -import com.google.containeranalysis.v1beta1.IamResourceName; -import com.google.containeranalysis.v1beta1.ListScanConfigsRequest; -import com.google.containeranalysis.v1beta1.ListScanConfigsResponse; -import com.google.containeranalysis.v1beta1.ProjectName; -import com.google.containeranalysis.v1beta1.ScanConfig; -import com.google.containeranalysis.v1beta1.ScanConfigName; -import com.google.containeranalysis.v1beta1.UpdateScanConfigRequest; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import java.io.IOException; -import java.util.List; -import java.util.concurrent.TimeUnit; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND SERVICE -/** - * Service Description: Retrieves analysis results of Cloud components such as Docker container - * images. The Container Analysis API is an implementation of the [Grafeas](grafeas.io) API. - * - *

Analysis results are stored as a series of occurrences. An `Occurrence` contains information - * about a specific analysis instance on a resource. An occurrence refers to a `Note`. A note - * contains details describing the analysis and is generally stored in a separate project, called a - * `Provider`. Multiple occurrences can refer to the same note. - * - *

For example, an SSL vulnerability could affect multiple images. In this case, there would be - * one note for the vulnerability and an occurrence for each image with the vulnerability referring - * to that note. - * - *

This class provides the ability to make remote calls to the backing service through method - * calls that map to API methods. Sample code to get started: - * - *

- * 
- * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
- *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
- *   Policy policy = Policy.newBuilder().build();
- *   Policy response = containerAnalysisV1Beta1Client.setIamPolicy(resource, policy);
- * }
- * 
- * 
- * - *

Note: close() needs to be called on the containerAnalysisV1Beta1Client object to clean up - * resources such as threads. In the example above, try-with-resources is used, which automatically - * calls close(). - * - *

The surface of this class includes several types of Java methods for each of the API's - * methods: - * - *

    - *
  1. A "flattened" method. With this type of method, the fields of the request type have been - * converted into function parameters. It may be the case that not all fields are available as - * parameters, and not every API method will have a flattened method entry point. - *
  2. A "request object" method. This type of method only takes one parameter, a request object, - * which must be constructed before the call. Not every API method will have a request object - * method. - *
  3. A "callable" method. This type of method takes no parameters and returns an immutable API - * callable object, which can be used to initiate calls to the service. - *
- * - *

See the individual methods for example code. - * - *

Many parameters require resource names to be formatted in a particular way. To assist with - * these names, this class includes a format method for each type of name, and additionally a parse - * method to extract the individual identifiers contained within names that are returned. - * - *

This class can be customized by passing in a custom instance of - * ContainerAnalysisV1Beta1Settings to create(). For example: - * - *

To customize credentials: - * - *

- * 
- * ContainerAnalysisV1Beta1Settings containerAnalysisV1Beta1Settings =
- *     ContainerAnalysisV1Beta1Settings.newBuilder()
- *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
- *         .build();
- * ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client =
- *     ContainerAnalysisV1Beta1Client.create(containerAnalysisV1Beta1Settings);
- * 
- * 
- * - * To customize the endpoint: - * - *
- * 
- * ContainerAnalysisV1Beta1Settings containerAnalysisV1Beta1Settings =
- *     ContainerAnalysisV1Beta1Settings.newBuilder().setEndpoint(myEndpoint).build();
- * ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client =
- *     ContainerAnalysisV1Beta1Client.create(containerAnalysisV1Beta1Settings);
- * 
- * 
- */ -@Generated("by gapic-generator") -@BetaApi -public class ContainerAnalysisV1Beta1Client implements BackgroundResource { - private final ContainerAnalysisV1Beta1Settings settings; - private final ContainerAnalysisV1Beta1Stub stub; - - /** Constructs an instance of ContainerAnalysisV1Beta1Client with default settings. */ - public static final ContainerAnalysisV1Beta1Client create() throws IOException { - return create(ContainerAnalysisV1Beta1Settings.newBuilder().build()); - } - - /** - * Constructs an instance of ContainerAnalysisV1Beta1Client, using the given settings. The - * channels are created based on the settings passed in, or defaults for any settings that are not - * set. - */ - public static final ContainerAnalysisV1Beta1Client create( - ContainerAnalysisV1Beta1Settings settings) throws IOException { - return new ContainerAnalysisV1Beta1Client(settings); - } - - /** - * Constructs an instance of ContainerAnalysisV1Beta1Client, using the given stub for making - * calls. This is for advanced usage - prefer to use ContainerAnalysisV1Beta1Settings}. - */ - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - public static final ContainerAnalysisV1Beta1Client create(ContainerAnalysisV1Beta1Stub stub) { - return new ContainerAnalysisV1Beta1Client(stub); - } - - /** - * Constructs an instance of ContainerAnalysisV1Beta1Client, using the given settings. This is - * protected so that it is easy to make a subclass, but otherwise, the static factory methods - * should be preferred. - */ - protected ContainerAnalysisV1Beta1Client(ContainerAnalysisV1Beta1Settings settings) - throws IOException { - this.settings = settings; - this.stub = ((ContainerAnalysisV1Beta1StubSettings) settings.getStubSettings()).createStub(); - } - - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - protected ContainerAnalysisV1Beta1Client(ContainerAnalysisV1Beta1Stub stub) { - this.settings = null; - this.stub = stub; - } - - public final ContainerAnalysisV1Beta1Settings getSettings() { - return settings; - } - - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - public ContainerAnalysisV1Beta1Stub getStub() { - return stub; - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Sets the access control policy on the specified note or occurrence. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or an occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Policy policy = Policy.newBuilder().build();
-   *   Policy response = containerAnalysisV1Beta1Client.setIamPolicy(resource, policy);
-   * }
-   * 
- * - * @param resource REQUIRED: The resource for which the policy is being specified. See the - * operation documentation for the appropriate value for this field. - * @param policy REQUIRED: The complete policy to be applied to the `resource`. The size of the - * policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud - * Platform services (such as Projects) might reject them. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Policy setIamPolicy(IamResourceName resource, Policy policy) { - - SetIamPolicyRequest request = - SetIamPolicyRequest.newBuilder() - .setResource(resource == null ? null : resource.toString()) - .setPolicy(policy) - .build(); - return setIamPolicy(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Sets the access control policy on the specified note or occurrence. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or an occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Policy policy = Policy.newBuilder().build();
-   *   Policy response = containerAnalysisV1Beta1Client.setIamPolicy(resource.toString(), policy);
-   * }
-   * 
- * - * @param resource REQUIRED: The resource for which the policy is being specified. See the - * operation documentation for the appropriate value for this field. - * @param policy REQUIRED: The complete policy to be applied to the `resource`. The size of the - * policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud - * Platform services (such as Projects) might reject them. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Policy setIamPolicy(String resource, Policy policy) { - - SetIamPolicyRequest request = - SetIamPolicyRequest.newBuilder().setResource(resource).setPolicy(policy).build(); - return setIamPolicy(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Sets the access control policy on the specified note or occurrence. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or an occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Policy policy = Policy.newBuilder().build();
-   *   SetIamPolicyRequest request = SetIamPolicyRequest.newBuilder()
-   *     .setResource(resource.toString())
-   *     .setPolicy(policy)
-   *     .build();
-   *   Policy response = containerAnalysisV1Beta1Client.setIamPolicy(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Policy setIamPolicy(SetIamPolicyRequest request) { - return setIamPolicyCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Sets the access control policy on the specified note or occurrence. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or an occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Policy policy = Policy.newBuilder().build();
-   *   SetIamPolicyRequest request = SetIamPolicyRequest.newBuilder()
-   *     .setResource(resource.toString())
-   *     .setPolicy(policy)
-   *     .build();
-   *   ApiFuture<Policy> future = containerAnalysisV1Beta1Client.setIamPolicyCallable().futureCall(request);
-   *   // Do something
-   *   Policy response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable setIamPolicyCallable() { - return stub.setIamPolicyCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the access control policy for a note or an occurrence resource. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Policy response = containerAnalysisV1Beta1Client.getIamPolicy(resource);
-   * }
-   * 
- * - * @param resource REQUIRED: The resource for which the policy is being requested. See the - * operation documentation for the appropriate value for this field. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Policy getIamPolicy(IamResourceName resource) { - - GetIamPolicyRequest request = - GetIamPolicyRequest.newBuilder() - .setResource(resource == null ? null : resource.toString()) - .build(); - return getIamPolicy(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the access control policy for a note or an occurrence resource. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Policy response = containerAnalysisV1Beta1Client.getIamPolicy(resource.toString());
-   * }
-   * 
- * - * @param resource REQUIRED: The resource for which the policy is being requested. See the - * operation documentation for the appropriate value for this field. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Policy getIamPolicy(String resource) { - - GetIamPolicyRequest request = GetIamPolicyRequest.newBuilder().setResource(resource).build(); - return getIamPolicy(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the access control policy for a note or an occurrence resource. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   GetIamPolicyRequest request = GetIamPolicyRequest.newBuilder()
-   *     .setResource(resource.toString())
-   *     .build();
-   *   Policy response = containerAnalysisV1Beta1Client.getIamPolicy(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Policy getIamPolicy(GetIamPolicyRequest request) { - return getIamPolicyCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the access control policy for a note or an occurrence resource. Requires - * `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` - * permission if the resource is a note or occurrence, respectively. - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   GetIamPolicyRequest request = GetIamPolicyRequest.newBuilder()
-   *     .setResource(resource.toString())
-   *     .build();
-   *   ApiFuture<Policy> future = containerAnalysisV1Beta1Client.getIamPolicyCallable().futureCall(request);
-   *   // Do something
-   *   Policy response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable getIamPolicyCallable() { - return stub.getIamPolicyCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns the permissions that a caller has on the specified note or occurrence. Requires list - * permission on the project (for example, `containeranalysis.notes.list`). - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   List<String> permissions = new ArrayList<>();
-   *   TestIamPermissionsResponse response = containerAnalysisV1Beta1Client.testIamPermissions(resource, permissions);
-   * }
-   * 
- * - * @param resource REQUIRED: The resource for which the policy detail is being requested. See the - * operation documentation for the appropriate value for this field. - * @param permissions The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final TestIamPermissionsResponse testIamPermissions( - IamResourceName resource, List permissions) { - - TestIamPermissionsRequest request = - TestIamPermissionsRequest.newBuilder() - .setResource(resource == null ? null : resource.toString()) - .addAllPermissions(permissions) - .build(); - return testIamPermissions(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns the permissions that a caller has on the specified note or occurrence. Requires list - * permission on the project (for example, `containeranalysis.notes.list`). - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   List<String> permissions = new ArrayList<>();
-   *   TestIamPermissionsResponse response = containerAnalysisV1Beta1Client.testIamPermissions(resource.toString(), permissions);
-   * }
-   * 
- * - * @param resource REQUIRED: The resource for which the policy detail is being requested. See the - * operation documentation for the appropriate value for this field. - * @param permissions The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final TestIamPermissionsResponse testIamPermissions( - String resource, List permissions) { - - TestIamPermissionsRequest request = - TestIamPermissionsRequest.newBuilder() - .setResource(resource) - .addAllPermissions(permissions) - .build(); - return testIamPermissions(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns the permissions that a caller has on the specified note or occurrence. Requires list - * permission on the project (for example, `containeranalysis.notes.list`). - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   List<String> permissions = new ArrayList<>();
-   *   TestIamPermissionsRequest request = TestIamPermissionsRequest.newBuilder()
-   *     .setResource(resource.toString())
-   *     .addAllPermissions(permissions)
-   *     .build();
-   *   TestIamPermissionsResponse response = containerAnalysisV1Beta1Client.testIamPermissions(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final TestIamPermissionsResponse testIamPermissions(TestIamPermissionsRequest request) { - return testIamPermissionsCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns the permissions that a caller has on the specified note or occurrence. Requires list - * permission on the project (for example, `containeranalysis.notes.list`). - * - *

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
-   *   List<String> permissions = new ArrayList<>();
-   *   TestIamPermissionsRequest request = TestIamPermissionsRequest.newBuilder()
-   *     .setResource(resource.toString())
-   *     .addAllPermissions(permissions)
-   *     .build();
-   *   ApiFuture<TestIamPermissionsResponse> future = containerAnalysisV1Beta1Client.testIamPermissionsCallable().futureCall(request);
-   *   // Do something
-   *   TestIamPermissionsResponse response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable - testIamPermissionsCallable() { - return stub.testIamPermissionsCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the specified scan configuration. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ScanConfigName name = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]");
-   *   ScanConfig response = containerAnalysisV1Beta1Client.getScanConfig(name);
-   * }
-   * 
- * - * @param name The name of the scan configuration in the form of - * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ScanConfig getScanConfig(ScanConfigName name) { - - GetScanConfigRequest request = - GetScanConfigRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return getScanConfig(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the specified scan configuration. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ScanConfigName name = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]");
-   *   ScanConfig response = containerAnalysisV1Beta1Client.getScanConfig(name.toString());
-   * }
-   * 
- * - * @param name The name of the scan configuration in the form of - * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ScanConfig getScanConfig(String name) { - - GetScanConfigRequest request = GetScanConfigRequest.newBuilder().setName(name).build(); - return getScanConfig(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the specified scan configuration. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ScanConfigName name = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]");
-   *   GetScanConfigRequest request = GetScanConfigRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   ScanConfig response = containerAnalysisV1Beta1Client.getScanConfig(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ScanConfig getScanConfig(GetScanConfigRequest request) { - return getScanConfigCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the specified scan configuration. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ScanConfigName name = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]");
-   *   GetScanConfigRequest request = GetScanConfigRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   ApiFuture<ScanConfig> future = containerAnalysisV1Beta1Client.getScanConfigCallable().futureCall(request);
-   *   // Do something
-   *   ScanConfig response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable getScanConfigCallable() { - return stub.getScanConfigCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists scan configurations for the specified project. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   String filter = "";
-   *   for (ScanConfig element : containerAnalysisV1Beta1Client.listScanConfigs(parent, filter).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- * - * @param parent The name of the project to list scan configurations for in the form of - * `projects/[PROJECT_ID]`. - * @param filter The filter expression. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListScanConfigsPagedResponse listScanConfigs(ProjectName parent, String filter) { - ListScanConfigsRequest request = - ListScanConfigsRequest.newBuilder() - .setParent(parent == null ? null : parent.toString()) - .setFilter(filter) - .build(); - return listScanConfigs(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists scan configurations for the specified project. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   String filter = "";
-   *   for (ScanConfig element : containerAnalysisV1Beta1Client.listScanConfigs(parent.toString(), filter).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- * - * @param parent The name of the project to list scan configurations for in the form of - * `projects/[PROJECT_ID]`. - * @param filter The filter expression. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListScanConfigsPagedResponse listScanConfigs(String parent, String filter) { - ListScanConfigsRequest request = - ListScanConfigsRequest.newBuilder().setParent(parent).setFilter(filter).build(); - return listScanConfigs(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists scan configurations for the specified project. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   ListScanConfigsRequest request = ListScanConfigsRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .build();
-   *   for (ScanConfig element : containerAnalysisV1Beta1Client.listScanConfigs(request).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListScanConfigsPagedResponse listScanConfigs(ListScanConfigsRequest request) { - return listScanConfigsPagedCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists scan configurations for the specified project. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   ListScanConfigsRequest request = ListScanConfigsRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .build();
-   *   ApiFuture<ListScanConfigsPagedResponse> future = containerAnalysisV1Beta1Client.listScanConfigsPagedCallable().futureCall(request);
-   *   // Do something
-   *   for (ScanConfig element : future.get().iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- */ - public final UnaryCallable - listScanConfigsPagedCallable() { - return stub.listScanConfigsPagedCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists scan configurations for the specified project. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   ListScanConfigsRequest request = ListScanConfigsRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .build();
-   *   while (true) {
-   *     ListScanConfigsResponse response = containerAnalysisV1Beta1Client.listScanConfigsCallable().call(request);
-   *     for (ScanConfig element : response.getScanConfigsList()) {
-   *       // doThingsWith(element);
-   *     }
-   *     String nextPageToken = response.getNextPageToken();
-   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
-   *       request = request.toBuilder().setPageToken(nextPageToken).build();
-   *     } else {
-   *       break;
-   *     }
-   *   }
-   * }
-   * 
- */ - public final UnaryCallable - listScanConfigsCallable() { - return stub.listScanConfigsCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Updates the specified scan configuration. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ScanConfigName name = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]");
-   *   ScanConfig scanConfig = ScanConfig.newBuilder().build();
-   *   ScanConfig response = containerAnalysisV1Beta1Client.updateScanConfig(name, scanConfig);
-   * }
-   * 
- * - * @param name The name of the scan configuration in the form of - * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`. - * @param scanConfig The updated scan configuration. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ScanConfig updateScanConfig(ScanConfigName name, ScanConfig scanConfig) { - - UpdateScanConfigRequest request = - UpdateScanConfigRequest.newBuilder() - .setName(name == null ? null : name.toString()) - .setScanConfig(scanConfig) - .build(); - return updateScanConfig(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Updates the specified scan configuration. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ScanConfigName name = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]");
-   *   ScanConfig scanConfig = ScanConfig.newBuilder().build();
-   *   ScanConfig response = containerAnalysisV1Beta1Client.updateScanConfig(name.toString(), scanConfig);
-   * }
-   * 
- * - * @param name The name of the scan configuration in the form of - * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`. - * @param scanConfig The updated scan configuration. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ScanConfig updateScanConfig(String name, ScanConfig scanConfig) { - - UpdateScanConfigRequest request = - UpdateScanConfigRequest.newBuilder().setName(name).setScanConfig(scanConfig).build(); - return updateScanConfig(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Updates the specified scan configuration. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ScanConfigName name = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]");
-   *   ScanConfig scanConfig = ScanConfig.newBuilder().build();
-   *   UpdateScanConfigRequest request = UpdateScanConfigRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .setScanConfig(scanConfig)
-   *     .build();
-   *   ScanConfig response = containerAnalysisV1Beta1Client.updateScanConfig(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ScanConfig updateScanConfig(UpdateScanConfigRequest request) { - return updateScanConfigCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Updates the specified scan configuration. - * - *

Sample code: - * - *


-   * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
-   *   ScanConfigName name = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]");
-   *   ScanConfig scanConfig = ScanConfig.newBuilder().build();
-   *   UpdateScanConfigRequest request = UpdateScanConfigRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .setScanConfig(scanConfig)
-   *     .build();
-   *   ApiFuture<ScanConfig> future = containerAnalysisV1Beta1Client.updateScanConfigCallable().futureCall(request);
-   *   // Do something
-   *   ScanConfig response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable updateScanConfigCallable() { - return stub.updateScanConfigCallable(); - } - - @Override - public final void close() { - stub.close(); - } - - @Override - public void shutdown() { - stub.shutdown(); - } - - @Override - public boolean isShutdown() { - return stub.isShutdown(); - } - - @Override - public boolean isTerminated() { - return stub.isTerminated(); - } - - @Override - public void shutdownNow() { - stub.shutdownNow(); - } - - @Override - public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { - return stub.awaitTermination(duration, unit); - } - - public static class ListScanConfigsPagedResponse - extends AbstractPagedListResponse< - ListScanConfigsRequest, - ListScanConfigsResponse, - ScanConfig, - ListScanConfigsPage, - ListScanConfigsFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - ListScanConfigsPage.createEmptyPage().createPageAsync(context, futureResponse); - return ApiFutures.transform( - futurePage, - new ApiFunction() { - @Override - public ListScanConfigsPagedResponse apply(ListScanConfigsPage input) { - return new ListScanConfigsPagedResponse(input); - } - }, - MoreExecutors.directExecutor()); - } - - private ListScanConfigsPagedResponse(ListScanConfigsPage page) { - super(page, ListScanConfigsFixedSizeCollection.createEmptyCollection()); - } - } - - public static class ListScanConfigsPage - extends AbstractPage< - ListScanConfigsRequest, ListScanConfigsResponse, ScanConfig, ListScanConfigsPage> { - - private ListScanConfigsPage( - PageContext context, - ListScanConfigsResponse response) { - super(context, response); - } - - private static ListScanConfigsPage createEmptyPage() { - return new ListScanConfigsPage(null, null); - } - - @Override - protected ListScanConfigsPage createPage( - PageContext context, - ListScanConfigsResponse response) { - return new ListScanConfigsPage(context, response); - } - - @Override - public ApiFuture createPageAsync( - PageContext context, - ApiFuture futureResponse) { - return super.createPageAsync(context, futureResponse); - } - } - - public static class ListScanConfigsFixedSizeCollection - extends AbstractFixedSizeCollection< - ListScanConfigsRequest, - ListScanConfigsResponse, - ScanConfig, - ListScanConfigsPage, - ListScanConfigsFixedSizeCollection> { - - private ListScanConfigsFixedSizeCollection( - List pages, int collectionSize) { - super(pages, collectionSize); - } - - private static ListScanConfigsFixedSizeCollection createEmptyCollection() { - return new ListScanConfigsFixedSizeCollection(null, 0); - } - - @Override - protected ListScanConfigsFixedSizeCollection createCollection( - List pages, int collectionSize) { - return new ListScanConfigsFixedSizeCollection(pages, collectionSize); - } - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/ContainerAnalysisV1Beta1Settings.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/ContainerAnalysisV1Beta1Settings.java deleted file mode 100644 index 8bb9a151..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/ContainerAnalysisV1Beta1Settings.java +++ /dev/null @@ -1,248 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1; - -import static com.google.cloud.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1Client.ListScanConfigsPagedResponse; - -import com.google.api.core.ApiFunction; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.GoogleCredentialsProvider; -import com.google.api.gax.core.InstantiatingExecutorProvider; -import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.ClientSettings; -import com.google.api.gax.rpc.PagedCallSettings; -import com.google.api.gax.rpc.TransportChannelProvider; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.cloud.devtools.containeranalysis.v1beta1.stub.ContainerAnalysisV1Beta1StubSettings; -import com.google.containeranalysis.v1beta1.GetScanConfigRequest; -import com.google.containeranalysis.v1beta1.ListScanConfigsRequest; -import com.google.containeranalysis.v1beta1.ListScanConfigsResponse; -import com.google.containeranalysis.v1beta1.ScanConfig; -import com.google.containeranalysis.v1beta1.UpdateScanConfigRequest; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import java.io.IOException; -import java.util.List; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * Settings class to configure an instance of {@link ContainerAnalysisV1Beta1Client}. - * - *

The default instance has everything set to sensible defaults: - * - *

    - *
  • The default service address (containeranalysis.googleapis.com) and default port (443) are - * used. - *
  • Credentials are acquired automatically through Application Default Credentials. - *
  • Retries are configured for idempotent methods but not for non-idempotent methods. - *
- * - *

The builder of this class is recursive, so contained classes are themselves builders. When - * build() is called, the tree of builders is called to create the complete settings object. - * - *

For example, to set the total timeout of setIamPolicy to 30 seconds: - * - *

- * 
- * ContainerAnalysisV1Beta1Settings.Builder containerAnalysisV1Beta1SettingsBuilder =
- *     ContainerAnalysisV1Beta1Settings.newBuilder();
- * containerAnalysisV1Beta1SettingsBuilder.setIamPolicySettings().getRetrySettings().toBuilder()
- *     .setTotalTimeout(Duration.ofSeconds(30));
- * ContainerAnalysisV1Beta1Settings containerAnalysisV1Beta1Settings = containerAnalysisV1Beta1SettingsBuilder.build();
- * 
- * 
- */ -@Generated("by gapic-generator") -@BetaApi -public class ContainerAnalysisV1Beta1Settings - extends ClientSettings { - /** Returns the object with the settings used for calls to setIamPolicy. */ - public UnaryCallSettings setIamPolicySettings() { - return ((ContainerAnalysisV1Beta1StubSettings) getStubSettings()).setIamPolicySettings(); - } - - /** Returns the object with the settings used for calls to getIamPolicy. */ - public UnaryCallSettings getIamPolicySettings() { - return ((ContainerAnalysisV1Beta1StubSettings) getStubSettings()).getIamPolicySettings(); - } - - /** Returns the object with the settings used for calls to testIamPermissions. */ - public UnaryCallSettings - testIamPermissionsSettings() { - return ((ContainerAnalysisV1Beta1StubSettings) getStubSettings()).testIamPermissionsSettings(); - } - - /** Returns the object with the settings used for calls to getScanConfig. */ - public UnaryCallSettings getScanConfigSettings() { - return ((ContainerAnalysisV1Beta1StubSettings) getStubSettings()).getScanConfigSettings(); - } - - /** Returns the object with the settings used for calls to listScanConfigs. */ - public PagedCallSettings< - ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> - listScanConfigsSettings() { - return ((ContainerAnalysisV1Beta1StubSettings) getStubSettings()).listScanConfigsSettings(); - } - - /** Returns the object with the settings used for calls to updateScanConfig. */ - public UnaryCallSettings updateScanConfigSettings() { - return ((ContainerAnalysisV1Beta1StubSettings) getStubSettings()).updateScanConfigSettings(); - } - - public static final ContainerAnalysisV1Beta1Settings create( - ContainerAnalysisV1Beta1StubSettings stub) throws IOException { - return new ContainerAnalysisV1Beta1Settings.Builder(stub.toBuilder()).build(); - } - - /** Returns a builder for the default ExecutorProvider for this service. */ - public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { - return ContainerAnalysisV1Beta1StubSettings.defaultExecutorProviderBuilder(); - } - - /** Returns the default service endpoint. */ - public static String getDefaultEndpoint() { - return ContainerAnalysisV1Beta1StubSettings.getDefaultEndpoint(); - } - - /** Returns the default service scopes. */ - public static List getDefaultServiceScopes() { - return ContainerAnalysisV1Beta1StubSettings.getDefaultServiceScopes(); - } - - /** Returns a builder for the default credentials for this service. */ - public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { - return ContainerAnalysisV1Beta1StubSettings.defaultCredentialsProviderBuilder(); - } - - /** Returns a builder for the default ChannelProvider for this service. */ - public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { - return ContainerAnalysisV1Beta1StubSettings.defaultGrpcTransportProviderBuilder(); - } - - public static TransportChannelProvider defaultTransportChannelProvider() { - return ContainerAnalysisV1Beta1StubSettings.defaultTransportChannelProvider(); - } - - @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") - public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { - return ContainerAnalysisV1Beta1StubSettings.defaultApiClientHeaderProviderBuilder(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder() { - return Builder.createDefault(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder(ClientContext clientContext) { - return new Builder(clientContext); - } - - /** Returns a builder containing all the values of this settings class. */ - public Builder toBuilder() { - return new Builder(this); - } - - protected ContainerAnalysisV1Beta1Settings(Builder settingsBuilder) throws IOException { - super(settingsBuilder); - } - - /** Builder for ContainerAnalysisV1Beta1Settings. */ - public static class Builder - extends ClientSettings.Builder { - protected Builder() throws IOException { - this((ClientContext) null); - } - - protected Builder(ClientContext clientContext) { - super(ContainerAnalysisV1Beta1StubSettings.newBuilder(clientContext)); - } - - private static Builder createDefault() { - return new Builder(ContainerAnalysisV1Beta1StubSettings.newBuilder()); - } - - protected Builder(ContainerAnalysisV1Beta1Settings settings) { - super(settings.getStubSettings().toBuilder()); - } - - protected Builder(ContainerAnalysisV1Beta1StubSettings.Builder stubSettings) { - super(stubSettings); - } - - public ContainerAnalysisV1Beta1StubSettings.Builder getStubSettingsBuilder() { - return ((ContainerAnalysisV1Beta1StubSettings.Builder) getStubSettings()); - } - - // NEXT_MAJOR_VER: remove 'throws Exception' - /** - * Applies the given settings updater function to all of the unary API methods in this service. - * - *

Note: This method does not support applying settings to streaming methods. - */ - public Builder applyToAllUnaryMethods( - ApiFunction, Void> settingsUpdater) throws Exception { - super.applyToAllUnaryMethods( - getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); - return this; - } - - /** Returns the builder for the settings used for calls to setIamPolicy. */ - public UnaryCallSettings.Builder setIamPolicySettings() { - return getStubSettingsBuilder().setIamPolicySettings(); - } - - /** Returns the builder for the settings used for calls to getIamPolicy. */ - public UnaryCallSettings.Builder getIamPolicySettings() { - return getStubSettingsBuilder().getIamPolicySettings(); - } - - /** Returns the builder for the settings used for calls to testIamPermissions. */ - public UnaryCallSettings.Builder - testIamPermissionsSettings() { - return getStubSettingsBuilder().testIamPermissionsSettings(); - } - - /** Returns the builder for the settings used for calls to getScanConfig. */ - public UnaryCallSettings.Builder getScanConfigSettings() { - return getStubSettingsBuilder().getScanConfigSettings(); - } - - /** Returns the builder for the settings used for calls to listScanConfigs. */ - public PagedCallSettings.Builder< - ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> - listScanConfigsSettings() { - return getStubSettingsBuilder().listScanConfigsSettings(); - } - - /** Returns the builder for the settings used for calls to updateScanConfig. */ - public UnaryCallSettings.Builder - updateScanConfigSettings() { - return getStubSettingsBuilder().updateScanConfigSettings(); - } - - @Override - public ContainerAnalysisV1Beta1Settings build() throws IOException { - return new ContainerAnalysisV1Beta1Settings(this); - } - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/GrafeasV1Beta1Client.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/GrafeasV1Beta1Client.java deleted file mode 100644 index fbc41442..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/GrafeasV1Beta1Client.java +++ /dev/null @@ -1,2117 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1; - -import com.google.api.core.ApiFunction; -import com.google.api.core.ApiFuture; -import com.google.api.core.ApiFutures; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.paging.AbstractFixedSizeCollection; -import com.google.api.gax.paging.AbstractPage; -import com.google.api.gax.paging.AbstractPagedListResponse; -import com.google.api.gax.rpc.PageContext; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.cloud.devtools.containeranalysis.v1beta1.stub.GrafeasV1Beta1Stub; -import com.google.cloud.devtools.containeranalysis.v1beta1.stub.GrafeasV1Beta1StubSettings; -import com.google.common.util.concurrent.MoreExecutors; -import com.google.containeranalysis.v1beta1.NoteName; -import com.google.containeranalysis.v1beta1.OccurrenceName; -import com.google.containeranalysis.v1beta1.ProjectName; -import com.google.protobuf.Empty; -import com.google.protobuf.FieldMask; -import io.grafeas.v1beta1.BatchCreateNotesRequest; -import io.grafeas.v1beta1.BatchCreateNotesResponse; -import io.grafeas.v1beta1.BatchCreateOccurrencesRequest; -import io.grafeas.v1beta1.BatchCreateOccurrencesResponse; -import io.grafeas.v1beta1.CreateNoteRequest; -import io.grafeas.v1beta1.CreateOccurrenceRequest; -import io.grafeas.v1beta1.DeleteNoteRequest; -import io.grafeas.v1beta1.DeleteOccurrenceRequest; -import io.grafeas.v1beta1.GetNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceRequest; -import io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesResponse; -import io.grafeas.v1beta1.ListNotesRequest; -import io.grafeas.v1beta1.ListNotesResponse; -import io.grafeas.v1beta1.ListOccurrencesRequest; -import io.grafeas.v1beta1.ListOccurrencesResponse; -import io.grafeas.v1beta1.Note; -import io.grafeas.v1beta1.Occurrence; -import io.grafeas.v1beta1.UpdateNoteRequest; -import io.grafeas.v1beta1.UpdateOccurrenceRequest; -import io.grafeas.v1beta1.VulnerabilityOccurrencesSummary; -import java.io.IOException; -import java.util.List; -import java.util.Map; -import java.util.concurrent.TimeUnit; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND SERVICE -/** - * Service Description: [Grafeas](grafeas.io) API. - * - *

Retrieves analysis results of Cloud components such as Docker container images. - * - *

Analysis results are stored as a series of occurrences. An `Occurrence` contains information - * about a specific analysis instance on a resource. An occurrence refers to a `Note`. A note - * contains details describing the analysis and is generally stored in a separate project, called a - * `Provider`. Multiple occurrences can refer to the same note. - * - *

For example, an SSL vulnerability could affect multiple images. In this case, there would be - * one note for the vulnerability and an occurrence for each image with the vulnerability referring - * to that note. - * - *

This class provides the ability to make remote calls to the backing service through method - * calls that map to API methods. Sample code to get started: - * - *

- * 
- * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
- *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
- *   Occurrence response = grafeasV1Beta1Client.getOccurrence(name);
- * }
- * 
- * 
- * - *

Note: close() needs to be called on the grafeasV1Beta1Client object to clean up resources such - * as threads. In the example above, try-with-resources is used, which automatically calls close(). - * - *

The surface of this class includes several types of Java methods for each of the API's - * methods: - * - *

    - *
  1. A "flattened" method. With this type of method, the fields of the request type have been - * converted into function parameters. It may be the case that not all fields are available as - * parameters, and not every API method will have a flattened method entry point. - *
  2. A "request object" method. This type of method only takes one parameter, a request object, - * which must be constructed before the call. Not every API method will have a request object - * method. - *
  3. A "callable" method. This type of method takes no parameters and returns an immutable API - * callable object, which can be used to initiate calls to the service. - *
- * - *

See the individual methods for example code. - * - *

Many parameters require resource names to be formatted in a particular way. To assist with - * these names, this class includes a format method for each type of name, and additionally a parse - * method to extract the individual identifiers contained within names that are returned. - * - *

This class can be customized by passing in a custom instance of GrafeasV1Beta1Settings to - * create(). For example: - * - *

To customize credentials: - * - *

- * 
- * GrafeasV1Beta1Settings grafeasV1Beta1Settings =
- *     GrafeasV1Beta1Settings.newBuilder()
- *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
- *         .build();
- * GrafeasV1Beta1Client grafeasV1Beta1Client =
- *     GrafeasV1Beta1Client.create(grafeasV1Beta1Settings);
- * 
- * 
- * - * To customize the endpoint: - * - *
- * 
- * GrafeasV1Beta1Settings grafeasV1Beta1Settings =
- *     GrafeasV1Beta1Settings.newBuilder().setEndpoint(myEndpoint).build();
- * GrafeasV1Beta1Client grafeasV1Beta1Client =
- *     GrafeasV1Beta1Client.create(grafeasV1Beta1Settings);
- * 
- * 
- */ -@Generated("by gapic-generator") -@BetaApi -public class GrafeasV1Beta1Client implements BackgroundResource { - private final GrafeasV1Beta1Settings settings; - private final GrafeasV1Beta1Stub stub; - - /** Constructs an instance of GrafeasV1Beta1Client with default settings. */ - public static final GrafeasV1Beta1Client create() throws IOException { - return create(GrafeasV1Beta1Settings.newBuilder().build()); - } - - /** - * Constructs an instance of GrafeasV1Beta1Client, using the given settings. The channels are - * created based on the settings passed in, or defaults for any settings that are not set. - */ - public static final GrafeasV1Beta1Client create(GrafeasV1Beta1Settings settings) - throws IOException { - return new GrafeasV1Beta1Client(settings); - } - - /** - * Constructs an instance of GrafeasV1Beta1Client, using the given stub for making calls. This is - * for advanced usage - prefer to use GrafeasV1Beta1Settings}. - */ - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - public static final GrafeasV1Beta1Client create(GrafeasV1Beta1Stub stub) { - return new GrafeasV1Beta1Client(stub); - } - - /** - * Constructs an instance of GrafeasV1Beta1Client, using the given settings. This is protected so - * that it is easy to make a subclass, but otherwise, the static factory methods should be - * preferred. - */ - protected GrafeasV1Beta1Client(GrafeasV1Beta1Settings settings) throws IOException { - this.settings = settings; - this.stub = ((GrafeasV1Beta1StubSettings) settings.getStubSettings()).createStub(); - } - - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - protected GrafeasV1Beta1Client(GrafeasV1Beta1Stub stub) { - this.settings = null; - this.stub = stub; - } - - public final GrafeasV1Beta1Settings getSettings() { - return settings; - } - - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - public GrafeasV1Beta1Stub getStub() { - return stub; - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the specified occurrence. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   Occurrence response = grafeasV1Beta1Client.getOccurrence(name);
-   * }
-   * 
- * - * @param name The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Occurrence getOccurrence(OccurrenceName name) { - - GetOccurrenceRequest request = - GetOccurrenceRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return getOccurrence(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the specified occurrence. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   Occurrence response = grafeasV1Beta1Client.getOccurrence(name.toString());
-   * }
-   * 
- * - * @param name The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Occurrence getOccurrence(String name) { - - GetOccurrenceRequest request = GetOccurrenceRequest.newBuilder().setName(name).build(); - return getOccurrence(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the specified occurrence. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   GetOccurrenceRequest request = GetOccurrenceRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   Occurrence response = grafeasV1Beta1Client.getOccurrence(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Occurrence getOccurrence(GetOccurrenceRequest request) { - return getOccurrenceCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the specified occurrence. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   GetOccurrenceRequest request = GetOccurrenceRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   ApiFuture<Occurrence> future = grafeasV1Beta1Client.getOccurrenceCallable().futureCall(request);
-   *   // Do something
-   *   Occurrence response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable getOccurrenceCallable() { - return stub.getOccurrenceCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists occurrences for the specified project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   String filter = "";
-   *   for (Occurrence element : grafeasV1Beta1Client.listOccurrences(parent, filter).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- * - * @param parent The name of the project to list occurrences for in the form of - * `projects/[PROJECT_ID]`. - * @param filter The filter expression. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListOccurrencesPagedResponse listOccurrences(ProjectName parent, String filter) { - ListOccurrencesRequest request = - ListOccurrencesRequest.newBuilder() - .setParent(parent == null ? null : parent.toString()) - .setFilter(filter) - .build(); - return listOccurrences(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists occurrences for the specified project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   String filter = "";
-   *   for (Occurrence element : grafeasV1Beta1Client.listOccurrences(parent.toString(), filter).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- * - * @param parent The name of the project to list occurrences for in the form of - * `projects/[PROJECT_ID]`. - * @param filter The filter expression. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListOccurrencesPagedResponse listOccurrences(String parent, String filter) { - ListOccurrencesRequest request = - ListOccurrencesRequest.newBuilder().setParent(parent).setFilter(filter).build(); - return listOccurrences(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists occurrences for the specified project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   ListOccurrencesRequest request = ListOccurrencesRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .build();
-   *   for (Occurrence element : grafeasV1Beta1Client.listOccurrences(request).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListOccurrencesPagedResponse listOccurrences(ListOccurrencesRequest request) { - return listOccurrencesPagedCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists occurrences for the specified project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   ListOccurrencesRequest request = ListOccurrencesRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .build();
-   *   ApiFuture<ListOccurrencesPagedResponse> future = grafeasV1Beta1Client.listOccurrencesPagedCallable().futureCall(request);
-   *   // Do something
-   *   for (Occurrence element : future.get().iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- */ - public final UnaryCallable - listOccurrencesPagedCallable() { - return stub.listOccurrencesPagedCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists occurrences for the specified project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   ListOccurrencesRequest request = ListOccurrencesRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .build();
-   *   while (true) {
-   *     ListOccurrencesResponse response = grafeasV1Beta1Client.listOccurrencesCallable().call(request);
-   *     for (Occurrence element : response.getOccurrencesList()) {
-   *       // doThingsWith(element);
-   *     }
-   *     String nextPageToken = response.getNextPageToken();
-   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
-   *       request = request.toBuilder().setPageToken(nextPageToken).build();
-   *     } else {
-   *       break;
-   *     }
-   *   }
-   * }
-   * 
- */ - public final UnaryCallable - listOccurrencesCallable() { - return stub.listOccurrencesCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Deletes the specified occurrence. For example, use this method to delete an occurrence when the - * occurrence is no longer applicable for the given resource. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   grafeasV1Beta1Client.deleteOccurrence(name);
-   * }
-   * 
- * - * @param name The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final void deleteOccurrence(OccurrenceName name) { - - DeleteOccurrenceRequest request = - DeleteOccurrenceRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - deleteOccurrence(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Deletes the specified occurrence. For example, use this method to delete an occurrence when the - * occurrence is no longer applicable for the given resource. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   grafeasV1Beta1Client.deleteOccurrence(name.toString());
-   * }
-   * 
- * - * @param name The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final void deleteOccurrence(String name) { - - DeleteOccurrenceRequest request = DeleteOccurrenceRequest.newBuilder().setName(name).build(); - deleteOccurrence(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Deletes the specified occurrence. For example, use this method to delete an occurrence when the - * occurrence is no longer applicable for the given resource. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   DeleteOccurrenceRequest request = DeleteOccurrenceRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   grafeasV1Beta1Client.deleteOccurrence(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final void deleteOccurrence(DeleteOccurrenceRequest request) { - deleteOccurrenceCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Deletes the specified occurrence. For example, use this method to delete an occurrence when the - * occurrence is no longer applicable for the given resource. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   DeleteOccurrenceRequest request = DeleteOccurrenceRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   ApiFuture<Void> future = grafeasV1Beta1Client.deleteOccurrenceCallable().futureCall(request);
-   *   // Do something
-   *   future.get();
-   * }
-   * 
- */ - public final UnaryCallable deleteOccurrenceCallable() { - return stub.deleteOccurrenceCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates a new occurrence. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   Occurrence occurrence = Occurrence.newBuilder().build();
-   *   Occurrence response = grafeasV1Beta1Client.createOccurrence(parent, occurrence);
-   * }
-   * 
- * - * @param parent The name of the project in the form of `projects/[PROJECT_ID]`, under which the - * occurrence is to be created. - * @param occurrence The occurrence to create. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Occurrence createOccurrence(ProjectName parent, Occurrence occurrence) { - - CreateOccurrenceRequest request = - CreateOccurrenceRequest.newBuilder() - .setParent(parent == null ? null : parent.toString()) - .setOccurrence(occurrence) - .build(); - return createOccurrence(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates a new occurrence. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   Occurrence occurrence = Occurrence.newBuilder().build();
-   *   Occurrence response = grafeasV1Beta1Client.createOccurrence(parent.toString(), occurrence);
-   * }
-   * 
- * - * @param parent The name of the project in the form of `projects/[PROJECT_ID]`, under which the - * occurrence is to be created. - * @param occurrence The occurrence to create. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Occurrence createOccurrence(String parent, Occurrence occurrence) { - - CreateOccurrenceRequest request = - CreateOccurrenceRequest.newBuilder().setParent(parent).setOccurrence(occurrence).build(); - return createOccurrence(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates a new occurrence. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   Occurrence occurrence = Occurrence.newBuilder().build();
-   *   CreateOccurrenceRequest request = CreateOccurrenceRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .setOccurrence(occurrence)
-   *     .build();
-   *   Occurrence response = grafeasV1Beta1Client.createOccurrence(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Occurrence createOccurrence(CreateOccurrenceRequest request) { - return createOccurrenceCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates a new occurrence. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   Occurrence occurrence = Occurrence.newBuilder().build();
-   *   CreateOccurrenceRequest request = CreateOccurrenceRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .setOccurrence(occurrence)
-   *     .build();
-   *   ApiFuture<Occurrence> future = grafeasV1Beta1Client.createOccurrenceCallable().futureCall(request);
-   *   // Do something
-   *   Occurrence response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable createOccurrenceCallable() { - return stub.createOccurrenceCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates new occurrences in batch. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   List<Occurrence> occurrences = new ArrayList<>();
-   *   BatchCreateOccurrencesResponse response = grafeasV1Beta1Client.batchCreateOccurrences(parent, occurrences);
-   * }
-   * 
- * - * @param parent The name of the project in the form of `projects/[PROJECT_ID]`, under which the - * occurrences are to be created. - * @param occurrences The occurrences to create. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final BatchCreateOccurrencesResponse batchCreateOccurrences( - ProjectName parent, List occurrences) { - - BatchCreateOccurrencesRequest request = - BatchCreateOccurrencesRequest.newBuilder() - .setParent(parent == null ? null : parent.toString()) - .addAllOccurrences(occurrences) - .build(); - return batchCreateOccurrences(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates new occurrences in batch. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   List<Occurrence> occurrences = new ArrayList<>();
-   *   BatchCreateOccurrencesResponse response = grafeasV1Beta1Client.batchCreateOccurrences(parent.toString(), occurrences);
-   * }
-   * 
- * - * @param parent The name of the project in the form of `projects/[PROJECT_ID]`, under which the - * occurrences are to be created. - * @param occurrences The occurrences to create. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final BatchCreateOccurrencesResponse batchCreateOccurrences( - String parent, List occurrences) { - - BatchCreateOccurrencesRequest request = - BatchCreateOccurrencesRequest.newBuilder() - .setParent(parent) - .addAllOccurrences(occurrences) - .build(); - return batchCreateOccurrences(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates new occurrences in batch. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   List<Occurrence> occurrences = new ArrayList<>();
-   *   BatchCreateOccurrencesRequest request = BatchCreateOccurrencesRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .addAllOccurrences(occurrences)
-   *     .build();
-   *   BatchCreateOccurrencesResponse response = grafeasV1Beta1Client.batchCreateOccurrences(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final BatchCreateOccurrencesResponse batchCreateOccurrences( - BatchCreateOccurrencesRequest request) { - return batchCreateOccurrencesCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates new occurrences in batch. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   List<Occurrence> occurrences = new ArrayList<>();
-   *   BatchCreateOccurrencesRequest request = BatchCreateOccurrencesRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .addAllOccurrences(occurrences)
-   *     .build();
-   *   ApiFuture<BatchCreateOccurrencesResponse> future = grafeasV1Beta1Client.batchCreateOccurrencesCallable().futureCall(request);
-   *   // Do something
-   *   BatchCreateOccurrencesResponse response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable - batchCreateOccurrencesCallable() { - return stub.batchCreateOccurrencesCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Updates the specified occurrence. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   Occurrence occurrence = Occurrence.newBuilder().build();
-   *   FieldMask updateMask = FieldMask.newBuilder().build();
-   *   Occurrence response = grafeasV1Beta1Client.updateOccurrence(name, occurrence, updateMask);
-   * }
-   * 
- * - * @param name The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @param occurrence The updated occurrence. - * @param updateMask The fields to update. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Occurrence updateOccurrence( - OccurrenceName name, Occurrence occurrence, FieldMask updateMask) { - - UpdateOccurrenceRequest request = - UpdateOccurrenceRequest.newBuilder() - .setName(name == null ? null : name.toString()) - .setOccurrence(occurrence) - .setUpdateMask(updateMask) - .build(); - return updateOccurrence(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Updates the specified occurrence. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   Occurrence occurrence = Occurrence.newBuilder().build();
-   *   FieldMask updateMask = FieldMask.newBuilder().build();
-   *   Occurrence response = grafeasV1Beta1Client.updateOccurrence(name.toString(), occurrence, updateMask);
-   * }
-   * 
- * - * @param name The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @param occurrence The updated occurrence. - * @param updateMask The fields to update. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Occurrence updateOccurrence( - String name, Occurrence occurrence, FieldMask updateMask) { - - UpdateOccurrenceRequest request = - UpdateOccurrenceRequest.newBuilder() - .setName(name) - .setOccurrence(occurrence) - .setUpdateMask(updateMask) - .build(); - return updateOccurrence(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Updates the specified occurrence. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   Occurrence occurrence = Occurrence.newBuilder().build();
-   *   UpdateOccurrenceRequest request = UpdateOccurrenceRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .setOccurrence(occurrence)
-   *     .build();
-   *   Occurrence response = grafeasV1Beta1Client.updateOccurrence(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Occurrence updateOccurrence(UpdateOccurrenceRequest request) { - return updateOccurrenceCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Updates the specified occurrence. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   Occurrence occurrence = Occurrence.newBuilder().build();
-   *   UpdateOccurrenceRequest request = UpdateOccurrenceRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .setOccurrence(occurrence)
-   *     .build();
-   *   ApiFuture<Occurrence> future = grafeasV1Beta1Client.updateOccurrenceCallable().futureCall(request);
-   *   // Do something
-   *   Occurrence response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable updateOccurrenceCallable() { - return stub.updateOccurrenceCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the note attached to the specified occurrence. Consumer projects can use this method to - * get a note that belongs to a provider project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   Note response = grafeasV1Beta1Client.getOccurrenceNote(name);
-   * }
-   * 
- * - * @param name The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Note getOccurrenceNote(OccurrenceName name) { - - GetOccurrenceNoteRequest request = - GetOccurrenceNoteRequest.newBuilder() - .setName(name == null ? null : name.toString()) - .build(); - return getOccurrenceNote(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the note attached to the specified occurrence. Consumer projects can use this method to - * get a note that belongs to a provider project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   Note response = grafeasV1Beta1Client.getOccurrenceNote(name.toString());
-   * }
-   * 
- * - * @param name The name of the occurrence in the form of - * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Note getOccurrenceNote(String name) { - - GetOccurrenceNoteRequest request = GetOccurrenceNoteRequest.newBuilder().setName(name).build(); - return getOccurrenceNote(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the note attached to the specified occurrence. Consumer projects can use this method to - * get a note that belongs to a provider project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   GetOccurrenceNoteRequest request = GetOccurrenceNoteRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   Note response = grafeasV1Beta1Client.getOccurrenceNote(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Note getOccurrenceNote(GetOccurrenceNoteRequest request) { - return getOccurrenceNoteCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the note attached to the specified occurrence. Consumer projects can use this method to - * get a note that belongs to a provider project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
-   *   GetOccurrenceNoteRequest request = GetOccurrenceNoteRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   ApiFuture<Note> future = grafeasV1Beta1Client.getOccurrenceNoteCallable().futureCall(request);
-   *   // Do something
-   *   Note response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable getOccurrenceNoteCallable() { - return stub.getOccurrenceNoteCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Note response = grafeasV1Beta1Client.getNote(name);
-   * }
-   * 
- * - * @param name The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Note getNote(NoteName name) { - - GetNoteRequest request = - GetNoteRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return getNote(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Note response = grafeasV1Beta1Client.getNote(name.toString());
-   * }
-   * 
- * - * @param name The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Note getNote(String name) { - - GetNoteRequest request = GetNoteRequest.newBuilder().setName(name).build(); - return getNote(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   GetNoteRequest request = GetNoteRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   Note response = grafeasV1Beta1Client.getNote(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Note getNote(GetNoteRequest request) { - return getNoteCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   GetNoteRequest request = GetNoteRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   ApiFuture<Note> future = grafeasV1Beta1Client.getNoteCallable().futureCall(request);
-   *   // Do something
-   *   Note response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable getNoteCallable() { - return stub.getNoteCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists notes for the specified project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   String filter = "";
-   *   for (Note element : grafeasV1Beta1Client.listNotes(parent, filter).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- * - * @param parent The name of the project to list notes for in the form of `projects/[PROJECT_ID]`. - * @param filter The filter expression. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListNotesPagedResponse listNotes(ProjectName parent, String filter) { - ListNotesRequest request = - ListNotesRequest.newBuilder() - .setParent(parent == null ? null : parent.toString()) - .setFilter(filter) - .build(); - return listNotes(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists notes for the specified project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   String filter = "";
-   *   for (Note element : grafeasV1Beta1Client.listNotes(parent.toString(), filter).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- * - * @param parent The name of the project to list notes for in the form of `projects/[PROJECT_ID]`. - * @param filter The filter expression. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListNotesPagedResponse listNotes(String parent, String filter) { - ListNotesRequest request = - ListNotesRequest.newBuilder().setParent(parent).setFilter(filter).build(); - return listNotes(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists notes for the specified project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   ListNotesRequest request = ListNotesRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .build();
-   *   for (Note element : grafeasV1Beta1Client.listNotes(request).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListNotesPagedResponse listNotes(ListNotesRequest request) { - return listNotesPagedCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists notes for the specified project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   ListNotesRequest request = ListNotesRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .build();
-   *   ApiFuture<ListNotesPagedResponse> future = grafeasV1Beta1Client.listNotesPagedCallable().futureCall(request);
-   *   // Do something
-   *   for (Note element : future.get().iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- */ - public final UnaryCallable listNotesPagedCallable() { - return stub.listNotesPagedCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists notes for the specified project. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   ListNotesRequest request = ListNotesRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .build();
-   *   while (true) {
-   *     ListNotesResponse response = grafeasV1Beta1Client.listNotesCallable().call(request);
-   *     for (Note element : response.getNotesList()) {
-   *       // doThingsWith(element);
-   *     }
-   *     String nextPageToken = response.getNextPageToken();
-   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
-   *       request = request.toBuilder().setPageToken(nextPageToken).build();
-   *     } else {
-   *       break;
-   *     }
-   *   }
-   * }
-   * 
- */ - public final UnaryCallable listNotesCallable() { - return stub.listNotesCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Deletes the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   grafeasV1Beta1Client.deleteNote(name);
-   * }
-   * 
- * - * @param name The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final void deleteNote(NoteName name) { - - DeleteNoteRequest request = - DeleteNoteRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - deleteNote(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Deletes the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   grafeasV1Beta1Client.deleteNote(name.toString());
-   * }
-   * 
- * - * @param name The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final void deleteNote(String name) { - - DeleteNoteRequest request = DeleteNoteRequest.newBuilder().setName(name).build(); - deleteNote(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Deletes the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   DeleteNoteRequest request = DeleteNoteRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   grafeasV1Beta1Client.deleteNote(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final void deleteNote(DeleteNoteRequest request) { - deleteNoteCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Deletes the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   DeleteNoteRequest request = DeleteNoteRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   ApiFuture<Void> future = grafeasV1Beta1Client.deleteNoteCallable().futureCall(request);
-   *   // Do something
-   *   future.get();
-   * }
-   * 
- */ - public final UnaryCallable deleteNoteCallable() { - return stub.deleteNoteCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates a new note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   String noteId = "";
-   *   Note note = Note.newBuilder().build();
-   *   Note response = grafeasV1Beta1Client.createNote(parent, noteId, note);
-   * }
-   * 
- * - * @param parent The name of the project in the form of `projects/[PROJECT_ID]`, under which the - * note is to be created. - * @param noteId The ID to use for this note. - * @param note The note to create. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Note createNote(ProjectName parent, String noteId, Note note) { - - CreateNoteRequest request = - CreateNoteRequest.newBuilder() - .setParent(parent == null ? null : parent.toString()) - .setNoteId(noteId) - .setNote(note) - .build(); - return createNote(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates a new note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   String noteId = "";
-   *   Note note = Note.newBuilder().build();
-   *   Note response = grafeasV1Beta1Client.createNote(parent.toString(), noteId, note);
-   * }
-   * 
- * - * @param parent The name of the project in the form of `projects/[PROJECT_ID]`, under which the - * note is to be created. - * @param noteId The ID to use for this note. - * @param note The note to create. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Note createNote(String parent, String noteId, Note note) { - - CreateNoteRequest request = - CreateNoteRequest.newBuilder().setParent(parent).setNoteId(noteId).setNote(note).build(); - return createNote(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates a new note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   String noteId = "";
-   *   Note note = Note.newBuilder().build();
-   *   CreateNoteRequest request = CreateNoteRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .setNoteId(noteId)
-   *     .setNote(note)
-   *     .build();
-   *   Note response = grafeasV1Beta1Client.createNote(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Note createNote(CreateNoteRequest request) { - return createNoteCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates a new note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   String noteId = "";
-   *   Note note = Note.newBuilder().build();
-   *   CreateNoteRequest request = CreateNoteRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .setNoteId(noteId)
-   *     .setNote(note)
-   *     .build();
-   *   ApiFuture<Note> future = grafeasV1Beta1Client.createNoteCallable().futureCall(request);
-   *   // Do something
-   *   Note response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable createNoteCallable() { - return stub.createNoteCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates new notes in batch. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   Map<String, Note> notes = new HashMap<>();
-   *   BatchCreateNotesResponse response = grafeasV1Beta1Client.batchCreateNotes(parent, notes);
-   * }
-   * 
- * - * @param parent The name of the project in the form of `projects/[PROJECT_ID]`, under which the - * notes are to be created. - * @param notes The notes to create. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final BatchCreateNotesResponse batchCreateNotes( - ProjectName parent, Map notes) { - - BatchCreateNotesRequest request = - BatchCreateNotesRequest.newBuilder() - .setParent(parent == null ? null : parent.toString()) - .putAllNotes(notes) - .build(); - return batchCreateNotes(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates new notes in batch. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   Map<String, Note> notes = new HashMap<>();
-   *   BatchCreateNotesResponse response = grafeasV1Beta1Client.batchCreateNotes(parent.toString(), notes);
-   * }
-   * 
- * - * @param parent The name of the project in the form of `projects/[PROJECT_ID]`, under which the - * notes are to be created. - * @param notes The notes to create. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final BatchCreateNotesResponse batchCreateNotes(String parent, Map notes) { - - BatchCreateNotesRequest request = - BatchCreateNotesRequest.newBuilder().setParent(parent).putAllNotes(notes).build(); - return batchCreateNotes(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates new notes in batch. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   Map<String, Note> notes = new HashMap<>();
-   *   BatchCreateNotesRequest request = BatchCreateNotesRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .putAllNotes(notes)
-   *     .build();
-   *   BatchCreateNotesResponse response = grafeasV1Beta1Client.batchCreateNotes(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final BatchCreateNotesResponse batchCreateNotes(BatchCreateNotesRequest request) { - return batchCreateNotesCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Creates new notes in batch. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   Map<String, Note> notes = new HashMap<>();
-   *   BatchCreateNotesRequest request = BatchCreateNotesRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .putAllNotes(notes)
-   *     .build();
-   *   ApiFuture<BatchCreateNotesResponse> future = grafeasV1Beta1Client.batchCreateNotesCallable().futureCall(request);
-   *   // Do something
-   *   BatchCreateNotesResponse response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable - batchCreateNotesCallable() { - return stub.batchCreateNotesCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Updates the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Note note = Note.newBuilder().build();
-   *   FieldMask updateMask = FieldMask.newBuilder().build();
-   *   Note response = grafeasV1Beta1Client.updateNote(name, note, updateMask);
-   * }
-   * 
- * - * @param name The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @param note The updated note. - * @param updateMask The fields to update. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Note updateNote(NoteName name, Note note, FieldMask updateMask) { - - UpdateNoteRequest request = - UpdateNoteRequest.newBuilder() - .setName(name == null ? null : name.toString()) - .setNote(note) - .setUpdateMask(updateMask) - .build(); - return updateNote(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Updates the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Note note = Note.newBuilder().build();
-   *   FieldMask updateMask = FieldMask.newBuilder().build();
-   *   Note response = grafeasV1Beta1Client.updateNote(name.toString(), note, updateMask);
-   * }
-   * 
- * - * @param name The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @param note The updated note. - * @param updateMask The fields to update. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Note updateNote(String name, Note note, FieldMask updateMask) { - - UpdateNoteRequest request = - UpdateNoteRequest.newBuilder() - .setName(name) - .setNote(note) - .setUpdateMask(updateMask) - .build(); - return updateNote(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Updates the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Note note = Note.newBuilder().build();
-   *   UpdateNoteRequest request = UpdateNoteRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .setNote(note)
-   *     .build();
-   *   Note response = grafeasV1Beta1Client.updateNote(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Note updateNote(UpdateNoteRequest request) { - return updateNoteCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Updates the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   Note note = Note.newBuilder().build();
-   *   UpdateNoteRequest request = UpdateNoteRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .setNote(note)
-   *     .build();
-   *   ApiFuture<Note> future = grafeasV1Beta1Client.updateNoteCallable().futureCall(request);
-   *   // Do something
-   *   Note response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable updateNoteCallable() { - return stub.updateNoteCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists occurrences referencing the specified note. Provider projects can use this method to get - * all occurrences across consumer projects referencing the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   String filter = "";
-   *   for (Occurrence element : grafeasV1Beta1Client.listNoteOccurrences(name, filter).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- * - * @param name The name of the note to list occurrences for in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @param filter The filter expression. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListNoteOccurrencesPagedResponse listNoteOccurrences(NoteName name, String filter) { - ListNoteOccurrencesRequest request = - ListNoteOccurrencesRequest.newBuilder() - .setName(name == null ? null : name.toString()) - .setFilter(filter) - .build(); - return listNoteOccurrences(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists occurrences referencing the specified note. Provider projects can use this method to get - * all occurrences across consumer projects referencing the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   String filter = "";
-   *   for (Occurrence element : grafeasV1Beta1Client.listNoteOccurrences(name.toString(), filter).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- * - * @param name The name of the note to list occurrences for in the form of - * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - * @param filter The filter expression. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListNoteOccurrencesPagedResponse listNoteOccurrences(String name, String filter) { - ListNoteOccurrencesRequest request = - ListNoteOccurrencesRequest.newBuilder().setName(name).setFilter(filter).build(); - return listNoteOccurrences(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists occurrences referencing the specified note. Provider projects can use this method to get - * all occurrences across consumer projects referencing the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   ListNoteOccurrencesRequest request = ListNoteOccurrencesRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   for (Occurrence element : grafeasV1Beta1Client.listNoteOccurrences(request).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListNoteOccurrencesPagedResponse listNoteOccurrences( - ListNoteOccurrencesRequest request) { - return listNoteOccurrencesPagedCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists occurrences referencing the specified note. Provider projects can use this method to get - * all occurrences across consumer projects referencing the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   ListNoteOccurrencesRequest request = ListNoteOccurrencesRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   ApiFuture<ListNoteOccurrencesPagedResponse> future = grafeasV1Beta1Client.listNoteOccurrencesPagedCallable().futureCall(request);
-   *   // Do something
-   *   for (Occurrence element : future.get().iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * 
- */ - public final UnaryCallable - listNoteOccurrencesPagedCallable() { - return stub.listNoteOccurrencesPagedCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Lists occurrences referencing the specified note. Provider projects can use this method to get - * all occurrences across consumer projects referencing the specified note. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   NoteName name = NoteName.of("[PROJECT]", "[NOTE]");
-   *   ListNoteOccurrencesRequest request = ListNoteOccurrencesRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   while (true) {
-   *     ListNoteOccurrencesResponse response = grafeasV1Beta1Client.listNoteOccurrencesCallable().call(request);
-   *     for (Occurrence element : response.getOccurrencesList()) {
-   *       // doThingsWith(element);
-   *     }
-   *     String nextPageToken = response.getNextPageToken();
-   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
-   *       request = request.toBuilder().setPageToken(nextPageToken).build();
-   *     } else {
-   *       break;
-   *     }
-   *   }
-   * }
-   * 
- */ - public final UnaryCallable - listNoteOccurrencesCallable() { - return stub.listNoteOccurrencesCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets a summary of the number and severity of occurrences. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   String filter = "";
-   *   VulnerabilityOccurrencesSummary response = grafeasV1Beta1Client.getVulnerabilityOccurrencesSummary(parent, filter);
-   * }
-   * 
- * - * @param parent The name of the project to get a vulnerability summary for in the form of - * `projects/[PROJECT_ID]`. - * @param filter The filter expression. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final VulnerabilityOccurrencesSummary getVulnerabilityOccurrencesSummary( - ProjectName parent, String filter) { - - GetVulnerabilityOccurrencesSummaryRequest request = - GetVulnerabilityOccurrencesSummaryRequest.newBuilder() - .setParent(parent == null ? null : parent.toString()) - .setFilter(filter) - .build(); - return getVulnerabilityOccurrencesSummary(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets a summary of the number and severity of occurrences. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   String filter = "";
-   *   VulnerabilityOccurrencesSummary response = grafeasV1Beta1Client.getVulnerabilityOccurrencesSummary(parent.toString(), filter);
-   * }
-   * 
- * - * @param parent The name of the project to get a vulnerability summary for in the form of - * `projects/[PROJECT_ID]`. - * @param filter The filter expression. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final VulnerabilityOccurrencesSummary getVulnerabilityOccurrencesSummary( - String parent, String filter) { - - GetVulnerabilityOccurrencesSummaryRequest request = - GetVulnerabilityOccurrencesSummaryRequest.newBuilder() - .setParent(parent) - .setFilter(filter) - .build(); - return getVulnerabilityOccurrencesSummary(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets a summary of the number and severity of occurrences. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   GetVulnerabilityOccurrencesSummaryRequest request = GetVulnerabilityOccurrencesSummaryRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .build();
-   *   VulnerabilityOccurrencesSummary response = grafeasV1Beta1Client.getVulnerabilityOccurrencesSummary(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final VulnerabilityOccurrencesSummary getVulnerabilityOccurrencesSummary( - GetVulnerabilityOccurrencesSummaryRequest request) { - return getVulnerabilityOccurrencesSummaryCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Gets a summary of the number and severity of occurrences. - * - *

Sample code: - * - *


-   * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
-   *   ProjectName parent = ProjectName.of("[PROJECT]");
-   *   GetVulnerabilityOccurrencesSummaryRequest request = GetVulnerabilityOccurrencesSummaryRequest.newBuilder()
-   *     .setParent(parent.toString())
-   *     .build();
-   *   ApiFuture<VulnerabilityOccurrencesSummary> future = grafeasV1Beta1Client.getVulnerabilityOccurrencesSummaryCallable().futureCall(request);
-   *   // Do something
-   *   VulnerabilityOccurrencesSummary response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable< - GetVulnerabilityOccurrencesSummaryRequest, VulnerabilityOccurrencesSummary> - getVulnerabilityOccurrencesSummaryCallable() { - return stub.getVulnerabilityOccurrencesSummaryCallable(); - } - - @Override - public final void close() { - stub.close(); - } - - @Override - public void shutdown() { - stub.shutdown(); - } - - @Override - public boolean isShutdown() { - return stub.isShutdown(); - } - - @Override - public boolean isTerminated() { - return stub.isTerminated(); - } - - @Override - public void shutdownNow() { - stub.shutdownNow(); - } - - @Override - public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { - return stub.awaitTermination(duration, unit); - } - - public static class ListOccurrencesPagedResponse - extends AbstractPagedListResponse< - ListOccurrencesRequest, - ListOccurrencesResponse, - Occurrence, - ListOccurrencesPage, - ListOccurrencesFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - ListOccurrencesPage.createEmptyPage().createPageAsync(context, futureResponse); - return ApiFutures.transform( - futurePage, - new ApiFunction() { - @Override - public ListOccurrencesPagedResponse apply(ListOccurrencesPage input) { - return new ListOccurrencesPagedResponse(input); - } - }, - MoreExecutors.directExecutor()); - } - - private ListOccurrencesPagedResponse(ListOccurrencesPage page) { - super(page, ListOccurrencesFixedSizeCollection.createEmptyCollection()); - } - } - - public static class ListOccurrencesPage - extends AbstractPage< - ListOccurrencesRequest, ListOccurrencesResponse, Occurrence, ListOccurrencesPage> { - - private ListOccurrencesPage( - PageContext context, - ListOccurrencesResponse response) { - super(context, response); - } - - private static ListOccurrencesPage createEmptyPage() { - return new ListOccurrencesPage(null, null); - } - - @Override - protected ListOccurrencesPage createPage( - PageContext context, - ListOccurrencesResponse response) { - return new ListOccurrencesPage(context, response); - } - - @Override - public ApiFuture createPageAsync( - PageContext context, - ApiFuture futureResponse) { - return super.createPageAsync(context, futureResponse); - } - } - - public static class ListOccurrencesFixedSizeCollection - extends AbstractFixedSizeCollection< - ListOccurrencesRequest, - ListOccurrencesResponse, - Occurrence, - ListOccurrencesPage, - ListOccurrencesFixedSizeCollection> { - - private ListOccurrencesFixedSizeCollection( - List pages, int collectionSize) { - super(pages, collectionSize); - } - - private static ListOccurrencesFixedSizeCollection createEmptyCollection() { - return new ListOccurrencesFixedSizeCollection(null, 0); - } - - @Override - protected ListOccurrencesFixedSizeCollection createCollection( - List pages, int collectionSize) { - return new ListOccurrencesFixedSizeCollection(pages, collectionSize); - } - } - - public static class ListNotesPagedResponse - extends AbstractPagedListResponse< - ListNotesRequest, ListNotesResponse, Note, ListNotesPage, ListNotesFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - ListNotesPage.createEmptyPage().createPageAsync(context, futureResponse); - return ApiFutures.transform( - futurePage, - new ApiFunction() { - @Override - public ListNotesPagedResponse apply(ListNotesPage input) { - return new ListNotesPagedResponse(input); - } - }, - MoreExecutors.directExecutor()); - } - - private ListNotesPagedResponse(ListNotesPage page) { - super(page, ListNotesFixedSizeCollection.createEmptyCollection()); - } - } - - public static class ListNotesPage - extends AbstractPage { - - private ListNotesPage( - PageContext context, - ListNotesResponse response) { - super(context, response); - } - - private static ListNotesPage createEmptyPage() { - return new ListNotesPage(null, null); - } - - @Override - protected ListNotesPage createPage( - PageContext context, - ListNotesResponse response) { - return new ListNotesPage(context, response); - } - - @Override - public ApiFuture createPageAsync( - PageContext context, - ApiFuture futureResponse) { - return super.createPageAsync(context, futureResponse); - } - } - - public static class ListNotesFixedSizeCollection - extends AbstractFixedSizeCollection< - ListNotesRequest, ListNotesResponse, Note, ListNotesPage, ListNotesFixedSizeCollection> { - - private ListNotesFixedSizeCollection(List pages, int collectionSize) { - super(pages, collectionSize); - } - - private static ListNotesFixedSizeCollection createEmptyCollection() { - return new ListNotesFixedSizeCollection(null, 0); - } - - @Override - protected ListNotesFixedSizeCollection createCollection( - List pages, int collectionSize) { - return new ListNotesFixedSizeCollection(pages, collectionSize); - } - } - - public static class ListNoteOccurrencesPagedResponse - extends AbstractPagedListResponse< - ListNoteOccurrencesRequest, - ListNoteOccurrencesResponse, - Occurrence, - ListNoteOccurrencesPage, - ListNoteOccurrencesFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - ListNoteOccurrencesPage.createEmptyPage().createPageAsync(context, futureResponse); - return ApiFutures.transform( - futurePage, - new ApiFunction() { - @Override - public ListNoteOccurrencesPagedResponse apply(ListNoteOccurrencesPage input) { - return new ListNoteOccurrencesPagedResponse(input); - } - }, - MoreExecutors.directExecutor()); - } - - private ListNoteOccurrencesPagedResponse(ListNoteOccurrencesPage page) { - super(page, ListNoteOccurrencesFixedSizeCollection.createEmptyCollection()); - } - } - - public static class ListNoteOccurrencesPage - extends AbstractPage< - ListNoteOccurrencesRequest, - ListNoteOccurrencesResponse, - Occurrence, - ListNoteOccurrencesPage> { - - private ListNoteOccurrencesPage( - PageContext context, - ListNoteOccurrencesResponse response) { - super(context, response); - } - - private static ListNoteOccurrencesPage createEmptyPage() { - return new ListNoteOccurrencesPage(null, null); - } - - @Override - protected ListNoteOccurrencesPage createPage( - PageContext context, - ListNoteOccurrencesResponse response) { - return new ListNoteOccurrencesPage(context, response); - } - - @Override - public ApiFuture createPageAsync( - PageContext context, - ApiFuture futureResponse) { - return super.createPageAsync(context, futureResponse); - } - } - - public static class ListNoteOccurrencesFixedSizeCollection - extends AbstractFixedSizeCollection< - ListNoteOccurrencesRequest, - ListNoteOccurrencesResponse, - Occurrence, - ListNoteOccurrencesPage, - ListNoteOccurrencesFixedSizeCollection> { - - private ListNoteOccurrencesFixedSizeCollection( - List pages, int collectionSize) { - super(pages, collectionSize); - } - - private static ListNoteOccurrencesFixedSizeCollection createEmptyCollection() { - return new ListNoteOccurrencesFixedSizeCollection(null, 0); - } - - @Override - protected ListNoteOccurrencesFixedSizeCollection createCollection( - List pages, int collectionSize) { - return new ListNoteOccurrencesFixedSizeCollection(pages, collectionSize); - } - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/GrafeasV1Beta1Settings.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/GrafeasV1Beta1Settings.java deleted file mode 100644 index b47282a4..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/GrafeasV1Beta1Settings.java +++ /dev/null @@ -1,370 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1; - -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListNoteOccurrencesPagedResponse; -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListNotesPagedResponse; -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListOccurrencesPagedResponse; - -import com.google.api.core.ApiFunction; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.GoogleCredentialsProvider; -import com.google.api.gax.core.InstantiatingExecutorProvider; -import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.ClientSettings; -import com.google.api.gax.rpc.PagedCallSettings; -import com.google.api.gax.rpc.TransportChannelProvider; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.cloud.devtools.containeranalysis.v1beta1.stub.GrafeasV1Beta1StubSettings; -import com.google.protobuf.Empty; -import io.grafeas.v1beta1.BatchCreateNotesRequest; -import io.grafeas.v1beta1.BatchCreateNotesResponse; -import io.grafeas.v1beta1.BatchCreateOccurrencesRequest; -import io.grafeas.v1beta1.BatchCreateOccurrencesResponse; -import io.grafeas.v1beta1.CreateNoteRequest; -import io.grafeas.v1beta1.CreateOccurrenceRequest; -import io.grafeas.v1beta1.DeleteNoteRequest; -import io.grafeas.v1beta1.DeleteOccurrenceRequest; -import io.grafeas.v1beta1.GetNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceRequest; -import io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesResponse; -import io.grafeas.v1beta1.ListNotesRequest; -import io.grafeas.v1beta1.ListNotesResponse; -import io.grafeas.v1beta1.ListOccurrencesRequest; -import io.grafeas.v1beta1.ListOccurrencesResponse; -import io.grafeas.v1beta1.Note; -import io.grafeas.v1beta1.Occurrence; -import io.grafeas.v1beta1.UpdateNoteRequest; -import io.grafeas.v1beta1.UpdateOccurrenceRequest; -import io.grafeas.v1beta1.VulnerabilityOccurrencesSummary; -import java.io.IOException; -import java.util.List; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * Settings class to configure an instance of {@link GrafeasV1Beta1Client}. - * - *

The default instance has everything set to sensible defaults: - * - *

    - *
  • The default service address (containeranalysis.googleapis.com) and default port (443) are - * used. - *
  • Credentials are acquired automatically through Application Default Credentials. - *
  • Retries are configured for idempotent methods but not for non-idempotent methods. - *
- * - *

The builder of this class is recursive, so contained classes are themselves builders. When - * build() is called, the tree of builders is called to create the complete settings object. - * - *

For example, to set the total timeout of getOccurrence to 30 seconds: - * - *

- * 
- * GrafeasV1Beta1Settings.Builder grafeasV1Beta1SettingsBuilder =
- *     GrafeasV1Beta1Settings.newBuilder();
- * grafeasV1Beta1SettingsBuilder.getOccurrenceSettings().getRetrySettings().toBuilder()
- *     .setTotalTimeout(Duration.ofSeconds(30));
- * GrafeasV1Beta1Settings grafeasV1Beta1Settings = grafeasV1Beta1SettingsBuilder.build();
- * 
- * 
- */ -@Generated("by gapic-generator") -@BetaApi -public class GrafeasV1Beta1Settings extends ClientSettings { - /** Returns the object with the settings used for calls to getOccurrence. */ - public UnaryCallSettings getOccurrenceSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).getOccurrenceSettings(); - } - - /** Returns the object with the settings used for calls to listOccurrences. */ - public PagedCallSettings< - ListOccurrencesRequest, ListOccurrencesResponse, ListOccurrencesPagedResponse> - listOccurrencesSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).listOccurrencesSettings(); - } - - /** Returns the object with the settings used for calls to deleteOccurrence. */ - public UnaryCallSettings deleteOccurrenceSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).deleteOccurrenceSettings(); - } - - /** Returns the object with the settings used for calls to createOccurrence. */ - public UnaryCallSettings createOccurrenceSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).createOccurrenceSettings(); - } - - /** Returns the object with the settings used for calls to batchCreateOccurrences. */ - public UnaryCallSettings - batchCreateOccurrencesSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).batchCreateOccurrencesSettings(); - } - - /** Returns the object with the settings used for calls to updateOccurrence. */ - public UnaryCallSettings updateOccurrenceSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).updateOccurrenceSettings(); - } - - /** Returns the object with the settings used for calls to getOccurrenceNote. */ - public UnaryCallSettings getOccurrenceNoteSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).getOccurrenceNoteSettings(); - } - - /** Returns the object with the settings used for calls to getNote. */ - public UnaryCallSettings getNoteSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).getNoteSettings(); - } - - /** Returns the object with the settings used for calls to listNotes. */ - public PagedCallSettings - listNotesSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).listNotesSettings(); - } - - /** Returns the object with the settings used for calls to deleteNote. */ - public UnaryCallSettings deleteNoteSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).deleteNoteSettings(); - } - - /** Returns the object with the settings used for calls to createNote. */ - public UnaryCallSettings createNoteSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).createNoteSettings(); - } - - /** Returns the object with the settings used for calls to batchCreateNotes. */ - public UnaryCallSettings - batchCreateNotesSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).batchCreateNotesSettings(); - } - - /** Returns the object with the settings used for calls to updateNote. */ - public UnaryCallSettings updateNoteSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).updateNoteSettings(); - } - - /** Returns the object with the settings used for calls to listNoteOccurrences. */ - public PagedCallSettings< - ListNoteOccurrencesRequest, ListNoteOccurrencesResponse, ListNoteOccurrencesPagedResponse> - listNoteOccurrencesSettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()).listNoteOccurrencesSettings(); - } - - /** Returns the object with the settings used for calls to getVulnerabilityOccurrencesSummary. */ - public UnaryCallSettings< - GetVulnerabilityOccurrencesSummaryRequest, VulnerabilityOccurrencesSummary> - getVulnerabilityOccurrencesSummarySettings() { - return ((GrafeasV1Beta1StubSettings) getStubSettings()) - .getVulnerabilityOccurrencesSummarySettings(); - } - - public static final GrafeasV1Beta1Settings create(GrafeasV1Beta1StubSettings stub) - throws IOException { - return new GrafeasV1Beta1Settings.Builder(stub.toBuilder()).build(); - } - - /** Returns a builder for the default ExecutorProvider for this service. */ - public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { - return GrafeasV1Beta1StubSettings.defaultExecutorProviderBuilder(); - } - - /** Returns the default service endpoint. */ - public static String getDefaultEndpoint() { - return GrafeasV1Beta1StubSettings.getDefaultEndpoint(); - } - - /** Returns the default service scopes. */ - public static List getDefaultServiceScopes() { - return GrafeasV1Beta1StubSettings.getDefaultServiceScopes(); - } - - /** Returns a builder for the default credentials for this service. */ - public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { - return GrafeasV1Beta1StubSettings.defaultCredentialsProviderBuilder(); - } - - /** Returns a builder for the default ChannelProvider for this service. */ - public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { - return GrafeasV1Beta1StubSettings.defaultGrpcTransportProviderBuilder(); - } - - public static TransportChannelProvider defaultTransportChannelProvider() { - return GrafeasV1Beta1StubSettings.defaultTransportChannelProvider(); - } - - @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") - public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { - return GrafeasV1Beta1StubSettings.defaultApiClientHeaderProviderBuilder(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder() { - return Builder.createDefault(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder(ClientContext clientContext) { - return new Builder(clientContext); - } - - /** Returns a builder containing all the values of this settings class. */ - public Builder toBuilder() { - return new Builder(this); - } - - protected GrafeasV1Beta1Settings(Builder settingsBuilder) throws IOException { - super(settingsBuilder); - } - - /** Builder for GrafeasV1Beta1Settings. */ - public static class Builder extends ClientSettings.Builder { - protected Builder() throws IOException { - this((ClientContext) null); - } - - protected Builder(ClientContext clientContext) { - super(GrafeasV1Beta1StubSettings.newBuilder(clientContext)); - } - - private static Builder createDefault() { - return new Builder(GrafeasV1Beta1StubSettings.newBuilder()); - } - - protected Builder(GrafeasV1Beta1Settings settings) { - super(settings.getStubSettings().toBuilder()); - } - - protected Builder(GrafeasV1Beta1StubSettings.Builder stubSettings) { - super(stubSettings); - } - - public GrafeasV1Beta1StubSettings.Builder getStubSettingsBuilder() { - return ((GrafeasV1Beta1StubSettings.Builder) getStubSettings()); - } - - // NEXT_MAJOR_VER: remove 'throws Exception' - /** - * Applies the given settings updater function to all of the unary API methods in this service. - * - *

Note: This method does not support applying settings to streaming methods. - */ - public Builder applyToAllUnaryMethods( - ApiFunction, Void> settingsUpdater) throws Exception { - super.applyToAllUnaryMethods( - getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); - return this; - } - - /** Returns the builder for the settings used for calls to getOccurrence. */ - public UnaryCallSettings.Builder getOccurrenceSettings() { - return getStubSettingsBuilder().getOccurrenceSettings(); - } - - /** Returns the builder for the settings used for calls to listOccurrences. */ - public PagedCallSettings.Builder< - ListOccurrencesRequest, ListOccurrencesResponse, ListOccurrencesPagedResponse> - listOccurrencesSettings() { - return getStubSettingsBuilder().listOccurrencesSettings(); - } - - /** Returns the builder for the settings used for calls to deleteOccurrence. */ - public UnaryCallSettings.Builder deleteOccurrenceSettings() { - return getStubSettingsBuilder().deleteOccurrenceSettings(); - } - - /** Returns the builder for the settings used for calls to createOccurrence. */ - public UnaryCallSettings.Builder - createOccurrenceSettings() { - return getStubSettingsBuilder().createOccurrenceSettings(); - } - - /** Returns the builder for the settings used for calls to batchCreateOccurrences. */ - public UnaryCallSettings.Builder - batchCreateOccurrencesSettings() { - return getStubSettingsBuilder().batchCreateOccurrencesSettings(); - } - - /** Returns the builder for the settings used for calls to updateOccurrence. */ - public UnaryCallSettings.Builder - updateOccurrenceSettings() { - return getStubSettingsBuilder().updateOccurrenceSettings(); - } - - /** Returns the builder for the settings used for calls to getOccurrenceNote. */ - public UnaryCallSettings.Builder getOccurrenceNoteSettings() { - return getStubSettingsBuilder().getOccurrenceNoteSettings(); - } - - /** Returns the builder for the settings used for calls to getNote. */ - public UnaryCallSettings.Builder getNoteSettings() { - return getStubSettingsBuilder().getNoteSettings(); - } - - /** Returns the builder for the settings used for calls to listNotes. */ - public PagedCallSettings.Builder - listNotesSettings() { - return getStubSettingsBuilder().listNotesSettings(); - } - - /** Returns the builder for the settings used for calls to deleteNote. */ - public UnaryCallSettings.Builder deleteNoteSettings() { - return getStubSettingsBuilder().deleteNoteSettings(); - } - - /** Returns the builder for the settings used for calls to createNote. */ - public UnaryCallSettings.Builder createNoteSettings() { - return getStubSettingsBuilder().createNoteSettings(); - } - - /** Returns the builder for the settings used for calls to batchCreateNotes. */ - public UnaryCallSettings.Builder - batchCreateNotesSettings() { - return getStubSettingsBuilder().batchCreateNotesSettings(); - } - - /** Returns the builder for the settings used for calls to updateNote. */ - public UnaryCallSettings.Builder updateNoteSettings() { - return getStubSettingsBuilder().updateNoteSettings(); - } - - /** Returns the builder for the settings used for calls to listNoteOccurrences. */ - public PagedCallSettings.Builder< - ListNoteOccurrencesRequest, - ListNoteOccurrencesResponse, - ListNoteOccurrencesPagedResponse> - listNoteOccurrencesSettings() { - return getStubSettingsBuilder().listNoteOccurrencesSettings(); - } - - /** - * Returns the builder for the settings used for calls to getVulnerabilityOccurrencesSummary. - */ - public UnaryCallSettings.Builder< - GetVulnerabilityOccurrencesSummaryRequest, VulnerabilityOccurrencesSummary> - getVulnerabilityOccurrencesSummarySettings() { - return getStubSettingsBuilder().getVulnerabilityOccurrencesSummarySettings(); - } - - @Override - public GrafeasV1Beta1Settings build() throws IOException { - return new GrafeasV1Beta1Settings(this); - } - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/package-info.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/package-info.java deleted file mode 100644 index b51edeb4..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/package-info.java +++ /dev/null @@ -1,77 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * A client to Container Analysis API. - * - *

The interfaces provided are listed below, along with usage samples. - * - *

============================== ContainerAnalysisV1Beta1Client ============================== - * - *

Service Description: Retrieves analysis results of Cloud components such as Docker container - * images. The Container Analysis API is an implementation of the [Grafeas](grafeas.io) API. - * - *

Analysis results are stored as a series of occurrences. An `Occurrence` contains information - * about a specific analysis instance on a resource. An occurrence refers to a `Note`. A note - * contains details describing the analysis and is generally stored in a separate project, called a - * `Provider`. Multiple occurrences can refer to the same note. - * - *

For example, an SSL vulnerability could affect multiple images. In this case, there would be - * one note for the vulnerability and an occurrence for each image with the vulnerability referring - * to that note. - * - *

Sample for ContainerAnalysisV1Beta1Client: - * - *

- * 
- * try (ContainerAnalysisV1Beta1Client containerAnalysisV1Beta1Client = ContainerAnalysisV1Beta1Client.create()) {
- *   IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]");
- *   Policy policy = Policy.newBuilder().build();
- *   Policy response = containerAnalysisV1Beta1Client.setIamPolicy(resource, policy);
- * }
- * 
- * 
- * - * ==================== GrafeasV1Beta1Client ==================== - * - *

Service Description: [Grafeas](grafeas.io) API. - * - *

Retrieves analysis results of Cloud components such as Docker container images. - * - *

Analysis results are stored as a series of occurrences. An `Occurrence` contains information - * about a specific analysis instance on a resource. An occurrence refers to a `Note`. A note - * contains details describing the analysis and is generally stored in a separate project, called a - * `Provider`. Multiple occurrences can refer to the same note. - * - *

For example, an SSL vulnerability could affect multiple images. In this case, there would be - * one note for the vulnerability and an occurrence for each image with the vulnerability referring - * to that note. - * - *

Sample for GrafeasV1Beta1Client: - * - *

- * 
- * try (GrafeasV1Beta1Client grafeasV1Beta1Client = GrafeasV1Beta1Client.create()) {
- *   OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]");
- *   Occurrence response = grafeasV1Beta1Client.getOccurrence(name);
- * }
- * 
- * 
- */ -@Generated("by gapic-generator") -package com.google.cloud.devtools.containeranalysis.v1beta1; - -import javax.annotation.Generated; diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/ContainerAnalysisV1Beta1Stub.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/ContainerAnalysisV1Beta1Stub.java deleted file mode 100644 index f47a1739..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/ContainerAnalysisV1Beta1Stub.java +++ /dev/null @@ -1,77 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1.stub; - -import static com.google.cloud.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1Client.ListScanConfigsPagedResponse; - -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.containeranalysis.v1beta1.GetScanConfigRequest; -import com.google.containeranalysis.v1beta1.ListScanConfigsRequest; -import com.google.containeranalysis.v1beta1.ListScanConfigsResponse; -import com.google.containeranalysis.v1beta1.ScanConfig; -import com.google.containeranalysis.v1beta1.UpdateScanConfigRequest; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * Base stub class for Container Analysis API. - * - *

This class is for advanced usage and reflects the underlying API directly. - */ -@Generated("by gapic-generator") -@BetaApi("A restructuring of stub classes is planned, so this may break in the future") -public abstract class ContainerAnalysisV1Beta1Stub implements BackgroundResource { - - public UnaryCallable setIamPolicyCallable() { - throw new UnsupportedOperationException("Not implemented: setIamPolicyCallable()"); - } - - public UnaryCallable getIamPolicyCallable() { - throw new UnsupportedOperationException("Not implemented: getIamPolicyCallable()"); - } - - public UnaryCallable - testIamPermissionsCallable() { - throw new UnsupportedOperationException("Not implemented: testIamPermissionsCallable()"); - } - - public UnaryCallable getScanConfigCallable() { - throw new UnsupportedOperationException("Not implemented: getScanConfigCallable()"); - } - - public UnaryCallable - listScanConfigsPagedCallable() { - throw new UnsupportedOperationException("Not implemented: listScanConfigsPagedCallable()"); - } - - public UnaryCallable listScanConfigsCallable() { - throw new UnsupportedOperationException("Not implemented: listScanConfigsCallable()"); - } - - public UnaryCallable updateScanConfigCallable() { - throw new UnsupportedOperationException("Not implemented: updateScanConfigCallable()"); - } - - @Override - public abstract void close(); -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/ContainerAnalysisV1Beta1StubSettings.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/ContainerAnalysisV1Beta1StubSettings.java deleted file mode 100644 index d9eec62e..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/ContainerAnalysisV1Beta1StubSettings.java +++ /dev/null @@ -1,473 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1.stub; - -import static com.google.cloud.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1Client.ListScanConfigsPagedResponse; - -import com.google.api.core.ApiFunction; -import com.google.api.core.ApiFuture; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.GaxProperties; -import com.google.api.gax.core.GoogleCredentialsProvider; -import com.google.api.gax.core.InstantiatingExecutorProvider; -import com.google.api.gax.grpc.GaxGrpcProperties; -import com.google.api.gax.grpc.GrpcTransportChannel; -import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; -import com.google.api.gax.retrying.RetrySettings; -import com.google.api.gax.rpc.ApiCallContext; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.PageContext; -import com.google.api.gax.rpc.PagedCallSettings; -import com.google.api.gax.rpc.PagedListDescriptor; -import com.google.api.gax.rpc.PagedListResponseFactory; -import com.google.api.gax.rpc.StatusCode; -import com.google.api.gax.rpc.StubSettings; -import com.google.api.gax.rpc.TransportChannelProvider; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.common.collect.ImmutableList; -import com.google.common.collect.ImmutableMap; -import com.google.common.collect.ImmutableSet; -import com.google.common.collect.Lists; -import com.google.containeranalysis.v1beta1.GetScanConfigRequest; -import com.google.containeranalysis.v1beta1.ListScanConfigsRequest; -import com.google.containeranalysis.v1beta1.ListScanConfigsResponse; -import com.google.containeranalysis.v1beta1.ScanConfig; -import com.google.containeranalysis.v1beta1.UpdateScanConfigRequest; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import java.io.IOException; -import java.util.List; -import javax.annotation.Generated; -import org.threeten.bp.Duration; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * Settings class to configure an instance of {@link ContainerAnalysisV1Beta1Stub}. - * - *

The default instance has everything set to sensible defaults: - * - *

    - *
  • The default service address (containeranalysis.googleapis.com) and default port (443) are - * used. - *
  • Credentials are acquired automatically through Application Default Credentials. - *
  • Retries are configured for idempotent methods but not for non-idempotent methods. - *
- * - *

The builder of this class is recursive, so contained classes are themselves builders. When - * build() is called, the tree of builders is called to create the complete settings object. - * - *

For example, to set the total timeout of setIamPolicy to 30 seconds: - * - *

- * 
- * ContainerAnalysisV1Beta1StubSettings.Builder containerAnalysisV1Beta1SettingsBuilder =
- *     ContainerAnalysisV1Beta1StubSettings.newBuilder();
- * containerAnalysisV1Beta1SettingsBuilder.setIamPolicySettings().getRetrySettings().toBuilder()
- *     .setTotalTimeout(Duration.ofSeconds(30));
- * ContainerAnalysisV1Beta1StubSettings containerAnalysisV1Beta1Settings = containerAnalysisV1Beta1SettingsBuilder.build();
- * 
- * 
- */ -@Generated("by gapic-generator") -@BetaApi -public class ContainerAnalysisV1Beta1StubSettings - extends StubSettings { - /** The default scopes of the service. */ - private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); - - private final UnaryCallSettings setIamPolicySettings; - private final UnaryCallSettings getIamPolicySettings; - private final UnaryCallSettings - testIamPermissionsSettings; - private final UnaryCallSettings getScanConfigSettings; - private final PagedCallSettings< - ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> - listScanConfigsSettings; - private final UnaryCallSettings updateScanConfigSettings; - - /** Returns the object with the settings used for calls to setIamPolicy. */ - public UnaryCallSettings setIamPolicySettings() { - return setIamPolicySettings; - } - - /** Returns the object with the settings used for calls to getIamPolicy. */ - public UnaryCallSettings getIamPolicySettings() { - return getIamPolicySettings; - } - - /** Returns the object with the settings used for calls to testIamPermissions. */ - public UnaryCallSettings - testIamPermissionsSettings() { - return testIamPermissionsSettings; - } - - /** Returns the object with the settings used for calls to getScanConfig. */ - public UnaryCallSettings getScanConfigSettings() { - return getScanConfigSettings; - } - - /** Returns the object with the settings used for calls to listScanConfigs. */ - public PagedCallSettings< - ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> - listScanConfigsSettings() { - return listScanConfigsSettings; - } - - /** Returns the object with the settings used for calls to updateScanConfig. */ - public UnaryCallSettings updateScanConfigSettings() { - return updateScanConfigSettings; - } - - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - public ContainerAnalysisV1Beta1Stub createStub() throws IOException { - if (getTransportChannelProvider() - .getTransportName() - .equals(GrpcTransportChannel.getGrpcTransportName())) { - return GrpcContainerAnalysisV1Beta1Stub.create(this); - } else { - throw new UnsupportedOperationException( - "Transport not supported: " + getTransportChannelProvider().getTransportName()); - } - } - - /** Returns a builder for the default ExecutorProvider for this service. */ - public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { - return InstantiatingExecutorProvider.newBuilder(); - } - - /** Returns the default service endpoint. */ - public static String getDefaultEndpoint() { - return "containeranalysis.googleapis.com:443"; - } - - /** Returns the default service scopes. */ - public static List getDefaultServiceScopes() { - return DEFAULT_SERVICE_SCOPES; - } - - /** Returns a builder for the default credentials for this service. */ - public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { - return GoogleCredentialsProvider.newBuilder().setScopesToApply(DEFAULT_SERVICE_SCOPES); - } - - /** Returns a builder for the default ChannelProvider for this service. */ - public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { - return InstantiatingGrpcChannelProvider.newBuilder() - .setMaxInboundMessageSize(Integer.MAX_VALUE); - } - - public static TransportChannelProvider defaultTransportChannelProvider() { - return defaultGrpcTransportProviderBuilder().build(); - } - - @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") - public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { - return ApiClientHeaderProvider.newBuilder() - .setGeneratedLibToken( - "gapic", GaxProperties.getLibraryVersion(ContainerAnalysisV1Beta1StubSettings.class)) - .setTransportToken( - GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder() { - return Builder.createDefault(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder(ClientContext clientContext) { - return new Builder(clientContext); - } - - /** Returns a builder containing all the values of this settings class. */ - public Builder toBuilder() { - return new Builder(this); - } - - protected ContainerAnalysisV1Beta1StubSettings(Builder settingsBuilder) throws IOException { - super(settingsBuilder); - - setIamPolicySettings = settingsBuilder.setIamPolicySettings().build(); - getIamPolicySettings = settingsBuilder.getIamPolicySettings().build(); - testIamPermissionsSettings = settingsBuilder.testIamPermissionsSettings().build(); - getScanConfigSettings = settingsBuilder.getScanConfigSettings().build(); - listScanConfigsSettings = settingsBuilder.listScanConfigsSettings().build(); - updateScanConfigSettings = settingsBuilder.updateScanConfigSettings().build(); - } - - private static final PagedListDescriptor< - ListScanConfigsRequest, ListScanConfigsResponse, ScanConfig> - LIST_SCAN_CONFIGS_PAGE_STR_DESC = - new PagedListDescriptor() { - @Override - public String emptyToken() { - return ""; - } - - @Override - public ListScanConfigsRequest injectToken( - ListScanConfigsRequest payload, String token) { - return ListScanConfigsRequest.newBuilder(payload).setPageToken(token).build(); - } - - @Override - public ListScanConfigsRequest injectPageSize( - ListScanConfigsRequest payload, int pageSize) { - return ListScanConfigsRequest.newBuilder(payload).setPageSize(pageSize).build(); - } - - @Override - public Integer extractPageSize(ListScanConfigsRequest payload) { - return payload.getPageSize(); - } - - @Override - public String extractNextToken(ListScanConfigsResponse payload) { - return payload.getNextPageToken(); - } - - @Override - public Iterable extractResources(ListScanConfigsResponse payload) { - return payload.getScanConfigsList() != null - ? payload.getScanConfigsList() - : ImmutableList.of(); - } - }; - - private static final PagedListResponseFactory< - ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> - LIST_SCAN_CONFIGS_PAGE_STR_FACT = - new PagedListResponseFactory< - ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse>() { - @Override - public ApiFuture getFuturePagedResponse( - UnaryCallable callable, - ListScanConfigsRequest request, - ApiCallContext context, - ApiFuture futureResponse) { - PageContext pageContext = - PageContext.create(callable, LIST_SCAN_CONFIGS_PAGE_STR_DESC, request, context); - return ListScanConfigsPagedResponse.createAsync(pageContext, futureResponse); - } - }; - - /** Builder for ContainerAnalysisV1Beta1StubSettings. */ - public static class Builder - extends StubSettings.Builder { - private final ImmutableList> unaryMethodSettingsBuilders; - - private final UnaryCallSettings.Builder setIamPolicySettings; - private final UnaryCallSettings.Builder getIamPolicySettings; - private final UnaryCallSettings.Builder - testIamPermissionsSettings; - private final UnaryCallSettings.Builder getScanConfigSettings; - private final PagedCallSettings.Builder< - ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> - listScanConfigsSettings; - private final UnaryCallSettings.Builder - updateScanConfigSettings; - - private static final ImmutableMap> - RETRYABLE_CODE_DEFINITIONS; - - static { - ImmutableMap.Builder> definitions = - ImmutableMap.builder(); - definitions.put( - "idempotent", - ImmutableSet.copyOf( - Lists.newArrayList( - StatusCode.Code.DEADLINE_EXCEEDED, StatusCode.Code.UNAVAILABLE))); - definitions.put("non_idempotent", ImmutableSet.copyOf(Lists.newArrayList())); - RETRYABLE_CODE_DEFINITIONS = definitions.build(); - } - - private static final ImmutableMap RETRY_PARAM_DEFINITIONS; - - static { - ImmutableMap.Builder definitions = ImmutableMap.builder(); - RetrySettings settings = null; - settings = - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(100L)) - .setRetryDelayMultiplier(1.3) - .setMaxRetryDelay(Duration.ofMillis(60000L)) - .setInitialRpcTimeout(Duration.ofMillis(20000L)) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ofMillis(20000L)) - .setTotalTimeout(Duration.ofMillis(600000L)) - .build(); - definitions.put("default", settings); - RETRY_PARAM_DEFINITIONS = definitions.build(); - } - - protected Builder() { - this((ClientContext) null); - } - - protected Builder(ClientContext clientContext) { - super(clientContext); - - setIamPolicySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - getIamPolicySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - testIamPermissionsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - getScanConfigSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - listScanConfigsSettings = PagedCallSettings.newBuilder(LIST_SCAN_CONFIGS_PAGE_STR_FACT); - - updateScanConfigSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - unaryMethodSettingsBuilders = - ImmutableList.>of( - setIamPolicySettings, - getIamPolicySettings, - testIamPermissionsSettings, - getScanConfigSettings, - listScanConfigsSettings, - updateScanConfigSettings); - - initDefaults(this); - } - - private static Builder createDefault() { - Builder builder = new Builder((ClientContext) null); - builder.setTransportChannelProvider(defaultTransportChannelProvider()); - builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); - builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); - builder.setEndpoint(getDefaultEndpoint()); - return initDefaults(builder); - } - - private static Builder initDefaults(Builder builder) { - - builder - .setIamPolicySettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .getIamPolicySettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .testIamPermissionsSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .getScanConfigSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .listScanConfigsSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .updateScanConfigSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - return builder; - } - - protected Builder(ContainerAnalysisV1Beta1StubSettings settings) { - super(settings); - - setIamPolicySettings = settings.setIamPolicySettings.toBuilder(); - getIamPolicySettings = settings.getIamPolicySettings.toBuilder(); - testIamPermissionsSettings = settings.testIamPermissionsSettings.toBuilder(); - getScanConfigSettings = settings.getScanConfigSettings.toBuilder(); - listScanConfigsSettings = settings.listScanConfigsSettings.toBuilder(); - updateScanConfigSettings = settings.updateScanConfigSettings.toBuilder(); - - unaryMethodSettingsBuilders = - ImmutableList.>of( - setIamPolicySettings, - getIamPolicySettings, - testIamPermissionsSettings, - getScanConfigSettings, - listScanConfigsSettings, - updateScanConfigSettings); - } - - // NEXT_MAJOR_VER: remove 'throws Exception' - /** - * Applies the given settings updater function to all of the unary API methods in this service. - * - *

Note: This method does not support applying settings to streaming methods. - */ - public Builder applyToAllUnaryMethods( - ApiFunction, Void> settingsUpdater) throws Exception { - super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); - return this; - } - - public ImmutableList> unaryMethodSettingsBuilders() { - return unaryMethodSettingsBuilders; - } - - /** Returns the builder for the settings used for calls to setIamPolicy. */ - public UnaryCallSettings.Builder setIamPolicySettings() { - return setIamPolicySettings; - } - - /** Returns the builder for the settings used for calls to getIamPolicy. */ - public UnaryCallSettings.Builder getIamPolicySettings() { - return getIamPolicySettings; - } - - /** Returns the builder for the settings used for calls to testIamPermissions. */ - public UnaryCallSettings.Builder - testIamPermissionsSettings() { - return testIamPermissionsSettings; - } - - /** Returns the builder for the settings used for calls to getScanConfig. */ - public UnaryCallSettings.Builder getScanConfigSettings() { - return getScanConfigSettings; - } - - /** Returns the builder for the settings used for calls to listScanConfigs. */ - public PagedCallSettings.Builder< - ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> - listScanConfigsSettings() { - return listScanConfigsSettings; - } - - /** Returns the builder for the settings used for calls to updateScanConfig. */ - public UnaryCallSettings.Builder - updateScanConfigSettings() { - return updateScanConfigSettings; - } - - @Override - public ContainerAnalysisV1Beta1StubSettings build() throws IOException { - return new ContainerAnalysisV1Beta1StubSettings(this); - } - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrafeasV1Beta1Stub.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrafeasV1Beta1Stub.java deleted file mode 100644 index a38d9248..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrafeasV1Beta1Stub.java +++ /dev/null @@ -1,142 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1.stub; - -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListNoteOccurrencesPagedResponse; -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListNotesPagedResponse; -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListOccurrencesPagedResponse; - -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.protobuf.Empty; -import io.grafeas.v1beta1.BatchCreateNotesRequest; -import io.grafeas.v1beta1.BatchCreateNotesResponse; -import io.grafeas.v1beta1.BatchCreateOccurrencesRequest; -import io.grafeas.v1beta1.BatchCreateOccurrencesResponse; -import io.grafeas.v1beta1.CreateNoteRequest; -import io.grafeas.v1beta1.CreateOccurrenceRequest; -import io.grafeas.v1beta1.DeleteNoteRequest; -import io.grafeas.v1beta1.DeleteOccurrenceRequest; -import io.grafeas.v1beta1.GetNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceRequest; -import io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesResponse; -import io.grafeas.v1beta1.ListNotesRequest; -import io.grafeas.v1beta1.ListNotesResponse; -import io.grafeas.v1beta1.ListOccurrencesRequest; -import io.grafeas.v1beta1.ListOccurrencesResponse; -import io.grafeas.v1beta1.Note; -import io.grafeas.v1beta1.Occurrence; -import io.grafeas.v1beta1.UpdateNoteRequest; -import io.grafeas.v1beta1.UpdateOccurrenceRequest; -import io.grafeas.v1beta1.VulnerabilityOccurrencesSummary; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * Base stub class for Container Analysis API. - * - *

This class is for advanced usage and reflects the underlying API directly. - */ -@Generated("by gapic-generator") -@BetaApi("A restructuring of stub classes is planned, so this may break in the future") -public abstract class GrafeasV1Beta1Stub implements BackgroundResource { - - public UnaryCallable getOccurrenceCallable() { - throw new UnsupportedOperationException("Not implemented: getOccurrenceCallable()"); - } - - public UnaryCallable - listOccurrencesPagedCallable() { - throw new UnsupportedOperationException("Not implemented: listOccurrencesPagedCallable()"); - } - - public UnaryCallable listOccurrencesCallable() { - throw new UnsupportedOperationException("Not implemented: listOccurrencesCallable()"); - } - - public UnaryCallable deleteOccurrenceCallable() { - throw new UnsupportedOperationException("Not implemented: deleteOccurrenceCallable()"); - } - - public UnaryCallable createOccurrenceCallable() { - throw new UnsupportedOperationException("Not implemented: createOccurrenceCallable()"); - } - - public UnaryCallable - batchCreateOccurrencesCallable() { - throw new UnsupportedOperationException("Not implemented: batchCreateOccurrencesCallable()"); - } - - public UnaryCallable updateOccurrenceCallable() { - throw new UnsupportedOperationException("Not implemented: updateOccurrenceCallable()"); - } - - public UnaryCallable getOccurrenceNoteCallable() { - throw new UnsupportedOperationException("Not implemented: getOccurrenceNoteCallable()"); - } - - public UnaryCallable getNoteCallable() { - throw new UnsupportedOperationException("Not implemented: getNoteCallable()"); - } - - public UnaryCallable listNotesPagedCallable() { - throw new UnsupportedOperationException("Not implemented: listNotesPagedCallable()"); - } - - public UnaryCallable listNotesCallable() { - throw new UnsupportedOperationException("Not implemented: listNotesCallable()"); - } - - public UnaryCallable deleteNoteCallable() { - throw new UnsupportedOperationException("Not implemented: deleteNoteCallable()"); - } - - public UnaryCallable createNoteCallable() { - throw new UnsupportedOperationException("Not implemented: createNoteCallable()"); - } - - public UnaryCallable - batchCreateNotesCallable() { - throw new UnsupportedOperationException("Not implemented: batchCreateNotesCallable()"); - } - - public UnaryCallable updateNoteCallable() { - throw new UnsupportedOperationException("Not implemented: updateNoteCallable()"); - } - - public UnaryCallable - listNoteOccurrencesPagedCallable() { - throw new UnsupportedOperationException("Not implemented: listNoteOccurrencesPagedCallable()"); - } - - public UnaryCallable - listNoteOccurrencesCallable() { - throw new UnsupportedOperationException("Not implemented: listNoteOccurrencesCallable()"); - } - - public UnaryCallable - getVulnerabilityOccurrencesSummaryCallable() { - throw new UnsupportedOperationException( - "Not implemented: getVulnerabilityOccurrencesSummaryCallable()"); - } - - @Override - public abstract void close(); -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrafeasV1Beta1StubSettings.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrafeasV1Beta1StubSettings.java deleted file mode 100644 index c3ffdc99..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrafeasV1Beta1StubSettings.java +++ /dev/null @@ -1,847 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1.stub; - -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListNoteOccurrencesPagedResponse; -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListNotesPagedResponse; -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListOccurrencesPagedResponse; - -import com.google.api.core.ApiFunction; -import com.google.api.core.ApiFuture; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.GaxProperties; -import com.google.api.gax.core.GoogleCredentialsProvider; -import com.google.api.gax.core.InstantiatingExecutorProvider; -import com.google.api.gax.grpc.GaxGrpcProperties; -import com.google.api.gax.grpc.GrpcTransportChannel; -import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; -import com.google.api.gax.retrying.RetrySettings; -import com.google.api.gax.rpc.ApiCallContext; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.PageContext; -import com.google.api.gax.rpc.PagedCallSettings; -import com.google.api.gax.rpc.PagedListDescriptor; -import com.google.api.gax.rpc.PagedListResponseFactory; -import com.google.api.gax.rpc.StatusCode; -import com.google.api.gax.rpc.StubSettings; -import com.google.api.gax.rpc.TransportChannelProvider; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.common.collect.ImmutableList; -import com.google.common.collect.ImmutableMap; -import com.google.common.collect.ImmutableSet; -import com.google.common.collect.Lists; -import com.google.protobuf.Empty; -import io.grafeas.v1beta1.BatchCreateNotesRequest; -import io.grafeas.v1beta1.BatchCreateNotesResponse; -import io.grafeas.v1beta1.BatchCreateOccurrencesRequest; -import io.grafeas.v1beta1.BatchCreateOccurrencesResponse; -import io.grafeas.v1beta1.CreateNoteRequest; -import io.grafeas.v1beta1.CreateOccurrenceRequest; -import io.grafeas.v1beta1.DeleteNoteRequest; -import io.grafeas.v1beta1.DeleteOccurrenceRequest; -import io.grafeas.v1beta1.GetNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceRequest; -import io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesResponse; -import io.grafeas.v1beta1.ListNotesRequest; -import io.grafeas.v1beta1.ListNotesResponse; -import io.grafeas.v1beta1.ListOccurrencesRequest; -import io.grafeas.v1beta1.ListOccurrencesResponse; -import io.grafeas.v1beta1.Note; -import io.grafeas.v1beta1.Occurrence; -import io.grafeas.v1beta1.UpdateNoteRequest; -import io.grafeas.v1beta1.UpdateOccurrenceRequest; -import io.grafeas.v1beta1.VulnerabilityOccurrencesSummary; -import java.io.IOException; -import java.util.List; -import javax.annotation.Generated; -import org.threeten.bp.Duration; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * Settings class to configure an instance of {@link GrafeasV1Beta1Stub}. - * - *

The default instance has everything set to sensible defaults: - * - *

    - *
  • The default service address (containeranalysis.googleapis.com) and default port (443) are - * used. - *
  • Credentials are acquired automatically through Application Default Credentials. - *
  • Retries are configured for idempotent methods but not for non-idempotent methods. - *
- * - *

The builder of this class is recursive, so contained classes are themselves builders. When - * build() is called, the tree of builders is called to create the complete settings object. - * - *

For example, to set the total timeout of getOccurrence to 30 seconds: - * - *

- * 
- * GrafeasV1Beta1StubSettings.Builder grafeasV1Beta1SettingsBuilder =
- *     GrafeasV1Beta1StubSettings.newBuilder();
- * grafeasV1Beta1SettingsBuilder.getOccurrenceSettings().getRetrySettings().toBuilder()
- *     .setTotalTimeout(Duration.ofSeconds(30));
- * GrafeasV1Beta1StubSettings grafeasV1Beta1Settings = grafeasV1Beta1SettingsBuilder.build();
- * 
- * 
- */ -@Generated("by gapic-generator") -@BetaApi -public class GrafeasV1Beta1StubSettings extends StubSettings { - /** The default scopes of the service. */ - private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); - - private final UnaryCallSettings getOccurrenceSettings; - private final PagedCallSettings< - ListOccurrencesRequest, ListOccurrencesResponse, ListOccurrencesPagedResponse> - listOccurrencesSettings; - private final UnaryCallSettings deleteOccurrenceSettings; - private final UnaryCallSettings createOccurrenceSettings; - private final UnaryCallSettings - batchCreateOccurrencesSettings; - private final UnaryCallSettings updateOccurrenceSettings; - private final UnaryCallSettings getOccurrenceNoteSettings; - private final UnaryCallSettings getNoteSettings; - private final PagedCallSettings - listNotesSettings; - private final UnaryCallSettings deleteNoteSettings; - private final UnaryCallSettings createNoteSettings; - private final UnaryCallSettings - batchCreateNotesSettings; - private final UnaryCallSettings updateNoteSettings; - private final PagedCallSettings< - ListNoteOccurrencesRequest, ListNoteOccurrencesResponse, ListNoteOccurrencesPagedResponse> - listNoteOccurrencesSettings; - private final UnaryCallSettings< - GetVulnerabilityOccurrencesSummaryRequest, VulnerabilityOccurrencesSummary> - getVulnerabilityOccurrencesSummarySettings; - - /** Returns the object with the settings used for calls to getOccurrence. */ - public UnaryCallSettings getOccurrenceSettings() { - return getOccurrenceSettings; - } - - /** Returns the object with the settings used for calls to listOccurrences. */ - public PagedCallSettings< - ListOccurrencesRequest, ListOccurrencesResponse, ListOccurrencesPagedResponse> - listOccurrencesSettings() { - return listOccurrencesSettings; - } - - /** Returns the object with the settings used for calls to deleteOccurrence. */ - public UnaryCallSettings deleteOccurrenceSettings() { - return deleteOccurrenceSettings; - } - - /** Returns the object with the settings used for calls to createOccurrence. */ - public UnaryCallSettings createOccurrenceSettings() { - return createOccurrenceSettings; - } - - /** Returns the object with the settings used for calls to batchCreateOccurrences. */ - public UnaryCallSettings - batchCreateOccurrencesSettings() { - return batchCreateOccurrencesSettings; - } - - /** Returns the object with the settings used for calls to updateOccurrence. */ - public UnaryCallSettings updateOccurrenceSettings() { - return updateOccurrenceSettings; - } - - /** Returns the object with the settings used for calls to getOccurrenceNote. */ - public UnaryCallSettings getOccurrenceNoteSettings() { - return getOccurrenceNoteSettings; - } - - /** Returns the object with the settings used for calls to getNote. */ - public UnaryCallSettings getNoteSettings() { - return getNoteSettings; - } - - /** Returns the object with the settings used for calls to listNotes. */ - public PagedCallSettings - listNotesSettings() { - return listNotesSettings; - } - - /** Returns the object with the settings used for calls to deleteNote. */ - public UnaryCallSettings deleteNoteSettings() { - return deleteNoteSettings; - } - - /** Returns the object with the settings used for calls to createNote. */ - public UnaryCallSettings createNoteSettings() { - return createNoteSettings; - } - - /** Returns the object with the settings used for calls to batchCreateNotes. */ - public UnaryCallSettings - batchCreateNotesSettings() { - return batchCreateNotesSettings; - } - - /** Returns the object with the settings used for calls to updateNote. */ - public UnaryCallSettings updateNoteSettings() { - return updateNoteSettings; - } - - /** Returns the object with the settings used for calls to listNoteOccurrences. */ - public PagedCallSettings< - ListNoteOccurrencesRequest, ListNoteOccurrencesResponse, ListNoteOccurrencesPagedResponse> - listNoteOccurrencesSettings() { - return listNoteOccurrencesSettings; - } - - /** Returns the object with the settings used for calls to getVulnerabilityOccurrencesSummary. */ - public UnaryCallSettings< - GetVulnerabilityOccurrencesSummaryRequest, VulnerabilityOccurrencesSummary> - getVulnerabilityOccurrencesSummarySettings() { - return getVulnerabilityOccurrencesSummarySettings; - } - - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - public GrafeasV1Beta1Stub createStub() throws IOException { - if (getTransportChannelProvider() - .getTransportName() - .equals(GrpcTransportChannel.getGrpcTransportName())) { - return GrpcGrafeasV1Beta1Stub.create(this); - } else { - throw new UnsupportedOperationException( - "Transport not supported: " + getTransportChannelProvider().getTransportName()); - } - } - - /** Returns a builder for the default ExecutorProvider for this service. */ - public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { - return InstantiatingExecutorProvider.newBuilder(); - } - - /** Returns the default service endpoint. */ - public static String getDefaultEndpoint() { - return "containeranalysis.googleapis.com:443"; - } - - /** Returns the default service scopes. */ - public static List getDefaultServiceScopes() { - return DEFAULT_SERVICE_SCOPES; - } - - /** Returns a builder for the default credentials for this service. */ - public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { - return GoogleCredentialsProvider.newBuilder().setScopesToApply(DEFAULT_SERVICE_SCOPES); - } - - /** Returns a builder for the default ChannelProvider for this service. */ - public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { - return InstantiatingGrpcChannelProvider.newBuilder() - .setMaxInboundMessageSize(Integer.MAX_VALUE); - } - - public static TransportChannelProvider defaultTransportChannelProvider() { - return defaultGrpcTransportProviderBuilder().build(); - } - - @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") - public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { - return ApiClientHeaderProvider.newBuilder() - .setGeneratedLibToken( - "gapic", GaxProperties.getLibraryVersion(GrafeasV1Beta1StubSettings.class)) - .setTransportToken( - GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder() { - return Builder.createDefault(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder(ClientContext clientContext) { - return new Builder(clientContext); - } - - /** Returns a builder containing all the values of this settings class. */ - public Builder toBuilder() { - return new Builder(this); - } - - protected GrafeasV1Beta1StubSettings(Builder settingsBuilder) throws IOException { - super(settingsBuilder); - - getOccurrenceSettings = settingsBuilder.getOccurrenceSettings().build(); - listOccurrencesSettings = settingsBuilder.listOccurrencesSettings().build(); - deleteOccurrenceSettings = settingsBuilder.deleteOccurrenceSettings().build(); - createOccurrenceSettings = settingsBuilder.createOccurrenceSettings().build(); - batchCreateOccurrencesSettings = settingsBuilder.batchCreateOccurrencesSettings().build(); - updateOccurrenceSettings = settingsBuilder.updateOccurrenceSettings().build(); - getOccurrenceNoteSettings = settingsBuilder.getOccurrenceNoteSettings().build(); - getNoteSettings = settingsBuilder.getNoteSettings().build(); - listNotesSettings = settingsBuilder.listNotesSettings().build(); - deleteNoteSettings = settingsBuilder.deleteNoteSettings().build(); - createNoteSettings = settingsBuilder.createNoteSettings().build(); - batchCreateNotesSettings = settingsBuilder.batchCreateNotesSettings().build(); - updateNoteSettings = settingsBuilder.updateNoteSettings().build(); - listNoteOccurrencesSettings = settingsBuilder.listNoteOccurrencesSettings().build(); - getVulnerabilityOccurrencesSummarySettings = - settingsBuilder.getVulnerabilityOccurrencesSummarySettings().build(); - } - - private static final PagedListDescriptor< - ListOccurrencesRequest, ListOccurrencesResponse, Occurrence> - LIST_OCCURRENCES_PAGE_STR_DESC = - new PagedListDescriptor() { - @Override - public String emptyToken() { - return ""; - } - - @Override - public ListOccurrencesRequest injectToken( - ListOccurrencesRequest payload, String token) { - return ListOccurrencesRequest.newBuilder(payload).setPageToken(token).build(); - } - - @Override - public ListOccurrencesRequest injectPageSize( - ListOccurrencesRequest payload, int pageSize) { - return ListOccurrencesRequest.newBuilder(payload).setPageSize(pageSize).build(); - } - - @Override - public Integer extractPageSize(ListOccurrencesRequest payload) { - return payload.getPageSize(); - } - - @Override - public String extractNextToken(ListOccurrencesResponse payload) { - return payload.getNextPageToken(); - } - - @Override - public Iterable extractResources(ListOccurrencesResponse payload) { - return payload.getOccurrencesList() != null - ? payload.getOccurrencesList() - : ImmutableList.of(); - } - }; - - private static final PagedListDescriptor - LIST_NOTES_PAGE_STR_DESC = - new PagedListDescriptor() { - @Override - public String emptyToken() { - return ""; - } - - @Override - public ListNotesRequest injectToken(ListNotesRequest payload, String token) { - return ListNotesRequest.newBuilder(payload).setPageToken(token).build(); - } - - @Override - public ListNotesRequest injectPageSize(ListNotesRequest payload, int pageSize) { - return ListNotesRequest.newBuilder(payload).setPageSize(pageSize).build(); - } - - @Override - public Integer extractPageSize(ListNotesRequest payload) { - return payload.getPageSize(); - } - - @Override - public String extractNextToken(ListNotesResponse payload) { - return payload.getNextPageToken(); - } - - @Override - public Iterable extractResources(ListNotesResponse payload) { - return payload.getNotesList() != null - ? payload.getNotesList() - : ImmutableList.of(); - } - }; - - private static final PagedListDescriptor< - ListNoteOccurrencesRequest, ListNoteOccurrencesResponse, Occurrence> - LIST_NOTE_OCCURRENCES_PAGE_STR_DESC = - new PagedListDescriptor< - ListNoteOccurrencesRequest, ListNoteOccurrencesResponse, Occurrence>() { - @Override - public String emptyToken() { - return ""; - } - - @Override - public ListNoteOccurrencesRequest injectToken( - ListNoteOccurrencesRequest payload, String token) { - return ListNoteOccurrencesRequest.newBuilder(payload).setPageToken(token).build(); - } - - @Override - public ListNoteOccurrencesRequest injectPageSize( - ListNoteOccurrencesRequest payload, int pageSize) { - return ListNoteOccurrencesRequest.newBuilder(payload).setPageSize(pageSize).build(); - } - - @Override - public Integer extractPageSize(ListNoteOccurrencesRequest payload) { - return payload.getPageSize(); - } - - @Override - public String extractNextToken(ListNoteOccurrencesResponse payload) { - return payload.getNextPageToken(); - } - - @Override - public Iterable extractResources(ListNoteOccurrencesResponse payload) { - return payload.getOccurrencesList() != null - ? payload.getOccurrencesList() - : ImmutableList.of(); - } - }; - - private static final PagedListResponseFactory< - ListOccurrencesRequest, ListOccurrencesResponse, ListOccurrencesPagedResponse> - LIST_OCCURRENCES_PAGE_STR_FACT = - new PagedListResponseFactory< - ListOccurrencesRequest, ListOccurrencesResponse, ListOccurrencesPagedResponse>() { - @Override - public ApiFuture getFuturePagedResponse( - UnaryCallable callable, - ListOccurrencesRequest request, - ApiCallContext context, - ApiFuture futureResponse) { - PageContext pageContext = - PageContext.create(callable, LIST_OCCURRENCES_PAGE_STR_DESC, request, context); - return ListOccurrencesPagedResponse.createAsync(pageContext, futureResponse); - } - }; - - private static final PagedListResponseFactory< - ListNotesRequest, ListNotesResponse, ListNotesPagedResponse> - LIST_NOTES_PAGE_STR_FACT = - new PagedListResponseFactory< - ListNotesRequest, ListNotesResponse, ListNotesPagedResponse>() { - @Override - public ApiFuture getFuturePagedResponse( - UnaryCallable callable, - ListNotesRequest request, - ApiCallContext context, - ApiFuture futureResponse) { - PageContext pageContext = - PageContext.create(callable, LIST_NOTES_PAGE_STR_DESC, request, context); - return ListNotesPagedResponse.createAsync(pageContext, futureResponse); - } - }; - - private static final PagedListResponseFactory< - ListNoteOccurrencesRequest, ListNoteOccurrencesResponse, ListNoteOccurrencesPagedResponse> - LIST_NOTE_OCCURRENCES_PAGE_STR_FACT = - new PagedListResponseFactory< - ListNoteOccurrencesRequest, - ListNoteOccurrencesResponse, - ListNoteOccurrencesPagedResponse>() { - @Override - public ApiFuture getFuturePagedResponse( - UnaryCallable callable, - ListNoteOccurrencesRequest request, - ApiCallContext context, - ApiFuture futureResponse) { - PageContext - pageContext = - PageContext.create( - callable, LIST_NOTE_OCCURRENCES_PAGE_STR_DESC, request, context); - return ListNoteOccurrencesPagedResponse.createAsync(pageContext, futureResponse); - } - }; - - /** Builder for GrafeasV1Beta1StubSettings. */ - public static class Builder extends StubSettings.Builder { - private final ImmutableList> unaryMethodSettingsBuilders; - - private final UnaryCallSettings.Builder getOccurrenceSettings; - private final PagedCallSettings.Builder< - ListOccurrencesRequest, ListOccurrencesResponse, ListOccurrencesPagedResponse> - listOccurrencesSettings; - private final UnaryCallSettings.Builder - deleteOccurrenceSettings; - private final UnaryCallSettings.Builder - createOccurrenceSettings; - private final UnaryCallSettings.Builder< - BatchCreateOccurrencesRequest, BatchCreateOccurrencesResponse> - batchCreateOccurrencesSettings; - private final UnaryCallSettings.Builder - updateOccurrenceSettings; - private final UnaryCallSettings.Builder - getOccurrenceNoteSettings; - private final UnaryCallSettings.Builder getNoteSettings; - private final PagedCallSettings.Builder< - ListNotesRequest, ListNotesResponse, ListNotesPagedResponse> - listNotesSettings; - private final UnaryCallSettings.Builder deleteNoteSettings; - private final UnaryCallSettings.Builder createNoteSettings; - private final UnaryCallSettings.Builder - batchCreateNotesSettings; - private final UnaryCallSettings.Builder updateNoteSettings; - private final PagedCallSettings.Builder< - ListNoteOccurrencesRequest, - ListNoteOccurrencesResponse, - ListNoteOccurrencesPagedResponse> - listNoteOccurrencesSettings; - private final UnaryCallSettings.Builder< - GetVulnerabilityOccurrencesSummaryRequest, VulnerabilityOccurrencesSummary> - getVulnerabilityOccurrencesSummarySettings; - - private static final ImmutableMap> - RETRYABLE_CODE_DEFINITIONS; - - static { - ImmutableMap.Builder> definitions = - ImmutableMap.builder(); - definitions.put( - "idempotent", - ImmutableSet.copyOf( - Lists.newArrayList( - StatusCode.Code.DEADLINE_EXCEEDED, StatusCode.Code.UNAVAILABLE))); - definitions.put("non_idempotent", ImmutableSet.copyOf(Lists.newArrayList())); - RETRYABLE_CODE_DEFINITIONS = definitions.build(); - } - - private static final ImmutableMap RETRY_PARAM_DEFINITIONS; - - static { - ImmutableMap.Builder definitions = ImmutableMap.builder(); - RetrySettings settings = null; - settings = - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(100L)) - .setRetryDelayMultiplier(1.3) - .setMaxRetryDelay(Duration.ofMillis(60000L)) - .setInitialRpcTimeout(Duration.ofMillis(20000L)) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ofMillis(20000L)) - .setTotalTimeout(Duration.ofMillis(600000L)) - .build(); - definitions.put("default", settings); - RETRY_PARAM_DEFINITIONS = definitions.build(); - } - - protected Builder() { - this((ClientContext) null); - } - - protected Builder(ClientContext clientContext) { - super(clientContext); - - getOccurrenceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - listOccurrencesSettings = PagedCallSettings.newBuilder(LIST_OCCURRENCES_PAGE_STR_FACT); - - deleteOccurrenceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - createOccurrenceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - batchCreateOccurrencesSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - updateOccurrenceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - getOccurrenceNoteSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - getNoteSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - listNotesSettings = PagedCallSettings.newBuilder(LIST_NOTES_PAGE_STR_FACT); - - deleteNoteSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - createNoteSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - batchCreateNotesSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - updateNoteSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - listNoteOccurrencesSettings = - PagedCallSettings.newBuilder(LIST_NOTE_OCCURRENCES_PAGE_STR_FACT); - - getVulnerabilityOccurrencesSummarySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - unaryMethodSettingsBuilders = - ImmutableList.>of( - getOccurrenceSettings, - listOccurrencesSettings, - deleteOccurrenceSettings, - createOccurrenceSettings, - batchCreateOccurrencesSettings, - updateOccurrenceSettings, - getOccurrenceNoteSettings, - getNoteSettings, - listNotesSettings, - deleteNoteSettings, - createNoteSettings, - batchCreateNotesSettings, - updateNoteSettings, - listNoteOccurrencesSettings, - getVulnerabilityOccurrencesSummarySettings); - - initDefaults(this); - } - - private static Builder createDefault() { - Builder builder = new Builder((ClientContext) null); - builder.setTransportChannelProvider(defaultTransportChannelProvider()); - builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); - builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); - builder.setEndpoint(getDefaultEndpoint()); - return initDefaults(builder); - } - - private static Builder initDefaults(Builder builder) { - - builder - .getOccurrenceSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .listOccurrencesSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .deleteOccurrenceSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .createOccurrenceSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .batchCreateOccurrencesSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .updateOccurrenceSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .getOccurrenceNoteSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .getNoteSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .listNotesSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .deleteNoteSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .createNoteSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .batchCreateNotesSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .updateNoteSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .listNoteOccurrencesSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .getVulnerabilityOccurrencesSummarySettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - return builder; - } - - protected Builder(GrafeasV1Beta1StubSettings settings) { - super(settings); - - getOccurrenceSettings = settings.getOccurrenceSettings.toBuilder(); - listOccurrencesSettings = settings.listOccurrencesSettings.toBuilder(); - deleteOccurrenceSettings = settings.deleteOccurrenceSettings.toBuilder(); - createOccurrenceSettings = settings.createOccurrenceSettings.toBuilder(); - batchCreateOccurrencesSettings = settings.batchCreateOccurrencesSettings.toBuilder(); - updateOccurrenceSettings = settings.updateOccurrenceSettings.toBuilder(); - getOccurrenceNoteSettings = settings.getOccurrenceNoteSettings.toBuilder(); - getNoteSettings = settings.getNoteSettings.toBuilder(); - listNotesSettings = settings.listNotesSettings.toBuilder(); - deleteNoteSettings = settings.deleteNoteSettings.toBuilder(); - createNoteSettings = settings.createNoteSettings.toBuilder(); - batchCreateNotesSettings = settings.batchCreateNotesSettings.toBuilder(); - updateNoteSettings = settings.updateNoteSettings.toBuilder(); - listNoteOccurrencesSettings = settings.listNoteOccurrencesSettings.toBuilder(); - getVulnerabilityOccurrencesSummarySettings = - settings.getVulnerabilityOccurrencesSummarySettings.toBuilder(); - - unaryMethodSettingsBuilders = - ImmutableList.>of( - getOccurrenceSettings, - listOccurrencesSettings, - deleteOccurrenceSettings, - createOccurrenceSettings, - batchCreateOccurrencesSettings, - updateOccurrenceSettings, - getOccurrenceNoteSettings, - getNoteSettings, - listNotesSettings, - deleteNoteSettings, - createNoteSettings, - batchCreateNotesSettings, - updateNoteSettings, - listNoteOccurrencesSettings, - getVulnerabilityOccurrencesSummarySettings); - } - - // NEXT_MAJOR_VER: remove 'throws Exception' - /** - * Applies the given settings updater function to all of the unary API methods in this service. - * - *

Note: This method does not support applying settings to streaming methods. - */ - public Builder applyToAllUnaryMethods( - ApiFunction, Void> settingsUpdater) throws Exception { - super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); - return this; - } - - public ImmutableList> unaryMethodSettingsBuilders() { - return unaryMethodSettingsBuilders; - } - - /** Returns the builder for the settings used for calls to getOccurrence. */ - public UnaryCallSettings.Builder getOccurrenceSettings() { - return getOccurrenceSettings; - } - - /** Returns the builder for the settings used for calls to listOccurrences. */ - public PagedCallSettings.Builder< - ListOccurrencesRequest, ListOccurrencesResponse, ListOccurrencesPagedResponse> - listOccurrencesSettings() { - return listOccurrencesSettings; - } - - /** Returns the builder for the settings used for calls to deleteOccurrence. */ - public UnaryCallSettings.Builder deleteOccurrenceSettings() { - return deleteOccurrenceSettings; - } - - /** Returns the builder for the settings used for calls to createOccurrence. */ - public UnaryCallSettings.Builder - createOccurrenceSettings() { - return createOccurrenceSettings; - } - - /** Returns the builder for the settings used for calls to batchCreateOccurrences. */ - public UnaryCallSettings.Builder - batchCreateOccurrencesSettings() { - return batchCreateOccurrencesSettings; - } - - /** Returns the builder for the settings used for calls to updateOccurrence. */ - public UnaryCallSettings.Builder - updateOccurrenceSettings() { - return updateOccurrenceSettings; - } - - /** Returns the builder for the settings used for calls to getOccurrenceNote. */ - public UnaryCallSettings.Builder getOccurrenceNoteSettings() { - return getOccurrenceNoteSettings; - } - - /** Returns the builder for the settings used for calls to getNote. */ - public UnaryCallSettings.Builder getNoteSettings() { - return getNoteSettings; - } - - /** Returns the builder for the settings used for calls to listNotes. */ - public PagedCallSettings.Builder - listNotesSettings() { - return listNotesSettings; - } - - /** Returns the builder for the settings used for calls to deleteNote. */ - public UnaryCallSettings.Builder deleteNoteSettings() { - return deleteNoteSettings; - } - - /** Returns the builder for the settings used for calls to createNote. */ - public UnaryCallSettings.Builder createNoteSettings() { - return createNoteSettings; - } - - /** Returns the builder for the settings used for calls to batchCreateNotes. */ - public UnaryCallSettings.Builder - batchCreateNotesSettings() { - return batchCreateNotesSettings; - } - - /** Returns the builder for the settings used for calls to updateNote. */ - public UnaryCallSettings.Builder updateNoteSettings() { - return updateNoteSettings; - } - - /** Returns the builder for the settings used for calls to listNoteOccurrences. */ - public PagedCallSettings.Builder< - ListNoteOccurrencesRequest, - ListNoteOccurrencesResponse, - ListNoteOccurrencesPagedResponse> - listNoteOccurrencesSettings() { - return listNoteOccurrencesSettings; - } - - /** - * Returns the builder for the settings used for calls to getVulnerabilityOccurrencesSummary. - */ - public UnaryCallSettings.Builder< - GetVulnerabilityOccurrencesSummaryRequest, VulnerabilityOccurrencesSummary> - getVulnerabilityOccurrencesSummarySettings() { - return getVulnerabilityOccurrencesSummarySettings; - } - - @Override - public GrafeasV1Beta1StubSettings build() throws IOException { - return new GrafeasV1Beta1StubSettings(this); - } - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcContainerAnalysisV1Beta1CallableFactory.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcContainerAnalysisV1Beta1CallableFactory.java deleted file mode 100644 index 9f6bd604..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcContainerAnalysisV1Beta1CallableFactory.java +++ /dev/null @@ -1,115 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1.stub; - -import com.google.api.core.BetaApi; -import com.google.api.gax.grpc.GrpcCallSettings; -import com.google.api.gax.grpc.GrpcCallableFactory; -import com.google.api.gax.grpc.GrpcStubCallableFactory; -import com.google.api.gax.rpc.BatchingCallSettings; -import com.google.api.gax.rpc.BidiStreamingCallable; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.ClientStreamingCallable; -import com.google.api.gax.rpc.OperationCallSettings; -import com.google.api.gax.rpc.OperationCallable; -import com.google.api.gax.rpc.PagedCallSettings; -import com.google.api.gax.rpc.ServerStreamingCallSettings; -import com.google.api.gax.rpc.ServerStreamingCallable; -import com.google.api.gax.rpc.StreamingCallSettings; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.longrunning.stub.OperationsStub; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * gRPC callable factory implementation for Container Analysis API. - * - *

This class is for advanced usage. - */ -@Generated("by gapic-generator") -@BetaApi("The surface for use by generated code is not stable yet and may change in the future.") -public class GrpcContainerAnalysisV1Beta1CallableFactory implements GrpcStubCallableFactory { - @Override - public UnaryCallable createUnaryCallable( - GrpcCallSettings grpcCallSettings, - UnaryCallSettings callSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createUnaryCallable(grpcCallSettings, callSettings, clientContext); - } - - @Override - public - UnaryCallable createPagedCallable( - GrpcCallSettings grpcCallSettings, - PagedCallSettings pagedCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createPagedCallable( - grpcCallSettings, pagedCallSettings, clientContext); - } - - @Override - public UnaryCallable createBatchingCallable( - GrpcCallSettings grpcCallSettings, - BatchingCallSettings batchingCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createBatchingCallable( - grpcCallSettings, batchingCallSettings, clientContext); - } - - @BetaApi( - "The surface for long-running operations is not stable yet and may change in the future.") - @Override - public - OperationCallable createOperationCallable( - GrpcCallSettings grpcCallSettings, - OperationCallSettings operationCallSettings, - ClientContext clientContext, - OperationsStub operationsStub) { - return GrpcCallableFactory.createOperationCallable( - grpcCallSettings, operationCallSettings, clientContext, operationsStub); - } - - @Override - public - BidiStreamingCallable createBidiStreamingCallable( - GrpcCallSettings grpcCallSettings, - StreamingCallSettings streamingCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createBidiStreamingCallable( - grpcCallSettings, streamingCallSettings, clientContext); - } - - @Override - public - ServerStreamingCallable createServerStreamingCallable( - GrpcCallSettings grpcCallSettings, - ServerStreamingCallSettings streamingCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createServerStreamingCallable( - grpcCallSettings, streamingCallSettings, clientContext); - } - - @Override - public - ClientStreamingCallable createClientStreamingCallable( - GrpcCallSettings grpcCallSettings, - StreamingCallSettings streamingCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createClientStreamingCallable( - grpcCallSettings, streamingCallSettings, clientContext); - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcContainerAnalysisV1Beta1Stub.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcContainerAnalysisV1Beta1Stub.java deleted file mode 100644 index 4c2a4319..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcContainerAnalysisV1Beta1Stub.java +++ /dev/null @@ -1,337 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1.stub; - -import static com.google.cloud.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1Client.ListScanConfigsPagedResponse; - -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.core.BackgroundResourceAggregation; -import com.google.api.gax.grpc.GrpcCallSettings; -import com.google.api.gax.grpc.GrpcStubCallableFactory; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.RequestParamsExtractor; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.common.collect.ImmutableMap; -import com.google.containeranalysis.v1beta1.GetScanConfigRequest; -import com.google.containeranalysis.v1beta1.ListScanConfigsRequest; -import com.google.containeranalysis.v1beta1.ListScanConfigsResponse; -import com.google.containeranalysis.v1beta1.ScanConfig; -import com.google.containeranalysis.v1beta1.UpdateScanConfigRequest; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import io.grpc.MethodDescriptor; -import io.grpc.protobuf.ProtoUtils; -import java.io.IOException; -import java.util.Map; -import java.util.concurrent.TimeUnit; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * gRPC stub implementation for Container Analysis API. - * - *

This class is for advanced usage and reflects the underlying API directly. - */ -@Generated("by gapic-generator") -@BetaApi("A restructuring of stub classes is planned, so this may break in the future") -public class GrpcContainerAnalysisV1Beta1Stub extends ContainerAnalysisV1Beta1Stub { - - private static final MethodDescriptor setIamPolicyMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1/SetIamPolicy") - .setRequestMarshaller(ProtoUtils.marshaller(SetIamPolicyRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Policy.getDefaultInstance())) - .build(); - private static final MethodDescriptor getIamPolicyMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1/GetIamPolicy") - .setRequestMarshaller(ProtoUtils.marshaller(GetIamPolicyRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Policy.getDefaultInstance())) - .build(); - private static final MethodDescriptor - testIamPermissionsMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1/TestIamPermissions") - .setRequestMarshaller( - ProtoUtils.marshaller(TestIamPermissionsRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(TestIamPermissionsResponse.getDefaultInstance())) - .build(); - private static final MethodDescriptor - getScanConfigMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1/GetScanConfig") - .setRequestMarshaller( - ProtoUtils.marshaller(GetScanConfigRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(ScanConfig.getDefaultInstance())) - .build(); - private static final MethodDescriptor - listScanConfigsMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1/ListScanConfigs") - .setRequestMarshaller( - ProtoUtils.marshaller(ListScanConfigsRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(ListScanConfigsResponse.getDefaultInstance())) - .build(); - private static final MethodDescriptor - updateScanConfigMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1/UpdateScanConfig") - .setRequestMarshaller( - ProtoUtils.marshaller(UpdateScanConfigRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(ScanConfig.getDefaultInstance())) - .build(); - - private final BackgroundResource backgroundResources; - - private final UnaryCallable setIamPolicyCallable; - private final UnaryCallable getIamPolicyCallable; - private final UnaryCallable - testIamPermissionsCallable; - private final UnaryCallable getScanConfigCallable; - private final UnaryCallable - listScanConfigsCallable; - private final UnaryCallable - listScanConfigsPagedCallable; - private final UnaryCallable updateScanConfigCallable; - - private final GrpcStubCallableFactory callableFactory; - - public static final GrpcContainerAnalysisV1Beta1Stub create( - ContainerAnalysisV1Beta1StubSettings settings) throws IOException { - return new GrpcContainerAnalysisV1Beta1Stub(settings, ClientContext.create(settings)); - } - - public static final GrpcContainerAnalysisV1Beta1Stub create(ClientContext clientContext) - throws IOException { - return new GrpcContainerAnalysisV1Beta1Stub( - ContainerAnalysisV1Beta1StubSettings.newBuilder().build(), clientContext); - } - - public static final GrpcContainerAnalysisV1Beta1Stub create( - ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { - return new GrpcContainerAnalysisV1Beta1Stub( - ContainerAnalysisV1Beta1StubSettings.newBuilder().build(), clientContext, callableFactory); - } - - /** - * Constructs an instance of GrpcContainerAnalysisV1Beta1Stub, using the given settings. This is - * protected so that it is easy to make a subclass, but otherwise, the static factory methods - * should be preferred. - */ - protected GrpcContainerAnalysisV1Beta1Stub( - ContainerAnalysisV1Beta1StubSettings settings, ClientContext clientContext) - throws IOException { - this(settings, clientContext, new GrpcContainerAnalysisV1Beta1CallableFactory()); - } - - /** - * Constructs an instance of GrpcContainerAnalysisV1Beta1Stub, using the given settings. This is - * protected so that it is easy to make a subclass, but otherwise, the static factory methods - * should be preferred. - */ - protected GrpcContainerAnalysisV1Beta1Stub( - ContainerAnalysisV1Beta1StubSettings settings, - ClientContext clientContext, - GrpcStubCallableFactory callableFactory) - throws IOException { - this.callableFactory = callableFactory; - - GrpcCallSettings setIamPolicyTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(setIamPolicyMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(SetIamPolicyRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("resource", String.valueOf(request.getResource())); - return params.build(); - } - }) - .build(); - GrpcCallSettings getIamPolicyTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(getIamPolicyMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(GetIamPolicyRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("resource", String.valueOf(request.getResource())); - return params.build(); - } - }) - .build(); - GrpcCallSettings - testIamPermissionsTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(testIamPermissionsMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(TestIamPermissionsRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("resource", String.valueOf(request.getResource())); - return params.build(); - } - }) - .build(); - GrpcCallSettings getScanConfigTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(getScanConfigMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(GetScanConfigRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - } - }) - .build(); - GrpcCallSettings - listScanConfigsTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(listScanConfigsMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(ListScanConfigsRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - return params.build(); - } - }) - .build(); - GrpcCallSettings updateScanConfigTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(updateScanConfigMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(UpdateScanConfigRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - } - }) - .build(); - - this.setIamPolicyCallable = - callableFactory.createUnaryCallable( - setIamPolicyTransportSettings, settings.setIamPolicySettings(), clientContext); - this.getIamPolicyCallable = - callableFactory.createUnaryCallable( - getIamPolicyTransportSettings, settings.getIamPolicySettings(), clientContext); - this.testIamPermissionsCallable = - callableFactory.createUnaryCallable( - testIamPermissionsTransportSettings, - settings.testIamPermissionsSettings(), - clientContext); - this.getScanConfigCallable = - callableFactory.createUnaryCallable( - getScanConfigTransportSettings, settings.getScanConfigSettings(), clientContext); - this.listScanConfigsCallable = - callableFactory.createUnaryCallable( - listScanConfigsTransportSettings, settings.listScanConfigsSettings(), clientContext); - this.listScanConfigsPagedCallable = - callableFactory.createPagedCallable( - listScanConfigsTransportSettings, settings.listScanConfigsSettings(), clientContext); - this.updateScanConfigCallable = - callableFactory.createUnaryCallable( - updateScanConfigTransportSettings, settings.updateScanConfigSettings(), clientContext); - - backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); - } - - public UnaryCallable setIamPolicyCallable() { - return setIamPolicyCallable; - } - - public UnaryCallable getIamPolicyCallable() { - return getIamPolicyCallable; - } - - public UnaryCallable - testIamPermissionsCallable() { - return testIamPermissionsCallable; - } - - public UnaryCallable getScanConfigCallable() { - return getScanConfigCallable; - } - - public UnaryCallable - listScanConfigsPagedCallable() { - return listScanConfigsPagedCallable; - } - - public UnaryCallable listScanConfigsCallable() { - return listScanConfigsCallable; - } - - public UnaryCallable updateScanConfigCallable() { - return updateScanConfigCallable; - } - - @Override - public final void close() { - shutdown(); - } - - @Override - public void shutdown() { - backgroundResources.shutdown(); - } - - @Override - public boolean isShutdown() { - return backgroundResources.isShutdown(); - } - - @Override - public boolean isTerminated() { - return backgroundResources.isTerminated(); - } - - @Override - public void shutdownNow() { - backgroundResources.shutdownNow(); - } - - @Override - public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { - return backgroundResources.awaitTermination(duration, unit); - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcGrafeasV1Beta1CallableFactory.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcGrafeasV1Beta1CallableFactory.java deleted file mode 100644 index f42094a4..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcGrafeasV1Beta1CallableFactory.java +++ /dev/null @@ -1,115 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1.stub; - -import com.google.api.core.BetaApi; -import com.google.api.gax.grpc.GrpcCallSettings; -import com.google.api.gax.grpc.GrpcCallableFactory; -import com.google.api.gax.grpc.GrpcStubCallableFactory; -import com.google.api.gax.rpc.BatchingCallSettings; -import com.google.api.gax.rpc.BidiStreamingCallable; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.ClientStreamingCallable; -import com.google.api.gax.rpc.OperationCallSettings; -import com.google.api.gax.rpc.OperationCallable; -import com.google.api.gax.rpc.PagedCallSettings; -import com.google.api.gax.rpc.ServerStreamingCallSettings; -import com.google.api.gax.rpc.ServerStreamingCallable; -import com.google.api.gax.rpc.StreamingCallSettings; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.longrunning.stub.OperationsStub; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * gRPC callable factory implementation for Container Analysis API. - * - *

This class is for advanced usage. - */ -@Generated("by gapic-generator") -@BetaApi("The surface for use by generated code is not stable yet and may change in the future.") -public class GrpcGrafeasV1Beta1CallableFactory implements GrpcStubCallableFactory { - @Override - public UnaryCallable createUnaryCallable( - GrpcCallSettings grpcCallSettings, - UnaryCallSettings callSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createUnaryCallable(grpcCallSettings, callSettings, clientContext); - } - - @Override - public - UnaryCallable createPagedCallable( - GrpcCallSettings grpcCallSettings, - PagedCallSettings pagedCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createPagedCallable( - grpcCallSettings, pagedCallSettings, clientContext); - } - - @Override - public UnaryCallable createBatchingCallable( - GrpcCallSettings grpcCallSettings, - BatchingCallSettings batchingCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createBatchingCallable( - grpcCallSettings, batchingCallSettings, clientContext); - } - - @BetaApi( - "The surface for long-running operations is not stable yet and may change in the future.") - @Override - public - OperationCallable createOperationCallable( - GrpcCallSettings grpcCallSettings, - OperationCallSettings operationCallSettings, - ClientContext clientContext, - OperationsStub operationsStub) { - return GrpcCallableFactory.createOperationCallable( - grpcCallSettings, operationCallSettings, clientContext, operationsStub); - } - - @Override - public - BidiStreamingCallable createBidiStreamingCallable( - GrpcCallSettings grpcCallSettings, - StreamingCallSettings streamingCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createBidiStreamingCallable( - grpcCallSettings, streamingCallSettings, clientContext); - } - - @Override - public - ServerStreamingCallable createServerStreamingCallable( - GrpcCallSettings grpcCallSettings, - ServerStreamingCallSettings streamingCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createServerStreamingCallable( - grpcCallSettings, streamingCallSettings, clientContext); - } - - @Override - public - ClientStreamingCallable createClientStreamingCallable( - GrpcCallSettings grpcCallSettings, - StreamingCallSettings streamingCallSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createClientStreamingCallable( - grpcCallSettings, streamingCallSettings, clientContext); - } -} diff --git a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcGrafeasV1Beta1Stub.java b/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcGrafeasV1Beta1Stub.java deleted file mode 100644 index f03a55b1..00000000 --- a/google-cloud-containeranalysis/src/main/java/com/google/cloud/devtools/containeranalysis/v1beta1/stub/GrpcGrafeasV1Beta1Stub.java +++ /dev/null @@ -1,661 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1.stub; - -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListNoteOccurrencesPagedResponse; -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListNotesPagedResponse; -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListOccurrencesPagedResponse; - -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.core.BackgroundResourceAggregation; -import com.google.api.gax.grpc.GrpcCallSettings; -import com.google.api.gax.grpc.GrpcStubCallableFactory; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.RequestParamsExtractor; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.common.collect.ImmutableMap; -import com.google.protobuf.Empty; -import io.grafeas.v1beta1.BatchCreateNotesRequest; -import io.grafeas.v1beta1.BatchCreateNotesResponse; -import io.grafeas.v1beta1.BatchCreateOccurrencesRequest; -import io.grafeas.v1beta1.BatchCreateOccurrencesResponse; -import io.grafeas.v1beta1.CreateNoteRequest; -import io.grafeas.v1beta1.CreateOccurrenceRequest; -import io.grafeas.v1beta1.DeleteNoteRequest; -import io.grafeas.v1beta1.DeleteOccurrenceRequest; -import io.grafeas.v1beta1.GetNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceRequest; -import io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesResponse; -import io.grafeas.v1beta1.ListNotesRequest; -import io.grafeas.v1beta1.ListNotesResponse; -import io.grafeas.v1beta1.ListOccurrencesRequest; -import io.grafeas.v1beta1.ListOccurrencesResponse; -import io.grafeas.v1beta1.Note; -import io.grafeas.v1beta1.Occurrence; -import io.grafeas.v1beta1.UpdateNoteRequest; -import io.grafeas.v1beta1.UpdateOccurrenceRequest; -import io.grafeas.v1beta1.VulnerabilityOccurrencesSummary; -import io.grpc.MethodDescriptor; -import io.grpc.protobuf.ProtoUtils; -import java.io.IOException; -import java.util.Map; -import java.util.concurrent.TimeUnit; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * gRPC stub implementation for Container Analysis API. - * - *

This class is for advanced usage and reflects the underlying API directly. - */ -@Generated("by gapic-generator") -@BetaApi("A restructuring of stub classes is planned, so this may break in the future") -public class GrpcGrafeasV1Beta1Stub extends GrafeasV1Beta1Stub { - - private static final MethodDescriptor - getOccurrenceMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/GetOccurrence") - .setRequestMarshaller( - ProtoUtils.marshaller(GetOccurrenceRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Occurrence.getDefaultInstance())) - .build(); - private static final MethodDescriptor - listOccurrencesMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/ListOccurrences") - .setRequestMarshaller( - ProtoUtils.marshaller(ListOccurrencesRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(ListOccurrencesResponse.getDefaultInstance())) - .build(); - private static final MethodDescriptor - deleteOccurrenceMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/DeleteOccurrence") - .setRequestMarshaller( - ProtoUtils.marshaller(DeleteOccurrenceRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Empty.getDefaultInstance())) - .build(); - private static final MethodDescriptor - createOccurrenceMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/CreateOccurrence") - .setRequestMarshaller( - ProtoUtils.marshaller(CreateOccurrenceRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Occurrence.getDefaultInstance())) - .build(); - private static final MethodDescriptor< - BatchCreateOccurrencesRequest, BatchCreateOccurrencesResponse> - batchCreateOccurrencesMethodDescriptor = - MethodDescriptor - .newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/BatchCreateOccurrences") - .setRequestMarshaller( - ProtoUtils.marshaller(BatchCreateOccurrencesRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(BatchCreateOccurrencesResponse.getDefaultInstance())) - .build(); - private static final MethodDescriptor - updateOccurrenceMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/UpdateOccurrence") - .setRequestMarshaller( - ProtoUtils.marshaller(UpdateOccurrenceRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Occurrence.getDefaultInstance())) - .build(); - private static final MethodDescriptor - getOccurrenceNoteMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/GetOccurrenceNote") - .setRequestMarshaller( - ProtoUtils.marshaller(GetOccurrenceNoteRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Note.getDefaultInstance())) - .build(); - private static final MethodDescriptor getNoteMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/GetNote") - .setRequestMarshaller(ProtoUtils.marshaller(GetNoteRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Note.getDefaultInstance())) - .build(); - private static final MethodDescriptor - listNotesMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/ListNotes") - .setRequestMarshaller(ProtoUtils.marshaller(ListNotesRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(ListNotesResponse.getDefaultInstance())) - .build(); - private static final MethodDescriptor deleteNoteMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/DeleteNote") - .setRequestMarshaller(ProtoUtils.marshaller(DeleteNoteRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Empty.getDefaultInstance())) - .build(); - private static final MethodDescriptor createNoteMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/CreateNote") - .setRequestMarshaller(ProtoUtils.marshaller(CreateNoteRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Note.getDefaultInstance())) - .build(); - private static final MethodDescriptor - batchCreateNotesMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/BatchCreateNotes") - .setRequestMarshaller( - ProtoUtils.marshaller(BatchCreateNotesRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(BatchCreateNotesResponse.getDefaultInstance())) - .build(); - private static final MethodDescriptor updateNoteMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/UpdateNote") - .setRequestMarshaller(ProtoUtils.marshaller(UpdateNoteRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Note.getDefaultInstance())) - .build(); - private static final MethodDescriptor - listNoteOccurrencesMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("grafeas.v1beta1.GrafeasV1Beta1/ListNoteOccurrences") - .setRequestMarshaller( - ProtoUtils.marshaller(ListNoteOccurrencesRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(ListNoteOccurrencesResponse.getDefaultInstance())) - .build(); - private static final MethodDescriptor< - GetVulnerabilityOccurrencesSummaryRequest, VulnerabilityOccurrencesSummary> - getVulnerabilityOccurrencesSummaryMethodDescriptor = - MethodDescriptor - . - newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - "grafeas.v1beta1.GrafeasV1Beta1/GetVulnerabilityOccurrencesSummary") - .setRequestMarshaller( - ProtoUtils.marshaller( - GetVulnerabilityOccurrencesSummaryRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(VulnerabilityOccurrencesSummary.getDefaultInstance())) - .build(); - - private final BackgroundResource backgroundResources; - - private final UnaryCallable getOccurrenceCallable; - private final UnaryCallable - listOccurrencesCallable; - private final UnaryCallable - listOccurrencesPagedCallable; - private final UnaryCallable deleteOccurrenceCallable; - private final UnaryCallable createOccurrenceCallable; - private final UnaryCallable - batchCreateOccurrencesCallable; - private final UnaryCallable updateOccurrenceCallable; - private final UnaryCallable getOccurrenceNoteCallable; - private final UnaryCallable getNoteCallable; - private final UnaryCallable listNotesCallable; - private final UnaryCallable listNotesPagedCallable; - private final UnaryCallable deleteNoteCallable; - private final UnaryCallable createNoteCallable; - private final UnaryCallable - batchCreateNotesCallable; - private final UnaryCallable updateNoteCallable; - private final UnaryCallable - listNoteOccurrencesCallable; - private final UnaryCallable - listNoteOccurrencesPagedCallable; - private final UnaryCallable< - GetVulnerabilityOccurrencesSummaryRequest, VulnerabilityOccurrencesSummary> - getVulnerabilityOccurrencesSummaryCallable; - - private final GrpcStubCallableFactory callableFactory; - - public static final GrpcGrafeasV1Beta1Stub create(GrafeasV1Beta1StubSettings settings) - throws IOException { - return new GrpcGrafeasV1Beta1Stub(settings, ClientContext.create(settings)); - } - - public static final GrpcGrafeasV1Beta1Stub create(ClientContext clientContext) - throws IOException { - return new GrpcGrafeasV1Beta1Stub( - GrafeasV1Beta1StubSettings.newBuilder().build(), clientContext); - } - - public static final GrpcGrafeasV1Beta1Stub create( - ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { - return new GrpcGrafeasV1Beta1Stub( - GrafeasV1Beta1StubSettings.newBuilder().build(), clientContext, callableFactory); - } - - /** - * Constructs an instance of GrpcGrafeasV1Beta1Stub, using the given settings. This is protected - * so that it is easy to make a subclass, but otherwise, the static factory methods should be - * preferred. - */ - protected GrpcGrafeasV1Beta1Stub(GrafeasV1Beta1StubSettings settings, ClientContext clientContext) - throws IOException { - this(settings, clientContext, new GrpcGrafeasV1Beta1CallableFactory()); - } - - /** - * Constructs an instance of GrpcGrafeasV1Beta1Stub, using the given settings. This is protected - * so that it is easy to make a subclass, but otherwise, the static factory methods should be - * preferred. - */ - protected GrpcGrafeasV1Beta1Stub( - GrafeasV1Beta1StubSettings settings, - ClientContext clientContext, - GrpcStubCallableFactory callableFactory) - throws IOException { - this.callableFactory = callableFactory; - - GrpcCallSettings getOccurrenceTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(getOccurrenceMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(GetOccurrenceRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - } - }) - .build(); - GrpcCallSettings - listOccurrencesTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(listOccurrencesMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(ListOccurrencesRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - return params.build(); - } - }) - .build(); - GrpcCallSettings deleteOccurrenceTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(deleteOccurrenceMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(DeleteOccurrenceRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - } - }) - .build(); - GrpcCallSettings createOccurrenceTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(createOccurrenceMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(CreateOccurrenceRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - return params.build(); - } - }) - .build(); - GrpcCallSettings - batchCreateOccurrencesTransportSettings = - GrpcCallSettings - .newBuilder() - .setMethodDescriptor(batchCreateOccurrencesMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(BatchCreateOccurrencesRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - return params.build(); - } - }) - .build(); - GrpcCallSettings updateOccurrenceTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(updateOccurrenceMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(UpdateOccurrenceRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - } - }) - .build(); - GrpcCallSettings getOccurrenceNoteTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(getOccurrenceNoteMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(GetOccurrenceNoteRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - } - }) - .build(); - GrpcCallSettings getNoteTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(getNoteMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(GetNoteRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - } - }) - .build(); - GrpcCallSettings listNotesTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(listNotesMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(ListNotesRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - return params.build(); - } - }) - .build(); - GrpcCallSettings deleteNoteTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(deleteNoteMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(DeleteNoteRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - } - }) - .build(); - GrpcCallSettings createNoteTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(createNoteMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(CreateNoteRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - return params.build(); - } - }) - .build(); - GrpcCallSettings - batchCreateNotesTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(batchCreateNotesMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(BatchCreateNotesRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - return params.build(); - } - }) - .build(); - GrpcCallSettings updateNoteTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(updateNoteMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(UpdateNoteRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - } - }) - .build(); - GrpcCallSettings - listNoteOccurrencesTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(listNoteOccurrencesMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract(ListNoteOccurrencesRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - } - }) - .build(); - GrpcCallSettings - getVulnerabilityOccurrencesSummaryTransportSettings = - GrpcCallSettings - . - newBuilder() - .setMethodDescriptor(getVulnerabilityOccurrencesSummaryMethodDescriptor) - .setParamsExtractor( - new RequestParamsExtractor() { - @Override - public Map extract( - GetVulnerabilityOccurrencesSummaryRequest request) { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - return params.build(); - } - }) - .build(); - - this.getOccurrenceCallable = - callableFactory.createUnaryCallable( - getOccurrenceTransportSettings, settings.getOccurrenceSettings(), clientContext); - this.listOccurrencesCallable = - callableFactory.createUnaryCallable( - listOccurrencesTransportSettings, settings.listOccurrencesSettings(), clientContext); - this.listOccurrencesPagedCallable = - callableFactory.createPagedCallable( - listOccurrencesTransportSettings, settings.listOccurrencesSettings(), clientContext); - this.deleteOccurrenceCallable = - callableFactory.createUnaryCallable( - deleteOccurrenceTransportSettings, settings.deleteOccurrenceSettings(), clientContext); - this.createOccurrenceCallable = - callableFactory.createUnaryCallable( - createOccurrenceTransportSettings, settings.createOccurrenceSettings(), clientContext); - this.batchCreateOccurrencesCallable = - callableFactory.createUnaryCallable( - batchCreateOccurrencesTransportSettings, - settings.batchCreateOccurrencesSettings(), - clientContext); - this.updateOccurrenceCallable = - callableFactory.createUnaryCallable( - updateOccurrenceTransportSettings, settings.updateOccurrenceSettings(), clientContext); - this.getOccurrenceNoteCallable = - callableFactory.createUnaryCallable( - getOccurrenceNoteTransportSettings, - settings.getOccurrenceNoteSettings(), - clientContext); - this.getNoteCallable = - callableFactory.createUnaryCallable( - getNoteTransportSettings, settings.getNoteSettings(), clientContext); - this.listNotesCallable = - callableFactory.createUnaryCallable( - listNotesTransportSettings, settings.listNotesSettings(), clientContext); - this.listNotesPagedCallable = - callableFactory.createPagedCallable( - listNotesTransportSettings, settings.listNotesSettings(), clientContext); - this.deleteNoteCallable = - callableFactory.createUnaryCallable( - deleteNoteTransportSettings, settings.deleteNoteSettings(), clientContext); - this.createNoteCallable = - callableFactory.createUnaryCallable( - createNoteTransportSettings, settings.createNoteSettings(), clientContext); - this.batchCreateNotesCallable = - callableFactory.createUnaryCallable( - batchCreateNotesTransportSettings, settings.batchCreateNotesSettings(), clientContext); - this.updateNoteCallable = - callableFactory.createUnaryCallable( - updateNoteTransportSettings, settings.updateNoteSettings(), clientContext); - this.listNoteOccurrencesCallable = - callableFactory.createUnaryCallable( - listNoteOccurrencesTransportSettings, - settings.listNoteOccurrencesSettings(), - clientContext); - this.listNoteOccurrencesPagedCallable = - callableFactory.createPagedCallable( - listNoteOccurrencesTransportSettings, - settings.listNoteOccurrencesSettings(), - clientContext); - this.getVulnerabilityOccurrencesSummaryCallable = - callableFactory.createUnaryCallable( - getVulnerabilityOccurrencesSummaryTransportSettings, - settings.getVulnerabilityOccurrencesSummarySettings(), - clientContext); - - backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); - } - - public UnaryCallable getOccurrenceCallable() { - return getOccurrenceCallable; - } - - public UnaryCallable - listOccurrencesPagedCallable() { - return listOccurrencesPagedCallable; - } - - public UnaryCallable listOccurrencesCallable() { - return listOccurrencesCallable; - } - - public UnaryCallable deleteOccurrenceCallable() { - return deleteOccurrenceCallable; - } - - public UnaryCallable createOccurrenceCallable() { - return createOccurrenceCallable; - } - - public UnaryCallable - batchCreateOccurrencesCallable() { - return batchCreateOccurrencesCallable; - } - - public UnaryCallable updateOccurrenceCallable() { - return updateOccurrenceCallable; - } - - public UnaryCallable getOccurrenceNoteCallable() { - return getOccurrenceNoteCallable; - } - - public UnaryCallable getNoteCallable() { - return getNoteCallable; - } - - public UnaryCallable listNotesPagedCallable() { - return listNotesPagedCallable; - } - - public UnaryCallable listNotesCallable() { - return listNotesCallable; - } - - public UnaryCallable deleteNoteCallable() { - return deleteNoteCallable; - } - - public UnaryCallable createNoteCallable() { - return createNoteCallable; - } - - public UnaryCallable - batchCreateNotesCallable() { - return batchCreateNotesCallable; - } - - public UnaryCallable updateNoteCallable() { - return updateNoteCallable; - } - - public UnaryCallable - listNoteOccurrencesPagedCallable() { - return listNoteOccurrencesPagedCallable; - } - - public UnaryCallable - listNoteOccurrencesCallable() { - return listNoteOccurrencesCallable; - } - - public UnaryCallable - getVulnerabilityOccurrencesSummaryCallable() { - return getVulnerabilityOccurrencesSummaryCallable; - } - - @Override - public final void close() { - shutdown(); - } - - @Override - public void shutdown() { - backgroundResources.shutdown(); - } - - @Override - public boolean isShutdown() { - return backgroundResources.isShutdown(); - } - - @Override - public boolean isTerminated() { - return backgroundResources.isTerminated(); - } - - @Override - public void shutdownNow() { - backgroundResources.shutdownNow(); - } - - @Override - public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { - return backgroundResources.awaitTermination(duration, unit); - } -} diff --git a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/ContainerAnalysisClientTest.java b/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/ContainerAnalysisClientTest.java deleted file mode 100644 index ad946c0f..00000000 --- a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/ContainerAnalysisClientTest.java +++ /dev/null @@ -1,209 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1; - -import com.google.api.gax.core.NoCredentialsProvider; -import com.google.api.gax.grpc.GaxGrpcProperties; -import com.google.api.gax.grpc.testing.LocalChannelProvider; -import com.google.api.gax.grpc.testing.MockGrpcService; -import com.google.api.gax.grpc.testing.MockServiceHelper; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.InvalidArgumentException; -import com.google.containeranalysis.v1.IamResourceName; -import com.google.containeranalysis.v1.NoteName; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import com.google.protobuf.AbstractMessage; -import com.google.protobuf.ByteString; -import io.grpc.Status; -import io.grpc.StatusRuntimeException; -import java.io.IOException; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; -import java.util.Objects; -import org.junit.After; -import org.junit.AfterClass; -import org.junit.Assert; -import org.junit.Before; -import org.junit.BeforeClass; -import org.junit.Test; - -@javax.annotation.Generated("by GAPIC") -public class ContainerAnalysisClientTest { - private static MockContainerAnalysis mockContainerAnalysis; - private static MockServiceHelper serviceHelper; - private ContainerAnalysisClient client; - private LocalChannelProvider channelProvider; - - @BeforeClass - public static void startStaticServer() { - mockContainerAnalysis = new MockContainerAnalysis(); - serviceHelper = - new MockServiceHelper( - "in-process-1", Arrays.asList(mockContainerAnalysis)); - serviceHelper.start(); - } - - @AfterClass - public static void stopServer() { - serviceHelper.stop(); - } - - @Before - public void setUp() throws IOException { - serviceHelper.reset(); - channelProvider = serviceHelper.createChannelProvider(); - ContainerAnalysisSettings settings = - ContainerAnalysisSettings.newBuilder() - .setTransportChannelProvider(channelProvider) - .setCredentialsProvider(NoCredentialsProvider.create()) - .build(); - client = ContainerAnalysisClient.create(settings); - } - - @After - public void tearDown() throws Exception { - client.close(); - } - - @Test - @SuppressWarnings("all") - public void setIamPolicyTest() { - int version = 351608024; - ByteString etag = ByteString.copyFromUtf8("21"); - Policy expectedResponse = Policy.newBuilder().setVersion(version).setEtag(etag).build(); - mockContainerAnalysis.addResponse(expectedResponse); - - IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]"); - Policy policy = Policy.newBuilder().build(); - - Policy actualResponse = client.setIamPolicy(resource, policy); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockContainerAnalysis.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - SetIamPolicyRequest actualRequest = (SetIamPolicyRequest) actualRequests.get(0); - - Assert.assertEquals(Objects.toString(resource), Objects.toString(actualRequest.getResource())); - Assert.assertEquals(policy, actualRequest.getPolicy()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void setIamPolicyExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockContainerAnalysis.addException(exception); - - try { - IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]"); - Policy policy = Policy.newBuilder().build(); - - client.setIamPolicy(resource, policy); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void getIamPolicyTest() { - int version = 351608024; - ByteString etag = ByteString.copyFromUtf8("21"); - Policy expectedResponse = Policy.newBuilder().setVersion(version).setEtag(etag).build(); - mockContainerAnalysis.addResponse(expectedResponse); - - IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]"); - - Policy actualResponse = client.getIamPolicy(resource); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockContainerAnalysis.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - GetIamPolicyRequest actualRequest = (GetIamPolicyRequest) actualRequests.get(0); - - Assert.assertEquals(Objects.toString(resource), Objects.toString(actualRequest.getResource())); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void getIamPolicyExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockContainerAnalysis.addException(exception); - - try { - IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]"); - - client.getIamPolicy(resource); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void testIamPermissionsTest() { - TestIamPermissionsResponse expectedResponse = TestIamPermissionsResponse.newBuilder().build(); - mockContainerAnalysis.addResponse(expectedResponse); - - IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]"); - List permissions = new ArrayList<>(); - - TestIamPermissionsResponse actualResponse = client.testIamPermissions(resource, permissions); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockContainerAnalysis.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - TestIamPermissionsRequest actualRequest = (TestIamPermissionsRequest) actualRequests.get(0); - - Assert.assertEquals(Objects.toString(resource), Objects.toString(actualRequest.getResource())); - Assert.assertEquals(permissions, actualRequest.getPermissionsList()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void testIamPermissionsExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockContainerAnalysis.addException(exception); - - try { - IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]"); - List permissions = new ArrayList<>(); - - client.testIamPermissions(resource, permissions); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } -} diff --git a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/ITGrafeasInteropTest.java b/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/ITGrafeasInteropTest.java deleted file mode 100644 index 53bc9630..00000000 --- a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/ITGrafeasInteropTest.java +++ /dev/null @@ -1,51 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1; - -import static org.junit.Assert.assertEquals; - -import io.grafeas.v1.GrafeasClient; -import io.grafeas.v1.GrafeasSettings; -import java.io.IOException; -import org.junit.Test; - -/** - * This test requires application default credentials. They are available if running in Google - * Compute Engine. Otherwise, the environment variable GOOGLE_APPLICATION_CREDENTIALS must point to - * a file containing the credentials. - */ -public class ITGrafeasInteropTest { - - @Test - public void createsGrafeasClient() throws IOException { - ContainerAnalysisClient client = - ContainerAnalysisClient.create(ContainerAnalysisSettings.newBuilder().build()); - GrafeasClient grafeasClient = client.getGrafeasClient(); - - ContainerAnalysisSettings settings = client.getSettings(); - GrafeasSettings grafeasSettings = grafeasClient.getSettings(); - - assertEquals(settings.getClock(), grafeasSettings.getClock()); - assertEquals(settings.getExecutorProvider(), grafeasSettings.getExecutorProvider()); - assertEquals(settings.getEndpoint(), grafeasSettings.getEndpoint()); - assertEquals(settings.getExecutorProvider(), grafeasSettings.getExecutorProvider()); - assertEquals(settings.getHeaderProvider(), grafeasSettings.getHeaderProvider()); - assertEquals( - settings.getTransportChannelProvider(), grafeasSettings.getTransportChannelProvider()); - assertEquals(settings.getWatchdogCheckInterval(), grafeasSettings.getWatchdogCheckInterval()); - assertEquals(settings.getWatchdogProvider(), grafeasSettings.getWatchdogProvider()); - } -} diff --git a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/MockContainerAnalysis.java b/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/MockContainerAnalysis.java deleted file mode 100644 index e348b9f0..00000000 --- a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/MockContainerAnalysis.java +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1; - -import com.google.api.core.BetaApi; -import com.google.api.gax.grpc.testing.MockGrpcService; -import com.google.protobuf.AbstractMessage; -import io.grpc.ServerServiceDefinition; -import java.util.List; - -@javax.annotation.Generated("by GAPIC") -@BetaApi -public class MockContainerAnalysis implements MockGrpcService { - private final MockContainerAnalysisImpl serviceImpl; - - public MockContainerAnalysis() { - serviceImpl = new MockContainerAnalysisImpl(); - } - - @Override - public List getRequests() { - return serviceImpl.getRequests(); - } - - @Override - public void addResponse(AbstractMessage response) { - serviceImpl.addResponse(response); - } - - @Override - public void addException(Exception exception) { - serviceImpl.addException(exception); - } - - @Override - public ServerServiceDefinition getServiceDefinition() { - return serviceImpl.bindService(); - } - - @Override - public void reset() { - serviceImpl.reset(); - } -} diff --git a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/MockContainerAnalysisImpl.java b/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/MockContainerAnalysisImpl.java deleted file mode 100644 index 313962d5..00000000 --- a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1/MockContainerAnalysisImpl.java +++ /dev/null @@ -1,107 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1; - -import com.google.api.core.BetaApi; -import com.google.containeranalysis.v1.ContainerAnalysisGrpc.ContainerAnalysisImplBase; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import com.google.protobuf.AbstractMessage; -import io.grpc.stub.StreamObserver; -import java.util.ArrayList; -import java.util.LinkedList; -import java.util.List; -import java.util.Queue; - -@javax.annotation.Generated("by GAPIC") -@BetaApi -public class MockContainerAnalysisImpl extends ContainerAnalysisImplBase { - private List requests; - private Queue responses; - - public MockContainerAnalysisImpl() { - requests = new ArrayList<>(); - responses = new LinkedList<>(); - } - - public List getRequests() { - return requests; - } - - public void addResponse(AbstractMessage response) { - responses.add(response); - } - - public void setResponses(List responses) { - this.responses = new LinkedList(responses); - } - - public void addException(Exception exception) { - responses.add(exception); - } - - public void reset() { - requests = new ArrayList<>(); - responses = new LinkedList<>(); - } - - @Override - public void setIamPolicy(SetIamPolicyRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Policy) { - requests.add(request); - responseObserver.onNext((Policy) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void getIamPolicy(GetIamPolicyRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Policy) { - requests.add(request); - responseObserver.onNext((Policy) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void testIamPermissions( - TestIamPermissionsRequest request, - StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof TestIamPermissionsResponse) { - requests.add(request); - responseObserver.onNext((TestIamPermissionsResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } -} diff --git a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/ContainerAnalysisV1Beta1ClientTest.java b/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/ContainerAnalysisV1Beta1ClientTest.java deleted file mode 100644 index 1e59d65d..00000000 --- a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/ContainerAnalysisV1Beta1ClientTest.java +++ /dev/null @@ -1,368 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1; - -import static com.google.cloud.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1Client.ListScanConfigsPagedResponse; - -import com.google.api.gax.core.NoCredentialsProvider; -import com.google.api.gax.grpc.GaxGrpcProperties; -import com.google.api.gax.grpc.testing.LocalChannelProvider; -import com.google.api.gax.grpc.testing.MockGrpcService; -import com.google.api.gax.grpc.testing.MockServiceHelper; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.InvalidArgumentException; -import com.google.common.collect.Lists; -import com.google.containeranalysis.v1beta1.GetScanConfigRequest; -import com.google.containeranalysis.v1beta1.IamResourceName; -import com.google.containeranalysis.v1beta1.IamResourceNames; -import com.google.containeranalysis.v1beta1.ListScanConfigsRequest; -import com.google.containeranalysis.v1beta1.ListScanConfigsResponse; -import com.google.containeranalysis.v1beta1.NoteName; -import com.google.containeranalysis.v1beta1.ProjectName; -import com.google.containeranalysis.v1beta1.ScanConfig; -import com.google.containeranalysis.v1beta1.ScanConfigName; -import com.google.containeranalysis.v1beta1.UpdateScanConfigRequest; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import com.google.protobuf.AbstractMessage; -import com.google.protobuf.ByteString; -import io.grpc.Status; -import io.grpc.StatusRuntimeException; -import java.io.IOException; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; -import org.junit.After; -import org.junit.AfterClass; -import org.junit.Assert; -import org.junit.Before; -import org.junit.BeforeClass; -import org.junit.Test; - -@javax.annotation.Generated("by GAPIC") -public class ContainerAnalysisV1Beta1ClientTest { - private static MockContainerAnalysisV1Beta1 mockContainerAnalysisV1Beta1; - private static MockGrafeasV1Beta1 mockGrafeasV1Beta1; - private static MockServiceHelper serviceHelper; - private ContainerAnalysisV1Beta1Client client; - private LocalChannelProvider channelProvider; - - @BeforeClass - public static void startStaticServer() { - mockContainerAnalysisV1Beta1 = new MockContainerAnalysisV1Beta1(); - mockGrafeasV1Beta1 = new MockGrafeasV1Beta1(); - serviceHelper = - new MockServiceHelper( - "in-process-1", - Arrays.asList(mockContainerAnalysisV1Beta1, mockGrafeasV1Beta1)); - serviceHelper.start(); - } - - @AfterClass - public static void stopServer() { - serviceHelper.stop(); - } - - @Before - public void setUp() throws IOException { - serviceHelper.reset(); - channelProvider = serviceHelper.createChannelProvider(); - ContainerAnalysisV1Beta1Settings settings = - ContainerAnalysisV1Beta1Settings.newBuilder() - .setTransportChannelProvider(channelProvider) - .setCredentialsProvider(NoCredentialsProvider.create()) - .build(); - client = ContainerAnalysisV1Beta1Client.create(settings); - } - - @After - public void tearDown() throws Exception { - client.close(); - } - - @Test - @SuppressWarnings("all") - public void setIamPolicyTest() { - int version = 351608024; - ByteString etag = ByteString.copyFromUtf8("21"); - Policy expectedResponse = Policy.newBuilder().setVersion(version).setEtag(etag).build(); - mockContainerAnalysisV1Beta1.addResponse(expectedResponse); - - IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]"); - Policy policy = Policy.newBuilder().build(); - - Policy actualResponse = client.setIamPolicy(resource, policy); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockContainerAnalysisV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - SetIamPolicyRequest actualRequest = (SetIamPolicyRequest) actualRequests.get(0); - - Assert.assertEquals(resource, IamResourceNames.parse(actualRequest.getResource())); - Assert.assertEquals(policy, actualRequest.getPolicy()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void setIamPolicyExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockContainerAnalysisV1Beta1.addException(exception); - - try { - IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]"); - Policy policy = Policy.newBuilder().build(); - - client.setIamPolicy(resource, policy); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void getIamPolicyTest() { - int version = 351608024; - ByteString etag = ByteString.copyFromUtf8("21"); - Policy expectedResponse = Policy.newBuilder().setVersion(version).setEtag(etag).build(); - mockContainerAnalysisV1Beta1.addResponse(expectedResponse); - - IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]"); - - Policy actualResponse = client.getIamPolicy(resource); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockContainerAnalysisV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - GetIamPolicyRequest actualRequest = (GetIamPolicyRequest) actualRequests.get(0); - - Assert.assertEquals(resource, IamResourceNames.parse(actualRequest.getResource())); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void getIamPolicyExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockContainerAnalysisV1Beta1.addException(exception); - - try { - IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]"); - - client.getIamPolicy(resource); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void testIamPermissionsTest() { - TestIamPermissionsResponse expectedResponse = TestIamPermissionsResponse.newBuilder().build(); - mockContainerAnalysisV1Beta1.addResponse(expectedResponse); - - IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]"); - List permissions = new ArrayList<>(); - - TestIamPermissionsResponse actualResponse = client.testIamPermissions(resource, permissions); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockContainerAnalysisV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - TestIamPermissionsRequest actualRequest = (TestIamPermissionsRequest) actualRequests.get(0); - - Assert.assertEquals(resource, IamResourceNames.parse(actualRequest.getResource())); - Assert.assertEquals(permissions, actualRequest.getPermissionsList()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void testIamPermissionsExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockContainerAnalysisV1Beta1.addException(exception); - - try { - IamResourceName resource = NoteName.of("[PROJECT]", "[NOTE]"); - List permissions = new ArrayList<>(); - - client.testIamPermissions(resource, permissions); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void getScanConfigTest() { - ScanConfigName name2 = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]"); - String description = "description-1724546052"; - boolean enabled = false; - ScanConfig expectedResponse = - ScanConfig.newBuilder() - .setName(name2.toString()) - .setDescription(description) - .setEnabled(enabled) - .build(); - mockContainerAnalysisV1Beta1.addResponse(expectedResponse); - - ScanConfigName name = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]"); - - ScanConfig actualResponse = client.getScanConfig(name); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockContainerAnalysisV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - GetScanConfigRequest actualRequest = (GetScanConfigRequest) actualRequests.get(0); - - Assert.assertEquals(name, ScanConfigName.parse(actualRequest.getName())); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void getScanConfigExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockContainerAnalysisV1Beta1.addException(exception); - - try { - ScanConfigName name = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]"); - - client.getScanConfig(name); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void listScanConfigsTest() { - String nextPageToken = ""; - ScanConfig scanConfigsElement = ScanConfig.newBuilder().build(); - List scanConfigs = Arrays.asList(scanConfigsElement); - ListScanConfigsResponse expectedResponse = - ListScanConfigsResponse.newBuilder() - .setNextPageToken(nextPageToken) - .addAllScanConfigs(scanConfigs) - .build(); - mockContainerAnalysisV1Beta1.addResponse(expectedResponse); - - ProjectName parent = ProjectName.of("[PROJECT]"); - String filter = "filter-1274492040"; - - ListScanConfigsPagedResponse pagedListResponse = client.listScanConfigs(parent, filter); - - List resources = Lists.newArrayList(pagedListResponse.iterateAll()); - Assert.assertEquals(1, resources.size()); - Assert.assertEquals(expectedResponse.getScanConfigsList().get(0), resources.get(0)); - - List actualRequests = mockContainerAnalysisV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ListScanConfigsRequest actualRequest = (ListScanConfigsRequest) actualRequests.get(0); - - Assert.assertEquals(parent, ProjectName.parse(actualRequest.getParent())); - Assert.assertEquals(filter, actualRequest.getFilter()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void listScanConfigsExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockContainerAnalysisV1Beta1.addException(exception); - - try { - ProjectName parent = ProjectName.of("[PROJECT]"); - String filter = "filter-1274492040"; - - client.listScanConfigs(parent, filter); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void updateScanConfigTest() { - ScanConfigName name2 = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]"); - String description = "description-1724546052"; - boolean enabled = false; - ScanConfig expectedResponse = - ScanConfig.newBuilder() - .setName(name2.toString()) - .setDescription(description) - .setEnabled(enabled) - .build(); - mockContainerAnalysisV1Beta1.addResponse(expectedResponse); - - ScanConfigName name = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]"); - ScanConfig scanConfig = ScanConfig.newBuilder().build(); - - ScanConfig actualResponse = client.updateScanConfig(name, scanConfig); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockContainerAnalysisV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - UpdateScanConfigRequest actualRequest = (UpdateScanConfigRequest) actualRequests.get(0); - - Assert.assertEquals(name, ScanConfigName.parse(actualRequest.getName())); - Assert.assertEquals(scanConfig, actualRequest.getScanConfig()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void updateScanConfigExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockContainerAnalysisV1Beta1.addException(exception); - - try { - ScanConfigName name = ScanConfigName.of("[PROJECT]", "[SCAN_CONFIG]"); - ScanConfig scanConfig = ScanConfig.newBuilder().build(); - - client.updateScanConfig(name, scanConfig); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } -} diff --git a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/GrafeasV1Beta1ClientTest.java b/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/GrafeasV1Beta1ClientTest.java deleted file mode 100644 index dc76f01c..00000000 --- a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/GrafeasV1Beta1ClientTest.java +++ /dev/null @@ -1,810 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1; - -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListNoteOccurrencesPagedResponse; -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListNotesPagedResponse; -import static com.google.cloud.devtools.containeranalysis.v1beta1.GrafeasV1Beta1Client.ListOccurrencesPagedResponse; - -import com.google.api.gax.core.NoCredentialsProvider; -import com.google.api.gax.grpc.GaxGrpcProperties; -import com.google.api.gax.grpc.testing.LocalChannelProvider; -import com.google.api.gax.grpc.testing.MockGrpcService; -import com.google.api.gax.grpc.testing.MockServiceHelper; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.InvalidArgumentException; -import com.google.common.collect.Lists; -import com.google.containeranalysis.v1beta1.NoteName; -import com.google.containeranalysis.v1beta1.OccurrenceName; -import com.google.containeranalysis.v1beta1.ProjectName; -import com.google.protobuf.AbstractMessage; -import com.google.protobuf.Empty; -import com.google.protobuf.FieldMask; -import io.grafeas.v1beta1.BatchCreateNotesRequest; -import io.grafeas.v1beta1.BatchCreateNotesResponse; -import io.grafeas.v1beta1.BatchCreateOccurrencesRequest; -import io.grafeas.v1beta1.BatchCreateOccurrencesResponse; -import io.grafeas.v1beta1.CreateNoteRequest; -import io.grafeas.v1beta1.CreateOccurrenceRequest; -import io.grafeas.v1beta1.DeleteNoteRequest; -import io.grafeas.v1beta1.DeleteOccurrenceRequest; -import io.grafeas.v1beta1.GetNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceRequest; -import io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesResponse; -import io.grafeas.v1beta1.ListNotesRequest; -import io.grafeas.v1beta1.ListNotesResponse; -import io.grafeas.v1beta1.ListOccurrencesRequest; -import io.grafeas.v1beta1.ListOccurrencesResponse; -import io.grafeas.v1beta1.Note; -import io.grafeas.v1beta1.Occurrence; -import io.grafeas.v1beta1.UpdateNoteRequest; -import io.grafeas.v1beta1.UpdateOccurrenceRequest; -import io.grafeas.v1beta1.VulnerabilityOccurrencesSummary; -import io.grpc.Status; -import io.grpc.StatusRuntimeException; -import java.io.IOException; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import org.junit.After; -import org.junit.AfterClass; -import org.junit.Assert; -import org.junit.Before; -import org.junit.BeforeClass; -import org.junit.Test; - -@javax.annotation.Generated("by GAPIC") -public class GrafeasV1Beta1ClientTest { - private static MockContainerAnalysisV1Beta1 mockContainerAnalysisV1Beta1; - private static MockGrafeasV1Beta1 mockGrafeasV1Beta1; - private static MockServiceHelper serviceHelper; - private GrafeasV1Beta1Client client; - private LocalChannelProvider channelProvider; - - @BeforeClass - public static void startStaticServer() { - mockContainerAnalysisV1Beta1 = new MockContainerAnalysisV1Beta1(); - mockGrafeasV1Beta1 = new MockGrafeasV1Beta1(); - serviceHelper = - new MockServiceHelper( - "in-process-1", - Arrays.asList(mockContainerAnalysisV1Beta1, mockGrafeasV1Beta1)); - serviceHelper.start(); - } - - @AfterClass - public static void stopServer() { - serviceHelper.stop(); - } - - @Before - public void setUp() throws IOException { - serviceHelper.reset(); - channelProvider = serviceHelper.createChannelProvider(); - GrafeasV1Beta1Settings settings = - GrafeasV1Beta1Settings.newBuilder() - .setTransportChannelProvider(channelProvider) - .setCredentialsProvider(NoCredentialsProvider.create()) - .build(); - client = GrafeasV1Beta1Client.create(settings); - } - - @After - public void tearDown() throws Exception { - client.close(); - } - - @Test - @SuppressWarnings("all") - public void getOccurrenceTest() { - String name2 = "name2-1052831874"; - String noteName = "noteName1780787896"; - String remediation = "remediation779381797"; - Occurrence expectedResponse = - Occurrence.newBuilder() - .setName(name2) - .setNoteName(noteName) - .setRemediation(remediation) - .build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]"); - - Occurrence actualResponse = client.getOccurrence(name); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - GetOccurrenceRequest actualRequest = (GetOccurrenceRequest) actualRequests.get(0); - - Assert.assertEquals(name, OccurrenceName.parse(actualRequest.getName())); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void getOccurrenceExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]"); - - client.getOccurrence(name); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void listOccurrencesTest() { - String nextPageToken = ""; - Occurrence occurrencesElement = Occurrence.newBuilder().build(); - List occurrences = Arrays.asList(occurrencesElement); - ListOccurrencesResponse expectedResponse = - ListOccurrencesResponse.newBuilder() - .setNextPageToken(nextPageToken) - .addAllOccurrences(occurrences) - .build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - ProjectName parent = ProjectName.of("[PROJECT]"); - String filter = "filter-1274492040"; - - ListOccurrencesPagedResponse pagedListResponse = client.listOccurrences(parent, filter); - - List resources = Lists.newArrayList(pagedListResponse.iterateAll()); - Assert.assertEquals(1, resources.size()); - Assert.assertEquals(expectedResponse.getOccurrencesList().get(0), resources.get(0)); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ListOccurrencesRequest actualRequest = (ListOccurrencesRequest) actualRequests.get(0); - - Assert.assertEquals(parent, ProjectName.parse(actualRequest.getParent())); - Assert.assertEquals(filter, actualRequest.getFilter()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void listOccurrencesExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - ProjectName parent = ProjectName.of("[PROJECT]"); - String filter = "filter-1274492040"; - - client.listOccurrences(parent, filter); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void deleteOccurrenceTest() { - Empty expectedResponse = Empty.newBuilder().build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]"); - - client.deleteOccurrence(name); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - DeleteOccurrenceRequest actualRequest = (DeleteOccurrenceRequest) actualRequests.get(0); - - Assert.assertEquals(name, OccurrenceName.parse(actualRequest.getName())); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void deleteOccurrenceExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]"); - - client.deleteOccurrence(name); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void createOccurrenceTest() { - String name = "name3373707"; - String noteName = "noteName1780787896"; - String remediation = "remediation779381797"; - Occurrence expectedResponse = - Occurrence.newBuilder() - .setName(name) - .setNoteName(noteName) - .setRemediation(remediation) - .build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - ProjectName parent = ProjectName.of("[PROJECT]"); - Occurrence occurrence = Occurrence.newBuilder().build(); - - Occurrence actualResponse = client.createOccurrence(parent, occurrence); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - CreateOccurrenceRequest actualRequest = (CreateOccurrenceRequest) actualRequests.get(0); - - Assert.assertEquals(parent, ProjectName.parse(actualRequest.getParent())); - Assert.assertEquals(occurrence, actualRequest.getOccurrence()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void createOccurrenceExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - ProjectName parent = ProjectName.of("[PROJECT]"); - Occurrence occurrence = Occurrence.newBuilder().build(); - - client.createOccurrence(parent, occurrence); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void batchCreateOccurrencesTest() { - BatchCreateOccurrencesResponse expectedResponse = - BatchCreateOccurrencesResponse.newBuilder().build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - ProjectName parent = ProjectName.of("[PROJECT]"); - List occurrences = new ArrayList<>(); - - BatchCreateOccurrencesResponse actualResponse = - client.batchCreateOccurrences(parent, occurrences); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - BatchCreateOccurrencesRequest actualRequest = - (BatchCreateOccurrencesRequest) actualRequests.get(0); - - Assert.assertEquals(parent, ProjectName.parse(actualRequest.getParent())); - Assert.assertEquals(occurrences, actualRequest.getOccurrencesList()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void batchCreateOccurrencesExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - ProjectName parent = ProjectName.of("[PROJECT]"); - List occurrences = new ArrayList<>(); - - client.batchCreateOccurrences(parent, occurrences); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void updateOccurrenceTest() { - String name2 = "name2-1052831874"; - String noteName = "noteName1780787896"; - String remediation = "remediation779381797"; - Occurrence expectedResponse = - Occurrence.newBuilder() - .setName(name2) - .setNoteName(noteName) - .setRemediation(remediation) - .build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]"); - Occurrence occurrence = Occurrence.newBuilder().build(); - FieldMask updateMask = FieldMask.newBuilder().build(); - - Occurrence actualResponse = client.updateOccurrence(name, occurrence, updateMask); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - UpdateOccurrenceRequest actualRequest = (UpdateOccurrenceRequest) actualRequests.get(0); - - Assert.assertEquals(name, OccurrenceName.parse(actualRequest.getName())); - Assert.assertEquals(occurrence, actualRequest.getOccurrence()); - Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void updateOccurrenceExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]"); - Occurrence occurrence = Occurrence.newBuilder().build(); - FieldMask updateMask = FieldMask.newBuilder().build(); - - client.updateOccurrence(name, occurrence, updateMask); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void getOccurrenceNoteTest() { - String name2 = "name2-1052831874"; - String shortDescription = "shortDescription-235369287"; - String longDescription = "longDescription-1747792199"; - Note expectedResponse = - Note.newBuilder() - .setName(name2) - .setShortDescription(shortDescription) - .setLongDescription(longDescription) - .build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]"); - - Note actualResponse = client.getOccurrenceNote(name); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - GetOccurrenceNoteRequest actualRequest = (GetOccurrenceNoteRequest) actualRequests.get(0); - - Assert.assertEquals(name, OccurrenceName.parse(actualRequest.getName())); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void getOccurrenceNoteExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - OccurrenceName name = OccurrenceName.of("[PROJECT]", "[OCCURRENCE]"); - - client.getOccurrenceNote(name); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void getNoteTest() { - String name2 = "name2-1052831874"; - String shortDescription = "shortDescription-235369287"; - String longDescription = "longDescription-1747792199"; - Note expectedResponse = - Note.newBuilder() - .setName(name2) - .setShortDescription(shortDescription) - .setLongDescription(longDescription) - .build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - NoteName name = NoteName.of("[PROJECT]", "[NOTE]"); - - Note actualResponse = client.getNote(name); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - GetNoteRequest actualRequest = (GetNoteRequest) actualRequests.get(0); - - Assert.assertEquals(name, NoteName.parse(actualRequest.getName())); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void getNoteExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - NoteName name = NoteName.of("[PROJECT]", "[NOTE]"); - - client.getNote(name); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void listNotesTest() { - String nextPageToken = ""; - Note notesElement = Note.newBuilder().build(); - List notes = Arrays.asList(notesElement); - ListNotesResponse expectedResponse = - ListNotesResponse.newBuilder().setNextPageToken(nextPageToken).addAllNotes(notes).build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - ProjectName parent = ProjectName.of("[PROJECT]"); - String filter = "filter-1274492040"; - - ListNotesPagedResponse pagedListResponse = client.listNotes(parent, filter); - - List resources = Lists.newArrayList(pagedListResponse.iterateAll()); - Assert.assertEquals(1, resources.size()); - Assert.assertEquals(expectedResponse.getNotesList().get(0), resources.get(0)); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ListNotesRequest actualRequest = (ListNotesRequest) actualRequests.get(0); - - Assert.assertEquals(parent, ProjectName.parse(actualRequest.getParent())); - Assert.assertEquals(filter, actualRequest.getFilter()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void listNotesExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - ProjectName parent = ProjectName.of("[PROJECT]"); - String filter = "filter-1274492040"; - - client.listNotes(parent, filter); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void deleteNoteTest() { - Empty expectedResponse = Empty.newBuilder().build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - NoteName name = NoteName.of("[PROJECT]", "[NOTE]"); - - client.deleteNote(name); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - DeleteNoteRequest actualRequest = (DeleteNoteRequest) actualRequests.get(0); - - Assert.assertEquals(name, NoteName.parse(actualRequest.getName())); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void deleteNoteExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - NoteName name = NoteName.of("[PROJECT]", "[NOTE]"); - - client.deleteNote(name); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void createNoteTest() { - String name = "name3373707"; - String shortDescription = "shortDescription-235369287"; - String longDescription = "longDescription-1747792199"; - Note expectedResponse = - Note.newBuilder() - .setName(name) - .setShortDescription(shortDescription) - .setLongDescription(longDescription) - .build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - ProjectName parent = ProjectName.of("[PROJECT]"); - String noteId = "noteId2129224840"; - Note note = Note.newBuilder().build(); - - Note actualResponse = client.createNote(parent, noteId, note); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - CreateNoteRequest actualRequest = (CreateNoteRequest) actualRequests.get(0); - - Assert.assertEquals(parent, ProjectName.parse(actualRequest.getParent())); - Assert.assertEquals(noteId, actualRequest.getNoteId()); - Assert.assertEquals(note, actualRequest.getNote()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void createNoteExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - ProjectName parent = ProjectName.of("[PROJECT]"); - String noteId = "noteId2129224840"; - Note note = Note.newBuilder().build(); - - client.createNote(parent, noteId, note); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void batchCreateNotesTest() { - BatchCreateNotesResponse expectedResponse = BatchCreateNotesResponse.newBuilder().build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - ProjectName parent = ProjectName.of("[PROJECT]"); - Map notes = new HashMap<>(); - - BatchCreateNotesResponse actualResponse = client.batchCreateNotes(parent, notes); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - BatchCreateNotesRequest actualRequest = (BatchCreateNotesRequest) actualRequests.get(0); - - Assert.assertEquals(parent, ProjectName.parse(actualRequest.getParent())); - Assert.assertEquals(notes, actualRequest.getNotesMap()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void batchCreateNotesExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - ProjectName parent = ProjectName.of("[PROJECT]"); - Map notes = new HashMap<>(); - - client.batchCreateNotes(parent, notes); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void updateNoteTest() { - String name2 = "name2-1052831874"; - String shortDescription = "shortDescription-235369287"; - String longDescription = "longDescription-1747792199"; - Note expectedResponse = - Note.newBuilder() - .setName(name2) - .setShortDescription(shortDescription) - .setLongDescription(longDescription) - .build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - NoteName name = NoteName.of("[PROJECT]", "[NOTE]"); - Note note = Note.newBuilder().build(); - FieldMask updateMask = FieldMask.newBuilder().build(); - - Note actualResponse = client.updateNote(name, note, updateMask); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - UpdateNoteRequest actualRequest = (UpdateNoteRequest) actualRequests.get(0); - - Assert.assertEquals(name, NoteName.parse(actualRequest.getName())); - Assert.assertEquals(note, actualRequest.getNote()); - Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void updateNoteExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - NoteName name = NoteName.of("[PROJECT]", "[NOTE]"); - Note note = Note.newBuilder().build(); - FieldMask updateMask = FieldMask.newBuilder().build(); - - client.updateNote(name, note, updateMask); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void listNoteOccurrencesTest() { - String nextPageToken = ""; - Occurrence occurrencesElement = Occurrence.newBuilder().build(); - List occurrences = Arrays.asList(occurrencesElement); - ListNoteOccurrencesResponse expectedResponse = - ListNoteOccurrencesResponse.newBuilder() - .setNextPageToken(nextPageToken) - .addAllOccurrences(occurrences) - .build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - NoteName name = NoteName.of("[PROJECT]", "[NOTE]"); - String filter = "filter-1274492040"; - - ListNoteOccurrencesPagedResponse pagedListResponse = client.listNoteOccurrences(name, filter); - - List resources = Lists.newArrayList(pagedListResponse.iterateAll()); - Assert.assertEquals(1, resources.size()); - Assert.assertEquals(expectedResponse.getOccurrencesList().get(0), resources.get(0)); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ListNoteOccurrencesRequest actualRequest = (ListNoteOccurrencesRequest) actualRequests.get(0); - - Assert.assertEquals(name, NoteName.parse(actualRequest.getName())); - Assert.assertEquals(filter, actualRequest.getFilter()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void listNoteOccurrencesExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - NoteName name = NoteName.of("[PROJECT]", "[NOTE]"); - String filter = "filter-1274492040"; - - client.listNoteOccurrences(name, filter); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void getVulnerabilityOccurrencesSummaryTest() { - VulnerabilityOccurrencesSummary expectedResponse = - VulnerabilityOccurrencesSummary.newBuilder().build(); - mockGrafeasV1Beta1.addResponse(expectedResponse); - - ProjectName parent = ProjectName.of("[PROJECT]"); - String filter = "filter-1274492040"; - - VulnerabilityOccurrencesSummary actualResponse = - client.getVulnerabilityOccurrencesSummary(parent, filter); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockGrafeasV1Beta1.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - GetVulnerabilityOccurrencesSummaryRequest actualRequest = - (GetVulnerabilityOccurrencesSummaryRequest) actualRequests.get(0); - - Assert.assertEquals(parent, ProjectName.parse(actualRequest.getParent())); - Assert.assertEquals(filter, actualRequest.getFilter()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void getVulnerabilityOccurrencesSummaryExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockGrafeasV1Beta1.addException(exception); - - try { - ProjectName parent = ProjectName.of("[PROJECT]"); - String filter = "filter-1274492040"; - - client.getVulnerabilityOccurrencesSummary(parent, filter); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } -} diff --git a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockContainerAnalysisV1Beta1.java b/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockContainerAnalysisV1Beta1.java deleted file mode 100644 index f7e15dcb..00000000 --- a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockContainerAnalysisV1Beta1.java +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1; - -import com.google.api.core.BetaApi; -import com.google.api.gax.grpc.testing.MockGrpcService; -import com.google.protobuf.AbstractMessage; -import io.grpc.ServerServiceDefinition; -import java.util.List; - -@javax.annotation.Generated("by GAPIC") -@BetaApi -public class MockContainerAnalysisV1Beta1 implements MockGrpcService { - private final MockContainerAnalysisV1Beta1Impl serviceImpl; - - public MockContainerAnalysisV1Beta1() { - serviceImpl = new MockContainerAnalysisV1Beta1Impl(); - } - - @Override - public List getRequests() { - return serviceImpl.getRequests(); - } - - @Override - public void addResponse(AbstractMessage response) { - serviceImpl.addResponse(response); - } - - @Override - public void addException(Exception exception) { - serviceImpl.addException(exception); - } - - @Override - public ServerServiceDefinition getServiceDefinition() { - return serviceImpl.bindService(); - } - - @Override - public void reset() { - serviceImpl.reset(); - } -} diff --git a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockContainerAnalysisV1Beta1Impl.java b/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockContainerAnalysisV1Beta1Impl.java deleted file mode 100644 index 406974f8..00000000 --- a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockContainerAnalysisV1Beta1Impl.java +++ /dev/null @@ -1,157 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1; - -import com.google.api.core.BetaApi; -import com.google.containeranalysis.v1beta1.ContainerAnalysisV1Beta1Grpc.ContainerAnalysisV1Beta1ImplBase; -import com.google.containeranalysis.v1beta1.GetScanConfigRequest; -import com.google.containeranalysis.v1beta1.ListScanConfigsRequest; -import com.google.containeranalysis.v1beta1.ListScanConfigsResponse; -import com.google.containeranalysis.v1beta1.ScanConfig; -import com.google.containeranalysis.v1beta1.UpdateScanConfigRequest; -import com.google.iam.v1.GetIamPolicyRequest; -import com.google.iam.v1.Policy; -import com.google.iam.v1.SetIamPolicyRequest; -import com.google.iam.v1.TestIamPermissionsRequest; -import com.google.iam.v1.TestIamPermissionsResponse; -import com.google.protobuf.AbstractMessage; -import io.grpc.stub.StreamObserver; -import java.util.ArrayList; -import java.util.LinkedList; -import java.util.List; -import java.util.Queue; - -@javax.annotation.Generated("by GAPIC") -@BetaApi -public class MockContainerAnalysisV1Beta1Impl extends ContainerAnalysisV1Beta1ImplBase { - private List requests; - private Queue responses; - - public MockContainerAnalysisV1Beta1Impl() { - requests = new ArrayList<>(); - responses = new LinkedList<>(); - } - - public List getRequests() { - return requests; - } - - public void addResponse(AbstractMessage response) { - responses.add(response); - } - - public void setResponses(List responses) { - this.responses = new LinkedList(responses); - } - - public void addException(Exception exception) { - responses.add(exception); - } - - public void reset() { - requests = new ArrayList<>(); - responses = new LinkedList<>(); - } - - @Override - public void setIamPolicy(SetIamPolicyRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Policy) { - requests.add(request); - responseObserver.onNext((Policy) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void getIamPolicy(GetIamPolicyRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Policy) { - requests.add(request); - responseObserver.onNext((Policy) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void testIamPermissions( - TestIamPermissionsRequest request, - StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof TestIamPermissionsResponse) { - requests.add(request); - responseObserver.onNext((TestIamPermissionsResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void getScanConfig( - GetScanConfigRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof ScanConfig) { - requests.add(request); - responseObserver.onNext((ScanConfig) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void listScanConfigs( - ListScanConfigsRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof ListScanConfigsResponse) { - requests.add(request); - responseObserver.onNext((ListScanConfigsResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void updateScanConfig( - UpdateScanConfigRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof ScanConfig) { - requests.add(request); - responseObserver.onNext((ScanConfig) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } -} diff --git a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockGrafeasV1Beta1.java b/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockGrafeasV1Beta1.java deleted file mode 100644 index a7019124..00000000 --- a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockGrafeasV1Beta1.java +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1; - -import com.google.api.core.BetaApi; -import com.google.api.gax.grpc.testing.MockGrpcService; -import com.google.protobuf.AbstractMessage; -import io.grpc.ServerServiceDefinition; -import java.util.List; - -@javax.annotation.Generated("by GAPIC") -@BetaApi -public class MockGrafeasV1Beta1 implements MockGrpcService { - private final MockGrafeasV1Beta1Impl serviceImpl; - - public MockGrafeasV1Beta1() { - serviceImpl = new MockGrafeasV1Beta1Impl(); - } - - @Override - public List getRequests() { - return serviceImpl.getRequests(); - } - - @Override - public void addResponse(AbstractMessage response) { - serviceImpl.addResponse(response); - } - - @Override - public void addException(Exception exception) { - serviceImpl.addException(exception); - } - - @Override - public ServerServiceDefinition getServiceDefinition() { - return serviceImpl.bindService(); - } - - @Override - public void reset() { - serviceImpl.reset(); - } -} diff --git a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockGrafeasV1Beta1Impl.java b/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockGrafeasV1Beta1Impl.java deleted file mode 100644 index 57664c3e..00000000 --- a/google-cloud-containeranalysis/src/test/java/com/google/cloud/devtools/containeranalysis/v1beta1/MockGrafeasV1Beta1Impl.java +++ /dev/null @@ -1,306 +0,0 @@ -/* - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.devtools.containeranalysis.v1beta1; - -import com.google.api.core.BetaApi; -import com.google.protobuf.AbstractMessage; -import com.google.protobuf.Empty; -import io.grafeas.v1beta1.BatchCreateNotesRequest; -import io.grafeas.v1beta1.BatchCreateNotesResponse; -import io.grafeas.v1beta1.BatchCreateOccurrencesRequest; -import io.grafeas.v1beta1.BatchCreateOccurrencesResponse; -import io.grafeas.v1beta1.CreateNoteRequest; -import io.grafeas.v1beta1.CreateOccurrenceRequest; -import io.grafeas.v1beta1.DeleteNoteRequest; -import io.grafeas.v1beta1.DeleteOccurrenceRequest; -import io.grafeas.v1beta1.GetNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceNoteRequest; -import io.grafeas.v1beta1.GetOccurrenceRequest; -import io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest; -import io.grafeas.v1beta1.GrafeasV1Beta1Grpc.GrafeasV1Beta1ImplBase; -import io.grafeas.v1beta1.ListNoteOccurrencesRequest; -import io.grafeas.v1beta1.ListNoteOccurrencesResponse; -import io.grafeas.v1beta1.ListNotesRequest; -import io.grafeas.v1beta1.ListNotesResponse; -import io.grafeas.v1beta1.ListOccurrencesRequest; -import io.grafeas.v1beta1.ListOccurrencesResponse; -import io.grafeas.v1beta1.Note; -import io.grafeas.v1beta1.Occurrence; -import io.grafeas.v1beta1.UpdateNoteRequest; -import io.grafeas.v1beta1.UpdateOccurrenceRequest; -import io.grafeas.v1beta1.VulnerabilityOccurrencesSummary; -import io.grpc.stub.StreamObserver; -import java.util.ArrayList; -import java.util.LinkedList; -import java.util.List; -import java.util.Queue; - -@javax.annotation.Generated("by GAPIC") -@BetaApi -public class MockGrafeasV1Beta1Impl extends GrafeasV1Beta1ImplBase { - private List requests; - private Queue responses; - - public MockGrafeasV1Beta1Impl() { - requests = new ArrayList<>(); - responses = new LinkedList<>(); - } - - public List getRequests() { - return requests; - } - - public void addResponse(AbstractMessage response) { - responses.add(response); - } - - public void setResponses(List responses) { - this.responses = new LinkedList(responses); - } - - public void addException(Exception exception) { - responses.add(exception); - } - - public void reset() { - requests = new ArrayList<>(); - responses = new LinkedList<>(); - } - - @Override - public void getOccurrence( - GetOccurrenceRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Occurrence) { - requests.add(request); - responseObserver.onNext((Occurrence) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void listOccurrences( - ListOccurrencesRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof ListOccurrencesResponse) { - requests.add(request); - responseObserver.onNext((ListOccurrencesResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void deleteOccurrence( - DeleteOccurrenceRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Empty) { - requests.add(request); - responseObserver.onNext((Empty) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void createOccurrence( - CreateOccurrenceRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Occurrence) { - requests.add(request); - responseObserver.onNext((Occurrence) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void batchCreateOccurrences( - BatchCreateOccurrencesRequest request, - StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof BatchCreateOccurrencesResponse) { - requests.add(request); - responseObserver.onNext((BatchCreateOccurrencesResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void updateOccurrence( - UpdateOccurrenceRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Occurrence) { - requests.add(request); - responseObserver.onNext((Occurrence) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void getOccurrenceNote( - GetOccurrenceNoteRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Note) { - requests.add(request); - responseObserver.onNext((Note) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void getNote(GetNoteRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Note) { - requests.add(request); - responseObserver.onNext((Note) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void listNotes( - ListNotesRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof ListNotesResponse) { - requests.add(request); - responseObserver.onNext((ListNotesResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void deleteNote(DeleteNoteRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Empty) { - requests.add(request); - responseObserver.onNext((Empty) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void createNote(CreateNoteRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Note) { - requests.add(request); - responseObserver.onNext((Note) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void batchCreateNotes( - BatchCreateNotesRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof BatchCreateNotesResponse) { - requests.add(request); - responseObserver.onNext((BatchCreateNotesResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void updateNote(UpdateNoteRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Note) { - requests.add(request); - responseObserver.onNext((Note) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void listNoteOccurrences( - ListNoteOccurrencesRequest request, - StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof ListNoteOccurrencesResponse) { - requests.add(request); - responseObserver.onNext((ListNoteOccurrencesResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void getVulnerabilityOccurrencesSummary( - GetVulnerabilityOccurrencesSummaryRequest request, - StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof VulnerabilityOccurrencesSummary) { - requests.add(request); - responseObserver.onNext((VulnerabilityOccurrencesSummary) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } -} diff --git a/google-cloud-containeranalysis/synth.metadata b/google-cloud-containeranalysis/synth.metadata deleted file mode 100644 index 35cf8520..00000000 --- a/google-cloud-containeranalysis/synth.metadata +++ /dev/null @@ -1,42 +0,0 @@ -{ - "updateTime": "2019-08-02T07:39:50.733241Z", - "sources": [ - { - "generator": { - "name": "artman", - "version": "0.32.0", - "dockerImage": "googleapis/artman@sha256:6929f343c400122d85818195b18613330a12a014bffc1e08499550d40571479d" - } - }, - { - "git": { - "name": "googleapis", - "remote": "https://github.com/googleapis/googleapis.git", - "sha": "1b1ef1ca146c2119f077bca5e2b638c6bacb0925", - "internalRef": "261214002" - } - } - ], - "destinations": [ - { - "client": { - "source": "googleapis", - "apiName": "containeranalysis", - "apiVersion": "v1beta1", - "language": "java", - "generator": "gapic", - "config": "google/devtools/containeranalysis/artman_containeranalysis_v1beta1.yaml" - } - }, - { - "client": { - "source": "googleapis", - "apiName": "containeranalysis", - "apiVersion": "v1", - "language": "java", - "generator": "gapic", - "config": "google/devtools/containeranalysis/artman_containeranalysis_v1.yaml" - } - } - ] -} \ No newline at end of file diff --git a/google-cloud-containeranalysis/synth.py b/google-cloud-containeranalysis/synth.py deleted file mode 100644 index 21ece409..00000000 --- a/google-cloud-containeranalysis/synth.py +++ /dev/null @@ -1,67 +0,0 @@ -# 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. - -"""This script is used to synthesize generated parts of this library.""" - -import synthtool as s -import synthtool.gcp as gcp -import synthtool.languages.java as java - -gapic = gcp.GAPICGenerator() - -service = 'containeranalysis' -versions = ['v1beta1', 'v1'] -config_pattern = '/google/devtools/containeranalysis/artman_containeranalysis_{version}.yaml' - -get_grafeas_code = """ - /** - * Returns a new GrafeasClient with the same configured settings. - * - * @throws IOException - */ - public GrafeasClient getGrafeasClient() throws IOException { - return GrafeasClient.create(GrafeasUtils.transformSettings(settings)); - } -""" - - -for version in versions: - library = gapic.java_library( - service=service, - version=version, - config_path=config_pattern.format(version=version), - artman_output_name='') - - if version == 'v1': - # add GrafeasClient import - s.replace( - library / f'gapic-google-cloud-{service}-{version}/src/**/ContainerAnalysisClient.java', - 'import com.google.iam.v1.TestIamPermissionsResponse;', - 'import com.google.iam.v1.TestIamPermissionsResponse;\nimport io.grafeas.v1.GrafeasClient;' - ) - - # add getGrafeasClient() - s.replace( - library / f'gapic-google-cloud-{service}-{version}/src/**/ContainerAnalysisClient.java', - r'(\s+private final ContainerAnalysisStub stub;.*)', - f'\g<1>{get_grafeas_code}' - ) - - s.copy(library / f'gapic-google-cloud-{service}-{version}/src', 'src') - s.copy(library / f'grpc-google-cloud-{service}-{version}/src', f'../../google-api-grpc/grpc-google-cloud-{service}-{version}/src') - s.copy(library / f'proto-google-cloud-{service}-{version}/src', f'../../google-api-grpc/proto-google-cloud-{service}-{version}/src') - - java.format_code('./src') - java.format_code(f'../../google-api-grpc/grpc-google-cloud-{service}-{version}/src') - java.format_code(f'../../google-api-grpc/proto-google-cloud-{service}-{version}/src') diff --git a/grpc-google-cloud-container-v1/pom.xml b/grpc-google-cloud-container-v1/pom.xml index c48c6726..9499c1a8 100644 --- a/grpc-google-cloud-container-v1/pom.xml +++ b/grpc-google-cloud-container-v1/pom.xml @@ -2,51 +2,55 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 + com.google.api.grpc grpc-google-cloud-container-v1 0.82.0 grpc-google-cloud-container-v1 GRPC library for grpc-google-cloud-container-v1 - com.google.api.grpc - google-api-grpc - 0.82.0 + com.google.cloud + google-cloud-container-parent + 0.117.0-beta + + io.grpc + grpc-api + io.grpc grpc-stub - compile io.grpc grpc-protobuf - compile + + + com.google.protobuf + protobuf-java com.google.api.grpc proto-google-cloud-container-v1 - compile + + + com.google.guava + guava - - - - org.apache.maven.plugins - maven-javadoc-plugin - 3.1.1 - - protected - true - none - true - - - ${project.javadoc.protobufBaseURL} - ../../../../proto-google-cloud-container-v1/target/site/apidocs/ - - - - - - - + + + + java9 + + [9,) + + + + javax.annotation + javax.annotation-api + + + + + \ No newline at end of file diff --git a/grpc-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterManagerGrpc.java b/grpc-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterManagerGrpc.java index 3b8ce5ec..554bfdac 100644 --- a/grpc-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterManagerGrpc.java +++ b/grpc-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterManagerGrpc.java @@ -1,3 +1,19 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.google.container.v1; import static io.grpc.MethodDescriptor.generateFullMethodName; diff --git a/grpc-google-cloud-containeranalysis-v1/pom.xml b/grpc-google-cloud-containeranalysis-v1/pom.xml deleted file mode 100644 index ad102384..00000000 --- a/grpc-google-cloud-containeranalysis-v1/pom.xml +++ /dev/null @@ -1,52 +0,0 @@ - - 4.0.0 - grpc-google-cloud-containeranalysis-v1 - 0.82.0 - grpc-google-cloud-containeranalysis-v1 - GRPC library for grpc-google-cloud-containeranalysis-v1 - - com.google.api.grpc - google-api-grpc - 0.82.0 - - - - io.grpc - grpc-stub - compile - - - io.grpc - grpc-protobuf - compile - - - com.google.api.grpc - proto-google-cloud-containeranalysis-v1 - compile - - - - - - org.apache.maven.plugins - maven-javadoc-plugin - 3.1.1 - - protected - true - none - true - - - ${project.javadoc.protobufBaseURL} - ../../../../proto-google-cloud-containeranalysis-v1/target/site/apidocs/ - - - - - - - diff --git a/grpc-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/ContainerAnalysisGrpc.java b/grpc-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/ContainerAnalysisGrpc.java deleted file mode 100644 index 8b5c6af7..00000000 --- a/grpc-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/ContainerAnalysisGrpc.java +++ /dev/null @@ -1,702 +0,0 @@ -package com.google.containeranalysis.v1; - -import static io.grpc.MethodDescriptor.generateFullMethodName; -import static io.grpc.stub.ClientCalls.asyncUnaryCall; -import static io.grpc.stub.ClientCalls.blockingUnaryCall; -import static io.grpc.stub.ClientCalls.futureUnaryCall; -import static io.grpc.stub.ServerCalls.asyncUnaryCall; -import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall; - -/** - * - * - *
- * Retrieves analysis results of Cloud components such as Docker container
- * images. The Container Analysis API is an implementation of the
- * [Grafeas](https://grafeas.io) API.
- * Analysis results are stored as a series of occurrences. An `Occurrence`
- * contains information about a specific analysis instance on a resource. An
- * occurrence refers to a `Note`. A note contains details describing the
- * analysis and is generally stored in a separate project, called a `Provider`.
- * Multiple occurrences can refer to the same note.
- * For example, an SSL vulnerability could affect multiple images. In this case,
- * there would be one note for the vulnerability and an occurrence for each
- * image with the vulnerability referring to that note.
- * 
- */ -@javax.annotation.Generated( - value = "by gRPC proto compiler (version 1.10.0)", - comments = "Source: google/devtools/containeranalysis/v1/containeranalysis.proto") -public final class ContainerAnalysisGrpc { - - private ContainerAnalysisGrpc() {} - - public static final String SERVICE_NAME = - "google.devtools.containeranalysis.v1.ContainerAnalysis"; - - // Static method descriptors that strictly reflect the proto. - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getSetIamPolicyMethod()} instead. - public static final io.grpc.MethodDescriptor< - com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy> - METHOD_SET_IAM_POLICY = getSetIamPolicyMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy> - getSetIamPolicyMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy> - getSetIamPolicyMethod() { - return getSetIamPolicyMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy> - getSetIamPolicyMethodHelper() { - io.grpc.MethodDescriptor - getSetIamPolicyMethod; - if ((getSetIamPolicyMethod = ContainerAnalysisGrpc.getSetIamPolicyMethod) == null) { - synchronized (ContainerAnalysisGrpc.class) { - if ((getSetIamPolicyMethod = ContainerAnalysisGrpc.getSetIamPolicyMethod) == null) { - ContainerAnalysisGrpc.getSetIamPolicyMethod = - getSetIamPolicyMethod = - io.grpc.MethodDescriptor - .newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "google.devtools.containeranalysis.v1.ContainerAnalysis", - "SetIamPolicy")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.iam.v1.SetIamPolicyRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.iam.v1.Policy.getDefaultInstance())) - .setSchemaDescriptor( - new ContainerAnalysisMethodDescriptorSupplier("SetIamPolicy")) - .build(); - } - } - } - return getSetIamPolicyMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getGetIamPolicyMethod()} instead. - public static final io.grpc.MethodDescriptor< - com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy> - METHOD_GET_IAM_POLICY = getGetIamPolicyMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy> - getGetIamPolicyMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy> - getGetIamPolicyMethod() { - return getGetIamPolicyMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy> - getGetIamPolicyMethodHelper() { - io.grpc.MethodDescriptor - getGetIamPolicyMethod; - if ((getGetIamPolicyMethod = ContainerAnalysisGrpc.getGetIamPolicyMethod) == null) { - synchronized (ContainerAnalysisGrpc.class) { - if ((getGetIamPolicyMethod = ContainerAnalysisGrpc.getGetIamPolicyMethod) == null) { - ContainerAnalysisGrpc.getGetIamPolicyMethod = - getGetIamPolicyMethod = - io.grpc.MethodDescriptor - .newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "google.devtools.containeranalysis.v1.ContainerAnalysis", - "GetIamPolicy")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.iam.v1.GetIamPolicyRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.iam.v1.Policy.getDefaultInstance())) - .setSchemaDescriptor( - new ContainerAnalysisMethodDescriptorSupplier("GetIamPolicy")) - .build(); - } - } - } - return getGetIamPolicyMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getTestIamPermissionsMethod()} instead. - public static final io.grpc.MethodDescriptor< - com.google.iam.v1.TestIamPermissionsRequest, com.google.iam.v1.TestIamPermissionsResponse> - METHOD_TEST_IAM_PERMISSIONS = getTestIamPermissionsMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - com.google.iam.v1.TestIamPermissionsRequest, com.google.iam.v1.TestIamPermissionsResponse> - getTestIamPermissionsMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - com.google.iam.v1.TestIamPermissionsRequest, com.google.iam.v1.TestIamPermissionsResponse> - getTestIamPermissionsMethod() { - return getTestIamPermissionsMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - com.google.iam.v1.TestIamPermissionsRequest, com.google.iam.v1.TestIamPermissionsResponse> - getTestIamPermissionsMethodHelper() { - io.grpc.MethodDescriptor< - com.google.iam.v1.TestIamPermissionsRequest, - com.google.iam.v1.TestIamPermissionsResponse> - getTestIamPermissionsMethod; - if ((getTestIamPermissionsMethod = ContainerAnalysisGrpc.getTestIamPermissionsMethod) == null) { - synchronized (ContainerAnalysisGrpc.class) { - if ((getTestIamPermissionsMethod = ContainerAnalysisGrpc.getTestIamPermissionsMethod) - == null) { - ContainerAnalysisGrpc.getTestIamPermissionsMethod = - getTestIamPermissionsMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "google.devtools.containeranalysis.v1.ContainerAnalysis", - "TestIamPermissions")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.iam.v1.TestIamPermissionsRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.iam.v1.TestIamPermissionsResponse.getDefaultInstance())) - .setSchemaDescriptor( - new ContainerAnalysisMethodDescriptorSupplier("TestIamPermissions")) - .build(); - } - } - } - return getTestIamPermissionsMethod; - } - - /** Creates a new async stub that supports all call types for the service */ - public static ContainerAnalysisStub newStub(io.grpc.Channel channel) { - return new ContainerAnalysisStub(channel); - } - - /** - * Creates a new blocking-style stub that supports unary and streaming output calls on the service - */ - public static ContainerAnalysisBlockingStub newBlockingStub(io.grpc.Channel channel) { - return new ContainerAnalysisBlockingStub(channel); - } - - /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ - public static ContainerAnalysisFutureStub newFutureStub(io.grpc.Channel channel) { - return new ContainerAnalysisFutureStub(channel); - } - - /** - * - * - *
-   * Retrieves analysis results of Cloud components such as Docker container
-   * images. The Container Analysis API is an implementation of the
-   * [Grafeas](https://grafeas.io) API.
-   * Analysis results are stored as a series of occurrences. An `Occurrence`
-   * contains information about a specific analysis instance on a resource. An
-   * occurrence refers to a `Note`. A note contains details describing the
-   * analysis and is generally stored in a separate project, called a `Provider`.
-   * Multiple occurrences can refer to the same note.
-   * For example, an SSL vulnerability could affect multiple images. In this case,
-   * there would be one note for the vulnerability and an occurrence for each
-   * image with the vulnerability referring to that note.
-   * 
- */ - public abstract static class ContainerAnalysisImplBase implements io.grpc.BindableService { - - /** - * - * - *
-     * Sets the access control policy on the specified note or occurrence.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or an occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public void setIamPolicy( - com.google.iam.v1.SetIamPolicyRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getSetIamPolicyMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Gets the access control policy for a note or an occurrence resource.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public void getIamPolicy( - com.google.iam.v1.GetIamPolicyRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getGetIamPolicyMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Returns the permissions that a caller has on the specified note or
-     * occurrence. Requires list permission on the project (for example,
-     * `containeranalysis.notes.list`).
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public void testIamPermissions( - com.google.iam.v1.TestIamPermissionsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnimplementedUnaryCall(getTestIamPermissionsMethodHelper(), responseObserver); - } - - @java.lang.Override - public final io.grpc.ServerServiceDefinition bindService() { - return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) - .addMethod( - getSetIamPolicyMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy>( - this, METHODID_SET_IAM_POLICY))) - .addMethod( - getGetIamPolicyMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy>( - this, METHODID_GET_IAM_POLICY))) - .addMethod( - getTestIamPermissionsMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.iam.v1.TestIamPermissionsRequest, - com.google.iam.v1.TestIamPermissionsResponse>( - this, METHODID_TEST_IAM_PERMISSIONS))) - .build(); - } - } - - /** - * - * - *
-   * Retrieves analysis results of Cloud components such as Docker container
-   * images. The Container Analysis API is an implementation of the
-   * [Grafeas](https://grafeas.io) API.
-   * Analysis results are stored as a series of occurrences. An `Occurrence`
-   * contains information about a specific analysis instance on a resource. An
-   * occurrence refers to a `Note`. A note contains details describing the
-   * analysis and is generally stored in a separate project, called a `Provider`.
-   * Multiple occurrences can refer to the same note.
-   * For example, an SSL vulnerability could affect multiple images. In this case,
-   * there would be one note for the vulnerability and an occurrence for each
-   * image with the vulnerability referring to that note.
-   * 
- */ - public static final class ContainerAnalysisStub - extends io.grpc.stub.AbstractStub { - private ContainerAnalysisStub(io.grpc.Channel channel) { - super(channel); - } - - private ContainerAnalysisStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected ContainerAnalysisStub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new ContainerAnalysisStub(channel, callOptions); - } - - /** - * - * - *
-     * Sets the access control policy on the specified note or occurrence.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or an occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public void setIamPolicy( - com.google.iam.v1.SetIamPolicyRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getSetIamPolicyMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Gets the access control policy for a note or an occurrence resource.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public void getIamPolicy( - com.google.iam.v1.GetIamPolicyRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getGetIamPolicyMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Returns the permissions that a caller has on the specified note or
-     * occurrence. Requires list permission on the project (for example,
-     * `containeranalysis.notes.list`).
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public void testIamPermissions( - com.google.iam.v1.TestIamPermissionsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnaryCall( - getChannel().newCall(getTestIamPermissionsMethodHelper(), getCallOptions()), - request, - responseObserver); - } - } - - /** - * - * - *
-   * Retrieves analysis results of Cloud components such as Docker container
-   * images. The Container Analysis API is an implementation of the
-   * [Grafeas](https://grafeas.io) API.
-   * Analysis results are stored as a series of occurrences. An `Occurrence`
-   * contains information about a specific analysis instance on a resource. An
-   * occurrence refers to a `Note`. A note contains details describing the
-   * analysis and is generally stored in a separate project, called a `Provider`.
-   * Multiple occurrences can refer to the same note.
-   * For example, an SSL vulnerability could affect multiple images. In this case,
-   * there would be one note for the vulnerability and an occurrence for each
-   * image with the vulnerability referring to that note.
-   * 
- */ - public static final class ContainerAnalysisBlockingStub - extends io.grpc.stub.AbstractStub { - private ContainerAnalysisBlockingStub(io.grpc.Channel channel) { - super(channel); - } - - private ContainerAnalysisBlockingStub( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected ContainerAnalysisBlockingStub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new ContainerAnalysisBlockingStub(channel, callOptions); - } - - /** - * - * - *
-     * Sets the access control policy on the specified note or occurrence.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or an occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public com.google.iam.v1.Policy setIamPolicy(com.google.iam.v1.SetIamPolicyRequest request) { - return blockingUnaryCall( - getChannel(), getSetIamPolicyMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Gets the access control policy for a note or an occurrence resource.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public com.google.iam.v1.Policy getIamPolicy(com.google.iam.v1.GetIamPolicyRequest request) { - return blockingUnaryCall( - getChannel(), getGetIamPolicyMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Returns the permissions that a caller has on the specified note or
-     * occurrence. Requires list permission on the project (for example,
-     * `containeranalysis.notes.list`).
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public com.google.iam.v1.TestIamPermissionsResponse testIamPermissions( - com.google.iam.v1.TestIamPermissionsRequest request) { - return blockingUnaryCall( - getChannel(), getTestIamPermissionsMethodHelper(), getCallOptions(), request); - } - } - - /** - * - * - *
-   * Retrieves analysis results of Cloud components such as Docker container
-   * images. The Container Analysis API is an implementation of the
-   * [Grafeas](https://grafeas.io) API.
-   * Analysis results are stored as a series of occurrences. An `Occurrence`
-   * contains information about a specific analysis instance on a resource. An
-   * occurrence refers to a `Note`. A note contains details describing the
-   * analysis and is generally stored in a separate project, called a `Provider`.
-   * Multiple occurrences can refer to the same note.
-   * For example, an SSL vulnerability could affect multiple images. In this case,
-   * there would be one note for the vulnerability and an occurrence for each
-   * image with the vulnerability referring to that note.
-   * 
- */ - public static final class ContainerAnalysisFutureStub - extends io.grpc.stub.AbstractStub { - private ContainerAnalysisFutureStub(io.grpc.Channel channel) { - super(channel); - } - - private ContainerAnalysisFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected ContainerAnalysisFutureStub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new ContainerAnalysisFutureStub(channel, callOptions); - } - - /** - * - * - *
-     * Sets the access control policy on the specified note or occurrence.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or an occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - setIamPolicy(com.google.iam.v1.SetIamPolicyRequest request) { - return futureUnaryCall( - getChannel().newCall(getSetIamPolicyMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Gets the access control policy for a note or an occurrence resource.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - getIamPolicy(com.google.iam.v1.GetIamPolicyRequest request) { - return futureUnaryCall( - getChannel().newCall(getGetIamPolicyMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Returns the permissions that a caller has on the specified note or
-     * occurrence. Requires list permission on the project (for example,
-     * `containeranalysis.notes.list`).
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - com.google.iam.v1.TestIamPermissionsResponse> - testIamPermissions(com.google.iam.v1.TestIamPermissionsRequest request) { - return futureUnaryCall( - getChannel().newCall(getTestIamPermissionsMethodHelper(), getCallOptions()), request); - } - } - - private static final int METHODID_SET_IAM_POLICY = 0; - private static final int METHODID_GET_IAM_POLICY = 1; - private static final int METHODID_TEST_IAM_PERMISSIONS = 2; - - private static final class MethodHandlers - implements io.grpc.stub.ServerCalls.UnaryMethod, - io.grpc.stub.ServerCalls.ServerStreamingMethod, - io.grpc.stub.ServerCalls.ClientStreamingMethod, - io.grpc.stub.ServerCalls.BidiStreamingMethod { - private final ContainerAnalysisImplBase serviceImpl; - private final int methodId; - - MethodHandlers(ContainerAnalysisImplBase serviceImpl, int methodId) { - this.serviceImpl = serviceImpl; - this.methodId = methodId; - } - - @java.lang.Override - @java.lang.SuppressWarnings("unchecked") - public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { - switch (methodId) { - case METHODID_SET_IAM_POLICY: - serviceImpl.setIamPolicy( - (com.google.iam.v1.SetIamPolicyRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_GET_IAM_POLICY: - serviceImpl.getIamPolicy( - (com.google.iam.v1.GetIamPolicyRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_TEST_IAM_PERMISSIONS: - serviceImpl.testIamPermissions( - (com.google.iam.v1.TestIamPermissionsRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - default: - throw new AssertionError(); - } - } - - @java.lang.Override - @java.lang.SuppressWarnings("unchecked") - public io.grpc.stub.StreamObserver invoke( - io.grpc.stub.StreamObserver responseObserver) { - switch (methodId) { - default: - throw new AssertionError(); - } - } - } - - private abstract static class ContainerAnalysisBaseDescriptorSupplier - implements io.grpc.protobuf.ProtoFileDescriptorSupplier, - io.grpc.protobuf.ProtoServiceDescriptorSupplier { - ContainerAnalysisBaseDescriptorSupplier() {} - - @java.lang.Override - public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { - return com.google.containeranalysis.v1.Containeranalysis.getDescriptor(); - } - - @java.lang.Override - public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { - return getFileDescriptor().findServiceByName("ContainerAnalysis"); - } - } - - private static final class ContainerAnalysisFileDescriptorSupplier - extends ContainerAnalysisBaseDescriptorSupplier { - ContainerAnalysisFileDescriptorSupplier() {} - } - - private static final class ContainerAnalysisMethodDescriptorSupplier - extends ContainerAnalysisBaseDescriptorSupplier - implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { - private final String methodName; - - ContainerAnalysisMethodDescriptorSupplier(String methodName) { - this.methodName = methodName; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { - return getServiceDescriptor().findMethodByName(methodName); - } - } - - private static volatile io.grpc.ServiceDescriptor serviceDescriptor; - - public static io.grpc.ServiceDescriptor getServiceDescriptor() { - io.grpc.ServiceDescriptor result = serviceDescriptor; - if (result == null) { - synchronized (ContainerAnalysisGrpc.class) { - result = serviceDescriptor; - if (result == null) { - serviceDescriptor = - result = - io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) - .setSchemaDescriptor(new ContainerAnalysisFileDescriptorSupplier()) - .addMethod(getSetIamPolicyMethodHelper()) - .addMethod(getGetIamPolicyMethodHelper()) - .addMethod(getTestIamPermissionsMethodHelper()) - .build(); - } - } - } - return result; - } -} diff --git a/grpc-google-cloud-containeranalysis-v1beta1/pom.xml b/grpc-google-cloud-containeranalysis-v1beta1/pom.xml deleted file mode 100644 index 78c013ab..00000000 --- a/grpc-google-cloud-containeranalysis-v1beta1/pom.xml +++ /dev/null @@ -1,52 +0,0 @@ - - 4.0.0 - grpc-google-cloud-containeranalysis-v1beta1 - 0.82.0 - grpc-google-cloud-containeranalysis-v1beta1 - GRPC library for grpc-google-cloud-containeranalysis-v1beta1 - - com.google.api.grpc - google-api-grpc - 0.82.0 - - - - io.grpc - grpc-stub - compile - - - io.grpc - grpc-protobuf - compile - - - com.google.api.grpc - proto-google-cloud-containeranalysis-v1beta1 - compile - - - - - - org.apache.maven.plugins - maven-javadoc-plugin - 3.1.1 - - protected - true - none - true - - - ${project.javadoc.protobufBaseURL} - ../../../../proto-google-cloud-containeranalysis-v1beta1/target/site/apidocs/ - - - - - - - diff --git a/grpc-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ContainerAnalysisV1Beta1Grpc.java b/grpc-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ContainerAnalysisV1Beta1Grpc.java deleted file mode 100644 index b819f720..00000000 --- a/grpc-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ContainerAnalysisV1Beta1Grpc.java +++ /dev/null @@ -1,1108 +0,0 @@ -package com.google.containeranalysis.v1beta1; - -import static io.grpc.MethodDescriptor.generateFullMethodName; -import static io.grpc.stub.ClientCalls.asyncUnaryCall; -import static io.grpc.stub.ClientCalls.blockingUnaryCall; -import static io.grpc.stub.ClientCalls.futureUnaryCall; -import static io.grpc.stub.ServerCalls.asyncUnaryCall; -import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall; - -/** - * - * - *
- * Retrieves analysis results of Cloud components such as Docker container
- * images. The Container Analysis API is an implementation of the
- * [Grafeas](grafeas.io) API.
- * Analysis results are stored as a series of occurrences. An `Occurrence`
- * contains information about a specific analysis instance on a resource. An
- * occurrence refers to a `Note`. A note contains details describing the
- * analysis and is generally stored in a separate project, called a `Provider`.
- * Multiple occurrences can refer to the same note.
- * For example, an SSL vulnerability could affect multiple images. In this case,
- * there would be one note for the vulnerability and an occurrence for each
- * image with the vulnerability referring to that note.
- * 
- */ -@javax.annotation.Generated( - value = "by gRPC proto compiler (version 1.10.0)", - comments = "Source: google/devtools/containeranalysis/v1beta1/containeranalysis.proto") -public final class ContainerAnalysisV1Beta1Grpc { - - private ContainerAnalysisV1Beta1Grpc() {} - - public static final String SERVICE_NAME = - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1"; - - // Static method descriptors that strictly reflect the proto. - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getSetIamPolicyMethod()} instead. - public static final io.grpc.MethodDescriptor< - com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy> - METHOD_SET_IAM_POLICY = getSetIamPolicyMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy> - getSetIamPolicyMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy> - getSetIamPolicyMethod() { - return getSetIamPolicyMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy> - getSetIamPolicyMethodHelper() { - io.grpc.MethodDescriptor - getSetIamPolicyMethod; - if ((getSetIamPolicyMethod = ContainerAnalysisV1Beta1Grpc.getSetIamPolicyMethod) == null) { - synchronized (ContainerAnalysisV1Beta1Grpc.class) { - if ((getSetIamPolicyMethod = ContainerAnalysisV1Beta1Grpc.getSetIamPolicyMethod) == null) { - ContainerAnalysisV1Beta1Grpc.getSetIamPolicyMethod = - getSetIamPolicyMethod = - io.grpc.MethodDescriptor - .newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1", - "SetIamPolicy")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.iam.v1.SetIamPolicyRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.iam.v1.Policy.getDefaultInstance())) - .setSchemaDescriptor( - new ContainerAnalysisV1Beta1MethodDescriptorSupplier("SetIamPolicy")) - .build(); - } - } - } - return getSetIamPolicyMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getGetIamPolicyMethod()} instead. - public static final io.grpc.MethodDescriptor< - com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy> - METHOD_GET_IAM_POLICY = getGetIamPolicyMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy> - getGetIamPolicyMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy> - getGetIamPolicyMethod() { - return getGetIamPolicyMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy> - getGetIamPolicyMethodHelper() { - io.grpc.MethodDescriptor - getGetIamPolicyMethod; - if ((getGetIamPolicyMethod = ContainerAnalysisV1Beta1Grpc.getGetIamPolicyMethod) == null) { - synchronized (ContainerAnalysisV1Beta1Grpc.class) { - if ((getGetIamPolicyMethod = ContainerAnalysisV1Beta1Grpc.getGetIamPolicyMethod) == null) { - ContainerAnalysisV1Beta1Grpc.getGetIamPolicyMethod = - getGetIamPolicyMethod = - io.grpc.MethodDescriptor - .newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1", - "GetIamPolicy")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.iam.v1.GetIamPolicyRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.iam.v1.Policy.getDefaultInstance())) - .setSchemaDescriptor( - new ContainerAnalysisV1Beta1MethodDescriptorSupplier("GetIamPolicy")) - .build(); - } - } - } - return getGetIamPolicyMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getTestIamPermissionsMethod()} instead. - public static final io.grpc.MethodDescriptor< - com.google.iam.v1.TestIamPermissionsRequest, com.google.iam.v1.TestIamPermissionsResponse> - METHOD_TEST_IAM_PERMISSIONS = getTestIamPermissionsMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - com.google.iam.v1.TestIamPermissionsRequest, com.google.iam.v1.TestIamPermissionsResponse> - getTestIamPermissionsMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - com.google.iam.v1.TestIamPermissionsRequest, com.google.iam.v1.TestIamPermissionsResponse> - getTestIamPermissionsMethod() { - return getTestIamPermissionsMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - com.google.iam.v1.TestIamPermissionsRequest, com.google.iam.v1.TestIamPermissionsResponse> - getTestIamPermissionsMethodHelper() { - io.grpc.MethodDescriptor< - com.google.iam.v1.TestIamPermissionsRequest, - com.google.iam.v1.TestIamPermissionsResponse> - getTestIamPermissionsMethod; - if ((getTestIamPermissionsMethod = ContainerAnalysisV1Beta1Grpc.getTestIamPermissionsMethod) - == null) { - synchronized (ContainerAnalysisV1Beta1Grpc.class) { - if ((getTestIamPermissionsMethod = ContainerAnalysisV1Beta1Grpc.getTestIamPermissionsMethod) - == null) { - ContainerAnalysisV1Beta1Grpc.getTestIamPermissionsMethod = - getTestIamPermissionsMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1", - "TestIamPermissions")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.iam.v1.TestIamPermissionsRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.iam.v1.TestIamPermissionsResponse.getDefaultInstance())) - .setSchemaDescriptor( - new ContainerAnalysisV1Beta1MethodDescriptorSupplier( - "TestIamPermissions")) - .build(); - } - } - } - return getTestIamPermissionsMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getGetScanConfigMethod()} instead. - public static final io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.GetScanConfigRequest, - com.google.containeranalysis.v1beta1.ScanConfig> - METHOD_GET_SCAN_CONFIG = getGetScanConfigMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.GetScanConfigRequest, - com.google.containeranalysis.v1beta1.ScanConfig> - getGetScanConfigMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.GetScanConfigRequest, - com.google.containeranalysis.v1beta1.ScanConfig> - getGetScanConfigMethod() { - return getGetScanConfigMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.GetScanConfigRequest, - com.google.containeranalysis.v1beta1.ScanConfig> - getGetScanConfigMethodHelper() { - io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.GetScanConfigRequest, - com.google.containeranalysis.v1beta1.ScanConfig> - getGetScanConfigMethod; - if ((getGetScanConfigMethod = ContainerAnalysisV1Beta1Grpc.getGetScanConfigMethod) == null) { - synchronized (ContainerAnalysisV1Beta1Grpc.class) { - if ((getGetScanConfigMethod = ContainerAnalysisV1Beta1Grpc.getGetScanConfigMethod) - == null) { - ContainerAnalysisV1Beta1Grpc.getGetScanConfigMethod = - getGetScanConfigMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1", - "GetScanConfig")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.containeranalysis.v1beta1.GetScanConfigRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.containeranalysis.v1beta1.ScanConfig.getDefaultInstance())) - .setSchemaDescriptor( - new ContainerAnalysisV1Beta1MethodDescriptorSupplier("GetScanConfig")) - .build(); - } - } - } - return getGetScanConfigMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getListScanConfigsMethod()} instead. - public static final io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.ListScanConfigsRequest, - com.google.containeranalysis.v1beta1.ListScanConfigsResponse> - METHOD_LIST_SCAN_CONFIGS = getListScanConfigsMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.ListScanConfigsRequest, - com.google.containeranalysis.v1beta1.ListScanConfigsResponse> - getListScanConfigsMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.ListScanConfigsRequest, - com.google.containeranalysis.v1beta1.ListScanConfigsResponse> - getListScanConfigsMethod() { - return getListScanConfigsMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.ListScanConfigsRequest, - com.google.containeranalysis.v1beta1.ListScanConfigsResponse> - getListScanConfigsMethodHelper() { - io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.ListScanConfigsRequest, - com.google.containeranalysis.v1beta1.ListScanConfigsResponse> - getListScanConfigsMethod; - if ((getListScanConfigsMethod = ContainerAnalysisV1Beta1Grpc.getListScanConfigsMethod) - == null) { - synchronized (ContainerAnalysisV1Beta1Grpc.class) { - if ((getListScanConfigsMethod = ContainerAnalysisV1Beta1Grpc.getListScanConfigsMethod) - == null) { - ContainerAnalysisV1Beta1Grpc.getListScanConfigsMethod = - getListScanConfigsMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1", - "ListScanConfigs")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.containeranalysis.v1beta1.ListScanConfigsRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.containeranalysis.v1beta1.ListScanConfigsResponse - .getDefaultInstance())) - .setSchemaDescriptor( - new ContainerAnalysisV1Beta1MethodDescriptorSupplier("ListScanConfigs")) - .build(); - } - } - } - return getListScanConfigsMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getUpdateScanConfigMethod()} instead. - public static final io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest, - com.google.containeranalysis.v1beta1.ScanConfig> - METHOD_UPDATE_SCAN_CONFIG = getUpdateScanConfigMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest, - com.google.containeranalysis.v1beta1.ScanConfig> - getUpdateScanConfigMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest, - com.google.containeranalysis.v1beta1.ScanConfig> - getUpdateScanConfigMethod() { - return getUpdateScanConfigMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest, - com.google.containeranalysis.v1beta1.ScanConfig> - getUpdateScanConfigMethodHelper() { - io.grpc.MethodDescriptor< - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest, - com.google.containeranalysis.v1beta1.ScanConfig> - getUpdateScanConfigMethod; - if ((getUpdateScanConfigMethod = ContainerAnalysisV1Beta1Grpc.getUpdateScanConfigMethod) - == null) { - synchronized (ContainerAnalysisV1Beta1Grpc.class) { - if ((getUpdateScanConfigMethod = ContainerAnalysisV1Beta1Grpc.getUpdateScanConfigMethod) - == null) { - ContainerAnalysisV1Beta1Grpc.getUpdateScanConfigMethod = - getUpdateScanConfigMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "google.devtools.containeranalysis.v1beta1.ContainerAnalysisV1Beta1", - "UpdateScanConfig")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.containeranalysis.v1beta1.ScanConfig.getDefaultInstance())) - .setSchemaDescriptor( - new ContainerAnalysisV1Beta1MethodDescriptorSupplier("UpdateScanConfig")) - .build(); - } - } - } - return getUpdateScanConfigMethod; - } - - /** Creates a new async stub that supports all call types for the service */ - public static ContainerAnalysisV1Beta1Stub newStub(io.grpc.Channel channel) { - return new ContainerAnalysisV1Beta1Stub(channel); - } - - /** - * Creates a new blocking-style stub that supports unary and streaming output calls on the service - */ - public static ContainerAnalysisV1Beta1BlockingStub newBlockingStub(io.grpc.Channel channel) { - return new ContainerAnalysisV1Beta1BlockingStub(channel); - } - - /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ - public static ContainerAnalysisV1Beta1FutureStub newFutureStub(io.grpc.Channel channel) { - return new ContainerAnalysisV1Beta1FutureStub(channel); - } - - /** - * - * - *
-   * Retrieves analysis results of Cloud components such as Docker container
-   * images. The Container Analysis API is an implementation of the
-   * [Grafeas](grafeas.io) API.
-   * Analysis results are stored as a series of occurrences. An `Occurrence`
-   * contains information about a specific analysis instance on a resource. An
-   * occurrence refers to a `Note`. A note contains details describing the
-   * analysis and is generally stored in a separate project, called a `Provider`.
-   * Multiple occurrences can refer to the same note.
-   * For example, an SSL vulnerability could affect multiple images. In this case,
-   * there would be one note for the vulnerability and an occurrence for each
-   * image with the vulnerability referring to that note.
-   * 
- */ - public abstract static class ContainerAnalysisV1Beta1ImplBase implements io.grpc.BindableService { - - /** - * - * - *
-     * Sets the access control policy on the specified note or occurrence.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or an occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public void setIamPolicy( - com.google.iam.v1.SetIamPolicyRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getSetIamPolicyMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Gets the access control policy for a note or an occurrence resource.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public void getIamPolicy( - com.google.iam.v1.GetIamPolicyRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getGetIamPolicyMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Returns the permissions that a caller has on the specified note or
-     * occurrence. Requires list permission on the project (for example,
-     * `containeranalysis.notes.list`).
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public void testIamPermissions( - com.google.iam.v1.TestIamPermissionsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnimplementedUnaryCall(getTestIamPermissionsMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Gets the specified scan configuration.
-     * 
- */ - public void getScanConfig( - com.google.containeranalysis.v1beta1.GetScanConfigRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnimplementedUnaryCall(getGetScanConfigMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Lists scan configurations for the specified project.
-     * 
- */ - public void listScanConfigs( - com.google.containeranalysis.v1beta1.ListScanConfigsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnimplementedUnaryCall(getListScanConfigsMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Updates the specified scan configuration.
-     * 
- */ - public void updateScanConfig( - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnimplementedUnaryCall(getUpdateScanConfigMethodHelper(), responseObserver); - } - - @java.lang.Override - public final io.grpc.ServerServiceDefinition bindService() { - return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) - .addMethod( - getSetIamPolicyMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy>( - this, METHODID_SET_IAM_POLICY))) - .addMethod( - getGetIamPolicyMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy>( - this, METHODID_GET_IAM_POLICY))) - .addMethod( - getTestIamPermissionsMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.iam.v1.TestIamPermissionsRequest, - com.google.iam.v1.TestIamPermissionsResponse>( - this, METHODID_TEST_IAM_PERMISSIONS))) - .addMethod( - getGetScanConfigMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.containeranalysis.v1beta1.GetScanConfigRequest, - com.google.containeranalysis.v1beta1.ScanConfig>( - this, METHODID_GET_SCAN_CONFIG))) - .addMethod( - getListScanConfigsMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.containeranalysis.v1beta1.ListScanConfigsRequest, - com.google.containeranalysis.v1beta1.ListScanConfigsResponse>( - this, METHODID_LIST_SCAN_CONFIGS))) - .addMethod( - getUpdateScanConfigMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest, - com.google.containeranalysis.v1beta1.ScanConfig>( - this, METHODID_UPDATE_SCAN_CONFIG))) - .build(); - } - } - - /** - * - * - *
-   * Retrieves analysis results of Cloud components such as Docker container
-   * images. The Container Analysis API is an implementation of the
-   * [Grafeas](grafeas.io) API.
-   * Analysis results are stored as a series of occurrences. An `Occurrence`
-   * contains information about a specific analysis instance on a resource. An
-   * occurrence refers to a `Note`. A note contains details describing the
-   * analysis and is generally stored in a separate project, called a `Provider`.
-   * Multiple occurrences can refer to the same note.
-   * For example, an SSL vulnerability could affect multiple images. In this case,
-   * there would be one note for the vulnerability and an occurrence for each
-   * image with the vulnerability referring to that note.
-   * 
- */ - public static final class ContainerAnalysisV1Beta1Stub - extends io.grpc.stub.AbstractStub { - private ContainerAnalysisV1Beta1Stub(io.grpc.Channel channel) { - super(channel); - } - - private ContainerAnalysisV1Beta1Stub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected ContainerAnalysisV1Beta1Stub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new ContainerAnalysisV1Beta1Stub(channel, callOptions); - } - - /** - * - * - *
-     * Sets the access control policy on the specified note or occurrence.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or an occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public void setIamPolicy( - com.google.iam.v1.SetIamPolicyRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getSetIamPolicyMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Gets the access control policy for a note or an occurrence resource.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public void getIamPolicy( - com.google.iam.v1.GetIamPolicyRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getGetIamPolicyMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Returns the permissions that a caller has on the specified note or
-     * occurrence. Requires list permission on the project (for example,
-     * `containeranalysis.notes.list`).
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public void testIamPermissions( - com.google.iam.v1.TestIamPermissionsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnaryCall( - getChannel().newCall(getTestIamPermissionsMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Gets the specified scan configuration.
-     * 
- */ - public void getScanConfig( - com.google.containeranalysis.v1beta1.GetScanConfigRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnaryCall( - getChannel().newCall(getGetScanConfigMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Lists scan configurations for the specified project.
-     * 
- */ - public void listScanConfigs( - com.google.containeranalysis.v1beta1.ListScanConfigsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnaryCall( - getChannel().newCall(getListScanConfigsMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Updates the specified scan configuration.
-     * 
- */ - public void updateScanConfig( - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnaryCall( - getChannel().newCall(getUpdateScanConfigMethodHelper(), getCallOptions()), - request, - responseObserver); - } - } - - /** - * - * - *
-   * Retrieves analysis results of Cloud components such as Docker container
-   * images. The Container Analysis API is an implementation of the
-   * [Grafeas](grafeas.io) API.
-   * Analysis results are stored as a series of occurrences. An `Occurrence`
-   * contains information about a specific analysis instance on a resource. An
-   * occurrence refers to a `Note`. A note contains details describing the
-   * analysis and is generally stored in a separate project, called a `Provider`.
-   * Multiple occurrences can refer to the same note.
-   * For example, an SSL vulnerability could affect multiple images. In this case,
-   * there would be one note for the vulnerability and an occurrence for each
-   * image with the vulnerability referring to that note.
-   * 
- */ - public static final class ContainerAnalysisV1Beta1BlockingStub - extends io.grpc.stub.AbstractStub { - private ContainerAnalysisV1Beta1BlockingStub(io.grpc.Channel channel) { - super(channel); - } - - private ContainerAnalysisV1Beta1BlockingStub( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected ContainerAnalysisV1Beta1BlockingStub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new ContainerAnalysisV1Beta1BlockingStub(channel, callOptions); - } - - /** - * - * - *
-     * Sets the access control policy on the specified note or occurrence.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or an occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public com.google.iam.v1.Policy setIamPolicy(com.google.iam.v1.SetIamPolicyRequest request) { - return blockingUnaryCall( - getChannel(), getSetIamPolicyMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Gets the access control policy for a note or an occurrence resource.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public com.google.iam.v1.Policy getIamPolicy(com.google.iam.v1.GetIamPolicyRequest request) { - return blockingUnaryCall( - getChannel(), getGetIamPolicyMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Returns the permissions that a caller has on the specified note or
-     * occurrence. Requires list permission on the project (for example,
-     * `containeranalysis.notes.list`).
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public com.google.iam.v1.TestIamPermissionsResponse testIamPermissions( - com.google.iam.v1.TestIamPermissionsRequest request) { - return blockingUnaryCall( - getChannel(), getTestIamPermissionsMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Gets the specified scan configuration.
-     * 
- */ - public com.google.containeranalysis.v1beta1.ScanConfig getScanConfig( - com.google.containeranalysis.v1beta1.GetScanConfigRequest request) { - return blockingUnaryCall( - getChannel(), getGetScanConfigMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Lists scan configurations for the specified project.
-     * 
- */ - public com.google.containeranalysis.v1beta1.ListScanConfigsResponse listScanConfigs( - com.google.containeranalysis.v1beta1.ListScanConfigsRequest request) { - return blockingUnaryCall( - getChannel(), getListScanConfigsMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Updates the specified scan configuration.
-     * 
- */ - public com.google.containeranalysis.v1beta1.ScanConfig updateScanConfig( - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest request) { - return blockingUnaryCall( - getChannel(), getUpdateScanConfigMethodHelper(), getCallOptions(), request); - } - } - - /** - * - * - *
-   * Retrieves analysis results of Cloud components such as Docker container
-   * images. The Container Analysis API is an implementation of the
-   * [Grafeas](grafeas.io) API.
-   * Analysis results are stored as a series of occurrences. An `Occurrence`
-   * contains information about a specific analysis instance on a resource. An
-   * occurrence refers to a `Note`. A note contains details describing the
-   * analysis and is generally stored in a separate project, called a `Provider`.
-   * Multiple occurrences can refer to the same note.
-   * For example, an SSL vulnerability could affect multiple images. In this case,
-   * there would be one note for the vulnerability and an occurrence for each
-   * image with the vulnerability referring to that note.
-   * 
- */ - public static final class ContainerAnalysisV1Beta1FutureStub - extends io.grpc.stub.AbstractStub { - private ContainerAnalysisV1Beta1FutureStub(io.grpc.Channel channel) { - super(channel); - } - - private ContainerAnalysisV1Beta1FutureStub( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected ContainerAnalysisV1Beta1FutureStub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new ContainerAnalysisV1Beta1FutureStub(channel, callOptions); - } - - /** - * - * - *
-     * Sets the access control policy on the specified note or occurrence.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or an occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - setIamPolicy(com.google.iam.v1.SetIamPolicyRequest request) { - return futureUnaryCall( - getChannel().newCall(getSetIamPolicyMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Gets the access control policy for a note or an occurrence resource.
-     * Requires `containeranalysis.notes.setIamPolicy` or
-     * `containeranalysis.occurrences.setIamPolicy` permission if the resource is
-     * a note or occurrence, respectively.
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - getIamPolicy(com.google.iam.v1.GetIamPolicyRequest request) { - return futureUnaryCall( - getChannel().newCall(getGetIamPolicyMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Returns the permissions that a caller has on the specified note or
-     * occurrence. Requires list permission on the project (for example,
-     * `containeranalysis.notes.list`).
-     * The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
-     * notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
-     * occurrences.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - com.google.iam.v1.TestIamPermissionsResponse> - testIamPermissions(com.google.iam.v1.TestIamPermissionsRequest request) { - return futureUnaryCall( - getChannel().newCall(getTestIamPermissionsMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Gets the specified scan configuration.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - com.google.containeranalysis.v1beta1.ScanConfig> - getScanConfig(com.google.containeranalysis.v1beta1.GetScanConfigRequest request) { - return futureUnaryCall( - getChannel().newCall(getGetScanConfigMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Lists scan configurations for the specified project.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - com.google.containeranalysis.v1beta1.ListScanConfigsResponse> - listScanConfigs(com.google.containeranalysis.v1beta1.ListScanConfigsRequest request) { - return futureUnaryCall( - getChannel().newCall(getListScanConfigsMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Updates the specified scan configuration.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - com.google.containeranalysis.v1beta1.ScanConfig> - updateScanConfig(com.google.containeranalysis.v1beta1.UpdateScanConfigRequest request) { - return futureUnaryCall( - getChannel().newCall(getUpdateScanConfigMethodHelper(), getCallOptions()), request); - } - } - - private static final int METHODID_SET_IAM_POLICY = 0; - private static final int METHODID_GET_IAM_POLICY = 1; - private static final int METHODID_TEST_IAM_PERMISSIONS = 2; - private static final int METHODID_GET_SCAN_CONFIG = 3; - private static final int METHODID_LIST_SCAN_CONFIGS = 4; - private static final int METHODID_UPDATE_SCAN_CONFIG = 5; - - private static final class MethodHandlers - implements io.grpc.stub.ServerCalls.UnaryMethod, - io.grpc.stub.ServerCalls.ServerStreamingMethod, - io.grpc.stub.ServerCalls.ClientStreamingMethod, - io.grpc.stub.ServerCalls.BidiStreamingMethod { - private final ContainerAnalysisV1Beta1ImplBase serviceImpl; - private final int methodId; - - MethodHandlers(ContainerAnalysisV1Beta1ImplBase serviceImpl, int methodId) { - this.serviceImpl = serviceImpl; - this.methodId = methodId; - } - - @java.lang.Override - @java.lang.SuppressWarnings("unchecked") - public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { - switch (methodId) { - case METHODID_SET_IAM_POLICY: - serviceImpl.setIamPolicy( - (com.google.iam.v1.SetIamPolicyRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_GET_IAM_POLICY: - serviceImpl.getIamPolicy( - (com.google.iam.v1.GetIamPolicyRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_TEST_IAM_PERMISSIONS: - serviceImpl.testIamPermissions( - (com.google.iam.v1.TestIamPermissionsRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - case METHODID_GET_SCAN_CONFIG: - serviceImpl.getScanConfig( - (com.google.containeranalysis.v1beta1.GetScanConfigRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - case METHODID_LIST_SCAN_CONFIGS: - serviceImpl.listScanConfigs( - (com.google.containeranalysis.v1beta1.ListScanConfigsRequest) request, - (io.grpc.stub.StreamObserver< - com.google.containeranalysis.v1beta1.ListScanConfigsResponse>) - responseObserver); - break; - case METHODID_UPDATE_SCAN_CONFIG: - serviceImpl.updateScanConfig( - (com.google.containeranalysis.v1beta1.UpdateScanConfigRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - default: - throw new AssertionError(); - } - } - - @java.lang.Override - @java.lang.SuppressWarnings("unchecked") - public io.grpc.stub.StreamObserver invoke( - io.grpc.stub.StreamObserver responseObserver) { - switch (methodId) { - default: - throw new AssertionError(); - } - } - } - - private abstract static class ContainerAnalysisV1Beta1BaseDescriptorSupplier - implements io.grpc.protobuf.ProtoFileDescriptorSupplier, - io.grpc.protobuf.ProtoServiceDescriptorSupplier { - ContainerAnalysisV1Beta1BaseDescriptorSupplier() {} - - @java.lang.Override - public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { - return com.google.containeranalysis.v1beta1.Containeranalysis.getDescriptor(); - } - - @java.lang.Override - public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { - return getFileDescriptor().findServiceByName("ContainerAnalysisV1Beta1"); - } - } - - private static final class ContainerAnalysisV1Beta1FileDescriptorSupplier - extends ContainerAnalysisV1Beta1BaseDescriptorSupplier { - ContainerAnalysisV1Beta1FileDescriptorSupplier() {} - } - - private static final class ContainerAnalysisV1Beta1MethodDescriptorSupplier - extends ContainerAnalysisV1Beta1BaseDescriptorSupplier - implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { - private final String methodName; - - ContainerAnalysisV1Beta1MethodDescriptorSupplier(String methodName) { - this.methodName = methodName; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { - return getServiceDescriptor().findMethodByName(methodName); - } - } - - private static volatile io.grpc.ServiceDescriptor serviceDescriptor; - - public static io.grpc.ServiceDescriptor getServiceDescriptor() { - io.grpc.ServiceDescriptor result = serviceDescriptor; - if (result == null) { - synchronized (ContainerAnalysisV1Beta1Grpc.class) { - result = serviceDescriptor; - if (result == null) { - serviceDescriptor = - result = - io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) - .setSchemaDescriptor(new ContainerAnalysisV1Beta1FileDescriptorSupplier()) - .addMethod(getSetIamPolicyMethodHelper()) - .addMethod(getGetIamPolicyMethodHelper()) - .addMethod(getTestIamPermissionsMethodHelper()) - .addMethod(getGetScanConfigMethodHelper()) - .addMethod(getListScanConfigsMethodHelper()) - .addMethod(getUpdateScanConfigMethodHelper()) - .build(); - } - } - } - return result; - } -} diff --git a/grpc-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GrafeasV1Beta1Grpc.java b/grpc-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GrafeasV1Beta1Grpc.java deleted file mode 100644 index 6720081d..00000000 --- a/grpc-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GrafeasV1Beta1Grpc.java +++ /dev/null @@ -1,2104 +0,0 @@ -package io.grafeas.v1beta1; - -import static io.grpc.MethodDescriptor.generateFullMethodName; -import static io.grpc.stub.ClientCalls.asyncUnaryCall; -import static io.grpc.stub.ClientCalls.blockingUnaryCall; -import static io.grpc.stub.ClientCalls.futureUnaryCall; -import static io.grpc.stub.ServerCalls.asyncUnaryCall; -import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall; - -/** - * - * - *
- * [Grafeas](grafeas.io) API.
- * Retrieves analysis results of Cloud components such as Docker container
- * images.
- * Analysis results are stored as a series of occurrences. An `Occurrence`
- * contains information about a specific analysis instance on a resource. An
- * occurrence refers to a `Note`. A note contains details describing the
- * analysis and is generally stored in a separate project, called a `Provider`.
- * Multiple occurrences can refer to the same note.
- * For example, an SSL vulnerability could affect multiple images. In this case,
- * there would be one note for the vulnerability and an occurrence for each
- * image with the vulnerability referring to that note.
- * 
- */ -@javax.annotation.Generated( - value = "by gRPC proto compiler (version 1.10.0)", - comments = "Source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto") -public final class GrafeasV1Beta1Grpc { - - private GrafeasV1Beta1Grpc() {} - - public static final String SERVICE_NAME = "grafeas.v1beta1.GrafeasV1Beta1"; - - // Static method descriptors that strictly reflect the proto. - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getGetOccurrenceMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - METHOD_GET_OCCURRENCE = getGetOccurrenceMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - getGetOccurrenceMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - getGetOccurrenceMethod() { - return getGetOccurrenceMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - getGetOccurrenceMethodHelper() { - io.grpc.MethodDescriptor - getGetOccurrenceMethod; - if ((getGetOccurrenceMethod = GrafeasV1Beta1Grpc.getGetOccurrenceMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getGetOccurrenceMethod = GrafeasV1Beta1Grpc.getGetOccurrenceMethod) == null) { - GrafeasV1Beta1Grpc.getGetOccurrenceMethod = - getGetOccurrenceMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName("grafeas.v1beta1.GrafeasV1Beta1", "GetOccurrence")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.GetOccurrenceRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.Occurrence.getDefaultInstance())) - .setSchemaDescriptor( - new GrafeasV1Beta1MethodDescriptorSupplier("GetOccurrence")) - .build(); - } - } - } - return getGetOccurrenceMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getListOccurrencesMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListOccurrencesRequest, io.grafeas.v1beta1.ListOccurrencesResponse> - METHOD_LIST_OCCURRENCES = getListOccurrencesMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListOccurrencesRequest, io.grafeas.v1beta1.ListOccurrencesResponse> - getListOccurrencesMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListOccurrencesRequest, io.grafeas.v1beta1.ListOccurrencesResponse> - getListOccurrencesMethod() { - return getListOccurrencesMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListOccurrencesRequest, io.grafeas.v1beta1.ListOccurrencesResponse> - getListOccurrencesMethodHelper() { - io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListOccurrencesRequest, io.grafeas.v1beta1.ListOccurrencesResponse> - getListOccurrencesMethod; - if ((getListOccurrencesMethod = GrafeasV1Beta1Grpc.getListOccurrencesMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getListOccurrencesMethod = GrafeasV1Beta1Grpc.getListOccurrencesMethod) == null) { - GrafeasV1Beta1Grpc.getListOccurrencesMethod = - getListOccurrencesMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "grafeas.v1beta1.GrafeasV1Beta1", "ListOccurrences")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.ListOccurrencesRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.ListOccurrencesResponse.getDefaultInstance())) - .setSchemaDescriptor( - new GrafeasV1Beta1MethodDescriptorSupplier("ListOccurrences")) - .build(); - } - } - } - return getListOccurrencesMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getDeleteOccurrenceMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.DeleteOccurrenceRequest, com.google.protobuf.Empty> - METHOD_DELETE_OCCURRENCE = getDeleteOccurrenceMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.DeleteOccurrenceRequest, com.google.protobuf.Empty> - getDeleteOccurrenceMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.DeleteOccurrenceRequest, com.google.protobuf.Empty> - getDeleteOccurrenceMethod() { - return getDeleteOccurrenceMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.DeleteOccurrenceRequest, com.google.protobuf.Empty> - getDeleteOccurrenceMethodHelper() { - io.grpc.MethodDescriptor - getDeleteOccurrenceMethod; - if ((getDeleteOccurrenceMethod = GrafeasV1Beta1Grpc.getDeleteOccurrenceMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getDeleteOccurrenceMethod = GrafeasV1Beta1Grpc.getDeleteOccurrenceMethod) == null) { - GrafeasV1Beta1Grpc.getDeleteOccurrenceMethod = - getDeleteOccurrenceMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "grafeas.v1beta1.GrafeasV1Beta1", "DeleteOccurrence")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.DeleteOccurrenceRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.protobuf.Empty.getDefaultInstance())) - .setSchemaDescriptor( - new GrafeasV1Beta1MethodDescriptorSupplier("DeleteOccurrence")) - .build(); - } - } - } - return getDeleteOccurrenceMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getCreateOccurrenceMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.CreateOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - METHOD_CREATE_OCCURRENCE = getCreateOccurrenceMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.CreateOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - getCreateOccurrenceMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.CreateOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - getCreateOccurrenceMethod() { - return getCreateOccurrenceMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.CreateOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - getCreateOccurrenceMethodHelper() { - io.grpc.MethodDescriptor< - io.grafeas.v1beta1.CreateOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - getCreateOccurrenceMethod; - if ((getCreateOccurrenceMethod = GrafeasV1Beta1Grpc.getCreateOccurrenceMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getCreateOccurrenceMethod = GrafeasV1Beta1Grpc.getCreateOccurrenceMethod) == null) { - GrafeasV1Beta1Grpc.getCreateOccurrenceMethod = - getCreateOccurrenceMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "grafeas.v1beta1.GrafeasV1Beta1", "CreateOccurrence")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.CreateOccurrenceRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.Occurrence.getDefaultInstance())) - .setSchemaDescriptor( - new GrafeasV1Beta1MethodDescriptorSupplier("CreateOccurrence")) - .build(); - } - } - } - return getCreateOccurrenceMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getBatchCreateOccurrencesMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.BatchCreateOccurrencesRequest, - io.grafeas.v1beta1.BatchCreateOccurrencesResponse> - METHOD_BATCH_CREATE_OCCURRENCES = getBatchCreateOccurrencesMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.BatchCreateOccurrencesRequest, - io.grafeas.v1beta1.BatchCreateOccurrencesResponse> - getBatchCreateOccurrencesMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.BatchCreateOccurrencesRequest, - io.grafeas.v1beta1.BatchCreateOccurrencesResponse> - getBatchCreateOccurrencesMethod() { - return getBatchCreateOccurrencesMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.BatchCreateOccurrencesRequest, - io.grafeas.v1beta1.BatchCreateOccurrencesResponse> - getBatchCreateOccurrencesMethodHelper() { - io.grpc.MethodDescriptor< - io.grafeas.v1beta1.BatchCreateOccurrencesRequest, - io.grafeas.v1beta1.BatchCreateOccurrencesResponse> - getBatchCreateOccurrencesMethod; - if ((getBatchCreateOccurrencesMethod = GrafeasV1Beta1Grpc.getBatchCreateOccurrencesMethod) - == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getBatchCreateOccurrencesMethod = GrafeasV1Beta1Grpc.getBatchCreateOccurrencesMethod) - == null) { - GrafeasV1Beta1Grpc.getBatchCreateOccurrencesMethod = - getBatchCreateOccurrencesMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "grafeas.v1beta1.GrafeasV1Beta1", "BatchCreateOccurrences")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.BatchCreateOccurrencesRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.BatchCreateOccurrencesResponse - .getDefaultInstance())) - .setSchemaDescriptor( - new GrafeasV1Beta1MethodDescriptorSupplier("BatchCreateOccurrences")) - .build(); - } - } - } - return getBatchCreateOccurrencesMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getUpdateOccurrenceMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.UpdateOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - METHOD_UPDATE_OCCURRENCE = getUpdateOccurrenceMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.UpdateOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - getUpdateOccurrenceMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.UpdateOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - getUpdateOccurrenceMethod() { - return getUpdateOccurrenceMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.UpdateOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - getUpdateOccurrenceMethodHelper() { - io.grpc.MethodDescriptor< - io.grafeas.v1beta1.UpdateOccurrenceRequest, io.grafeas.v1beta1.Occurrence> - getUpdateOccurrenceMethod; - if ((getUpdateOccurrenceMethod = GrafeasV1Beta1Grpc.getUpdateOccurrenceMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getUpdateOccurrenceMethod = GrafeasV1Beta1Grpc.getUpdateOccurrenceMethod) == null) { - GrafeasV1Beta1Grpc.getUpdateOccurrenceMethod = - getUpdateOccurrenceMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "grafeas.v1beta1.GrafeasV1Beta1", "UpdateOccurrence")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.UpdateOccurrenceRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.Occurrence.getDefaultInstance())) - .setSchemaDescriptor( - new GrafeasV1Beta1MethodDescriptorSupplier("UpdateOccurrence")) - .build(); - } - } - } - return getUpdateOccurrenceMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getGetOccurrenceNoteMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetOccurrenceNoteRequest, io.grafeas.v1beta1.Note> - METHOD_GET_OCCURRENCE_NOTE = getGetOccurrenceNoteMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetOccurrenceNoteRequest, io.grafeas.v1beta1.Note> - getGetOccurrenceNoteMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetOccurrenceNoteRequest, io.grafeas.v1beta1.Note> - getGetOccurrenceNoteMethod() { - return getGetOccurrenceNoteMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetOccurrenceNoteRequest, io.grafeas.v1beta1.Note> - getGetOccurrenceNoteMethodHelper() { - io.grpc.MethodDescriptor - getGetOccurrenceNoteMethod; - if ((getGetOccurrenceNoteMethod = GrafeasV1Beta1Grpc.getGetOccurrenceNoteMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getGetOccurrenceNoteMethod = GrafeasV1Beta1Grpc.getGetOccurrenceNoteMethod) == null) { - GrafeasV1Beta1Grpc.getGetOccurrenceNoteMethod = - getGetOccurrenceNoteMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "grafeas.v1beta1.GrafeasV1Beta1", "GetOccurrenceNote")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.GetOccurrenceNoteRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.Note.getDefaultInstance())) - .setSchemaDescriptor( - new GrafeasV1Beta1MethodDescriptorSupplier("GetOccurrenceNote")) - .build(); - } - } - } - return getGetOccurrenceNoteMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getGetNoteMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetNoteRequest, io.grafeas.v1beta1.Note> - METHOD_GET_NOTE = getGetNoteMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetNoteRequest, io.grafeas.v1beta1.Note> - getGetNoteMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor - getGetNoteMethod() { - return getGetNoteMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetNoteRequest, io.grafeas.v1beta1.Note> - getGetNoteMethodHelper() { - io.grpc.MethodDescriptor - getGetNoteMethod; - if ((getGetNoteMethod = GrafeasV1Beta1Grpc.getGetNoteMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getGetNoteMethod = GrafeasV1Beta1Grpc.getGetNoteMethod) == null) { - GrafeasV1Beta1Grpc.getGetNoteMethod = - getGetNoteMethod = - io.grpc.MethodDescriptor - .newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName("grafeas.v1beta1.GrafeasV1Beta1", "GetNote")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.GetNoteRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.Note.getDefaultInstance())) - .setSchemaDescriptor(new GrafeasV1Beta1MethodDescriptorSupplier("GetNote")) - .build(); - } - } - } - return getGetNoteMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getListNotesMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListNotesRequest, io.grafeas.v1beta1.ListNotesResponse> - METHOD_LIST_NOTES = getListNotesMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListNotesRequest, io.grafeas.v1beta1.ListNotesResponse> - getListNotesMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListNotesRequest, io.grafeas.v1beta1.ListNotesResponse> - getListNotesMethod() { - return getListNotesMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListNotesRequest, io.grafeas.v1beta1.ListNotesResponse> - getListNotesMethodHelper() { - io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListNotesRequest, io.grafeas.v1beta1.ListNotesResponse> - getListNotesMethod; - if ((getListNotesMethod = GrafeasV1Beta1Grpc.getListNotesMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getListNotesMethod = GrafeasV1Beta1Grpc.getListNotesMethod) == null) { - GrafeasV1Beta1Grpc.getListNotesMethod = - getListNotesMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName("grafeas.v1beta1.GrafeasV1Beta1", "ListNotes")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.ListNotesRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.ListNotesResponse.getDefaultInstance())) - .setSchemaDescriptor(new GrafeasV1Beta1MethodDescriptorSupplier("ListNotes")) - .build(); - } - } - } - return getListNotesMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getDeleteNoteMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.DeleteNoteRequest, com.google.protobuf.Empty> - METHOD_DELETE_NOTE = getDeleteNoteMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.DeleteNoteRequest, com.google.protobuf.Empty> - getDeleteNoteMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.DeleteNoteRequest, com.google.protobuf.Empty> - getDeleteNoteMethod() { - return getDeleteNoteMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.DeleteNoteRequest, com.google.protobuf.Empty> - getDeleteNoteMethodHelper() { - io.grpc.MethodDescriptor - getDeleteNoteMethod; - if ((getDeleteNoteMethod = GrafeasV1Beta1Grpc.getDeleteNoteMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getDeleteNoteMethod = GrafeasV1Beta1Grpc.getDeleteNoteMethod) == null) { - GrafeasV1Beta1Grpc.getDeleteNoteMethod = - getDeleteNoteMethod = - io.grpc.MethodDescriptor - .newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName("grafeas.v1beta1.GrafeasV1Beta1", "DeleteNote")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.DeleteNoteRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.protobuf.Empty.getDefaultInstance())) - .setSchemaDescriptor(new GrafeasV1Beta1MethodDescriptorSupplier("DeleteNote")) - .build(); - } - } - } - return getDeleteNoteMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getCreateNoteMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.CreateNoteRequest, io.grafeas.v1beta1.Note> - METHOD_CREATE_NOTE = getCreateNoteMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.CreateNoteRequest, io.grafeas.v1beta1.Note> - getCreateNoteMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.CreateNoteRequest, io.grafeas.v1beta1.Note> - getCreateNoteMethod() { - return getCreateNoteMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.CreateNoteRequest, io.grafeas.v1beta1.Note> - getCreateNoteMethodHelper() { - io.grpc.MethodDescriptor - getCreateNoteMethod; - if ((getCreateNoteMethod = GrafeasV1Beta1Grpc.getCreateNoteMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getCreateNoteMethod = GrafeasV1Beta1Grpc.getCreateNoteMethod) == null) { - GrafeasV1Beta1Grpc.getCreateNoteMethod = - getCreateNoteMethod = - io.grpc.MethodDescriptor - .newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName("grafeas.v1beta1.GrafeasV1Beta1", "CreateNote")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.CreateNoteRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.Note.getDefaultInstance())) - .setSchemaDescriptor(new GrafeasV1Beta1MethodDescriptorSupplier("CreateNote")) - .build(); - } - } - } - return getCreateNoteMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getBatchCreateNotesMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.BatchCreateNotesRequest, io.grafeas.v1beta1.BatchCreateNotesResponse> - METHOD_BATCH_CREATE_NOTES = getBatchCreateNotesMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.BatchCreateNotesRequest, io.grafeas.v1beta1.BatchCreateNotesResponse> - getBatchCreateNotesMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.BatchCreateNotesRequest, io.grafeas.v1beta1.BatchCreateNotesResponse> - getBatchCreateNotesMethod() { - return getBatchCreateNotesMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.BatchCreateNotesRequest, io.grafeas.v1beta1.BatchCreateNotesResponse> - getBatchCreateNotesMethodHelper() { - io.grpc.MethodDescriptor< - io.grafeas.v1beta1.BatchCreateNotesRequest, io.grafeas.v1beta1.BatchCreateNotesResponse> - getBatchCreateNotesMethod; - if ((getBatchCreateNotesMethod = GrafeasV1Beta1Grpc.getBatchCreateNotesMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getBatchCreateNotesMethod = GrafeasV1Beta1Grpc.getBatchCreateNotesMethod) == null) { - GrafeasV1Beta1Grpc.getBatchCreateNotesMethod = - getBatchCreateNotesMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "grafeas.v1beta1.GrafeasV1Beta1", "BatchCreateNotes")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.BatchCreateNotesRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.BatchCreateNotesResponse.getDefaultInstance())) - .setSchemaDescriptor( - new GrafeasV1Beta1MethodDescriptorSupplier("BatchCreateNotes")) - .build(); - } - } - } - return getBatchCreateNotesMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getUpdateNoteMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.UpdateNoteRequest, io.grafeas.v1beta1.Note> - METHOD_UPDATE_NOTE = getUpdateNoteMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.UpdateNoteRequest, io.grafeas.v1beta1.Note> - getUpdateNoteMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.UpdateNoteRequest, io.grafeas.v1beta1.Note> - getUpdateNoteMethod() { - return getUpdateNoteMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.UpdateNoteRequest, io.grafeas.v1beta1.Note> - getUpdateNoteMethodHelper() { - io.grpc.MethodDescriptor - getUpdateNoteMethod; - if ((getUpdateNoteMethod = GrafeasV1Beta1Grpc.getUpdateNoteMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getUpdateNoteMethod = GrafeasV1Beta1Grpc.getUpdateNoteMethod) == null) { - GrafeasV1Beta1Grpc.getUpdateNoteMethod = - getUpdateNoteMethod = - io.grpc.MethodDescriptor - .newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName("grafeas.v1beta1.GrafeasV1Beta1", "UpdateNote")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.UpdateNoteRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.Note.getDefaultInstance())) - .setSchemaDescriptor(new GrafeasV1Beta1MethodDescriptorSupplier("UpdateNote")) - .build(); - } - } - } - return getUpdateNoteMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getListNoteOccurrencesMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListNoteOccurrencesRequest, - io.grafeas.v1beta1.ListNoteOccurrencesResponse> - METHOD_LIST_NOTE_OCCURRENCES = getListNoteOccurrencesMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListNoteOccurrencesRequest, - io.grafeas.v1beta1.ListNoteOccurrencesResponse> - getListNoteOccurrencesMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListNoteOccurrencesRequest, - io.grafeas.v1beta1.ListNoteOccurrencesResponse> - getListNoteOccurrencesMethod() { - return getListNoteOccurrencesMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListNoteOccurrencesRequest, - io.grafeas.v1beta1.ListNoteOccurrencesResponse> - getListNoteOccurrencesMethodHelper() { - io.grpc.MethodDescriptor< - io.grafeas.v1beta1.ListNoteOccurrencesRequest, - io.grafeas.v1beta1.ListNoteOccurrencesResponse> - getListNoteOccurrencesMethod; - if ((getListNoteOccurrencesMethod = GrafeasV1Beta1Grpc.getListNoteOccurrencesMethod) == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getListNoteOccurrencesMethod = GrafeasV1Beta1Grpc.getListNoteOccurrencesMethod) - == null) { - GrafeasV1Beta1Grpc.getListNoteOccurrencesMethod = - getListNoteOccurrencesMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "grafeas.v1beta1.GrafeasV1Beta1", "ListNoteOccurrences")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.ListNoteOccurrencesRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.ListNoteOccurrencesResponse.getDefaultInstance())) - .setSchemaDescriptor( - new GrafeasV1Beta1MethodDescriptorSupplier("ListNoteOccurrences")) - .build(); - } - } - } - return getListNoteOccurrencesMethod; - } - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getGetVulnerabilityOccurrencesSummaryMethod()} instead. - public static final io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary> - METHOD_GET_VULNERABILITY_OCCURRENCES_SUMMARY = - getGetVulnerabilityOccurrencesSummaryMethodHelper(); - - private static volatile io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary> - getGetVulnerabilityOccurrencesSummaryMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary> - getGetVulnerabilityOccurrencesSummaryMethod() { - return getGetVulnerabilityOccurrencesSummaryMethodHelper(); - } - - private static io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary> - getGetVulnerabilityOccurrencesSummaryMethodHelper() { - io.grpc.MethodDescriptor< - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary> - getGetVulnerabilityOccurrencesSummaryMethod; - if ((getGetVulnerabilityOccurrencesSummaryMethod = - GrafeasV1Beta1Grpc.getGetVulnerabilityOccurrencesSummaryMethod) - == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - if ((getGetVulnerabilityOccurrencesSummaryMethod = - GrafeasV1Beta1Grpc.getGetVulnerabilityOccurrencesSummaryMethod) - == null) { - GrafeasV1Beta1Grpc.getGetVulnerabilityOccurrencesSummaryMethod = - getGetVulnerabilityOccurrencesSummaryMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName( - "grafeas.v1beta1.GrafeasV1Beta1", - "GetVulnerabilityOccurrencesSummary")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary - .getDefaultInstance())) - .setSchemaDescriptor( - new GrafeasV1Beta1MethodDescriptorSupplier( - "GetVulnerabilityOccurrencesSummary")) - .build(); - } - } - } - return getGetVulnerabilityOccurrencesSummaryMethod; - } - - /** Creates a new async stub that supports all call types for the service */ - public static GrafeasV1Beta1Stub newStub(io.grpc.Channel channel) { - return new GrafeasV1Beta1Stub(channel); - } - - /** - * Creates a new blocking-style stub that supports unary and streaming output calls on the service - */ - public static GrafeasV1Beta1BlockingStub newBlockingStub(io.grpc.Channel channel) { - return new GrafeasV1Beta1BlockingStub(channel); - } - - /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ - public static GrafeasV1Beta1FutureStub newFutureStub(io.grpc.Channel channel) { - return new GrafeasV1Beta1FutureStub(channel); - } - - /** - * - * - *
-   * [Grafeas](grafeas.io) API.
-   * Retrieves analysis results of Cloud components such as Docker container
-   * images.
-   * Analysis results are stored as a series of occurrences. An `Occurrence`
-   * contains information about a specific analysis instance on a resource. An
-   * occurrence refers to a `Note`. A note contains details describing the
-   * analysis and is generally stored in a separate project, called a `Provider`.
-   * Multiple occurrences can refer to the same note.
-   * For example, an SSL vulnerability could affect multiple images. In this case,
-   * there would be one note for the vulnerability and an occurrence for each
-   * image with the vulnerability referring to that note.
-   * 
- */ - public abstract static class GrafeasV1Beta1ImplBase implements io.grpc.BindableService { - - /** - * - * - *
-     * Gets the specified occurrence.
-     * 
- */ - public void getOccurrence( - io.grafeas.v1beta1.GetOccurrenceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getGetOccurrenceMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Lists occurrences for the specified project.
-     * 
- */ - public void listOccurrences( - io.grafeas.v1beta1.ListOccurrencesRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getListOccurrencesMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Deletes the specified occurrence. For example, use this method to delete an
-     * occurrence when the occurrence is no longer applicable for the given
-     * resource.
-     * 
- */ - public void deleteOccurrence( - io.grafeas.v1beta1.DeleteOccurrenceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getDeleteOccurrenceMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Creates a new occurrence.
-     * 
- */ - public void createOccurrence( - io.grafeas.v1beta1.CreateOccurrenceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getCreateOccurrenceMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Creates new occurrences in batch.
-     * 
- */ - public void batchCreateOccurrences( - io.grafeas.v1beta1.BatchCreateOccurrencesRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnimplementedUnaryCall(getBatchCreateOccurrencesMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Updates the specified occurrence.
-     * 
- */ - public void updateOccurrence( - io.grafeas.v1beta1.UpdateOccurrenceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getUpdateOccurrenceMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Gets the note attached to the specified occurrence. Consumer projects can
-     * use this method to get a note that belongs to a provider project.
-     * 
- */ - public void getOccurrenceNote( - io.grafeas.v1beta1.GetOccurrenceNoteRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getGetOccurrenceNoteMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Gets the specified note.
-     * 
- */ - public void getNote( - io.grafeas.v1beta1.GetNoteRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getGetNoteMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Lists notes for the specified project.
-     * 
- */ - public void listNotes( - io.grafeas.v1beta1.ListNotesRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getListNotesMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Deletes the specified note.
-     * 
- */ - public void deleteNote( - io.grafeas.v1beta1.DeleteNoteRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getDeleteNoteMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Creates a new note.
-     * 
- */ - public void createNote( - io.grafeas.v1beta1.CreateNoteRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getCreateNoteMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Creates new notes in batch.
-     * 
- */ - public void batchCreateNotes( - io.grafeas.v1beta1.BatchCreateNotesRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getBatchCreateNotesMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Updates the specified note.
-     * 
- */ - public void updateNote( - io.grafeas.v1beta1.UpdateNoteRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getUpdateNoteMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Lists occurrences referencing the specified note. Provider projects can use
-     * this method to get all occurrences across consumer projects referencing the
-     * specified note.
-     * 
- */ - public void listNoteOccurrences( - io.grafeas.v1beta1.ListNoteOccurrencesRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnimplementedUnaryCall(getListNoteOccurrencesMethodHelper(), responseObserver); - } - - /** - * - * - *
-     * Gets a summary of the number and severity of occurrences.
-     * 
- */ - public void getVulnerabilityOccurrencesSummary( - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnimplementedUnaryCall( - getGetVulnerabilityOccurrencesSummaryMethodHelper(), responseObserver); - } - - @java.lang.Override - public final io.grpc.ServerServiceDefinition bindService() { - return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) - .addMethod( - getGetOccurrenceMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - io.grafeas.v1beta1.GetOccurrenceRequest, io.grafeas.v1beta1.Occurrence>( - this, METHODID_GET_OCCURRENCE))) - .addMethod( - getListOccurrencesMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - io.grafeas.v1beta1.ListOccurrencesRequest, - io.grafeas.v1beta1.ListOccurrencesResponse>(this, METHODID_LIST_OCCURRENCES))) - .addMethod( - getDeleteOccurrenceMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - io.grafeas.v1beta1.DeleteOccurrenceRequest, com.google.protobuf.Empty>( - this, METHODID_DELETE_OCCURRENCE))) - .addMethod( - getCreateOccurrenceMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - io.grafeas.v1beta1.CreateOccurrenceRequest, io.grafeas.v1beta1.Occurrence>( - this, METHODID_CREATE_OCCURRENCE))) - .addMethod( - getBatchCreateOccurrencesMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - io.grafeas.v1beta1.BatchCreateOccurrencesRequest, - io.grafeas.v1beta1.BatchCreateOccurrencesResponse>( - this, METHODID_BATCH_CREATE_OCCURRENCES))) - .addMethod( - getUpdateOccurrenceMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - io.grafeas.v1beta1.UpdateOccurrenceRequest, io.grafeas.v1beta1.Occurrence>( - this, METHODID_UPDATE_OCCURRENCE))) - .addMethod( - getGetOccurrenceNoteMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - io.grafeas.v1beta1.GetOccurrenceNoteRequest, io.grafeas.v1beta1.Note>( - this, METHODID_GET_OCCURRENCE_NOTE))) - .addMethod( - getGetNoteMethodHelper(), - asyncUnaryCall( - new MethodHandlers( - this, METHODID_GET_NOTE))) - .addMethod( - getListNotesMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - io.grafeas.v1beta1.ListNotesRequest, io.grafeas.v1beta1.ListNotesResponse>( - this, METHODID_LIST_NOTES))) - .addMethod( - getDeleteNoteMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - io.grafeas.v1beta1.DeleteNoteRequest, com.google.protobuf.Empty>( - this, METHODID_DELETE_NOTE))) - .addMethod( - getCreateNoteMethodHelper(), - asyncUnaryCall( - new MethodHandlers( - this, METHODID_CREATE_NOTE))) - .addMethod( - getBatchCreateNotesMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - io.grafeas.v1beta1.BatchCreateNotesRequest, - io.grafeas.v1beta1.BatchCreateNotesResponse>( - this, METHODID_BATCH_CREATE_NOTES))) - .addMethod( - getUpdateNoteMethodHelper(), - asyncUnaryCall( - new MethodHandlers( - this, METHODID_UPDATE_NOTE))) - .addMethod( - getListNoteOccurrencesMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - io.grafeas.v1beta1.ListNoteOccurrencesRequest, - io.grafeas.v1beta1.ListNoteOccurrencesResponse>( - this, METHODID_LIST_NOTE_OCCURRENCES))) - .addMethod( - getGetVulnerabilityOccurrencesSummaryMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary>( - this, METHODID_GET_VULNERABILITY_OCCURRENCES_SUMMARY))) - .build(); - } - } - - /** - * - * - *
-   * [Grafeas](grafeas.io) API.
-   * Retrieves analysis results of Cloud components such as Docker container
-   * images.
-   * Analysis results are stored as a series of occurrences. An `Occurrence`
-   * contains information about a specific analysis instance on a resource. An
-   * occurrence refers to a `Note`. A note contains details describing the
-   * analysis and is generally stored in a separate project, called a `Provider`.
-   * Multiple occurrences can refer to the same note.
-   * For example, an SSL vulnerability could affect multiple images. In this case,
-   * there would be one note for the vulnerability and an occurrence for each
-   * image with the vulnerability referring to that note.
-   * 
- */ - public static final class GrafeasV1Beta1Stub - extends io.grpc.stub.AbstractStub { - private GrafeasV1Beta1Stub(io.grpc.Channel channel) { - super(channel); - } - - private GrafeasV1Beta1Stub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected GrafeasV1Beta1Stub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new GrafeasV1Beta1Stub(channel, callOptions); - } - - /** - * - * - *
-     * Gets the specified occurrence.
-     * 
- */ - public void getOccurrence( - io.grafeas.v1beta1.GetOccurrenceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getGetOccurrenceMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Lists occurrences for the specified project.
-     * 
- */ - public void listOccurrences( - io.grafeas.v1beta1.ListOccurrencesRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getListOccurrencesMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Deletes the specified occurrence. For example, use this method to delete an
-     * occurrence when the occurrence is no longer applicable for the given
-     * resource.
-     * 
- */ - public void deleteOccurrence( - io.grafeas.v1beta1.DeleteOccurrenceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getDeleteOccurrenceMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Creates a new occurrence.
-     * 
- */ - public void createOccurrence( - io.grafeas.v1beta1.CreateOccurrenceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getCreateOccurrenceMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Creates new occurrences in batch.
-     * 
- */ - public void batchCreateOccurrences( - io.grafeas.v1beta1.BatchCreateOccurrencesRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnaryCall( - getChannel().newCall(getBatchCreateOccurrencesMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Updates the specified occurrence.
-     * 
- */ - public void updateOccurrence( - io.grafeas.v1beta1.UpdateOccurrenceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getUpdateOccurrenceMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Gets the note attached to the specified occurrence. Consumer projects can
-     * use this method to get a note that belongs to a provider project.
-     * 
- */ - public void getOccurrenceNote( - io.grafeas.v1beta1.GetOccurrenceNoteRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getGetOccurrenceNoteMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Gets the specified note.
-     * 
- */ - public void getNote( - io.grafeas.v1beta1.GetNoteRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getGetNoteMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Lists notes for the specified project.
-     * 
- */ - public void listNotes( - io.grafeas.v1beta1.ListNotesRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getListNotesMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Deletes the specified note.
-     * 
- */ - public void deleteNote( - io.grafeas.v1beta1.DeleteNoteRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getDeleteNoteMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Creates a new note.
-     * 
- */ - public void createNote( - io.grafeas.v1beta1.CreateNoteRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getCreateNoteMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Creates new notes in batch.
-     * 
- */ - public void batchCreateNotes( - io.grafeas.v1beta1.BatchCreateNotesRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getBatchCreateNotesMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Updates the specified note.
-     * 
- */ - public void updateNote( - io.grafeas.v1beta1.UpdateNoteRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getUpdateNoteMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Lists occurrences referencing the specified note. Provider projects can use
-     * this method to get all occurrences across consumer projects referencing the
-     * specified note.
-     * 
- */ - public void listNoteOccurrences( - io.grafeas.v1beta1.ListNoteOccurrencesRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnaryCall( - getChannel().newCall(getListNoteOccurrencesMethodHelper(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Gets a summary of the number and severity of occurrences.
-     * 
- */ - public void getVulnerabilityOccurrencesSummary( - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - asyncUnaryCall( - getChannel() - .newCall(getGetVulnerabilityOccurrencesSummaryMethodHelper(), getCallOptions()), - request, - responseObserver); - } - } - - /** - * - * - *
-   * [Grafeas](grafeas.io) API.
-   * Retrieves analysis results of Cloud components such as Docker container
-   * images.
-   * Analysis results are stored as a series of occurrences. An `Occurrence`
-   * contains information about a specific analysis instance on a resource. An
-   * occurrence refers to a `Note`. A note contains details describing the
-   * analysis and is generally stored in a separate project, called a `Provider`.
-   * Multiple occurrences can refer to the same note.
-   * For example, an SSL vulnerability could affect multiple images. In this case,
-   * there would be one note for the vulnerability and an occurrence for each
-   * image with the vulnerability referring to that note.
-   * 
- */ - public static final class GrafeasV1Beta1BlockingStub - extends io.grpc.stub.AbstractStub { - private GrafeasV1Beta1BlockingStub(io.grpc.Channel channel) { - super(channel); - } - - private GrafeasV1Beta1BlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected GrafeasV1Beta1BlockingStub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new GrafeasV1Beta1BlockingStub(channel, callOptions); - } - - /** - * - * - *
-     * Gets the specified occurrence.
-     * 
- */ - public io.grafeas.v1beta1.Occurrence getOccurrence( - io.grafeas.v1beta1.GetOccurrenceRequest request) { - return blockingUnaryCall( - getChannel(), getGetOccurrenceMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Lists occurrences for the specified project.
-     * 
- */ - public io.grafeas.v1beta1.ListOccurrencesResponse listOccurrences( - io.grafeas.v1beta1.ListOccurrencesRequest request) { - return blockingUnaryCall( - getChannel(), getListOccurrencesMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Deletes the specified occurrence. For example, use this method to delete an
-     * occurrence when the occurrence is no longer applicable for the given
-     * resource.
-     * 
- */ - public com.google.protobuf.Empty deleteOccurrence( - io.grafeas.v1beta1.DeleteOccurrenceRequest request) { - return blockingUnaryCall( - getChannel(), getDeleteOccurrenceMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Creates a new occurrence.
-     * 
- */ - public io.grafeas.v1beta1.Occurrence createOccurrence( - io.grafeas.v1beta1.CreateOccurrenceRequest request) { - return blockingUnaryCall( - getChannel(), getCreateOccurrenceMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Creates new occurrences in batch.
-     * 
- */ - public io.grafeas.v1beta1.BatchCreateOccurrencesResponse batchCreateOccurrences( - io.grafeas.v1beta1.BatchCreateOccurrencesRequest request) { - return blockingUnaryCall( - getChannel(), getBatchCreateOccurrencesMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Updates the specified occurrence.
-     * 
- */ - public io.grafeas.v1beta1.Occurrence updateOccurrence( - io.grafeas.v1beta1.UpdateOccurrenceRequest request) { - return blockingUnaryCall( - getChannel(), getUpdateOccurrenceMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Gets the note attached to the specified occurrence. Consumer projects can
-     * use this method to get a note that belongs to a provider project.
-     * 
- */ - public io.grafeas.v1beta1.Note getOccurrenceNote( - io.grafeas.v1beta1.GetOccurrenceNoteRequest request) { - return blockingUnaryCall( - getChannel(), getGetOccurrenceNoteMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Gets the specified note.
-     * 
- */ - public io.grafeas.v1beta1.Note getNote(io.grafeas.v1beta1.GetNoteRequest request) { - return blockingUnaryCall(getChannel(), getGetNoteMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Lists notes for the specified project.
-     * 
- */ - public io.grafeas.v1beta1.ListNotesResponse listNotes( - io.grafeas.v1beta1.ListNotesRequest request) { - return blockingUnaryCall(getChannel(), getListNotesMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Deletes the specified note.
-     * 
- */ - public com.google.protobuf.Empty deleteNote(io.grafeas.v1beta1.DeleteNoteRequest request) { - return blockingUnaryCall( - getChannel(), getDeleteNoteMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Creates a new note.
-     * 
- */ - public io.grafeas.v1beta1.Note createNote(io.grafeas.v1beta1.CreateNoteRequest request) { - return blockingUnaryCall( - getChannel(), getCreateNoteMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Creates new notes in batch.
-     * 
- */ - public io.grafeas.v1beta1.BatchCreateNotesResponse batchCreateNotes( - io.grafeas.v1beta1.BatchCreateNotesRequest request) { - return blockingUnaryCall( - getChannel(), getBatchCreateNotesMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Updates the specified note.
-     * 
- */ - public io.grafeas.v1beta1.Note updateNote(io.grafeas.v1beta1.UpdateNoteRequest request) { - return blockingUnaryCall( - getChannel(), getUpdateNoteMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Lists occurrences referencing the specified note. Provider projects can use
-     * this method to get all occurrences across consumer projects referencing the
-     * specified note.
-     * 
- */ - public io.grafeas.v1beta1.ListNoteOccurrencesResponse listNoteOccurrences( - io.grafeas.v1beta1.ListNoteOccurrencesRequest request) { - return blockingUnaryCall( - getChannel(), getListNoteOccurrencesMethodHelper(), getCallOptions(), request); - } - - /** - * - * - *
-     * Gets a summary of the number and severity of occurrences.
-     * 
- */ - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary getVulnerabilityOccurrencesSummary( - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest request) { - return blockingUnaryCall( - getChannel(), - getGetVulnerabilityOccurrencesSummaryMethodHelper(), - getCallOptions(), - request); - } - } - - /** - * - * - *
-   * [Grafeas](grafeas.io) API.
-   * Retrieves analysis results of Cloud components such as Docker container
-   * images.
-   * Analysis results are stored as a series of occurrences. An `Occurrence`
-   * contains information about a specific analysis instance on a resource. An
-   * occurrence refers to a `Note`. A note contains details describing the
-   * analysis and is generally stored in a separate project, called a `Provider`.
-   * Multiple occurrences can refer to the same note.
-   * For example, an SSL vulnerability could affect multiple images. In this case,
-   * there would be one note for the vulnerability and an occurrence for each
-   * image with the vulnerability referring to that note.
-   * 
- */ - public static final class GrafeasV1Beta1FutureStub - extends io.grpc.stub.AbstractStub { - private GrafeasV1Beta1FutureStub(io.grpc.Channel channel) { - super(channel); - } - - private GrafeasV1Beta1FutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected GrafeasV1Beta1FutureStub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new GrafeasV1Beta1FutureStub(channel, callOptions); - } - - /** - * - * - *
-     * Gets the specified occurrence.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - getOccurrence(io.grafeas.v1beta1.GetOccurrenceRequest request) { - return futureUnaryCall( - getChannel().newCall(getGetOccurrenceMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Lists occurrences for the specified project.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - io.grafeas.v1beta1.ListOccurrencesResponse> - listOccurrences(io.grafeas.v1beta1.ListOccurrencesRequest request) { - return futureUnaryCall( - getChannel().newCall(getListOccurrencesMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Deletes the specified occurrence. For example, use this method to delete an
-     * occurrence when the occurrence is no longer applicable for the given
-     * resource.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - deleteOccurrence(io.grafeas.v1beta1.DeleteOccurrenceRequest request) { - return futureUnaryCall( - getChannel().newCall(getDeleteOccurrenceMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Creates a new occurrence.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - createOccurrence(io.grafeas.v1beta1.CreateOccurrenceRequest request) { - return futureUnaryCall( - getChannel().newCall(getCreateOccurrenceMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Creates new occurrences in batch.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - io.grafeas.v1beta1.BatchCreateOccurrencesResponse> - batchCreateOccurrences(io.grafeas.v1beta1.BatchCreateOccurrencesRequest request) { - return futureUnaryCall( - getChannel().newCall(getBatchCreateOccurrencesMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Updates the specified occurrence.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - updateOccurrence(io.grafeas.v1beta1.UpdateOccurrenceRequest request) { - return futureUnaryCall( - getChannel().newCall(getUpdateOccurrenceMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Gets the note attached to the specified occurrence. Consumer projects can
-     * use this method to get a note that belongs to a provider project.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - getOccurrenceNote(io.grafeas.v1beta1.GetOccurrenceNoteRequest request) { - return futureUnaryCall( - getChannel().newCall(getGetOccurrenceNoteMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Gets the specified note.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture getNote( - io.grafeas.v1beta1.GetNoteRequest request) { - return futureUnaryCall( - getChannel().newCall(getGetNoteMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Lists notes for the specified project.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - listNotes(io.grafeas.v1beta1.ListNotesRequest request) { - return futureUnaryCall( - getChannel().newCall(getListNotesMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Deletes the specified note.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture deleteNote( - io.grafeas.v1beta1.DeleteNoteRequest request) { - return futureUnaryCall( - getChannel().newCall(getDeleteNoteMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Creates a new note.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture createNote( - io.grafeas.v1beta1.CreateNoteRequest request) { - return futureUnaryCall( - getChannel().newCall(getCreateNoteMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Creates new notes in batch.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - io.grafeas.v1beta1.BatchCreateNotesResponse> - batchCreateNotes(io.grafeas.v1beta1.BatchCreateNotesRequest request) { - return futureUnaryCall( - getChannel().newCall(getBatchCreateNotesMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Updates the specified note.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture updateNote( - io.grafeas.v1beta1.UpdateNoteRequest request) { - return futureUnaryCall( - getChannel().newCall(getUpdateNoteMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Lists occurrences referencing the specified note. Provider projects can use
-     * this method to get all occurrences across consumer projects referencing the
-     * specified note.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - io.grafeas.v1beta1.ListNoteOccurrencesResponse> - listNoteOccurrences(io.grafeas.v1beta1.ListNoteOccurrencesRequest request) { - return futureUnaryCall( - getChannel().newCall(getListNoteOccurrencesMethodHelper(), getCallOptions()), request); - } - - /** - * - * - *
-     * Gets a summary of the number and severity of occurrences.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary> - getVulnerabilityOccurrencesSummary( - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest request) { - return futureUnaryCall( - getChannel() - .newCall(getGetVulnerabilityOccurrencesSummaryMethodHelper(), getCallOptions()), - request); - } - } - - private static final int METHODID_GET_OCCURRENCE = 0; - private static final int METHODID_LIST_OCCURRENCES = 1; - private static final int METHODID_DELETE_OCCURRENCE = 2; - private static final int METHODID_CREATE_OCCURRENCE = 3; - private static final int METHODID_BATCH_CREATE_OCCURRENCES = 4; - private static final int METHODID_UPDATE_OCCURRENCE = 5; - private static final int METHODID_GET_OCCURRENCE_NOTE = 6; - private static final int METHODID_GET_NOTE = 7; - private static final int METHODID_LIST_NOTES = 8; - private static final int METHODID_DELETE_NOTE = 9; - private static final int METHODID_CREATE_NOTE = 10; - private static final int METHODID_BATCH_CREATE_NOTES = 11; - private static final int METHODID_UPDATE_NOTE = 12; - private static final int METHODID_LIST_NOTE_OCCURRENCES = 13; - private static final int METHODID_GET_VULNERABILITY_OCCURRENCES_SUMMARY = 14; - - private static final class MethodHandlers - implements io.grpc.stub.ServerCalls.UnaryMethod, - io.grpc.stub.ServerCalls.ServerStreamingMethod, - io.grpc.stub.ServerCalls.ClientStreamingMethod, - io.grpc.stub.ServerCalls.BidiStreamingMethod { - private final GrafeasV1Beta1ImplBase serviceImpl; - private final int methodId; - - MethodHandlers(GrafeasV1Beta1ImplBase serviceImpl, int methodId) { - this.serviceImpl = serviceImpl; - this.methodId = methodId; - } - - @java.lang.Override - @java.lang.SuppressWarnings("unchecked") - public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { - switch (methodId) { - case METHODID_GET_OCCURRENCE: - serviceImpl.getOccurrence( - (io.grafeas.v1beta1.GetOccurrenceRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_LIST_OCCURRENCES: - serviceImpl.listOccurrences( - (io.grafeas.v1beta1.ListOccurrencesRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - case METHODID_DELETE_OCCURRENCE: - serviceImpl.deleteOccurrence( - (io.grafeas.v1beta1.DeleteOccurrenceRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_CREATE_OCCURRENCE: - serviceImpl.createOccurrence( - (io.grafeas.v1beta1.CreateOccurrenceRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_BATCH_CREATE_OCCURRENCES: - serviceImpl.batchCreateOccurrences( - (io.grafeas.v1beta1.BatchCreateOccurrencesRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - case METHODID_UPDATE_OCCURRENCE: - serviceImpl.updateOccurrence( - (io.grafeas.v1beta1.UpdateOccurrenceRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_GET_OCCURRENCE_NOTE: - serviceImpl.getOccurrenceNote( - (io.grafeas.v1beta1.GetOccurrenceNoteRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_GET_NOTE: - serviceImpl.getNote( - (io.grafeas.v1beta1.GetNoteRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_LIST_NOTES: - serviceImpl.listNotes( - (io.grafeas.v1beta1.ListNotesRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_DELETE_NOTE: - serviceImpl.deleteNote( - (io.grafeas.v1beta1.DeleteNoteRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_CREATE_NOTE: - serviceImpl.createNote( - (io.grafeas.v1beta1.CreateNoteRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_BATCH_CREATE_NOTES: - serviceImpl.batchCreateNotes( - (io.grafeas.v1beta1.BatchCreateNotesRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - case METHODID_UPDATE_NOTE: - serviceImpl.updateNote( - (io.grafeas.v1beta1.UpdateNoteRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_LIST_NOTE_OCCURRENCES: - serviceImpl.listNoteOccurrences( - (io.grafeas.v1beta1.ListNoteOccurrencesRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - case METHODID_GET_VULNERABILITY_OCCURRENCES_SUMMARY: - serviceImpl.getVulnerabilityOccurrencesSummary( - (io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - default: - throw new AssertionError(); - } - } - - @java.lang.Override - @java.lang.SuppressWarnings("unchecked") - public io.grpc.stub.StreamObserver invoke( - io.grpc.stub.StreamObserver responseObserver) { - switch (methodId) { - default: - throw new AssertionError(); - } - } - } - - private abstract static class GrafeasV1Beta1BaseDescriptorSupplier - implements io.grpc.protobuf.ProtoFileDescriptorSupplier, - io.grpc.protobuf.ProtoServiceDescriptorSupplier { - GrafeasV1Beta1BaseDescriptorSupplier() {} - - @java.lang.Override - public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { - return io.grafeas.v1beta1.Grafeas.getDescriptor(); - } - - @java.lang.Override - public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { - return getFileDescriptor().findServiceByName("GrafeasV1Beta1"); - } - } - - private static final class GrafeasV1Beta1FileDescriptorSupplier - extends GrafeasV1Beta1BaseDescriptorSupplier { - GrafeasV1Beta1FileDescriptorSupplier() {} - } - - private static final class GrafeasV1Beta1MethodDescriptorSupplier - extends GrafeasV1Beta1BaseDescriptorSupplier - implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { - private final String methodName; - - GrafeasV1Beta1MethodDescriptorSupplier(String methodName) { - this.methodName = methodName; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { - return getServiceDescriptor().findMethodByName(methodName); - } - } - - private static volatile io.grpc.ServiceDescriptor serviceDescriptor; - - public static io.grpc.ServiceDescriptor getServiceDescriptor() { - io.grpc.ServiceDescriptor result = serviceDescriptor; - if (result == null) { - synchronized (GrafeasV1Beta1Grpc.class) { - result = serviceDescriptor; - if (result == null) { - serviceDescriptor = - result = - io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) - .setSchemaDescriptor(new GrafeasV1Beta1FileDescriptorSupplier()) - .addMethod(getGetOccurrenceMethodHelper()) - .addMethod(getListOccurrencesMethodHelper()) - .addMethod(getDeleteOccurrenceMethodHelper()) - .addMethod(getCreateOccurrenceMethodHelper()) - .addMethod(getBatchCreateOccurrencesMethodHelper()) - .addMethod(getUpdateOccurrenceMethodHelper()) - .addMethod(getGetOccurrenceNoteMethodHelper()) - .addMethod(getGetNoteMethodHelper()) - .addMethod(getListNotesMethodHelper()) - .addMethod(getDeleteNoteMethodHelper()) - .addMethod(getCreateNoteMethodHelper()) - .addMethod(getBatchCreateNotesMethodHelper()) - .addMethod(getUpdateNoteMethodHelper()) - .addMethod(getListNoteOccurrencesMethodHelper()) - .addMethod(getGetVulnerabilityOccurrencesSummaryMethodHelper()) - .build(); - } - } - } - return result; - } -} diff --git a/java.header b/java.header new file mode 100644 index 00000000..3a9b503a --- /dev/null +++ b/java.header @@ -0,0 +1,15 @@ +^/\*$ +^ \* Copyright \d\d\d\d,? Google (Inc\.|LLC)( All [rR]ights [rR]eserved\.)?$ +^ \*$ +^ \* Licensed under the Apache License, Version 2\.0 \(the "License"\);$ +^ \* you may not use this file except in compliance with the License\.$ +^ \* You may obtain a copy of the License at$ +^ \*$ +^ \*[ ]+https?://www.apache.org/licenses/LICENSE-2\.0$ +^ \*$ +^ \* Unless required by applicable law or agreed to in writing, software$ +^ \* distributed under the License is distributed on an "AS IS" BASIS,$ +^ \* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied\.$ +^ \* See the License for the specific language governing permissions and$ +^ \* limitations under the License\.$ +^ \*/$ diff --git a/license-checks.xml b/license-checks.xml new file mode 100644 index 00000000..6597fced --- /dev/null +++ b/license-checks.xml @@ -0,0 +1,10 @@ + + + + + + + + diff --git a/pom.xml b/pom.xml new file mode 100644 index 00000000..28ca9493 --- /dev/null +++ b/pom.xml @@ -0,0 +1,294 @@ + + + 4.0.0 + com.google.cloud + google-cloud-container-parent + pom + 0.117.0-beta + Google Cloud Container Parent + https://github.com/googleapis/java-container + + Java idiomatic client for Google Cloud Platform services. + + + + com.google.cloud + google-cloud-shared-config + 0.2.1 + + + + + chingor + Jeff Ching + chingor@google.com + Google + + Developer + + + + + Google LLC + + + scm:git:git@github.com:googleapis/java-container.git + scm:git:git@github.com:googleapis/java-container.git + https://github.com/googleapis/java-container + HEAD + + + https://github.com/googleapis/java-container/issues + GitHub Issues + + + + sonatype-nexus-snapshots + https://oss.sonatype.org/content/repositories/snapshots + + + sonatype-nexus-staging + https://oss.sonatype.org/service/local/staging/deploy/maven2/ + + + + + Apache-2.0 + https://www.apache.org/licenses/LICENSE-2.0.txt + + + + + UTF-8 + UTF-8 + github + google-cloud-container-parent + 1.91.1 + 1.8.1 + 1.17.0 + 1.49.0 + 1.24.1 + 3.10.0 + 4.12 + 28.1-android + 1.4.0 + 1.3.2 + 1.18 + + + + + + com.google.api.grpc + proto-google-cloud-containeranalysis-v1 + 0.82.0 + + + com.google.api.grpc + proto-google-cloud-container-v1 + 0.82.0 + + + com.google.api.grpc + proto-google-cloud-containeranalysis-v1beta1 + 0.82.0 + + + com.google.api.grpc + grpc-google-cloud-containeranalysis-v1beta1 + 0.82.0 + + + com.google.api.grpc + grpc-google-cloud-container-v1 + 0.82.0 + + + com.google.api.grpc + grpc-google-cloud-containeranalysis-v1 + 0.82.0 + + + com.google.cloud + google-cloud-containeranalysis + 0.117.0-beta + + + com.google.cloud + google-cloud-container + 0.117.0-beta + + + + io.grpc + grpc-bom + ${grpc.version} + pom + import + + + com.google.api + gax-bom + ${gax.version} + pom + import + + + com.google.guava + guava-bom + ${guava.version} + pom + import + + + com.google.protobuf + protobuf-bom + 3.10.0 + pom + import + + + + + com.google.protobuf + protobuf-java + ${protobuf.version} + + + com.google.api + api-common + ${google.api-common.version} + + + com.google.api.grpc + proto-google-common-protos + ${google.common-protos.version} + + + org.threeten + threetenbp + ${threeten.version} + + + javax.annotation + javax.annotation-api + ${javax.annotations.version} + + + org.codehaus.mojo + animal-sniffer-annotations + ${animal-sniffer.version} + + + com.google.code.gson + gson + 2.8.6 + + + + junit + junit + ${junit.version} + test + + + com.google.api + gax-grpc + ${gax.version} + testlib + test + + + + + + + + + org.apache.maven.plugins + maven-dependency-plugin + + org.objenesis:objenesis + + + + + + + + proto-google-cloud-container-v1 + grpc-google-cloud-container-v1 + google-cloud-container + google-cloud-container-bom + + + + + + org.apache.maven.plugins + maven-project-info-reports-plugin + 3.0.0 + + + + index + dependency-info + team + ci-management + issue-management + licenses + scm + dependency-management + distribution-management + summary + modules + + + + + true + ${site.installationModule} + jar + + + + org.apache.maven.plugins + maven-javadoc-plugin + 3.1.1 + + + html + + aggregate + javadoc + + + + + none + protected + true + ${project.build.directory}/javadoc + + + Test helpers packages + com.google.cloud.testing + + + SPI packages + com.google.cloud.spi* + + + + + https://grpc.io/grpc-java/javadoc/ + https://developers.google.com/protocol-buffers/docs/reference/java/ + https://googleapis.dev/java/google-auth-library/latest/ + https://googleapis.dev/java/gax/latest/ + https://googleapis.github.io/api-common-java/${google.api-common.version}/apidocs/ + + + + + + \ No newline at end of file diff --git a/proto-google-cloud-container-v1/pom.xml b/proto-google-cloud-container-v1/pom.xml index 170b1d6e..ac7a9f3a 100644 --- a/proto-google-cloud-container-v1/pom.xml +++ b/proto-google-cloud-container-v1/pom.xml @@ -2,30 +2,24 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 + com.google.api.grpc proto-google-cloud-container-v1 0.82.0 proto-google-cloud-container-v1 PROTO library for proto-google-cloud-container-v1 - com.google.api.grpc - google-api-grpc - 0.82.0 + com.google.cloud + google-cloud-container-parent + 0.117.0-beta com.google.protobuf protobuf-java - compile - - - com.google.api - api-common - compile com.google.api.grpc proto-google-common-protos - compile \ No newline at end of file diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AcceleratorConfig.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AcceleratorConfig.java index 10df4594..61de534b 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AcceleratorConfig.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AcceleratorConfig.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AcceleratorConfigOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AcceleratorConfigOrBuilder.java index b8717fe0..9536fe25 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AcceleratorConfigOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AcceleratorConfigOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AddonsConfig.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AddonsConfig.java index 9c263398..02f55157 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AddonsConfig.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AddonsConfig.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AddonsConfigOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AddonsConfigOrBuilder.java index 06d4a2d7..6b76a26a 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AddonsConfigOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AddonsConfigOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AutoUpgradeOptions.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AutoUpgradeOptions.java index 76b291ea..b67b97b5 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AutoUpgradeOptions.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AutoUpgradeOptions.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AutoUpgradeOptionsOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AutoUpgradeOptionsOrBuilder.java index 1014507c..8b3d3493 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AutoUpgradeOptionsOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/AutoUpgradeOptionsOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CancelOperationRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CancelOperationRequest.java index 18de66e4..9d7df713 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CancelOperationRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CancelOperationRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CancelOperationRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CancelOperationRequestOrBuilder.java index 1f8da53d..95e8d2a7 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CancelOperationRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CancelOperationRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClientCertificateConfig.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClientCertificateConfig.java index 3677a587..b7d57033 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClientCertificateConfig.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClientCertificateConfig.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClientCertificateConfigOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClientCertificateConfigOrBuilder.java index 612c45b5..34f7bd91 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClientCertificateConfigOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClientCertificateConfigOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/Cluster.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/Cluster.java index ec850dc5..d7e5cb5b 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/Cluster.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/Cluster.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterOrBuilder.java index 38bec5b3..8b63a20e 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterServiceProto.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterServiceProto.java index 02ef0667..26a91c00 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterServiceProto.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterServiceProto.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterUpdate.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterUpdate.java index 1132987d..285c4768 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterUpdate.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterUpdate.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterUpdateOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterUpdateOrBuilder.java index 26977b39..088a27fb 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterUpdateOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ClusterUpdateOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CompleteIPRotationRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CompleteIPRotationRequest.java index ff949055..eef9bad5 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CompleteIPRotationRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CompleteIPRotationRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CompleteIPRotationRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CompleteIPRotationRequestOrBuilder.java index 6d2c57f8..58123b50 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CompleteIPRotationRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CompleteIPRotationRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateClusterRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateClusterRequest.java index eaa5bab0..86fb3e18 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateClusterRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateClusterRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateClusterRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateClusterRequestOrBuilder.java index 4952dff4..98fd0436 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateClusterRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateClusterRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateNodePoolRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateNodePoolRequest.java index 185b012c..52734e3d 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateNodePoolRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateNodePoolRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateNodePoolRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateNodePoolRequestOrBuilder.java index a7f41aa7..5ff2dbb4 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateNodePoolRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/CreateNodePoolRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DailyMaintenanceWindow.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DailyMaintenanceWindow.java index f58baffb..85e2731d 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DailyMaintenanceWindow.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DailyMaintenanceWindow.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DailyMaintenanceWindowOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DailyMaintenanceWindowOrBuilder.java index a7faa6f0..0ff01bc8 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DailyMaintenanceWindowOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DailyMaintenanceWindowOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteClusterRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteClusterRequest.java index a83a848e..ee92fa9d 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteClusterRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteClusterRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteClusterRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteClusterRequestOrBuilder.java index 9497a252..18f35c5a 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteClusterRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteClusterRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteNodePoolRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteNodePoolRequest.java index b78afff9..4d8f9877 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteNodePoolRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteNodePoolRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteNodePoolRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteNodePoolRequestOrBuilder.java index 7658f608..28bdeb18 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteNodePoolRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/DeleteNodePoolRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetClusterRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetClusterRequest.java index 3c1f13ce..7b121c1f 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetClusterRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetClusterRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetClusterRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetClusterRequestOrBuilder.java index 3622e473..4b4550da 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetClusterRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetClusterRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetNodePoolRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetNodePoolRequest.java index 1ab06d9f..cead270f 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetNodePoolRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetNodePoolRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetNodePoolRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetNodePoolRequestOrBuilder.java index 9f04d993..d0e46d87 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetNodePoolRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetNodePoolRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetOperationRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetOperationRequest.java index fcf9b785..eb4c2ac6 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetOperationRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetOperationRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetOperationRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetOperationRequestOrBuilder.java index 14defabd..b9857f35 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetOperationRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetOperationRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetServerConfigRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetServerConfigRequest.java index 41795a88..cb58bc37 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetServerConfigRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetServerConfigRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetServerConfigRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetServerConfigRequestOrBuilder.java index e86a0c9f..55820bed 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetServerConfigRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/GetServerConfigRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HorizontalPodAutoscaling.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HorizontalPodAutoscaling.java index 5cb0f345..5fcb2d28 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HorizontalPodAutoscaling.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HorizontalPodAutoscaling.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HorizontalPodAutoscalingOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HorizontalPodAutoscalingOrBuilder.java index 04500921..ce28611c 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HorizontalPodAutoscalingOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HorizontalPodAutoscalingOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HttpLoadBalancing.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HttpLoadBalancing.java index c3ffe047..1a7ded3a 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HttpLoadBalancing.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HttpLoadBalancing.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HttpLoadBalancingOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HttpLoadBalancingOrBuilder.java index da283543..5f859bf9 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HttpLoadBalancingOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/HttpLoadBalancingOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/IPAllocationPolicy.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/IPAllocationPolicy.java index aca66076..dbb42012 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/IPAllocationPolicy.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/IPAllocationPolicy.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/IPAllocationPolicyOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/IPAllocationPolicyOrBuilder.java index b11ec60a..a551b757 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/IPAllocationPolicyOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/IPAllocationPolicyOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/KubernetesDashboard.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/KubernetesDashboard.java index bd3764f3..31f9b400 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/KubernetesDashboard.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/KubernetesDashboard.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/KubernetesDashboardOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/KubernetesDashboardOrBuilder.java index d26e9520..c87280a1 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/KubernetesDashboardOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/KubernetesDashboardOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/LegacyAbac.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/LegacyAbac.java index 92429f4e..9205346e 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/LegacyAbac.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/LegacyAbac.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/LegacyAbacOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/LegacyAbacOrBuilder.java index 7ebceae3..ea5a1a52 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/LegacyAbacOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/LegacyAbacOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersRequest.java index edd51efc..c8343091 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersRequestOrBuilder.java index f4be25d1..6950a546 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersResponse.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersResponse.java index 9cd05a1f..f7881bc0 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersResponse.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersResponse.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersResponseOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersResponseOrBuilder.java index 3daff27d..5c89ab6e 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersResponseOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListClustersResponseOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsRequest.java index 346456a8..0baf27e9 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsRequestOrBuilder.java index 5a337d0b..5ed2a8dd 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsResponse.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsResponse.java index 1412ca3a..99a5e6e4 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsResponse.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsResponse.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsResponseOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsResponseOrBuilder.java index 9b448efe..d6015818 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsResponseOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListNodePoolsResponseOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsRequest.java index 6e5a3c5f..8497ef35 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsRequestOrBuilder.java index 8897fbf2..dc926252 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsResponse.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsResponse.java index 137a99b0..f9fe7b85 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsResponse.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsResponse.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsResponseOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsResponseOrBuilder.java index e286e06a..ae5b61c0 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsResponseOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ListOperationsResponseOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenancePolicy.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenancePolicy.java index d2c6c815..359ec60e 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenancePolicy.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenancePolicy.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenancePolicyOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenancePolicyOrBuilder.java index 16b06356..f9c5edc1 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenancePolicyOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenancePolicyOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenanceWindow.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenanceWindow.java index 06684660..530aef8c 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenanceWindow.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenanceWindow.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenanceWindowOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenanceWindowOrBuilder.java index fe554fef..5e7f3e06 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenanceWindowOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MaintenanceWindowOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuth.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuth.java index 5cf2832a..f13ec49d 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuth.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuth.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuthOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuthOrBuilder.java index f5ccbbd4..029a377c 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuthOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuthOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuthorizedNetworksConfig.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuthorizedNetworksConfig.java index 07579ed5..6cdde30a 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuthorizedNetworksConfig.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuthorizedNetworksConfig.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuthorizedNetworksConfigOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuthorizedNetworksConfigOrBuilder.java index 7121ca7b..d766f9cf 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuthorizedNetworksConfigOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/MasterAuthorizedNetworksConfigOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkConfig.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkConfig.java index 28e1a46a..e8d6d4e6 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkConfig.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkConfig.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkConfigOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkConfigOrBuilder.java index 3aaa2e4d..e2b8e17e 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkConfigOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkConfigOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicy.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicy.java index e5c6ee86..32158902 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicy.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicy.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicyConfig.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicyConfig.java index 1dfda02a..9d7f933b 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicyConfig.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicyConfig.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicyConfigOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicyConfigOrBuilder.java index cf9176ef..932f0fcd 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicyConfigOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicyConfigOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicyOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicyOrBuilder.java index d74a697b..342ac607 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicyOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NetworkPolicyOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeConfig.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeConfig.java index 9f77b913..f90a7715 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeConfig.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeConfig.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeConfigOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeConfigOrBuilder.java index 4ee17ab9..5cabe3d8 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeConfigOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeConfigOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeManagement.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeManagement.java index 2365e52c..6eeebf41 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeManagement.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeManagement.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeManagementOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeManagementOrBuilder.java index aa01bc0f..1a580f10 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeManagementOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodeManagementOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePool.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePool.java index 59f157f3..18a4ee74 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePool.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePool.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePoolAutoscaling.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePoolAutoscaling.java index 15e3b71a..5db03801 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePoolAutoscaling.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePoolAutoscaling.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePoolAutoscalingOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePoolAutoscalingOrBuilder.java index 64125317..9444e70c 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePoolAutoscalingOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePoolAutoscalingOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePoolOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePoolOrBuilder.java index 221483ca..233080dc 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePoolOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/NodePoolOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/Operation.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/Operation.java index 59f69842..6b3f4675 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/Operation.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/Operation.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/OperationOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/OperationOrBuilder.java index fce9492b..780422d5 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/OperationOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/OperationOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/PrivateClusterConfig.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/PrivateClusterConfig.java index 4aa44e12..0de135b5 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/PrivateClusterConfig.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/PrivateClusterConfig.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/PrivateClusterConfigOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/PrivateClusterConfigOrBuilder.java index 56ebd19c..f6445873 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/PrivateClusterConfigOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/PrivateClusterConfigOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/RollbackNodePoolUpgradeRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/RollbackNodePoolUpgradeRequest.java index 56907d13..3990691b 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/RollbackNodePoolUpgradeRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/RollbackNodePoolUpgradeRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/RollbackNodePoolUpgradeRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/RollbackNodePoolUpgradeRequestOrBuilder.java index 3666d238..68f08938 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/RollbackNodePoolUpgradeRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/RollbackNodePoolUpgradeRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ServerConfig.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ServerConfig.java index 5bc49b8b..36c4ea49 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ServerConfig.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ServerConfig.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ServerConfigOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ServerConfigOrBuilder.java index 1d677c7c..574cab70 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ServerConfigOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/ServerConfigOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetAddonsConfigRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetAddonsConfigRequest.java index 58ae12a3..704c61db 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetAddonsConfigRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetAddonsConfigRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetAddonsConfigRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetAddonsConfigRequestOrBuilder.java index 2f5db52b..b7aa7f20 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetAddonsConfigRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetAddonsConfigRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLabelsRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLabelsRequest.java index a92ce98e..03970f9e 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLabelsRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLabelsRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLabelsRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLabelsRequestOrBuilder.java index a7d12dd3..e5469fdb 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLabelsRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLabelsRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLegacyAbacRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLegacyAbacRequest.java index 845c5ec7..018f2f3e 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLegacyAbacRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLegacyAbacRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLegacyAbacRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLegacyAbacRequestOrBuilder.java index 570e2570..3465ebe6 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLegacyAbacRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLegacyAbacRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLocationsRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLocationsRequest.java index 2d0d24dc..0cb52d7f 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLocationsRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLocationsRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLocationsRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLocationsRequestOrBuilder.java index b3467de0..c7a9cfb3 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLocationsRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLocationsRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLoggingServiceRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLoggingServiceRequest.java index 0c7a8054..e78e0baf 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLoggingServiceRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLoggingServiceRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLoggingServiceRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLoggingServiceRequestOrBuilder.java index a3f8bba1..21694679 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLoggingServiceRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetLoggingServiceRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMaintenancePolicyRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMaintenancePolicyRequest.java index c9eb9505..321d8abe 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMaintenancePolicyRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMaintenancePolicyRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMaintenancePolicyRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMaintenancePolicyRequestOrBuilder.java index d8e2b5a3..46140698 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMaintenancePolicyRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMaintenancePolicyRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMasterAuthRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMasterAuthRequest.java index 67ee1c4d..6a9988a1 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMasterAuthRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMasterAuthRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMasterAuthRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMasterAuthRequestOrBuilder.java index 17336219..d2ebd196 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMasterAuthRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMasterAuthRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMonitoringServiceRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMonitoringServiceRequest.java index e317136d..7addc2b4 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMonitoringServiceRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMonitoringServiceRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMonitoringServiceRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMonitoringServiceRequestOrBuilder.java index a98f6984..21579d5b 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMonitoringServiceRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetMonitoringServiceRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNetworkPolicyRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNetworkPolicyRequest.java index 0fe2c5f5..3734662e 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNetworkPolicyRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNetworkPolicyRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNetworkPolicyRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNetworkPolicyRequestOrBuilder.java index 4d8453e2..7d045c7b 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNetworkPolicyRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNetworkPolicyRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolAutoscalingRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolAutoscalingRequest.java index 98942ad9..c6012465 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolAutoscalingRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolAutoscalingRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolAutoscalingRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolAutoscalingRequestOrBuilder.java index 44e0faf8..03483e7b 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolAutoscalingRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolAutoscalingRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolManagementRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolManagementRequest.java index 6cc53348..b7d82aeb 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolManagementRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolManagementRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolManagementRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolManagementRequestOrBuilder.java index b2c859ac..cb15960c 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolManagementRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolManagementRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolSizeRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolSizeRequest.java index edba389e..bbb48593 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolSizeRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolSizeRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolSizeRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolSizeRequestOrBuilder.java index 2760ff57..c11f9187 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolSizeRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/SetNodePoolSizeRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/StartIPRotationRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/StartIPRotationRequest.java index 2dad2d55..c1e209ea 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/StartIPRotationRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/StartIPRotationRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/StartIPRotationRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/StartIPRotationRequestOrBuilder.java index 9e400700..c6756d59 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/StartIPRotationRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/StartIPRotationRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateClusterRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateClusterRequest.java index ab673582..601bf274 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateClusterRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateClusterRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateClusterRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateClusterRequestOrBuilder.java index 9fd03604..fa3eabb7 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateClusterRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateClusterRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateMasterRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateMasterRequest.java index 16ea42bd..42eba598 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateMasterRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateMasterRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateMasterRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateMasterRequestOrBuilder.java index b81c3df0..51d814e7 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateMasterRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateMasterRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateNodePoolRequest.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateNodePoolRequest.java index 9dcd308f..61906f52 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateNodePoolRequest.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateNodePoolRequest.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateNodePoolRequestOrBuilder.java b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateNodePoolRequestOrBuilder.java index 1e5e5b7f..0c688913 100644 --- a/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateNodePoolRequestOrBuilder.java +++ b/proto-google-cloud-container-v1/src/main/java/com/google/container/v1/UpdateNodePoolRequestOrBuilder.java @@ -1,3 +1,18 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/container/v1/cluster_service.proto diff --git a/proto-google-cloud-containeranalysis-v1/pom.xml b/proto-google-cloud-containeranalysis-v1/pom.xml deleted file mode 100644 index 3f3412e7..00000000 --- a/proto-google-cloud-containeranalysis-v1/pom.xml +++ /dev/null @@ -1,36 +0,0 @@ - - 4.0.0 - proto-google-cloud-containeranalysis-v1 - 0.82.0 - proto-google-cloud-containeranalysis-v1 - PROTO library for proto-google-cloud-containeranalysis-v1 - - com.google.api.grpc - google-api-grpc - 0.82.0 - - - - com.google.protobuf - protobuf-java - compile - - - com.google.api - api-common - compile - - - com.google.api.grpc - proto-google-common-protos - compile - - - com.google.api.grpc - proto-google-iam-v1 - compile - - - \ No newline at end of file diff --git a/proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/Containeranalysis.java b/proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/Containeranalysis.java deleted file mode 100644 index fc20085f..00000000 --- a/proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/Containeranalysis.java +++ /dev/null @@ -1,81 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1/containeranalysis.proto - -package com.google.containeranalysis.v1; - -public final class Containeranalysis { - private Containeranalysis() {} - - public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} - - public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { - registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); - } - - public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { - return descriptor; - } - - private static com.google.protobuf.Descriptors.FileDescriptor descriptor; - - static { - java.lang.String[] descriptorData = { - "\n fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/OccurrenceName.java deleted file mode 100644 index 6927a7e5..00000000 --- a/proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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.containeranalysis.v1; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/ProjectName.java b/proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/ProjectName.java deleted file mode 100644 index b9c9996a..00000000 --- a/proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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.containeranalysis.v1; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/UntypedIamResourceName.java deleted file mode 100644 index 019b93b0..00000000 --- a/proto-google-cloud-containeranalysis-v1/src/main/java/com/google/containeranalysis/v1/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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.containeranalysis.v1; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1/src/main/proto/google/devtools/containeranalysis/v1/containeranalysis.proto b/proto-google-cloud-containeranalysis-v1/src/main/proto/google/devtools/containeranalysis/v1/containeranalysis.proto deleted file mode 100644 index 0a54ccc6..00000000 --- a/proto-google-cloud-containeranalysis-v1/src/main/proto/google/devtools/containeranalysis/v1/containeranalysis.proto +++ /dev/null @@ -1,101 +0,0 @@ -// Copyright 2019 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. -// - -syntax = "proto3"; - -package google.devtools.containeranalysis.v1; - -import "google/api/annotations.proto"; -import "google/iam/v1/iam_policy.proto"; -import "google/iam/v1/policy.proto"; -import "google/protobuf/timestamp.proto"; - -option csharp_namespace = "Google.Cloud.DevTools.ContainerAnalysis.V1"; -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1;containeranalysis"; -option java_multiple_files = true; -option java_package = "com.google.containeranalysis.v1"; -option objc_class_prefix = "GCA"; -option ruby_package = "Google::Cloud::ContainerAnalysis::V1"; - -// Retrieves analysis results of Cloud components such as Docker container -// images. The Container Analysis API is an implementation of the -// [Grafeas](https://grafeas.io) API. -// -// Analysis results are stored as a series of occurrences. An `Occurrence` -// contains information about a specific analysis instance on a resource. An -// occurrence refers to a `Note`. A note contains details describing the -// analysis and is generally stored in a separate project, called a `Provider`. -// Multiple occurrences can refer to the same note. -// -// For example, an SSL vulnerability could affect multiple images. In this case, -// there would be one note for the vulnerability and an occurrence for each -// image with the vulnerability referring to that note. -service ContainerAnalysis { - // Sets the access control policy on the specified note or occurrence. - // Requires `containeranalysis.notes.setIamPolicy` or - // `containeranalysis.occurrences.setIamPolicy` permission if the resource is - // a note or an occurrence, respectively. - // - // The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for - // notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for - // occurrences. - rpc SetIamPolicy(google.iam.v1.SetIamPolicyRequest) returns (google.iam.v1.Policy) { - option (google.api.http) = { - post: "/v1/{resource=projects/*/notes/*}:setIamPolicy" - body: "*" - additional_bindings { - post: "/v1/{resource=projects/*/occurrences/*}:setIamPolicy" - body: "*" - } - }; - } - - // Gets the access control policy for a note or an occurrence resource. - // Requires `containeranalysis.notes.setIamPolicy` or - // `containeranalysis.occurrences.setIamPolicy` permission if the resource is - // a note or occurrence, respectively. - // - // The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for - // notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for - // occurrences. - rpc GetIamPolicy(google.iam.v1.GetIamPolicyRequest) returns (google.iam.v1.Policy) { - option (google.api.http) = { - post: "/v1/{resource=projects/*/notes/*}:getIamPolicy" - body: "*" - additional_bindings { - post: "/v1/{resource=projects/*/occurrences/*}:getIamPolicy" - body: "*" - } - }; - } - - // Returns the permissions that a caller has on the specified note or - // occurrence. Requires list permission on the project (for example, - // `containeranalysis.notes.list`). - // - // The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for - // notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for - // occurrences. - rpc TestIamPermissions(google.iam.v1.TestIamPermissionsRequest) returns (google.iam.v1.TestIamPermissionsResponse) { - option (google.api.http) = { - post: "/v1/{resource=projects/*/notes/*}:testIamPermissions" - body: "*" - additional_bindings { - post: "/v1/{resource=projects/*/occurrences/*}:testIamPermissions" - body: "*" - } - }; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/pom.xml b/proto-google-cloud-containeranalysis-v1beta1/pom.xml deleted file mode 100644 index 18dea030..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/pom.xml +++ /dev/null @@ -1,36 +0,0 @@ - - 4.0.0 - proto-google-cloud-containeranalysis-v1beta1 - 0.82.0 - proto-google-cloud-containeranalysis-v1beta1 - PROTO library for proto-google-cloud-containeranalysis-v1beta1 - - com.google.api.grpc - google-api-grpc - 0.82.0 - - - - com.google.protobuf - protobuf-java - compile - - - com.google.api - api-common - compile - - - com.google.api.grpc - proto-google-common-protos - compile - - - com.google.api.grpc - proto-google-iam-v1 - compile - - - \ No newline at end of file diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/Containeranalysis.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/Containeranalysis.java deleted file mode 100644 index fe0538dd..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/Containeranalysis.java +++ /dev/null @@ -1,170 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/containeranalysis.proto - -package com.google.containeranalysis.v1beta1; - -public final class Containeranalysis { - private Containeranalysis() {} - - 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_devtools_containeranalysis_v1beta1_ScanConfig_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_containeranalysis_v1beta1_ScanConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_containeranalysis_v1beta1_GetScanConfigRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_containeranalysis_v1beta1_GetScanConfigRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsResponse_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_containeranalysis_v1beta1_UpdateScanConfigRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_containeranalysis_v1beta1_UpdateScanConfigRequest_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { - return descriptor; - } - - private static com.google.protobuf.Descriptors.FileDescriptor descriptor; - - static { - java.lang.String[] descriptorData = { - "\nAgoogle/devtools/containeranalysis/v1be" - + "ta1/containeranalysis.proto\022)google.devt" - + "ools.containeranalysis.v1beta1\032\034google/a" - + "pi/annotations.proto\032\036google/iam/v1/iam_" - + "policy.proto\032\032google/iam/v1/policy.proto" - + "\032\037google/protobuf/timestamp.proto\"\242\001\n\nSc" - + "anConfig\022\014\n\004name\030\001 \001(\t\022\023\n\013description\030\002 " - + "\001(\t\022\017\n\007enabled\030\003 \001(\010\022/\n\013create_time\030\004 \001(" - + "\0132\032.google.protobuf.Timestamp\022/\n\013update_" - + "time\030\005 \001(\0132\032.google.protobuf.Timestamp\"$" - + "\n\024GetScanConfigRequest\022\014\n\004name\030\001 \001(\t\"_\n\026" - + "ListScanConfigsRequest\022\016\n\006parent\030\001 \001(\t\022\016" - + "\n\006filter\030\002 \001(\t\022\021\n\tpage_size\030\003 \001(\005\022\022\n\npag" - + "e_token\030\004 \001(\t\"\177\n\027ListScanConfigsResponse" - + "\022K\n\014scan_configs\030\001 \003(\01325.google.devtools" - + ".containeranalysis.v1beta1.ScanConfig\022\027\n" - + "\017next_page_token\030\002 \001(\t\"s\n\027UpdateScanConf" - + "igRequest\022\014\n\004name\030\001 \001(\t\022J\n\013scan_config\030\002" - + " \001(\01325.google.devtools.containeranalysis" - + ".v1beta1.ScanConfig2\204\n\n\030ContainerAnalysi" - + "sV1Beta1\022\311\001\n\014SetIamPolicy\022\".google.iam.v" - + "1.SetIamPolicyRequest\032\025.google.iam.v1.Po" - + "licy\"~\202\323\344\223\002x\"3/v1beta1/{resource=project" - + "s/*/notes/*}:setIamPolicy:\001*Z>\"9/v1beta1" - + "/{resource=projects/*/occurrences/*}:set" - + "IamPolicy:\001*\022\311\001\n\014GetIamPolicy\022\".google.i" - + "am.v1.GetIamPolicyRequest\032\025.google.iam.v" - + "1.Policy\"~\202\323\344\223\002x\"3/v1beta1/{resource=pro" - + "jects/*/notes/*}:getIamPolicy:\001*Z>\"9/v1b" - + "eta1/{resource=projects/*/occurrences/*}" - + ":getIamPolicy:\001*\022\367\001\n\022TestIamPermissions\022" - + "(.google.iam.v1.TestIamPermissionsReques" - + "t\032).google.iam.v1.TestIamPermissionsResp" - + "onse\"\213\001\202\323\344\223\002\204\001\"9/v1beta1/{resource=proje" - + "cts/*/notes/*}:testIamPermissions:\001*ZD\"?" - + "/v1beta1/{resource=projects/*/occurrence" - + "s/*}:testIamPermissions:\001*\022\271\001\n\rGetScanCo" - + "nfig\022?.google.devtools.containeranalysis" - + ".v1beta1.GetScanConfigRequest\0325.google.d" - + "evtools.containeranalysis.v1beta1.ScanCo" - + "nfig\"0\202\323\344\223\002*\022(/v1beta1/{name=projects/*/" - + "scanConfigs/*}\022\312\001\n\017ListScanConfigs\022A.goo" - + "gle.devtools.containeranalysis.v1beta1.L" - + "istScanConfigsRequest\032B.google.devtools." - + "containeranalysis.v1beta1.ListScanConfig" - + "sResponse\"0\202\323\344\223\002*\022(/v1beta1/{parent=proj" - + "ects/*}/scanConfigs\022\314\001\n\020UpdateScanConfig" - + "\022B.google.devtools.containeranalysis.v1b" - + "eta1.UpdateScanConfigRequest\0325.google.de" - + "vtools.containeranalysis.v1beta1.ScanCon" - + "fig\"=\202\323\344\223\0027\032(/v1beta1/{name=projects/*/s" - + "canConfigs/*}:\013scan_configB\212\001\n$com.googl" - + "e.containeranalysis.v1beta1P\001ZZgoogle.go" - + "lang.org/genproto/googleapis/devtools/co" - + "ntaineranalysis/v1beta1;containeranalysi" - + "s\242\002\003GCAb\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.iam.v1.IamPolicyProto.getDescriptor(), - com.google.iam.v1.PolicyProto.getDescriptor(), - com.google.protobuf.TimestampProto.getDescriptor(), - }, - assigner); - internal_static_google_devtools_containeranalysis_v1beta1_ScanConfig_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_google_devtools_containeranalysis_v1beta1_ScanConfig_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_containeranalysis_v1beta1_ScanConfig_descriptor, - new java.lang.String[] { - "Name", "Description", "Enabled", "CreateTime", "UpdateTime", - }); - internal_static_google_devtools_containeranalysis_v1beta1_GetScanConfigRequest_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_google_devtools_containeranalysis_v1beta1_GetScanConfigRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_containeranalysis_v1beta1_GetScanConfigRequest_descriptor, - new java.lang.String[] { - "Name", - }); - internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsRequest_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsRequest_descriptor, - new java.lang.String[] { - "Parent", "Filter", "PageSize", "PageToken", - }); - internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsResponse_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsResponse_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsResponse_descriptor, - new java.lang.String[] { - "ScanConfigs", "NextPageToken", - }); - internal_static_google_devtools_containeranalysis_v1beta1_UpdateScanConfigRequest_descriptor = - getDescriptor().getMessageTypes().get(4); - internal_static_google_devtools_containeranalysis_v1beta1_UpdateScanConfigRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_containeranalysis_v1beta1_UpdateScanConfigRequest_descriptor, - new java.lang.String[] { - "Name", "ScanConfig", - }); - com.google.protobuf.ExtensionRegistry registry = - com.google.protobuf.ExtensionRegistry.newInstance(); - registry.add(com.google.api.AnnotationsProto.http); - com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( - descriptor, registry); - com.google.api.AnnotationsProto.getDescriptor(); - com.google.iam.v1.IamPolicyProto.getDescriptor(); - com.google.iam.v1.PolicyProto.getDescriptor(); - com.google.protobuf.TimestampProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/GetScanConfigRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/GetScanConfigRequest.java deleted file mode 100644 index 2878f596..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/GetScanConfigRequest.java +++ /dev/null @@ -1,606 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/containeranalysis.proto - -package com.google.containeranalysis.v1beta1; - -/** - * - * - *
- * Request to get a scan configuration.
- * 
- * - * Protobuf type {@code google.devtools.containeranalysis.v1beta1.GetScanConfigRequest} - */ -public final class GetScanConfigRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.containeranalysis.v1beta1.GetScanConfigRequest) - GetScanConfigRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use GetScanConfigRequest.newBuilder() to construct. - private GetScanConfigRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private GetScanConfigRequest() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private GetScanConfigRequest( - 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; - } - default: - { - if (!parseUnknownField(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.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_GetScanConfigRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_GetScanConfigRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.containeranalysis.v1beta1.GetScanConfigRequest.class, - com.google.containeranalysis.v1beta1.GetScanConfigRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the scan configuration in the form of
-   * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-   * 
- * - * 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 name of the scan configuration in the form of
-   * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-   * 
- * - * 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; - } - } - - 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_); - } - 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_); - } - 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.containeranalysis.v1beta1.GetScanConfigRequest)) { - return super.equals(obj); - } - com.google.containeranalysis.v1beta1.GetScanConfigRequest other = - (com.google.containeranalysis.v1beta1.GetScanConfigRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.containeranalysis.v1beta1.GetScanConfigRequest parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.GetScanConfigRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.containeranalysis.v1beta1.GetScanConfigRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.GetScanConfigRequest 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.containeranalysis.v1beta1.GetScanConfigRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.GetScanConfigRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.containeranalysis.v1beta1.GetScanConfigRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.GetScanConfigRequest 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.containeranalysis.v1beta1.GetScanConfigRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.GetScanConfigRequest 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.containeranalysis.v1beta1.GetScanConfigRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.GetScanConfigRequest 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.containeranalysis.v1beta1.GetScanConfigRequest 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 to get a scan configuration.
-   * 
- * - * Protobuf type {@code google.devtools.containeranalysis.v1beta1.GetScanConfigRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.containeranalysis.v1beta1.GetScanConfigRequest) - com.google.containeranalysis.v1beta1.GetScanConfigRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_GetScanConfigRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_GetScanConfigRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.containeranalysis.v1beta1.GetScanConfigRequest.class, - com.google.containeranalysis.v1beta1.GetScanConfigRequest.Builder.class); - } - - // Construct using com.google.containeranalysis.v1beta1.GetScanConfigRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_GetScanConfigRequest_descriptor; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.GetScanConfigRequest getDefaultInstanceForType() { - return com.google.containeranalysis.v1beta1.GetScanConfigRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.GetScanConfigRequest build() { - com.google.containeranalysis.v1beta1.GetScanConfigRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.GetScanConfigRequest buildPartial() { - com.google.containeranalysis.v1beta1.GetScanConfigRequest result = - new com.google.containeranalysis.v1beta1.GetScanConfigRequest(this); - result.name_ = name_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.containeranalysis.v1beta1.GetScanConfigRequest) { - return mergeFrom((com.google.containeranalysis.v1beta1.GetScanConfigRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.containeranalysis.v1beta1.GetScanConfigRequest other) { - if (other == com.google.containeranalysis.v1beta1.GetScanConfigRequest.getDefaultInstance()) - return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.containeranalysis.v1beta1.GetScanConfigRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.containeranalysis.v1beta1.GetScanConfigRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * 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 name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * 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 name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.containeranalysis.v1beta1.GetScanConfigRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.containeranalysis.v1beta1.GetScanConfigRequest) - private static final com.google.containeranalysis.v1beta1.GetScanConfigRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.containeranalysis.v1beta1.GetScanConfigRequest(); - } - - public static com.google.containeranalysis.v1beta1.GetScanConfigRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetScanConfigRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new GetScanConfigRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.GetScanConfigRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/GetScanConfigRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/GetScanConfigRequestOrBuilder.java deleted file mode 100644 index ce33e312..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/GetScanConfigRequestOrBuilder.java +++ /dev/null @@ -1,33 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/containeranalysis.proto - -package com.google.containeranalysis.v1beta1; - -public interface GetScanConfigRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.containeranalysis.v1beta1.GetScanConfigRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the scan configuration in the form of
-   * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the scan configuration in the form of
-   * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/IamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/IamResourceName.java deleted file mode 100644 index 53ba6cb9..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/IamResourceName.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * 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.containeranalysis.v1beta1; - -import com.google.api.resourcenames.ResourceName; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public abstract class IamResourceName implements ResourceName { - protected IamResourceName() {} -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/IamResourceNames.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/IamResourceNames.java deleted file mode 100644 index ab4cab95..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/IamResourceNames.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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.containeranalysis.v1beta1; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class IamResourceNames { - private IamResourceNames() {} - - public static IamResourceName parse(String resourceNameString) { - if (NoteName.isParsableFrom(resourceNameString)) { - return NoteName.parse(resourceNameString); - } - if (OccurrenceName.isParsableFrom(resourceNameString)) { - return OccurrenceName.parse(resourceNameString); - } - return UntypedIamResourceName.parse(resourceNameString); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsRequest.java deleted file mode 100644 index 55acacc0..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsRequest.java +++ /dev/null @@ -1,1007 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/containeranalysis.proto - -package com.google.containeranalysis.v1beta1; - -/** - * - * - *
- * Request to list scan configurations.
- * 
- * - * Protobuf type {@code google.devtools.containeranalysis.v1beta1.ListScanConfigsRequest} - */ -public final class ListScanConfigsRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.containeranalysis.v1beta1.ListScanConfigsRequest) - ListScanConfigsRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListScanConfigsRequest.newBuilder() to construct. - private ListScanConfigsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListScanConfigsRequest() { - parent_ = ""; - filter_ = ""; - pageToken_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ListScanConfigsRequest( - 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(); - - filter_ = s; - break; - } - case 24: - { - pageSize_ = input.readInt32(); - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(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.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.containeranalysis.v1beta1.ListScanConfigsRequest.class, - com.google.containeranalysis.v1beta1.ListScanConfigsRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 1; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * The name of the project to list scan configurations for in the form of
-   * `projects/[PROJECT_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; - } - } - /** - * - * - *
-   * The name of the project to list scan configurations for in the form of
-   * `projects/[PROJECT_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 FILTER_FIELD_NUMBER = 2; - private volatile java.lang.Object filter_; - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - 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(); - filter_ = s; - return s; - } - } - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PAGE_SIZE_FIELD_NUMBER = 3; - private int pageSize_; - /** - * - * - *
-   * The number of scan configs to return in the list.
-   * 
- * - * int32 page_size = 3; - */ - public int getPageSize() { - return pageSize_; - } - - public static final int PAGE_TOKEN_FIELD_NUMBER = 4; - private volatile java.lang.Object pageToken_; - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - 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(); - pageToken_ = s; - return s; - } - } - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getParentBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); - } - if (!getFilterBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, filter_); - } - if (pageSize_ != 0) { - output.writeInt32(3, pageSize_); - } - if (!getPageTokenBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, pageToken_); - } - 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 (!getFilterBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, filter_); - } - if (pageSize_ != 0) { - size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, pageSize_); - } - if (!getPageTokenBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, pageToken_); - } - 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.containeranalysis.v1beta1.ListScanConfigsRequest)) { - return super.equals(obj); - } - com.google.containeranalysis.v1beta1.ListScanConfigsRequest other = - (com.google.containeranalysis.v1beta1.ListScanConfigsRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (!getFilter().equals(other.getFilter())) return false; - if (getPageSize() != other.getPageSize()) return false; - if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - hash = (37 * hash) + FILTER_FIELD_NUMBER; - hash = (53 * hash) + getFilter().hashCode(); - hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; - hash = (53 * hash) + getPageSize(); - hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsRequest parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsRequest 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.containeranalysis.v1beta1.ListScanConfigsRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsRequest 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.containeranalysis.v1beta1.ListScanConfigsRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsRequest 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.containeranalysis.v1beta1.ListScanConfigsRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsRequest 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.containeranalysis.v1beta1.ListScanConfigsRequest 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 to list scan configurations.
-   * 
- * - * Protobuf type {@code google.devtools.containeranalysis.v1beta1.ListScanConfigsRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.containeranalysis.v1beta1.ListScanConfigsRequest) - com.google.containeranalysis.v1beta1.ListScanConfigsRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.containeranalysis.v1beta1.ListScanConfigsRequest.class, - com.google.containeranalysis.v1beta1.ListScanConfigsRequest.Builder.class); - } - - // Construct using com.google.containeranalysis.v1beta1.ListScanConfigsRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - filter_ = ""; - - pageSize_ = 0; - - pageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsRequest_descriptor; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.ListScanConfigsRequest getDefaultInstanceForType() { - return com.google.containeranalysis.v1beta1.ListScanConfigsRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.ListScanConfigsRequest build() { - com.google.containeranalysis.v1beta1.ListScanConfigsRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.ListScanConfigsRequest buildPartial() { - com.google.containeranalysis.v1beta1.ListScanConfigsRequest result = - new com.google.containeranalysis.v1beta1.ListScanConfigsRequest(this); - result.parent_ = parent_; - result.filter_ = filter_; - result.pageSize_ = pageSize_; - result.pageToken_ = pageToken_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.containeranalysis.v1beta1.ListScanConfigsRequest) { - return mergeFrom((com.google.containeranalysis.v1beta1.ListScanConfigsRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.containeranalysis.v1beta1.ListScanConfigsRequest other) { - if (other == com.google.containeranalysis.v1beta1.ListScanConfigsRequest.getDefaultInstance()) - return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (!other.getFilter().isEmpty()) { - filter_ = other.filter_; - onChanged(); - } - if (other.getPageSize() != 0) { - setPageSize(other.getPageSize()); - } - if (!other.getPageToken().isEmpty()) { - pageToken_ = other.pageToken_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.containeranalysis.v1beta1.ListScanConfigsRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.containeranalysis.v1beta1.ListScanConfigsRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * The name of the project to list scan configurations for in the form of
-     * `projects/[PROJECT_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; - } - } - /** - * - * - *
-     * The name of the project to list scan configurations for in the form of
-     * `projects/[PROJECT_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; - } - } - /** - * - * - *
-     * The name of the project to list scan configurations for in the form of
-     * `projects/[PROJECT_ID]`.
-     * 
- * - * string parent = 1; - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project to list scan configurations for in the form of
-     * `projects/[PROJECT_ID]`.
-     * 
- * - * string parent = 1; - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project to list scan configurations for in the form of
-     * `projects/[PROJECT_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 filter_ = ""; - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - filter_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder setFilter(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - filter_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder clearFilter() { - - filter_ = getDefaultInstance().getFilter(); - onChanged(); - return this; - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder setFilterBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - filter_ = value; - onChanged(); - return this; - } - - private int pageSize_; - /** - * - * - *
-     * The number of scan configs to return in the list.
-     * 
- * - * int32 page_size = 3; - */ - public int getPageSize() { - return pageSize_; - } - /** - * - * - *
-     * The number of scan configs to return in the list.
-     * 
- * - * int32 page_size = 3; - */ - public Builder setPageSize(int value) { - - pageSize_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The number of scan configs to return in the list.
-     * 
- * - * int32 page_size = 3; - */ - public Builder clearPageSize() { - - pageSize_ = 0; - onChanged(); - return this; - } - - private java.lang.Object pageToken_ = ""; - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - pageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public Builder setPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - pageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public Builder clearPageToken() { - - pageToken_ = getDefaultInstance().getPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - pageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.containeranalysis.v1beta1.ListScanConfigsRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.containeranalysis.v1beta1.ListScanConfigsRequest) - private static final com.google.containeranalysis.v1beta1.ListScanConfigsRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.containeranalysis.v1beta1.ListScanConfigsRequest(); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListScanConfigsRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListScanConfigsRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.ListScanConfigsRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsRequestOrBuilder.java deleted file mode 100644 index 1fa68848..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsRequestOrBuilder.java +++ /dev/null @@ -1,86 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/containeranalysis.proto - -package com.google.containeranalysis.v1beta1; - -public interface ListScanConfigsRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.containeranalysis.v1beta1.ListScanConfigsRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the project to list scan configurations for in the form of
-   * `projects/[PROJECT_ID]`.
-   * 
- * - * string parent = 1; - */ - java.lang.String getParent(); - /** - * - * - *
-   * The name of the project to list scan configurations for in the form of
-   * `projects/[PROJECT_ID]`.
-   * 
- * - * string parent = 1; - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - java.lang.String getFilter(); - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - com.google.protobuf.ByteString getFilterBytes(); - - /** - * - * - *
-   * The number of scan configs to return in the list.
-   * 
- * - * int32 page_size = 3; - */ - int getPageSize(); - - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - java.lang.String getPageToken(); - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - com.google.protobuf.ByteString getPageTokenBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsResponse.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsResponse.java deleted file mode 100644 index d13901d3..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsResponse.java +++ /dev/null @@ -1,1114 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/containeranalysis.proto - -package com.google.containeranalysis.v1beta1; - -/** - * - * - *
- * Response for listing scan configurations.
- * 
- * - * Protobuf type {@code google.devtools.containeranalysis.v1beta1.ListScanConfigsResponse} - */ -public final class ListScanConfigsResponse extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.containeranalysis.v1beta1.ListScanConfigsResponse) - ListScanConfigsResponseOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListScanConfigsResponse.newBuilder() to construct. - private ListScanConfigsResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListScanConfigsResponse() { - scanConfigs_ = java.util.Collections.emptyList(); - nextPageToken_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ListScanConfigsResponse( - 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: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - scanConfigs_ = - new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - scanConfigs_.add( - input.readMessage( - com.google.containeranalysis.v1beta1.ScanConfig.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000001) != 0)) { - scanConfigs_ = java.util.Collections.unmodifiableList(scanConfigs_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.containeranalysis.v1beta1.ListScanConfigsResponse.class, - com.google.containeranalysis.v1beta1.ListScanConfigsResponse.Builder.class); - } - - private int bitField0_; - public static final int SCAN_CONFIGS_FIELD_NUMBER = 1; - private java.util.List scanConfigs_; - /** - * - * - *
-   * The scan configurations requested.
-   * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public java.util.List getScanConfigsList() { - return scanConfigs_; - } - /** - * - * - *
-   * The scan configurations requested.
-   * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public java.util.List - getScanConfigsOrBuilderList() { - return scanConfigs_; - } - /** - * - * - *
-   * The scan configurations requested.
-   * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public int getScanConfigsCount() { - return scanConfigs_.size(); - } - /** - * - * - *
-   * The scan configurations requested.
-   * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public com.google.containeranalysis.v1beta1.ScanConfig getScanConfigs(int index) { - return scanConfigs_.get(index); - } - /** - * - * - *
-   * The scan configurations requested.
-   * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public com.google.containeranalysis.v1beta1.ScanConfigOrBuilder getScanConfigsOrBuilder( - int index) { - return scanConfigs_.get(index); - } - - public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; - private volatile java.lang.Object nextPageToken_; - /** - * - * - *
-   * The next pagination token in the list response. It should be used as
-   * `page_token` for the following request. An empty value means no more
-   * results.
-   * 
- * - * string next_page_token = 2; - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - 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(); - nextPageToken_ = s; - return s; - } - } - /** - * - * - *
-   * The next pagination token in the list response. It should be used as
-   * `page_token` for the following request. An empty value means no more
-   * results.
-   * 
- * - * string next_page_token = 2; - */ - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < scanConfigs_.size(); i++) { - output.writeMessage(1, scanConfigs_.get(i)); - } - if (!getNextPageTokenBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < scanConfigs_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, scanConfigs_.get(i)); - } - if (!getNextPageTokenBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); - } - 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.containeranalysis.v1beta1.ListScanConfigsResponse)) { - return super.equals(obj); - } - com.google.containeranalysis.v1beta1.ListScanConfigsResponse other = - (com.google.containeranalysis.v1beta1.ListScanConfigsResponse) obj; - - if (!getScanConfigsList().equals(other.getScanConfigsList())) return false; - if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getScanConfigsCount() > 0) { - hash = (37 * hash) + SCAN_CONFIGS_FIELD_NUMBER; - hash = (53 * hash) + getScanConfigsList().hashCode(); - } - hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsResponse parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsResponse parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsResponse 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.containeranalysis.v1beta1.ListScanConfigsResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsResponse parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsResponse parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsResponse 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.containeranalysis.v1beta1.ListScanConfigsResponse parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsResponse 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.containeranalysis.v1beta1.ListScanConfigsResponse parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsResponse 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.containeranalysis.v1beta1.ListScanConfigsResponse 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; - } - /** - * - * - *
-   * Response for listing scan configurations.
-   * 
- * - * Protobuf type {@code google.devtools.containeranalysis.v1beta1.ListScanConfigsResponse} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.containeranalysis.v1beta1.ListScanConfigsResponse) - com.google.containeranalysis.v1beta1.ListScanConfigsResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.containeranalysis.v1beta1.ListScanConfigsResponse.class, - com.google.containeranalysis.v1beta1.ListScanConfigsResponse.Builder.class); - } - - // Construct using com.google.containeranalysis.v1beta1.ListScanConfigsResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getScanConfigsFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (scanConfigsBuilder_ == null) { - scanConfigs_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - scanConfigsBuilder_.clear(); - } - nextPageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ListScanConfigsResponse_descriptor; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.ListScanConfigsResponse - getDefaultInstanceForType() { - return com.google.containeranalysis.v1beta1.ListScanConfigsResponse.getDefaultInstance(); - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.ListScanConfigsResponse build() { - com.google.containeranalysis.v1beta1.ListScanConfigsResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.ListScanConfigsResponse buildPartial() { - com.google.containeranalysis.v1beta1.ListScanConfigsResponse result = - new com.google.containeranalysis.v1beta1.ListScanConfigsResponse(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (scanConfigsBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - scanConfigs_ = java.util.Collections.unmodifiableList(scanConfigs_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.scanConfigs_ = scanConfigs_; - } else { - result.scanConfigs_ = scanConfigsBuilder_.build(); - } - result.nextPageToken_ = nextPageToken_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.containeranalysis.v1beta1.ListScanConfigsResponse) { - return mergeFrom((com.google.containeranalysis.v1beta1.ListScanConfigsResponse) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.containeranalysis.v1beta1.ListScanConfigsResponse other) { - if (other - == com.google.containeranalysis.v1beta1.ListScanConfigsResponse.getDefaultInstance()) - return this; - if (scanConfigsBuilder_ == null) { - if (!other.scanConfigs_.isEmpty()) { - if (scanConfigs_.isEmpty()) { - scanConfigs_ = other.scanConfigs_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureScanConfigsIsMutable(); - scanConfigs_.addAll(other.scanConfigs_); - } - onChanged(); - } - } else { - if (!other.scanConfigs_.isEmpty()) { - if (scanConfigsBuilder_.isEmpty()) { - scanConfigsBuilder_.dispose(); - scanConfigsBuilder_ = null; - scanConfigs_ = other.scanConfigs_; - bitField0_ = (bitField0_ & ~0x00000001); - scanConfigsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getScanConfigsFieldBuilder() - : null; - } else { - scanConfigsBuilder_.addAllMessages(other.scanConfigs_); - } - } - } - if (!other.getNextPageToken().isEmpty()) { - nextPageToken_ = other.nextPageToken_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.containeranalysis.v1beta1.ListScanConfigsResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.containeranalysis.v1beta1.ListScanConfigsResponse) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.util.List scanConfigs_ = - java.util.Collections.emptyList(); - - private void ensureScanConfigsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - scanConfigs_ = - new java.util.ArrayList(scanConfigs_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.containeranalysis.v1beta1.ScanConfig, - com.google.containeranalysis.v1beta1.ScanConfig.Builder, - com.google.containeranalysis.v1beta1.ScanConfigOrBuilder> - scanConfigsBuilder_; - - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public java.util.List getScanConfigsList() { - if (scanConfigsBuilder_ == null) { - return java.util.Collections.unmodifiableList(scanConfigs_); - } else { - return scanConfigsBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public int getScanConfigsCount() { - if (scanConfigsBuilder_ == null) { - return scanConfigs_.size(); - } else { - return scanConfigsBuilder_.getCount(); - } - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public com.google.containeranalysis.v1beta1.ScanConfig getScanConfigs(int index) { - if (scanConfigsBuilder_ == null) { - return scanConfigs_.get(index); - } else { - return scanConfigsBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public Builder setScanConfigs( - int index, com.google.containeranalysis.v1beta1.ScanConfig value) { - if (scanConfigsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureScanConfigsIsMutable(); - scanConfigs_.set(index, value); - onChanged(); - } else { - scanConfigsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public Builder setScanConfigs( - int index, com.google.containeranalysis.v1beta1.ScanConfig.Builder builderForValue) { - if (scanConfigsBuilder_ == null) { - ensureScanConfigsIsMutable(); - scanConfigs_.set(index, builderForValue.build()); - onChanged(); - } else { - scanConfigsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public Builder addScanConfigs(com.google.containeranalysis.v1beta1.ScanConfig value) { - if (scanConfigsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureScanConfigsIsMutable(); - scanConfigs_.add(value); - onChanged(); - } else { - scanConfigsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public Builder addScanConfigs( - int index, com.google.containeranalysis.v1beta1.ScanConfig value) { - if (scanConfigsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureScanConfigsIsMutable(); - scanConfigs_.add(index, value); - onChanged(); - } else { - scanConfigsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public Builder addScanConfigs( - com.google.containeranalysis.v1beta1.ScanConfig.Builder builderForValue) { - if (scanConfigsBuilder_ == null) { - ensureScanConfigsIsMutable(); - scanConfigs_.add(builderForValue.build()); - onChanged(); - } else { - scanConfigsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public Builder addScanConfigs( - int index, com.google.containeranalysis.v1beta1.ScanConfig.Builder builderForValue) { - if (scanConfigsBuilder_ == null) { - ensureScanConfigsIsMutable(); - scanConfigs_.add(index, builderForValue.build()); - onChanged(); - } else { - scanConfigsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public Builder addAllScanConfigs( - java.lang.Iterable values) { - if (scanConfigsBuilder_ == null) { - ensureScanConfigsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, scanConfigs_); - onChanged(); - } else { - scanConfigsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public Builder clearScanConfigs() { - if (scanConfigsBuilder_ == null) { - scanConfigs_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - scanConfigsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public Builder removeScanConfigs(int index) { - if (scanConfigsBuilder_ == null) { - ensureScanConfigsIsMutable(); - scanConfigs_.remove(index); - onChanged(); - } else { - scanConfigsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public com.google.containeranalysis.v1beta1.ScanConfig.Builder getScanConfigsBuilder( - int index) { - return getScanConfigsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public com.google.containeranalysis.v1beta1.ScanConfigOrBuilder getScanConfigsOrBuilder( - int index) { - if (scanConfigsBuilder_ == null) { - return scanConfigs_.get(index); - } else { - return scanConfigsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public java.util.List - getScanConfigsOrBuilderList() { - if (scanConfigsBuilder_ != null) { - return scanConfigsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(scanConfigs_); - } - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public com.google.containeranalysis.v1beta1.ScanConfig.Builder addScanConfigsBuilder() { - return getScanConfigsFieldBuilder() - .addBuilder(com.google.containeranalysis.v1beta1.ScanConfig.getDefaultInstance()); - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public com.google.containeranalysis.v1beta1.ScanConfig.Builder addScanConfigsBuilder( - int index) { - return getScanConfigsFieldBuilder() - .addBuilder(index, com.google.containeranalysis.v1beta1.ScanConfig.getDefaultInstance()); - } - /** - * - * - *
-     * The scan configurations requested.
-     * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - public java.util.List - getScanConfigsBuilderList() { - return getScanConfigsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.containeranalysis.v1beta1.ScanConfig, - com.google.containeranalysis.v1beta1.ScanConfig.Builder, - com.google.containeranalysis.v1beta1.ScanConfigOrBuilder> - getScanConfigsFieldBuilder() { - if (scanConfigsBuilder_ == null) { - scanConfigsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.containeranalysis.v1beta1.ScanConfig, - com.google.containeranalysis.v1beta1.ScanConfig.Builder, - com.google.containeranalysis.v1beta1.ScanConfigOrBuilder>( - scanConfigs_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - scanConfigs_ = null; - } - return scanConfigsBuilder_; - } - - private java.lang.Object nextPageToken_ = ""; - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextPageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public Builder setNextPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - nextPageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public Builder clearNextPageToken() { - - nextPageToken_ = getDefaultInstance().getNextPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - nextPageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.containeranalysis.v1beta1.ListScanConfigsResponse) - } - - // @@protoc_insertion_point(class_scope:google.devtools.containeranalysis.v1beta1.ListScanConfigsResponse) - private static final com.google.containeranalysis.v1beta1.ListScanConfigsResponse - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.containeranalysis.v1beta1.ListScanConfigsResponse(); - } - - public static com.google.containeranalysis.v1beta1.ListScanConfigsResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListScanConfigsResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListScanConfigsResponse(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.ListScanConfigsResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsResponseOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsResponseOrBuilder.java deleted file mode 100644 index 1be54784..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ListScanConfigsResponseOrBuilder.java +++ /dev/null @@ -1,87 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/containeranalysis.proto - -package com.google.containeranalysis.v1beta1; - -public interface ListScanConfigsResponseOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.containeranalysis.v1beta1.ListScanConfigsResponse) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The scan configurations requested.
-   * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - java.util.List getScanConfigsList(); - /** - * - * - *
-   * The scan configurations requested.
-   * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - com.google.containeranalysis.v1beta1.ScanConfig getScanConfigs(int index); - /** - * - * - *
-   * The scan configurations requested.
-   * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - int getScanConfigsCount(); - /** - * - * - *
-   * The scan configurations requested.
-   * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - java.util.List - getScanConfigsOrBuilderList(); - /** - * - * - *
-   * The scan configurations requested.
-   * 
- * - * repeated .google.devtools.containeranalysis.v1beta1.ScanConfig scan_configs = 1; - */ - com.google.containeranalysis.v1beta1.ScanConfigOrBuilder getScanConfigsOrBuilder(int index); - - /** - * - * - *
-   * The next pagination token in the list response. It should be used as
-   * `page_token` for the following request. An empty value means no more
-   * results.
-   * 
- * - * string next_page_token = 2; - */ - java.lang.String getNextPageToken(); - /** - * - * - *
-   * The next pagination token in the list response. It should be used as
-   * `page_token` for the following request. An empty value means no more
-   * results.
-   * 
- * - * string next_page_token = 2; - */ - com.google.protobuf.ByteString getNextPageTokenBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/NoteName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/NoteName.java deleted file mode 100644 index 464012ec..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/NoteName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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.containeranalysis.v1beta1; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class NoteName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/notes/{note}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/OccurrenceName.java deleted file mode 100644 index 2b71eaf0..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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.containeranalysis.v1beta1; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ProjectName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ProjectName.java deleted file mode 100644 index e76864c7..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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.containeranalysis.v1beta1; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ScanConfig.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ScanConfig.java deleted file mode 100644 index ed284f0b..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ScanConfig.java +++ /dev/null @@ -1,1377 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/containeranalysis.proto - -package com.google.containeranalysis.v1beta1; - -/** - * - * - *
- * A scan configuration specifies whether Cloud components in a project have a
- * particular type of analysis being run. For example, it can configure whether
- * vulnerability scanning is being done on Docker images or not.
- * 
- * - * Protobuf type {@code google.devtools.containeranalysis.v1beta1.ScanConfig} - */ -public final class ScanConfig extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.containeranalysis.v1beta1.ScanConfig) - ScanConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use ScanConfig.newBuilder() to construct. - private ScanConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ScanConfig() { - name_ = ""; - description_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ScanConfig( - 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(); - - description_ = s; - break; - } - case 24: - { - enabled_ = input.readBool(); - break; - } - case 34: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 42: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (updateTime_ != null) { - subBuilder = updateTime_.toBuilder(); - } - updateTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateTime_); - updateTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ScanConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ScanConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.containeranalysis.v1beta1.ScanConfig.class, - com.google.containeranalysis.v1beta1.ScanConfig.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Output only. The name of the scan configuration in the form of
-   * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-   * 
- * - * 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; - } - } - /** - * - * - *
-   * Output only. The name of the scan configuration in the form of
-   * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-   * 
- * - * 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 DESCRIPTION_FIELD_NUMBER = 2; - private volatile java.lang.Object description_; - /** - * - * - *
-   * Output only. A human-readable description of what the scan configuration
-   * does.
-   * 
- * - * string description = 2; - */ - public java.lang.String getDescription() { - java.lang.Object ref = description_; - 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(); - description_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. A human-readable description of what the scan configuration
-   * does.
-   * 
- * - * string description = 2; - */ - public com.google.protobuf.ByteString getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ENABLED_FIELD_NUMBER = 3; - private boolean enabled_; - /** - * - * - *
-   * Whether the scan is enabled.
-   * 
- * - * bool enabled = 3; - */ - public boolean getEnabled() { - return enabled_; - } - - public static final int CREATE_TIME_FIELD_NUMBER = 4; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-   * Output only. The time this scan config was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-   * Output only. The time this scan config was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-   * Output only. The time this scan config was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int UPDATE_TIME_FIELD_NUMBER = 5; - private com.google.protobuf.Timestamp updateTime_; - /** - * - * - *
-   * Output only. The time this scan config was last updated.
-   * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - public boolean hasUpdateTime() { - return updateTime_ != null; - } - /** - * - * - *
-   * Output only. The time this scan config was last updated.
-   * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - public com.google.protobuf.Timestamp getUpdateTime() { - return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; - } - /** - * - * - *
-   * Output only. The time this scan config was last updated.
-   * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - 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 (!getDescriptionBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, description_); - } - if (enabled_ != false) { - output.writeBool(3, enabled_); - } - if (createTime_ != null) { - output.writeMessage(4, getCreateTime()); - } - if (updateTime_ != null) { - output.writeMessage(5, 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 (!getDescriptionBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_); - } - if (enabled_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, enabled_); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getCreateTime()); - } - if (updateTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getUpdateTime()); - } - 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.containeranalysis.v1beta1.ScanConfig)) { - return super.equals(obj); - } - com.google.containeranalysis.v1beta1.ScanConfig other = - (com.google.containeranalysis.v1beta1.ScanConfig) obj; - - if (!getName().equals(other.getName())) return false; - if (!getDescription().equals(other.getDescription())) return false; - if (getEnabled() != other.getEnabled()) return false; - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasUpdateTime() != other.hasUpdateTime()) return false; - if (hasUpdateTime()) { - if (!getUpdateTime().equals(other.getUpdateTime())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; - hash = (53 * hash) + getDescription().hashCode(); - hash = (37 * hash) + ENABLED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getEnabled()); - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasUpdateTime()) { - hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getUpdateTime().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.containeranalysis.v1beta1.ScanConfig parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.ScanConfig parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.containeranalysis.v1beta1.ScanConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.ScanConfig 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.containeranalysis.v1beta1.ScanConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.ScanConfig parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.containeranalysis.v1beta1.ScanConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.ScanConfig 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.containeranalysis.v1beta1.ScanConfig parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.ScanConfig 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.containeranalysis.v1beta1.ScanConfig parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.ScanConfig 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.containeranalysis.v1beta1.ScanConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A scan configuration specifies whether Cloud components in a project have a
-   * particular type of analysis being run. For example, it can configure whether
-   * vulnerability scanning is being done on Docker images or not.
-   * 
- * - * Protobuf type {@code google.devtools.containeranalysis.v1beta1.ScanConfig} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.containeranalysis.v1beta1.ScanConfig) - com.google.containeranalysis.v1beta1.ScanConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ScanConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ScanConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.containeranalysis.v1beta1.ScanConfig.class, - com.google.containeranalysis.v1beta1.ScanConfig.Builder.class); - } - - // Construct using com.google.containeranalysis.v1beta1.ScanConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - description_ = ""; - - enabled_ = false; - - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (updateTimeBuilder_ == null) { - updateTime_ = null; - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_ScanConfig_descriptor; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.ScanConfig getDefaultInstanceForType() { - return com.google.containeranalysis.v1beta1.ScanConfig.getDefaultInstance(); - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.ScanConfig build() { - com.google.containeranalysis.v1beta1.ScanConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.ScanConfig buildPartial() { - com.google.containeranalysis.v1beta1.ScanConfig result = - new com.google.containeranalysis.v1beta1.ScanConfig(this); - result.name_ = name_; - result.description_ = description_; - result.enabled_ = enabled_; - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (updateTimeBuilder_ == null) { - result.updateTime_ = updateTime_; - } else { - result.updateTime_ = updateTimeBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.containeranalysis.v1beta1.ScanConfig) { - return mergeFrom((com.google.containeranalysis.v1beta1.ScanConfig) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.containeranalysis.v1beta1.ScanConfig other) { - if (other == com.google.containeranalysis.v1beta1.ScanConfig.getDefaultInstance()) - return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getDescription().isEmpty()) { - description_ = other.description_; - onChanged(); - } - if (other.getEnabled() != false) { - setEnabled(other.getEnabled()); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasUpdateTime()) { - mergeUpdateTime(other.getUpdateTime()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.containeranalysis.v1beta1.ScanConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.containeranalysis.v1beta1.ScanConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Output only. The name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * Output only. The name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * Output only. The name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * 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 java.lang.Object description_ = ""; - /** - * - * - *
-     * Output only. A human-readable description of what the scan configuration
-     * does.
-     * 
- * - * string description = 2; - */ - public java.lang.String getDescription() { - java.lang.Object ref = description_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - description_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. A human-readable description of what the scan configuration
-     * does.
-     * 
- * - * string description = 2; - */ - public com.google.protobuf.ByteString getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. A human-readable description of what the scan configuration
-     * does.
-     * 
- * - * string description = 2; - */ - public Builder setDescription(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - description_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. A human-readable description of what the scan configuration
-     * does.
-     * 
- * - * string description = 2; - */ - public Builder clearDescription() { - - description_ = getDefaultInstance().getDescription(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. A human-readable description of what the scan configuration
-     * does.
-     * 
- * - * string description = 2; - */ - public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - description_ = value; - onChanged(); - return this; - } - - private boolean enabled_; - /** - * - * - *
-     * Whether the scan is enabled.
-     * 
- * - * bool enabled = 3; - */ - public boolean getEnabled() { - return enabled_; - } - /** - * - * - *
-     * Whether the scan is enabled.
-     * 
- * - * bool enabled = 3; - */ - public Builder setEnabled(boolean value) { - - enabled_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Whether the scan is enabled.
-     * 
- * - * bool enabled = 3; - */ - public Builder clearEnabled() { - - enabled_ = false; - onChanged(); - return this; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-     * Output only. The time this scan config was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-     * Output only. The time this scan config was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. The time this scan config was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - 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; - } - /** - * - * - *
-     * Output only. The time this scan config was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. The time this scan config was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - 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; - } - /** - * - * - *
-     * Output only. The time this scan config was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. The time this scan config was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. The time this scan config was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-     * Output only. The time this scan config was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - 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_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - updateTimeBuilder_; - /** - * - * - *
-     * Output only. The time this scan config was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - public boolean hasUpdateTime() { - return updateTimeBuilder_ != null || updateTime_ != null; - } - /** - * - * - *
-     * Output only. The time this scan config was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - public com.google.protobuf.Timestamp getUpdateTime() { - if (updateTimeBuilder_ == null) { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } else { - return updateTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. The time this scan config was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - 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; - } - /** - * - * - *
-     * Output only. The time this scan config was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (updateTimeBuilder_ == null) { - updateTime_ = builderForValue.build(); - onChanged(); - } else { - updateTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. The time this scan config was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - 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; - } - /** - * - * - *
-     * Output only. The time this scan config was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - public Builder clearUpdateTime() { - if (updateTimeBuilder_ == null) { - updateTime_ = null; - onChanged(); - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. The time this scan config was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - - onChanged(); - return getUpdateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. The time this scan config was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - if (updateTimeBuilder_ != null) { - return updateTimeBuilder_.getMessageOrBuilder(); - } else { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } - } - /** - * - * - *
-     * Output only. The time this scan config was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - 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.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.containeranalysis.v1beta1.ScanConfig) - } - - // @@protoc_insertion_point(class_scope:google.devtools.containeranalysis.v1beta1.ScanConfig) - private static final com.google.containeranalysis.v1beta1.ScanConfig DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.containeranalysis.v1beta1.ScanConfig(); - } - - public static com.google.containeranalysis.v1beta1.ScanConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ScanConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ScanConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.ScanConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ScanConfigName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ScanConfigName.java deleted file mode 100644 index b4a22474..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ScanConfigName.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * 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.containeranalysis.v1beta1; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ScanConfigName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ScanConfigName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - scanConfig = Preconditions.checkNotNull(builder.getScanConfig()); - } - - public static ScanConfigName of(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build(); - } - - public static String format(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build().toString(); - } - - public static ScanConfigName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ScanConfigName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("scan_config")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ScanConfigName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("scanConfig", scanConfig); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "scan_config", scanConfig); - } - - /** Builder for ScanConfigName. */ - public static class Builder { - - private String project; - private String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setScanConfig(String scanConfig) { - this.scanConfig = scanConfig; - return this; - } - - private Builder() {} - - private Builder(ScanConfigName scanConfigName) { - project = scanConfigName.project; - scanConfig = scanConfigName.scanConfig; - } - - public ScanConfigName build() { - return new ScanConfigName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ScanConfigName) { - ScanConfigName that = (ScanConfigName) o; - return (this.project.equals(that.project)) && (this.scanConfig.equals(that.scanConfig)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= scanConfig.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ScanConfigOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ScanConfigOrBuilder.java deleted file mode 100644 index 3f9500c4..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/ScanConfigOrBuilder.java +++ /dev/null @@ -1,129 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/containeranalysis.proto - -package com.google.containeranalysis.v1beta1; - -public interface ScanConfigOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.containeranalysis.v1beta1.ScanConfig) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Output only. The name of the scan configuration in the form of
-   * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * Output only. The name of the scan configuration in the form of
-   * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Output only. A human-readable description of what the scan configuration
-   * does.
-   * 
- * - * string description = 2; - */ - java.lang.String getDescription(); - /** - * - * - *
-   * Output only. A human-readable description of what the scan configuration
-   * does.
-   * 
- * - * string description = 2; - */ - com.google.protobuf.ByteString getDescriptionBytes(); - - /** - * - * - *
-   * Whether the scan is enabled.
-   * 
- * - * bool enabled = 3; - */ - boolean getEnabled(); - - /** - * - * - *
-   * Output only. The time this scan config was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - boolean hasCreateTime(); - /** - * - * - *
-   * Output only. The time this scan config was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-   * Output only. The time this scan config was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 4; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-   * Output only. The time this scan config was last updated.
-   * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - boolean hasUpdateTime(); - /** - * - * - *
-   * Output only. The time this scan config was last updated.
-   * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - com.google.protobuf.Timestamp getUpdateTime(); - /** - * - * - *
-   * Output only. The time this scan config was last updated.
-   * 
- * - * .google.protobuf.Timestamp update_time = 5; - */ - com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/UntypedIamResourceName.java deleted file mode 100644 index a39952a3..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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.containeranalysis.v1beta1; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/UpdateScanConfigRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/UpdateScanConfigRequest.java deleted file mode 100644 index 7235a7c4..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/UpdateScanConfigRequest.java +++ /dev/null @@ -1,876 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/containeranalysis.proto - -package com.google.containeranalysis.v1beta1; - -/** - * - * - *
- * A request to update a scan configuration.
- * 
- * - * Protobuf type {@code google.devtools.containeranalysis.v1beta1.UpdateScanConfigRequest} - */ -public final class UpdateScanConfigRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.containeranalysis.v1beta1.UpdateScanConfigRequest) - UpdateScanConfigRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use UpdateScanConfigRequest.newBuilder() to construct. - private UpdateScanConfigRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private UpdateScanConfigRequest() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private UpdateScanConfigRequest( - 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.containeranalysis.v1beta1.ScanConfig.Builder subBuilder = null; - if (scanConfig_ != null) { - subBuilder = scanConfig_.toBuilder(); - } - scanConfig_ = - input.readMessage( - com.google.containeranalysis.v1beta1.ScanConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(scanConfig_); - scanConfig_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_UpdateScanConfigRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_UpdateScanConfigRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest.class, - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the scan configuration in the form of
-   * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-   * 
- * - * 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 name of the scan configuration in the form of
-   * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-   * 
- * - * 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 SCAN_CONFIG_FIELD_NUMBER = 2; - private com.google.containeranalysis.v1beta1.ScanConfig scanConfig_; - /** - * - * - *
-   * The updated scan configuration.
-   * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - public boolean hasScanConfig() { - return scanConfig_ != null; - } - /** - * - * - *
-   * The updated scan configuration.
-   * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - public com.google.containeranalysis.v1beta1.ScanConfig getScanConfig() { - return scanConfig_ == null - ? com.google.containeranalysis.v1beta1.ScanConfig.getDefaultInstance() - : scanConfig_; - } - /** - * - * - *
-   * The updated scan configuration.
-   * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - public com.google.containeranalysis.v1beta1.ScanConfigOrBuilder getScanConfigOrBuilder() { - return getScanConfig(); - } - - 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 (scanConfig_ != null) { - output.writeMessage(2, getScanConfig()); - } - 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 (scanConfig_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getScanConfig()); - } - 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.containeranalysis.v1beta1.UpdateScanConfigRequest)) { - return super.equals(obj); - } - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest other = - (com.google.containeranalysis.v1beta1.UpdateScanConfigRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (hasScanConfig() != other.hasScanConfig()) return false; - if (hasScanConfig()) { - if (!getScanConfig().equals(other.getScanConfig())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - if (hasScanConfig()) { - hash = (37 * hash) + SCAN_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getScanConfig().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.containeranalysis.v1beta1.UpdateScanConfigRequest parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.UpdateScanConfigRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.containeranalysis.v1beta1.UpdateScanConfigRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.UpdateScanConfigRequest 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.containeranalysis.v1beta1.UpdateScanConfigRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.containeranalysis.v1beta1.UpdateScanConfigRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.containeranalysis.v1beta1.UpdateScanConfigRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.UpdateScanConfigRequest 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.containeranalysis.v1beta1.UpdateScanConfigRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.UpdateScanConfigRequest 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.containeranalysis.v1beta1.UpdateScanConfigRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.containeranalysis.v1beta1.UpdateScanConfigRequest 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.containeranalysis.v1beta1.UpdateScanConfigRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A request to update a scan configuration.
-   * 
- * - * Protobuf type {@code google.devtools.containeranalysis.v1beta1.UpdateScanConfigRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.containeranalysis.v1beta1.UpdateScanConfigRequest) - com.google.containeranalysis.v1beta1.UpdateScanConfigRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_UpdateScanConfigRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_UpdateScanConfigRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest.class, - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest.Builder.class); - } - - // Construct using com.google.containeranalysis.v1beta1.UpdateScanConfigRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - if (scanConfigBuilder_ == null) { - scanConfig_ = null; - } else { - scanConfig_ = null; - scanConfigBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.containeranalysis.v1beta1.Containeranalysis - .internal_static_google_devtools_containeranalysis_v1beta1_UpdateScanConfigRequest_descriptor; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.UpdateScanConfigRequest - getDefaultInstanceForType() { - return com.google.containeranalysis.v1beta1.UpdateScanConfigRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.UpdateScanConfigRequest build() { - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.UpdateScanConfigRequest buildPartial() { - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest result = - new com.google.containeranalysis.v1beta1.UpdateScanConfigRequest(this); - result.name_ = name_; - if (scanConfigBuilder_ == null) { - result.scanConfig_ = scanConfig_; - } else { - result.scanConfig_ = scanConfigBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.containeranalysis.v1beta1.UpdateScanConfigRequest) { - return mergeFrom((com.google.containeranalysis.v1beta1.UpdateScanConfigRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.containeranalysis.v1beta1.UpdateScanConfigRequest other) { - if (other - == com.google.containeranalysis.v1beta1.UpdateScanConfigRequest.getDefaultInstance()) - return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (other.hasScanConfig()) { - mergeScanConfig(other.getScanConfig()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.containeranalysis.v1beta1.UpdateScanConfigRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.containeranalysis.v1beta1.UpdateScanConfigRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * 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 name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * 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 name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the scan configuration in the form of
-     * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-     * 
- * - * 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.containeranalysis.v1beta1.ScanConfig scanConfig_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.containeranalysis.v1beta1.ScanConfig, - com.google.containeranalysis.v1beta1.ScanConfig.Builder, - com.google.containeranalysis.v1beta1.ScanConfigOrBuilder> - scanConfigBuilder_; - /** - * - * - *
-     * The updated scan configuration.
-     * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - public boolean hasScanConfig() { - return scanConfigBuilder_ != null || scanConfig_ != null; - } - /** - * - * - *
-     * The updated scan configuration.
-     * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - public com.google.containeranalysis.v1beta1.ScanConfig getScanConfig() { - if (scanConfigBuilder_ == null) { - return scanConfig_ == null - ? com.google.containeranalysis.v1beta1.ScanConfig.getDefaultInstance() - : scanConfig_; - } else { - return scanConfigBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The updated scan configuration.
-     * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - public Builder setScanConfig(com.google.containeranalysis.v1beta1.ScanConfig value) { - if (scanConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - scanConfig_ = value; - onChanged(); - } else { - scanConfigBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The updated scan configuration.
-     * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - public Builder setScanConfig( - com.google.containeranalysis.v1beta1.ScanConfig.Builder builderForValue) { - if (scanConfigBuilder_ == null) { - scanConfig_ = builderForValue.build(); - onChanged(); - } else { - scanConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The updated scan configuration.
-     * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - public Builder mergeScanConfig(com.google.containeranalysis.v1beta1.ScanConfig value) { - if (scanConfigBuilder_ == null) { - if (scanConfig_ != null) { - scanConfig_ = - com.google.containeranalysis.v1beta1.ScanConfig.newBuilder(scanConfig_) - .mergeFrom(value) - .buildPartial(); - } else { - scanConfig_ = value; - } - onChanged(); - } else { - scanConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The updated scan configuration.
-     * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - public Builder clearScanConfig() { - if (scanConfigBuilder_ == null) { - scanConfig_ = null; - onChanged(); - } else { - scanConfig_ = null; - scanConfigBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The updated scan configuration.
-     * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - public com.google.containeranalysis.v1beta1.ScanConfig.Builder getScanConfigBuilder() { - - onChanged(); - return getScanConfigFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The updated scan configuration.
-     * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - public com.google.containeranalysis.v1beta1.ScanConfigOrBuilder getScanConfigOrBuilder() { - if (scanConfigBuilder_ != null) { - return scanConfigBuilder_.getMessageOrBuilder(); - } else { - return scanConfig_ == null - ? com.google.containeranalysis.v1beta1.ScanConfig.getDefaultInstance() - : scanConfig_; - } - } - /** - * - * - *
-     * The updated scan configuration.
-     * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.containeranalysis.v1beta1.ScanConfig, - com.google.containeranalysis.v1beta1.ScanConfig.Builder, - com.google.containeranalysis.v1beta1.ScanConfigOrBuilder> - getScanConfigFieldBuilder() { - if (scanConfigBuilder_ == null) { - scanConfigBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.containeranalysis.v1beta1.ScanConfig, - com.google.containeranalysis.v1beta1.ScanConfig.Builder, - com.google.containeranalysis.v1beta1.ScanConfigOrBuilder>( - getScanConfig(), getParentForChildren(), isClean()); - scanConfig_ = null; - } - return scanConfigBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.containeranalysis.v1beta1.UpdateScanConfigRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.containeranalysis.v1beta1.UpdateScanConfigRequest) - private static final com.google.containeranalysis.v1beta1.UpdateScanConfigRequest - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.containeranalysis.v1beta1.UpdateScanConfigRequest(); - } - - public static com.google.containeranalysis.v1beta1.UpdateScanConfigRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public UpdateScanConfigRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new UpdateScanConfigRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.containeranalysis.v1beta1.UpdateScanConfigRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/UpdateScanConfigRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/UpdateScanConfigRequestOrBuilder.java deleted file mode 100644 index 338f5650..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/com/google/containeranalysis/v1beta1/UpdateScanConfigRequestOrBuilder.java +++ /dev/null @@ -1,64 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/containeranalysis.proto - -package com.google.containeranalysis.v1beta1; - -public interface UpdateScanConfigRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.containeranalysis.v1beta1.UpdateScanConfigRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the scan configuration in the form of
-   * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the scan configuration in the form of
-   * `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * The updated scan configuration.
-   * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - boolean hasScanConfig(); - /** - * - * - *
-   * The updated scan configuration.
-   * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - com.google.containeranalysis.v1beta1.ScanConfig getScanConfig(); - /** - * - * - *
-   * The updated scan configuration.
-   * 
- * - * .google.devtools.containeranalysis.v1beta1.ScanConfig scan_config = 2; - */ - com.google.containeranalysis.v1beta1.ScanConfigOrBuilder getScanConfigOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesRequest.java deleted file mode 100644 index 4adf9d81..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesRequest.java +++ /dev/null @@ -1,924 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to create notes in batch.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.BatchCreateNotesRequest} - */ -public final class BatchCreateNotesRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.BatchCreateNotesRequest) - BatchCreateNotesRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use BatchCreateNotesRequest.newBuilder() to construct. - private BatchCreateNotesRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BatchCreateNotesRequest() { - parent_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private BatchCreateNotesRequest( - 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: - { - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - notes_ = - com.google.protobuf.MapField.newMapField(NotesDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000002; - } - com.google.protobuf.MapEntry notes__ = - input.readMessage( - NotesDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); - notes_.getMutableMap().put(notes__.getKey(), notes__.getValue()); - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateNotesRequest_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 2: - return internalGetNotes(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateNotesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.BatchCreateNotesRequest.class, - io.grafeas.v1beta1.BatchCreateNotesRequest.Builder.class); - } - - private int bitField0_; - public static final int PARENT_FIELD_NUMBER = 1; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the notes are to be created.
-   * 
- * - * 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; - } - } - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the notes are to be created.
-   * 
- * - * 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 NOTES_FIELD_NUMBER = 2; - - private static final class NotesDefaultEntryHolder { - static final com.google.protobuf.MapEntry - defaultEntry = - com.google.protobuf.MapEntry - .newDefaultInstance( - io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateNotesRequest_NotesEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.MESSAGE, - io.grafeas.v1beta1.Note.getDefaultInstance()); - } - - private com.google.protobuf.MapField notes_; - - private com.google.protobuf.MapField - internalGetNotes() { - if (notes_ == null) { - return com.google.protobuf.MapField.emptyMapField(NotesDefaultEntryHolder.defaultEntry); - } - return notes_; - } - - public int getNotesCount() { - return internalGetNotes().getMap().size(); - } - /** - * - * - *
-   * The notes to create.
-   * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - public boolean containsNotes(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - return internalGetNotes().getMap().containsKey(key); - } - /** Use {@link #getNotesMap()} instead. */ - @java.lang.Deprecated - public java.util.Map getNotes() { - return getNotesMap(); - } - /** - * - * - *
-   * The notes to create.
-   * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - public java.util.Map getNotesMap() { - return internalGetNotes().getMap(); - } - /** - * - * - *
-   * The notes to create.
-   * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - public io.grafeas.v1beta1.Note getNotesOrDefault( - java.lang.String key, io.grafeas.v1beta1.Note defaultValue) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetNotes().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-   * The notes to create.
-   * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - public io.grafeas.v1beta1.Note getNotesOrThrow(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetNotes().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - 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_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetNotes(), NotesDefaultEntryHolder.defaultEntry, 2); - 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_); - } - for (java.util.Map.Entry entry : - internalGetNotes().getMap().entrySet()) { - com.google.protobuf.MapEntry notes__ = - NotesDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, notes__); - } - 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 io.grafeas.v1beta1.BatchCreateNotesRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.BatchCreateNotesRequest other = - (io.grafeas.v1beta1.BatchCreateNotesRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (!internalGetNotes().equals(other.internalGetNotes())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - if (!internalGetNotes().getMap().isEmpty()) { - hash = (37 * hash) + NOTES_FIELD_NUMBER; - hash = (53 * hash) + internalGetNotes().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.BatchCreateNotesRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.BatchCreateNotesRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.BatchCreateNotesRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.BatchCreateNotesRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.BatchCreateNotesRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.BatchCreateNotesRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.BatchCreateNotesRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.BatchCreateNotesRequest 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 io.grafeas.v1beta1.BatchCreateNotesRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.BatchCreateNotesRequest 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 io.grafeas.v1beta1.BatchCreateNotesRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.BatchCreateNotesRequest 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(io.grafeas.v1beta1.BatchCreateNotesRequest 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 to create notes in batch.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.BatchCreateNotesRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.BatchCreateNotesRequest) - io.grafeas.v1beta1.BatchCreateNotesRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateNotesRequest_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 2: - return internalGetNotes(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 2: - return internalGetMutableNotes(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateNotesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.BatchCreateNotesRequest.class, - io.grafeas.v1beta1.BatchCreateNotesRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.BatchCreateNotesRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - internalGetMutableNotes().clear(); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateNotesRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateNotesRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.BatchCreateNotesRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateNotesRequest build() { - io.grafeas.v1beta1.BatchCreateNotesRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateNotesRequest buildPartial() { - io.grafeas.v1beta1.BatchCreateNotesRequest result = - new io.grafeas.v1beta1.BatchCreateNotesRequest(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.parent_ = parent_; - result.notes_ = internalGetNotes(); - result.notes_.makeImmutable(); - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.BatchCreateNotesRequest) { - return mergeFrom((io.grafeas.v1beta1.BatchCreateNotesRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.BatchCreateNotesRequest other) { - if (other == io.grafeas.v1beta1.BatchCreateNotesRequest.getDefaultInstance()) return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - internalGetMutableNotes().mergeFrom(other.internalGetNotes()); - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.BatchCreateNotesRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.BatchCreateNotesRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the notes are to be created.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the notes are to be created.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the notes are to be created.
-     * 
- * - * string parent = 1; - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the notes are to be created.
-     * 
- * - * string parent = 1; - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the notes are to be created.
-     * 
- * - * 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.protobuf.MapField notes_; - - private com.google.protobuf.MapField - internalGetNotes() { - if (notes_ == null) { - return com.google.protobuf.MapField.emptyMapField(NotesDefaultEntryHolder.defaultEntry); - } - return notes_; - } - - private com.google.protobuf.MapField - internalGetMutableNotes() { - onChanged(); - ; - if (notes_ == null) { - notes_ = com.google.protobuf.MapField.newMapField(NotesDefaultEntryHolder.defaultEntry); - } - if (!notes_.isMutable()) { - notes_ = notes_.copy(); - } - return notes_; - } - - public int getNotesCount() { - return internalGetNotes().getMap().size(); - } - /** - * - * - *
-     * The notes to create.
-     * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - public boolean containsNotes(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - return internalGetNotes().getMap().containsKey(key); - } - /** Use {@link #getNotesMap()} instead. */ - @java.lang.Deprecated - public java.util.Map getNotes() { - return getNotesMap(); - } - /** - * - * - *
-     * The notes to create.
-     * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - public java.util.Map getNotesMap() { - return internalGetNotes().getMap(); - } - /** - * - * - *
-     * The notes to create.
-     * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - public io.grafeas.v1beta1.Note getNotesOrDefault( - java.lang.String key, io.grafeas.v1beta1.Note defaultValue) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetNotes().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * The notes to create.
-     * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - public io.grafeas.v1beta1.Note getNotesOrThrow(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetNotes().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearNotes() { - internalGetMutableNotes().getMutableMap().clear(); - return this; - } - /** - * - * - *
-     * The notes to create.
-     * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - public Builder removeNotes(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - internalGetMutableNotes().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map getMutableNotes() { - return internalGetMutableNotes().getMutableMap(); - } - /** - * - * - *
-     * The notes to create.
-     * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - public Builder putNotes(java.lang.String key, io.grafeas.v1beta1.Note value) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - if (value == null) { - throw new java.lang.NullPointerException(); - } - internalGetMutableNotes().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-     * The notes to create.
-     * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - public Builder putAllNotes(java.util.Map values) { - internalGetMutableNotes().getMutableMap().putAll(values); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.BatchCreateNotesRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.BatchCreateNotesRequest) - private static final io.grafeas.v1beta1.BatchCreateNotesRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.BatchCreateNotesRequest(); - } - - public static io.grafeas.v1beta1.BatchCreateNotesRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BatchCreateNotesRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new BatchCreateNotesRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateNotesRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesRequestOrBuilder.java deleted file mode 100644 index 3b69c56e..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesRequestOrBuilder.java +++ /dev/null @@ -1,88 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface BatchCreateNotesRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.BatchCreateNotesRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the notes are to be created.
-   * 
- * - * string parent = 1; - */ - java.lang.String getParent(); - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the notes are to be created.
-   * 
- * - * string parent = 1; - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * The notes to create.
-   * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - int getNotesCount(); - /** - * - * - *
-   * The notes to create.
-   * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - boolean containsNotes(java.lang.String key); - /** Use {@link #getNotesMap()} instead. */ - @java.lang.Deprecated - java.util.Map getNotes(); - /** - * - * - *
-   * The notes to create.
-   * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - java.util.Map getNotesMap(); - /** - * - * - *
-   * The notes to create.
-   * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - io.grafeas.v1beta1.Note getNotesOrDefault( - java.lang.String key, io.grafeas.v1beta1.Note defaultValue); - /** - * - * - *
-   * The notes to create.
-   * 
- * - * map<string, .grafeas.v1beta1.Note> notes = 2; - */ - io.grafeas.v1beta1.Note getNotesOrThrow(java.lang.String key); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesResponse.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesResponse.java deleted file mode 100644 index bf407610..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesResponse.java +++ /dev/null @@ -1,910 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Response for creating notes in batch.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.BatchCreateNotesResponse} - */ -public final class BatchCreateNotesResponse extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.BatchCreateNotesResponse) - BatchCreateNotesResponseOrBuilder { - private static final long serialVersionUID = 0L; - // Use BatchCreateNotesResponse.newBuilder() to construct. - private BatchCreateNotesResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BatchCreateNotesResponse() { - notes_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private BatchCreateNotesResponse( - 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: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - notes_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - notes_.add(input.readMessage(io.grafeas.v1beta1.Note.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000001) != 0)) { - notes_ = java.util.Collections.unmodifiableList(notes_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateNotesResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateNotesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.BatchCreateNotesResponse.class, - io.grafeas.v1beta1.BatchCreateNotesResponse.Builder.class); - } - - public static final int NOTES_FIELD_NUMBER = 1; - private java.util.List notes_; - /** - * - * - *
-   * The notes that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public java.util.List getNotesList() { - return notes_; - } - /** - * - * - *
-   * The notes that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public java.util.List getNotesOrBuilderList() { - return notes_; - } - /** - * - * - *
-   * The notes that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public int getNotesCount() { - return notes_.size(); - } - /** - * - * - *
-   * The notes that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.Note getNotes(int index) { - return notes_.get(index); - } - /** - * - * - *
-   * The notes that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.NoteOrBuilder getNotesOrBuilder(int index) { - return notes_.get(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 { - for (int i = 0; i < notes_.size(); i++) { - output.writeMessage(1, notes_.get(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < notes_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, notes_.get(i)); - } - 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 io.grafeas.v1beta1.BatchCreateNotesResponse)) { - return super.equals(obj); - } - io.grafeas.v1beta1.BatchCreateNotesResponse other = - (io.grafeas.v1beta1.BatchCreateNotesResponse) obj; - - if (!getNotesList().equals(other.getNotesList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getNotesCount() > 0) { - hash = (37 * hash) + NOTES_FIELD_NUMBER; - hash = (53 * hash) + getNotesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.BatchCreateNotesResponse parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.BatchCreateNotesResponse parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.BatchCreateNotesResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.BatchCreateNotesResponse parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.BatchCreateNotesResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.BatchCreateNotesResponse parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.BatchCreateNotesResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.BatchCreateNotesResponse 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 io.grafeas.v1beta1.BatchCreateNotesResponse parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.BatchCreateNotesResponse 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 io.grafeas.v1beta1.BatchCreateNotesResponse parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.BatchCreateNotesResponse 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(io.grafeas.v1beta1.BatchCreateNotesResponse 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; - } - /** - * - * - *
-   * Response for creating notes in batch.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.BatchCreateNotesResponse} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.BatchCreateNotesResponse) - io.grafeas.v1beta1.BatchCreateNotesResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateNotesResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateNotesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.BatchCreateNotesResponse.class, - io.grafeas.v1beta1.BatchCreateNotesResponse.Builder.class); - } - - // Construct using io.grafeas.v1beta1.BatchCreateNotesResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getNotesFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (notesBuilder_ == null) { - notes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - notesBuilder_.clear(); - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateNotesResponse_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateNotesResponse getDefaultInstanceForType() { - return io.grafeas.v1beta1.BatchCreateNotesResponse.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateNotesResponse build() { - io.grafeas.v1beta1.BatchCreateNotesResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateNotesResponse buildPartial() { - io.grafeas.v1beta1.BatchCreateNotesResponse result = - new io.grafeas.v1beta1.BatchCreateNotesResponse(this); - int from_bitField0_ = bitField0_; - if (notesBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - notes_ = java.util.Collections.unmodifiableList(notes_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.notes_ = notes_; - } else { - result.notes_ = notesBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.BatchCreateNotesResponse) { - return mergeFrom((io.grafeas.v1beta1.BatchCreateNotesResponse) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.BatchCreateNotesResponse other) { - if (other == io.grafeas.v1beta1.BatchCreateNotesResponse.getDefaultInstance()) return this; - if (notesBuilder_ == null) { - if (!other.notes_.isEmpty()) { - if (notes_.isEmpty()) { - notes_ = other.notes_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureNotesIsMutable(); - notes_.addAll(other.notes_); - } - onChanged(); - } - } else { - if (!other.notes_.isEmpty()) { - if (notesBuilder_.isEmpty()) { - notesBuilder_.dispose(); - notesBuilder_ = null; - notes_ = other.notes_; - bitField0_ = (bitField0_ & ~0x00000001); - notesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getNotesFieldBuilder() - : null; - } else { - notesBuilder_.addAllMessages(other.notes_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.BatchCreateNotesResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.BatchCreateNotesResponse) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.util.List notes_ = java.util.Collections.emptyList(); - - private void ensureNotesIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - notes_ = new java.util.ArrayList(notes_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Note, - io.grafeas.v1beta1.Note.Builder, - io.grafeas.v1beta1.NoteOrBuilder> - notesBuilder_; - - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public java.util.List getNotesList() { - if (notesBuilder_ == null) { - return java.util.Collections.unmodifiableList(notes_); - } else { - return notesBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public int getNotesCount() { - if (notesBuilder_ == null) { - return notes_.size(); - } else { - return notesBuilder_.getCount(); - } - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.Note getNotes(int index) { - if (notesBuilder_ == null) { - return notes_.get(index); - } else { - return notesBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder setNotes(int index, io.grafeas.v1beta1.Note value) { - if (notesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureNotesIsMutable(); - notes_.set(index, value); - onChanged(); - } else { - notesBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder setNotes(int index, io.grafeas.v1beta1.Note.Builder builderForValue) { - if (notesBuilder_ == null) { - ensureNotesIsMutable(); - notes_.set(index, builderForValue.build()); - onChanged(); - } else { - notesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder addNotes(io.grafeas.v1beta1.Note value) { - if (notesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureNotesIsMutable(); - notes_.add(value); - onChanged(); - } else { - notesBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder addNotes(int index, io.grafeas.v1beta1.Note value) { - if (notesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureNotesIsMutable(); - notes_.add(index, value); - onChanged(); - } else { - notesBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder addNotes(io.grafeas.v1beta1.Note.Builder builderForValue) { - if (notesBuilder_ == null) { - ensureNotesIsMutable(); - notes_.add(builderForValue.build()); - onChanged(); - } else { - notesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder addNotes(int index, io.grafeas.v1beta1.Note.Builder builderForValue) { - if (notesBuilder_ == null) { - ensureNotesIsMutable(); - notes_.add(index, builderForValue.build()); - onChanged(); - } else { - notesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder addAllNotes(java.lang.Iterable values) { - if (notesBuilder_ == null) { - ensureNotesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, notes_); - onChanged(); - } else { - notesBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder clearNotes() { - if (notesBuilder_ == null) { - notes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - notesBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder removeNotes(int index) { - if (notesBuilder_ == null) { - ensureNotesIsMutable(); - notes_.remove(index); - onChanged(); - } else { - notesBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.Note.Builder getNotesBuilder(int index) { - return getNotesFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.NoteOrBuilder getNotesOrBuilder(int index) { - if (notesBuilder_ == null) { - return notes_.get(index); - } else { - return notesBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public java.util.List getNotesOrBuilderList() { - if (notesBuilder_ != null) { - return notesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(notes_); - } - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.Note.Builder addNotesBuilder() { - return getNotesFieldBuilder().addBuilder(io.grafeas.v1beta1.Note.getDefaultInstance()); - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.Note.Builder addNotesBuilder(int index) { - return getNotesFieldBuilder().addBuilder(index, io.grafeas.v1beta1.Note.getDefaultInstance()); - } - /** - * - * - *
-     * The notes that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public java.util.List getNotesBuilderList() { - return getNotesFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Note, - io.grafeas.v1beta1.Note.Builder, - io.grafeas.v1beta1.NoteOrBuilder> - getNotesFieldBuilder() { - if (notesBuilder_ == null) { - notesBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Note, - io.grafeas.v1beta1.Note.Builder, - io.grafeas.v1beta1.NoteOrBuilder>( - notes_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - notes_ = null; - } - return notesBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.BatchCreateNotesResponse) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.BatchCreateNotesResponse) - private static final io.grafeas.v1beta1.BatchCreateNotesResponse DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.BatchCreateNotesResponse(); - } - - public static io.grafeas.v1beta1.BatchCreateNotesResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BatchCreateNotesResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new BatchCreateNotesResponse(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateNotesResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesResponseOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesResponseOrBuilder.java deleted file mode 100644 index 4cf64f75..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateNotesResponseOrBuilder.java +++ /dev/null @@ -1,61 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface BatchCreateNotesResponseOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.BatchCreateNotesResponse) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The notes that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - java.util.List getNotesList(); - /** - * - * - *
-   * The notes that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - io.grafeas.v1beta1.Note getNotes(int index); - /** - * - * - *
-   * The notes that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - int getNotesCount(); - /** - * - * - *
-   * The notes that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - java.util.List getNotesOrBuilderList(); - /** - * - * - *
-   * The notes that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - io.grafeas.v1beta1.NoteOrBuilder getNotesOrBuilder(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesRequest.java deleted file mode 100644 index 029e0b18..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesRequest.java +++ /dev/null @@ -1,1091 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to create occurrences in batch.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.BatchCreateOccurrencesRequest} - */ -public final class BatchCreateOccurrencesRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.BatchCreateOccurrencesRequest) - BatchCreateOccurrencesRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use BatchCreateOccurrencesRequest.newBuilder() to construct. - private BatchCreateOccurrencesRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BatchCreateOccurrencesRequest() { - parent_ = ""; - occurrences_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private BatchCreateOccurrencesRequest( - 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: - { - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - occurrences_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - occurrences_.add( - input.readMessage(io.grafeas.v1beta1.Occurrence.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000002) != 0)) { - occurrences_ = java.util.Collections.unmodifiableList(occurrences_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateOccurrencesRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateOccurrencesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.BatchCreateOccurrencesRequest.class, - io.grafeas.v1beta1.BatchCreateOccurrencesRequest.Builder.class); - } - - private int bitField0_; - public static final int PARENT_FIELD_NUMBER = 1; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the occurrences are to be created.
-   * 
- * - * 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; - } - } - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the occurrences are to be created.
-   * 
- * - * 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 OCCURRENCES_FIELD_NUMBER = 2; - private java.util.List occurrences_; - /** - * - * - *
-   * The occurrences to create.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public java.util.List getOccurrencesList() { - return occurrences_; - } - /** - * - * - *
-   * The occurrences to create.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public java.util.List - getOccurrencesOrBuilderList() { - return occurrences_; - } - /** - * - * - *
-   * The occurrences to create.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public int getOccurrencesCount() { - return occurrences_.size(); - } - /** - * - * - *
-   * The occurrences to create.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public io.grafeas.v1beta1.Occurrence getOccurrences(int index) { - return occurrences_.get(index); - } - /** - * - * - *
-   * The occurrences to create.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrencesOrBuilder(int index) { - return occurrences_.get(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 (!getParentBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); - } - for (int i = 0; i < occurrences_.size(); i++) { - output.writeMessage(2, occurrences_.get(i)); - } - 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_); - } - for (int i = 0; i < occurrences_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, occurrences_.get(i)); - } - 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 io.grafeas.v1beta1.BatchCreateOccurrencesRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.BatchCreateOccurrencesRequest other = - (io.grafeas.v1beta1.BatchCreateOccurrencesRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (!getOccurrencesList().equals(other.getOccurrencesList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - if (getOccurrencesCount() > 0) { - hash = (37 * hash) + OCCURRENCES_FIELD_NUMBER; - hash = (53 * hash) + getOccurrencesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesRequest 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 io.grafeas.v1beta1.BatchCreateOccurrencesRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesRequest 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 io.grafeas.v1beta1.BatchCreateOccurrencesRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesRequest 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(io.grafeas.v1beta1.BatchCreateOccurrencesRequest 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 to create occurrences in batch.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.BatchCreateOccurrencesRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.BatchCreateOccurrencesRequest) - io.grafeas.v1beta1.BatchCreateOccurrencesRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateOccurrencesRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateOccurrencesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.BatchCreateOccurrencesRequest.class, - io.grafeas.v1beta1.BatchCreateOccurrencesRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.BatchCreateOccurrencesRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getOccurrencesFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - if (occurrencesBuilder_ == null) { - occurrences_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - occurrencesBuilder_.clear(); - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateOccurrencesRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateOccurrencesRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.BatchCreateOccurrencesRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateOccurrencesRequest build() { - io.grafeas.v1beta1.BatchCreateOccurrencesRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateOccurrencesRequest buildPartial() { - io.grafeas.v1beta1.BatchCreateOccurrencesRequest result = - new io.grafeas.v1beta1.BatchCreateOccurrencesRequest(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.parent_ = parent_; - if (occurrencesBuilder_ == null) { - if (((bitField0_ & 0x00000002) != 0)) { - occurrences_ = java.util.Collections.unmodifiableList(occurrences_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.occurrences_ = occurrences_; - } else { - result.occurrences_ = occurrencesBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.BatchCreateOccurrencesRequest) { - return mergeFrom((io.grafeas.v1beta1.BatchCreateOccurrencesRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.BatchCreateOccurrencesRequest other) { - if (other == io.grafeas.v1beta1.BatchCreateOccurrencesRequest.getDefaultInstance()) - return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (occurrencesBuilder_ == null) { - if (!other.occurrences_.isEmpty()) { - if (occurrences_.isEmpty()) { - occurrences_ = other.occurrences_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureOccurrencesIsMutable(); - occurrences_.addAll(other.occurrences_); - } - onChanged(); - } - } else { - if (!other.occurrences_.isEmpty()) { - if (occurrencesBuilder_.isEmpty()) { - occurrencesBuilder_.dispose(); - occurrencesBuilder_ = null; - occurrences_ = other.occurrences_; - bitField0_ = (bitField0_ & ~0x00000002); - occurrencesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getOccurrencesFieldBuilder() - : null; - } else { - occurrencesBuilder_.addAllMessages(other.occurrences_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.BatchCreateOccurrencesRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.BatchCreateOccurrencesRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the occurrences are to be created.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the occurrences are to be created.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the occurrences are to be created.
-     * 
- * - * string parent = 1; - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the occurrences are to be created.
-     * 
- * - * string parent = 1; - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the occurrences are to be created.
-     * 
- * - * 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.util.List occurrences_ = - java.util.Collections.emptyList(); - - private void ensureOccurrencesIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { - occurrences_ = new java.util.ArrayList(occurrences_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder> - occurrencesBuilder_; - - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public java.util.List getOccurrencesList() { - if (occurrencesBuilder_ == null) { - return java.util.Collections.unmodifiableList(occurrences_); - } else { - return occurrencesBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public int getOccurrencesCount() { - if (occurrencesBuilder_ == null) { - return occurrences_.size(); - } else { - return occurrencesBuilder_.getCount(); - } - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public io.grafeas.v1beta1.Occurrence getOccurrences(int index) { - if (occurrencesBuilder_ == null) { - return occurrences_.get(index); - } else { - return occurrencesBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public Builder setOccurrences(int index, io.grafeas.v1beta1.Occurrence value) { - if (occurrencesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureOccurrencesIsMutable(); - occurrences_.set(index, value); - onChanged(); - } else { - occurrencesBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public Builder setOccurrences( - int index, io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.set(index, builderForValue.build()); - onChanged(); - } else { - occurrencesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public Builder addOccurrences(io.grafeas.v1beta1.Occurrence value) { - if (occurrencesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureOccurrencesIsMutable(); - occurrences_.add(value); - onChanged(); - } else { - occurrencesBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public Builder addOccurrences(int index, io.grafeas.v1beta1.Occurrence value) { - if (occurrencesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureOccurrencesIsMutable(); - occurrences_.add(index, value); - onChanged(); - } else { - occurrencesBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public Builder addOccurrences(io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.add(builderForValue.build()); - onChanged(); - } else { - occurrencesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public Builder addOccurrences( - int index, io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.add(index, builderForValue.build()); - onChanged(); - } else { - occurrencesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public Builder addAllOccurrences( - java.lang.Iterable values) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, occurrences_); - onChanged(); - } else { - occurrencesBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public Builder clearOccurrences() { - if (occurrencesBuilder_ == null) { - occurrences_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - occurrencesBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public Builder removeOccurrences(int index) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.remove(index); - onChanged(); - } else { - occurrencesBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public io.grafeas.v1beta1.Occurrence.Builder getOccurrencesBuilder(int index) { - return getOccurrencesFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrencesOrBuilder(int index) { - if (occurrencesBuilder_ == null) { - return occurrences_.get(index); - } else { - return occurrencesBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public java.util.List - getOccurrencesOrBuilderList() { - if (occurrencesBuilder_ != null) { - return occurrencesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(occurrences_); - } - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public io.grafeas.v1beta1.Occurrence.Builder addOccurrencesBuilder() { - return getOccurrencesFieldBuilder() - .addBuilder(io.grafeas.v1beta1.Occurrence.getDefaultInstance()); - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public io.grafeas.v1beta1.Occurrence.Builder addOccurrencesBuilder(int index) { - return getOccurrencesFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.Occurrence.getDefaultInstance()); - } - /** - * - * - *
-     * The occurrences to create.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - public java.util.List getOccurrencesBuilderList() { - return getOccurrencesFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder> - getOccurrencesFieldBuilder() { - if (occurrencesBuilder_ == null) { - occurrencesBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder>( - occurrences_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); - occurrences_ = null; - } - return occurrencesBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.BatchCreateOccurrencesRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.BatchCreateOccurrencesRequest) - private static final io.grafeas.v1beta1.BatchCreateOccurrencesRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.BatchCreateOccurrencesRequest(); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BatchCreateOccurrencesRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new BatchCreateOccurrencesRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateOccurrencesRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesRequestOrBuilder.java deleted file mode 100644 index 57b6e010..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesRequestOrBuilder.java +++ /dev/null @@ -1,84 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface BatchCreateOccurrencesRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.BatchCreateOccurrencesRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the occurrences are to be created.
-   * 
- * - * string parent = 1; - */ - java.lang.String getParent(); - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the occurrences are to be created.
-   * 
- * - * string parent = 1; - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * The occurrences to create.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - java.util.List getOccurrencesList(); - /** - * - * - *
-   * The occurrences to create.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - io.grafeas.v1beta1.Occurrence getOccurrences(int index); - /** - * - * - *
-   * The occurrences to create.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - int getOccurrencesCount(); - /** - * - * - *
-   * The occurrences to create.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - java.util.List getOccurrencesOrBuilderList(); - /** - * - * - *
-   * The occurrences to create.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 2; - */ - io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrencesOrBuilder(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesResponse.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesResponse.java deleted file mode 100644 index 376c2a96..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesResponse.java +++ /dev/null @@ -1,922 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Response for creating occurrences in batch.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.BatchCreateOccurrencesResponse} - */ -public final class BatchCreateOccurrencesResponse extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.BatchCreateOccurrencesResponse) - BatchCreateOccurrencesResponseOrBuilder { - private static final long serialVersionUID = 0L; - // Use BatchCreateOccurrencesResponse.newBuilder() to construct. - private BatchCreateOccurrencesResponse( - com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BatchCreateOccurrencesResponse() { - occurrences_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private BatchCreateOccurrencesResponse( - 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: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - occurrences_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - occurrences_.add( - input.readMessage(io.grafeas.v1beta1.Occurrence.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000001) != 0)) { - occurrences_ = java.util.Collections.unmodifiableList(occurrences_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateOccurrencesResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateOccurrencesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.BatchCreateOccurrencesResponse.class, - io.grafeas.v1beta1.BatchCreateOccurrencesResponse.Builder.class); - } - - public static final int OCCURRENCES_FIELD_NUMBER = 1; - private java.util.List occurrences_; - /** - * - * - *
-   * The occurrences that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List getOccurrencesList() { - return occurrences_; - } - /** - * - * - *
-   * The occurrences that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List - getOccurrencesOrBuilderList() { - return occurrences_; - } - /** - * - * - *
-   * The occurrences that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public int getOccurrencesCount() { - return occurrences_.size(); - } - /** - * - * - *
-   * The occurrences that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence getOccurrences(int index) { - return occurrences_.get(index); - } - /** - * - * - *
-   * The occurrences that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrencesOrBuilder(int index) { - return occurrences_.get(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 { - for (int i = 0; i < occurrences_.size(); i++) { - output.writeMessage(1, occurrences_.get(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < occurrences_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, occurrences_.get(i)); - } - 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 io.grafeas.v1beta1.BatchCreateOccurrencesResponse)) { - return super.equals(obj); - } - io.grafeas.v1beta1.BatchCreateOccurrencesResponse other = - (io.grafeas.v1beta1.BatchCreateOccurrencesResponse) obj; - - if (!getOccurrencesList().equals(other.getOccurrencesList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getOccurrencesCount() > 0) { - hash = (37 * hash) + OCCURRENCES_FIELD_NUMBER; - hash = (53 * hash) + getOccurrencesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesResponse parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesResponse parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesResponse parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesResponse parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesResponse parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesResponse 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 io.grafeas.v1beta1.BatchCreateOccurrencesResponse parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesResponse 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 io.grafeas.v1beta1.BatchCreateOccurrencesResponse parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesResponse 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(io.grafeas.v1beta1.BatchCreateOccurrencesResponse 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; - } - /** - * - * - *
-   * Response for creating occurrences in batch.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.BatchCreateOccurrencesResponse} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.BatchCreateOccurrencesResponse) - io.grafeas.v1beta1.BatchCreateOccurrencesResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateOccurrencesResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateOccurrencesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.BatchCreateOccurrencesResponse.class, - io.grafeas.v1beta1.BatchCreateOccurrencesResponse.Builder.class); - } - - // Construct using io.grafeas.v1beta1.BatchCreateOccurrencesResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getOccurrencesFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (occurrencesBuilder_ == null) { - occurrences_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - occurrencesBuilder_.clear(); - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_BatchCreateOccurrencesResponse_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateOccurrencesResponse getDefaultInstanceForType() { - return io.grafeas.v1beta1.BatchCreateOccurrencesResponse.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateOccurrencesResponse build() { - io.grafeas.v1beta1.BatchCreateOccurrencesResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateOccurrencesResponse buildPartial() { - io.grafeas.v1beta1.BatchCreateOccurrencesResponse result = - new io.grafeas.v1beta1.BatchCreateOccurrencesResponse(this); - int from_bitField0_ = bitField0_; - if (occurrencesBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - occurrences_ = java.util.Collections.unmodifiableList(occurrences_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.occurrences_ = occurrences_; - } else { - result.occurrences_ = occurrencesBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.BatchCreateOccurrencesResponse) { - return mergeFrom((io.grafeas.v1beta1.BatchCreateOccurrencesResponse) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.BatchCreateOccurrencesResponse other) { - if (other == io.grafeas.v1beta1.BatchCreateOccurrencesResponse.getDefaultInstance()) - return this; - if (occurrencesBuilder_ == null) { - if (!other.occurrences_.isEmpty()) { - if (occurrences_.isEmpty()) { - occurrences_ = other.occurrences_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureOccurrencesIsMutable(); - occurrences_.addAll(other.occurrences_); - } - onChanged(); - } - } else { - if (!other.occurrences_.isEmpty()) { - if (occurrencesBuilder_.isEmpty()) { - occurrencesBuilder_.dispose(); - occurrencesBuilder_ = null; - occurrences_ = other.occurrences_; - bitField0_ = (bitField0_ & ~0x00000001); - occurrencesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getOccurrencesFieldBuilder() - : null; - } else { - occurrencesBuilder_.addAllMessages(other.occurrences_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.BatchCreateOccurrencesResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (io.grafeas.v1beta1.BatchCreateOccurrencesResponse) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.util.List occurrences_ = - java.util.Collections.emptyList(); - - private void ensureOccurrencesIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - occurrences_ = new java.util.ArrayList(occurrences_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder> - occurrencesBuilder_; - - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List getOccurrencesList() { - if (occurrencesBuilder_ == null) { - return java.util.Collections.unmodifiableList(occurrences_); - } else { - return occurrencesBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public int getOccurrencesCount() { - if (occurrencesBuilder_ == null) { - return occurrences_.size(); - } else { - return occurrencesBuilder_.getCount(); - } - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence getOccurrences(int index) { - if (occurrencesBuilder_ == null) { - return occurrences_.get(index); - } else { - return occurrencesBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder setOccurrences(int index, io.grafeas.v1beta1.Occurrence value) { - if (occurrencesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureOccurrencesIsMutable(); - occurrences_.set(index, value); - onChanged(); - } else { - occurrencesBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder setOccurrences( - int index, io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.set(index, builderForValue.build()); - onChanged(); - } else { - occurrencesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addOccurrences(io.grafeas.v1beta1.Occurrence value) { - if (occurrencesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureOccurrencesIsMutable(); - occurrences_.add(value); - onChanged(); - } else { - occurrencesBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addOccurrences(int index, io.grafeas.v1beta1.Occurrence value) { - if (occurrencesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureOccurrencesIsMutable(); - occurrences_.add(index, value); - onChanged(); - } else { - occurrencesBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addOccurrences(io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.add(builderForValue.build()); - onChanged(); - } else { - occurrencesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addOccurrences( - int index, io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.add(index, builderForValue.build()); - onChanged(); - } else { - occurrencesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addAllOccurrences( - java.lang.Iterable values) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, occurrences_); - onChanged(); - } else { - occurrencesBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder clearOccurrences() { - if (occurrencesBuilder_ == null) { - occurrences_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - occurrencesBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder removeOccurrences(int index) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.remove(index); - onChanged(); - } else { - occurrencesBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence.Builder getOccurrencesBuilder(int index) { - return getOccurrencesFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrencesOrBuilder(int index) { - if (occurrencesBuilder_ == null) { - return occurrences_.get(index); - } else { - return occurrencesBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List - getOccurrencesOrBuilderList() { - if (occurrencesBuilder_ != null) { - return occurrencesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(occurrences_); - } - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence.Builder addOccurrencesBuilder() { - return getOccurrencesFieldBuilder() - .addBuilder(io.grafeas.v1beta1.Occurrence.getDefaultInstance()); - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence.Builder addOccurrencesBuilder(int index) { - return getOccurrencesFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.Occurrence.getDefaultInstance()); - } - /** - * - * - *
-     * The occurrences that were created.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List getOccurrencesBuilderList() { - return getOccurrencesFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder> - getOccurrencesFieldBuilder() { - if (occurrencesBuilder_ == null) { - occurrencesBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder>( - occurrences_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - occurrences_ = null; - } - return occurrencesBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.BatchCreateOccurrencesResponse) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.BatchCreateOccurrencesResponse) - private static final io.grafeas.v1beta1.BatchCreateOccurrencesResponse DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.BatchCreateOccurrencesResponse(); - } - - public static io.grafeas.v1beta1.BatchCreateOccurrencesResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BatchCreateOccurrencesResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new BatchCreateOccurrencesResponse(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.BatchCreateOccurrencesResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesResponseOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesResponseOrBuilder.java deleted file mode 100644 index d21ce294..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/BatchCreateOccurrencesResponseOrBuilder.java +++ /dev/null @@ -1,61 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface BatchCreateOccurrencesResponseOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.BatchCreateOccurrencesResponse) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The occurrences that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - java.util.List getOccurrencesList(); - /** - * - * - *
-   * The occurrences that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - io.grafeas.v1beta1.Occurrence getOccurrences(int index); - /** - * - * - *
-   * The occurrences that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - int getOccurrencesCount(); - /** - * - * - *
-   * The occurrences that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - java.util.List getOccurrencesOrBuilderList(); - /** - * - * - *
-   * The occurrences that were created.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrencesOrBuilder(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateNoteRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateNoteRequest.java deleted file mode 100644 index f7f334ec..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateNoteRequest.java +++ /dev/null @@ -1,1014 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to create a new note.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.CreateNoteRequest} - */ -public final class CreateNoteRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.CreateNoteRequest) - CreateNoteRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use CreateNoteRequest.newBuilder() to construct. - private CreateNoteRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private CreateNoteRequest() { - parent_ = ""; - noteId_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private CreateNoteRequest( - 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(); - - noteId_ = s; - break; - } - case 26: - { - io.grafeas.v1beta1.Note.Builder subBuilder = null; - if (note_ != null) { - subBuilder = note_.toBuilder(); - } - note_ = input.readMessage(io.grafeas.v1beta1.Note.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(note_); - note_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_CreateNoteRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_CreateNoteRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.CreateNoteRequest.class, - io.grafeas.v1beta1.CreateNoteRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 1; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the note is to be created.
-   * 
- * - * 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; - } - } - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the note is to be created.
-   * 
- * - * 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 NOTE_ID_FIELD_NUMBER = 2; - private volatile java.lang.Object noteId_; - /** - * - * - *
-   * The ID to use for this note.
-   * 
- * - * string note_id = 2; - */ - public java.lang.String getNoteId() { - java.lang.Object ref = noteId_; - 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(); - noteId_ = s; - return s; - } - } - /** - * - * - *
-   * The ID to use for this note.
-   * 
- * - * string note_id = 2; - */ - public com.google.protobuf.ByteString getNoteIdBytes() { - java.lang.Object ref = noteId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - noteId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int NOTE_FIELD_NUMBER = 3; - private io.grafeas.v1beta1.Note note_; - /** - * - * - *
-   * The note to create.
-   * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - public boolean hasNote() { - return note_ != null; - } - /** - * - * - *
-   * The note to create.
-   * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - public io.grafeas.v1beta1.Note getNote() { - return note_ == null ? io.grafeas.v1beta1.Note.getDefaultInstance() : note_; - } - /** - * - * - *
-   * The note to create.
-   * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - public io.grafeas.v1beta1.NoteOrBuilder getNoteOrBuilder() { - return getNote(); - } - - 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 (!getNoteIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, noteId_); - } - if (note_ != null) { - output.writeMessage(3, getNote()); - } - 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 (!getNoteIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, noteId_); - } - if (note_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getNote()); - } - 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 io.grafeas.v1beta1.CreateNoteRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.CreateNoteRequest other = (io.grafeas.v1beta1.CreateNoteRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (!getNoteId().equals(other.getNoteId())) return false; - if (hasNote() != other.hasNote()) return false; - if (hasNote()) { - if (!getNote().equals(other.getNote())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - hash = (37 * hash) + NOTE_ID_FIELD_NUMBER; - hash = (53 * hash) + getNoteId().hashCode(); - if (hasNote()) { - hash = (37 * hash) + NOTE_FIELD_NUMBER; - hash = (53 * hash) + getNote().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.CreateNoteRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.CreateNoteRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.CreateNoteRequest parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.CreateNoteRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.CreateNoteRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.CreateNoteRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.CreateNoteRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.CreateNoteRequest 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 io.grafeas.v1beta1.CreateNoteRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.CreateNoteRequest 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 io.grafeas.v1beta1.CreateNoteRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.CreateNoteRequest 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(io.grafeas.v1beta1.CreateNoteRequest 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 to create a new note.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.CreateNoteRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.CreateNoteRequest) - io.grafeas.v1beta1.CreateNoteRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_CreateNoteRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_CreateNoteRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.CreateNoteRequest.class, - io.grafeas.v1beta1.CreateNoteRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.CreateNoteRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - noteId_ = ""; - - if (noteBuilder_ == null) { - note_ = null; - } else { - note_ = null; - noteBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_CreateNoteRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.CreateNoteRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.CreateNoteRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.CreateNoteRequest build() { - io.grafeas.v1beta1.CreateNoteRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.CreateNoteRequest buildPartial() { - io.grafeas.v1beta1.CreateNoteRequest result = new io.grafeas.v1beta1.CreateNoteRequest(this); - result.parent_ = parent_; - result.noteId_ = noteId_; - if (noteBuilder_ == null) { - result.note_ = note_; - } else { - result.note_ = noteBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.CreateNoteRequest) { - return mergeFrom((io.grafeas.v1beta1.CreateNoteRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.CreateNoteRequest other) { - if (other == io.grafeas.v1beta1.CreateNoteRequest.getDefaultInstance()) return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (!other.getNoteId().isEmpty()) { - noteId_ = other.noteId_; - onChanged(); - } - if (other.hasNote()) { - mergeNote(other.getNote()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.CreateNoteRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.CreateNoteRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the note is to be created.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the note is to be created.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the note is to be created.
-     * 
- * - * string parent = 1; - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the note is to be created.
-     * 
- * - * string parent = 1; - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the note is to be created.
-     * 
- * - * 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 noteId_ = ""; - /** - * - * - *
-     * The ID to use for this note.
-     * 
- * - * string note_id = 2; - */ - public java.lang.String getNoteId() { - java.lang.Object ref = noteId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - noteId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The ID to use for this note.
-     * 
- * - * string note_id = 2; - */ - public com.google.protobuf.ByteString getNoteIdBytes() { - java.lang.Object ref = noteId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - noteId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The ID to use for this note.
-     * 
- * - * string note_id = 2; - */ - public Builder setNoteId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - noteId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The ID to use for this note.
-     * 
- * - * string note_id = 2; - */ - public Builder clearNoteId() { - - noteId_ = getDefaultInstance().getNoteId(); - onChanged(); - return this; - } - /** - * - * - *
-     * The ID to use for this note.
-     * 
- * - * string note_id = 2; - */ - public Builder setNoteIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - noteId_ = value; - onChanged(); - return this; - } - - private io.grafeas.v1beta1.Note note_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Note, - io.grafeas.v1beta1.Note.Builder, - io.grafeas.v1beta1.NoteOrBuilder> - noteBuilder_; - /** - * - * - *
-     * The note to create.
-     * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - public boolean hasNote() { - return noteBuilder_ != null || note_ != null; - } - /** - * - * - *
-     * The note to create.
-     * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - public io.grafeas.v1beta1.Note getNote() { - if (noteBuilder_ == null) { - return note_ == null ? io.grafeas.v1beta1.Note.getDefaultInstance() : note_; - } else { - return noteBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The note to create.
-     * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - public Builder setNote(io.grafeas.v1beta1.Note value) { - if (noteBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - note_ = value; - onChanged(); - } else { - noteBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The note to create.
-     * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - public Builder setNote(io.grafeas.v1beta1.Note.Builder builderForValue) { - if (noteBuilder_ == null) { - note_ = builderForValue.build(); - onChanged(); - } else { - noteBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The note to create.
-     * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - public Builder mergeNote(io.grafeas.v1beta1.Note value) { - if (noteBuilder_ == null) { - if (note_ != null) { - note_ = io.grafeas.v1beta1.Note.newBuilder(note_).mergeFrom(value).buildPartial(); - } else { - note_ = value; - } - onChanged(); - } else { - noteBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The note to create.
-     * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - public Builder clearNote() { - if (noteBuilder_ == null) { - note_ = null; - onChanged(); - } else { - note_ = null; - noteBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The note to create.
-     * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - public io.grafeas.v1beta1.Note.Builder getNoteBuilder() { - - onChanged(); - return getNoteFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The note to create.
-     * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - public io.grafeas.v1beta1.NoteOrBuilder getNoteOrBuilder() { - if (noteBuilder_ != null) { - return noteBuilder_.getMessageOrBuilder(); - } else { - return note_ == null ? io.grafeas.v1beta1.Note.getDefaultInstance() : note_; - } - } - /** - * - * - *
-     * The note to create.
-     * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Note, - io.grafeas.v1beta1.Note.Builder, - io.grafeas.v1beta1.NoteOrBuilder> - getNoteFieldBuilder() { - if (noteBuilder_ == null) { - noteBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Note, - io.grafeas.v1beta1.Note.Builder, - io.grafeas.v1beta1.NoteOrBuilder>(getNote(), getParentForChildren(), isClean()); - note_ = null; - } - return noteBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.CreateNoteRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.CreateNoteRequest) - private static final io.grafeas.v1beta1.CreateNoteRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.CreateNoteRequest(); - } - - public static io.grafeas.v1beta1.CreateNoteRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public CreateNoteRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateNoteRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.CreateNoteRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateNoteRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateNoteRequestOrBuilder.java deleted file mode 100644 index b6e6a3f1..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateNoteRequestOrBuilder.java +++ /dev/null @@ -1,85 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface CreateNoteRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.CreateNoteRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the note is to be created.
-   * 
- * - * string parent = 1; - */ - java.lang.String getParent(); - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the note is to be created.
-   * 
- * - * string parent = 1; - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * The ID to use for this note.
-   * 
- * - * string note_id = 2; - */ - java.lang.String getNoteId(); - /** - * - * - *
-   * The ID to use for this note.
-   * 
- * - * string note_id = 2; - */ - com.google.protobuf.ByteString getNoteIdBytes(); - - /** - * - * - *
-   * The note to create.
-   * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - boolean hasNote(); - /** - * - * - *
-   * The note to create.
-   * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - io.grafeas.v1beta1.Note getNote(); - /** - * - * - *
-   * The note to create.
-   * 
- * - * .grafeas.v1beta1.Note note = 3; - */ - io.grafeas.v1beta1.NoteOrBuilder getNoteOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateOccurrenceRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateOccurrenceRequest.java deleted file mode 100644 index 1a1e6c6e..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateOccurrenceRequest.java +++ /dev/null @@ -1,864 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to create a new occurrence.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.CreateOccurrenceRequest} - */ -public final class CreateOccurrenceRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.CreateOccurrenceRequest) - CreateOccurrenceRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use CreateOccurrenceRequest.newBuilder() to construct. - private CreateOccurrenceRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private CreateOccurrenceRequest() { - parent_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private CreateOccurrenceRequest( - 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: - { - io.grafeas.v1beta1.Occurrence.Builder subBuilder = null; - if (occurrence_ != null) { - subBuilder = occurrence_.toBuilder(); - } - occurrence_ = - input.readMessage(io.grafeas.v1beta1.Occurrence.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(occurrence_); - occurrence_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_CreateOccurrenceRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_CreateOccurrenceRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.CreateOccurrenceRequest.class, - io.grafeas.v1beta1.CreateOccurrenceRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 1; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the occurrence is to be created.
-   * 
- * - * 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; - } - } - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the occurrence is to be created.
-   * 
- * - * 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 OCCURRENCE_FIELD_NUMBER = 2; - private io.grafeas.v1beta1.Occurrence occurrence_; - /** - * - * - *
-   * The occurrence to create.
-   * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public boolean hasOccurrence() { - return occurrence_ != null; - } - /** - * - * - *
-   * The occurrence to create.
-   * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public io.grafeas.v1beta1.Occurrence getOccurrence() { - return occurrence_ == null ? io.grafeas.v1beta1.Occurrence.getDefaultInstance() : occurrence_; - } - /** - * - * - *
-   * The occurrence to create.
-   * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrenceOrBuilder() { - return getOccurrence(); - } - - 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 (occurrence_ != null) { - output.writeMessage(2, getOccurrence()); - } - 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 (occurrence_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getOccurrence()); - } - 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 io.grafeas.v1beta1.CreateOccurrenceRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.CreateOccurrenceRequest other = - (io.grafeas.v1beta1.CreateOccurrenceRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (hasOccurrence() != other.hasOccurrence()) return false; - if (hasOccurrence()) { - if (!getOccurrence().equals(other.getOccurrence())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - if (hasOccurrence()) { - hash = (37 * hash) + OCCURRENCE_FIELD_NUMBER; - hash = (53 * hash) + getOccurrence().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.CreateOccurrenceRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.CreateOccurrenceRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.CreateOccurrenceRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.CreateOccurrenceRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.CreateOccurrenceRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.CreateOccurrenceRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.CreateOccurrenceRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.CreateOccurrenceRequest 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 io.grafeas.v1beta1.CreateOccurrenceRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.CreateOccurrenceRequest 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 io.grafeas.v1beta1.CreateOccurrenceRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.CreateOccurrenceRequest 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(io.grafeas.v1beta1.CreateOccurrenceRequest 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 to create a new occurrence.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.CreateOccurrenceRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.CreateOccurrenceRequest) - io.grafeas.v1beta1.CreateOccurrenceRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_CreateOccurrenceRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_CreateOccurrenceRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.CreateOccurrenceRequest.class, - io.grafeas.v1beta1.CreateOccurrenceRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.CreateOccurrenceRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - if (occurrenceBuilder_ == null) { - occurrence_ = null; - } else { - occurrence_ = null; - occurrenceBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_CreateOccurrenceRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.CreateOccurrenceRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.CreateOccurrenceRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.CreateOccurrenceRequest build() { - io.grafeas.v1beta1.CreateOccurrenceRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.CreateOccurrenceRequest buildPartial() { - io.grafeas.v1beta1.CreateOccurrenceRequest result = - new io.grafeas.v1beta1.CreateOccurrenceRequest(this); - result.parent_ = parent_; - if (occurrenceBuilder_ == null) { - result.occurrence_ = occurrence_; - } else { - result.occurrence_ = occurrenceBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.CreateOccurrenceRequest) { - return mergeFrom((io.grafeas.v1beta1.CreateOccurrenceRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.CreateOccurrenceRequest other) { - if (other == io.grafeas.v1beta1.CreateOccurrenceRequest.getDefaultInstance()) return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (other.hasOccurrence()) { - mergeOccurrence(other.getOccurrence()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.CreateOccurrenceRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.CreateOccurrenceRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the occurrence is to be created.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the occurrence is to be created.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the occurrence is to be created.
-     * 
- * - * string parent = 1; - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the occurrence is to be created.
-     * 
- * - * string parent = 1; - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-     * the occurrence is to be created.
-     * 
- * - * 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 io.grafeas.v1beta1.Occurrence occurrence_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder> - occurrenceBuilder_; - /** - * - * - *
-     * The occurrence to create.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public boolean hasOccurrence() { - return occurrenceBuilder_ != null || occurrence_ != null; - } - /** - * - * - *
-     * The occurrence to create.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public io.grafeas.v1beta1.Occurrence getOccurrence() { - if (occurrenceBuilder_ == null) { - return occurrence_ == null - ? io.grafeas.v1beta1.Occurrence.getDefaultInstance() - : occurrence_; - } else { - return occurrenceBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The occurrence to create.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public Builder setOccurrence(io.grafeas.v1beta1.Occurrence value) { - if (occurrenceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - occurrence_ = value; - onChanged(); - } else { - occurrenceBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The occurrence to create.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public Builder setOccurrence(io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrenceBuilder_ == null) { - occurrence_ = builderForValue.build(); - onChanged(); - } else { - occurrenceBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The occurrence to create.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public Builder mergeOccurrence(io.grafeas.v1beta1.Occurrence value) { - if (occurrenceBuilder_ == null) { - if (occurrence_ != null) { - occurrence_ = - io.grafeas.v1beta1.Occurrence.newBuilder(occurrence_).mergeFrom(value).buildPartial(); - } else { - occurrence_ = value; - } - onChanged(); - } else { - occurrenceBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The occurrence to create.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public Builder clearOccurrence() { - if (occurrenceBuilder_ == null) { - occurrence_ = null; - onChanged(); - } else { - occurrence_ = null; - occurrenceBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The occurrence to create.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public io.grafeas.v1beta1.Occurrence.Builder getOccurrenceBuilder() { - - onChanged(); - return getOccurrenceFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The occurrence to create.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrenceOrBuilder() { - if (occurrenceBuilder_ != null) { - return occurrenceBuilder_.getMessageOrBuilder(); - } else { - return occurrence_ == null - ? io.grafeas.v1beta1.Occurrence.getDefaultInstance() - : occurrence_; - } - } - /** - * - * - *
-     * The occurrence to create.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder> - getOccurrenceFieldBuilder() { - if (occurrenceBuilder_ == null) { - occurrenceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder>( - getOccurrence(), getParentForChildren(), isClean()); - occurrence_ = null; - } - return occurrenceBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.CreateOccurrenceRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.CreateOccurrenceRequest) - private static final io.grafeas.v1beta1.CreateOccurrenceRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.CreateOccurrenceRequest(); - } - - public static io.grafeas.v1beta1.CreateOccurrenceRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public CreateOccurrenceRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateOccurrenceRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.CreateOccurrenceRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateOccurrenceRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateOccurrenceRequestOrBuilder.java deleted file mode 100644 index d6e46b43..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/CreateOccurrenceRequestOrBuilder.java +++ /dev/null @@ -1,64 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface CreateOccurrenceRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.CreateOccurrenceRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the occurrence is to be created.
-   * 
- * - * string parent = 1; - */ - java.lang.String getParent(); - /** - * - * - *
-   * The name of the project in the form of `projects/[PROJECT_ID]`, under which
-   * the occurrence is to be created.
-   * 
- * - * string parent = 1; - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * The occurrence to create.
-   * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - boolean hasOccurrence(); - /** - * - * - *
-   * The occurrence to create.
-   * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - io.grafeas.v1beta1.Occurrence getOccurrence(); - /** - * - * - *
-   * The occurrence to create.
-   * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrenceOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteNoteRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteNoteRequest.java deleted file mode 100644 index 96ed2588..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteNoteRequest.java +++ /dev/null @@ -1,599 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to delete a note.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.DeleteNoteRequest} - */ -public final class DeleteNoteRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.DeleteNoteRequest) - DeleteNoteRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use DeleteNoteRequest.newBuilder() to construct. - private DeleteNoteRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private DeleteNoteRequest() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private DeleteNoteRequest( - 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; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_DeleteNoteRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_DeleteNoteRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.DeleteNoteRequest.class, - io.grafeas.v1beta1.DeleteNoteRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * 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 name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * 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; - } - } - - 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_); - } - 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_); - } - 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 io.grafeas.v1beta1.DeleteNoteRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.DeleteNoteRequest other = (io.grafeas.v1beta1.DeleteNoteRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.DeleteNoteRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.DeleteNoteRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.DeleteNoteRequest parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.DeleteNoteRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.DeleteNoteRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.DeleteNoteRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.DeleteNoteRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.DeleteNoteRequest 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 io.grafeas.v1beta1.DeleteNoteRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.DeleteNoteRequest 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 io.grafeas.v1beta1.DeleteNoteRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.DeleteNoteRequest 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(io.grafeas.v1beta1.DeleteNoteRequest 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 to delete a note.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.DeleteNoteRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.DeleteNoteRequest) - io.grafeas.v1beta1.DeleteNoteRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_DeleteNoteRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_DeleteNoteRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.DeleteNoteRequest.class, - io.grafeas.v1beta1.DeleteNoteRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.DeleteNoteRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_DeleteNoteRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.DeleteNoteRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.DeleteNoteRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.DeleteNoteRequest build() { - io.grafeas.v1beta1.DeleteNoteRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.DeleteNoteRequest buildPartial() { - io.grafeas.v1beta1.DeleteNoteRequest result = new io.grafeas.v1beta1.DeleteNoteRequest(this); - result.name_ = name_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.DeleteNoteRequest) { - return mergeFrom((io.grafeas.v1beta1.DeleteNoteRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.DeleteNoteRequest other) { - if (other == io.grafeas.v1beta1.DeleteNoteRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.DeleteNoteRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.DeleteNoteRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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 name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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 name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.DeleteNoteRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.DeleteNoteRequest) - private static final io.grafeas.v1beta1.DeleteNoteRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.DeleteNoteRequest(); - } - - public static io.grafeas.v1beta1.DeleteNoteRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public DeleteNoteRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteNoteRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.DeleteNoteRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteNoteRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteNoteRequestOrBuilder.java deleted file mode 100644 index f91a646c..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteNoteRequestOrBuilder.java +++ /dev/null @@ -1,33 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface DeleteNoteRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.DeleteNoteRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteOccurrenceRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteOccurrenceRequest.java deleted file mode 100644 index 8cacedb4..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteOccurrenceRequest.java +++ /dev/null @@ -1,603 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to delete a occurrence.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.DeleteOccurrenceRequest} - */ -public final class DeleteOccurrenceRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.DeleteOccurrenceRequest) - DeleteOccurrenceRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use DeleteOccurrenceRequest.newBuilder() to construct. - private DeleteOccurrenceRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private DeleteOccurrenceRequest() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private DeleteOccurrenceRequest( - 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; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_DeleteOccurrenceRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_DeleteOccurrenceRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.DeleteOccurrenceRequest.class, - io.grafeas.v1beta1.DeleteOccurrenceRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * 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 name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * 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; - } - } - - 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_); - } - 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_); - } - 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 io.grafeas.v1beta1.DeleteOccurrenceRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.DeleteOccurrenceRequest other = - (io.grafeas.v1beta1.DeleteOccurrenceRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.DeleteOccurrenceRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.DeleteOccurrenceRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.DeleteOccurrenceRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.DeleteOccurrenceRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.DeleteOccurrenceRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.DeleteOccurrenceRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.DeleteOccurrenceRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.DeleteOccurrenceRequest 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 io.grafeas.v1beta1.DeleteOccurrenceRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.DeleteOccurrenceRequest 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 io.grafeas.v1beta1.DeleteOccurrenceRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.DeleteOccurrenceRequest 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(io.grafeas.v1beta1.DeleteOccurrenceRequest 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 to delete a occurrence.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.DeleteOccurrenceRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.DeleteOccurrenceRequest) - io.grafeas.v1beta1.DeleteOccurrenceRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_DeleteOccurrenceRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_DeleteOccurrenceRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.DeleteOccurrenceRequest.class, - io.grafeas.v1beta1.DeleteOccurrenceRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.DeleteOccurrenceRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_DeleteOccurrenceRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.DeleteOccurrenceRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.DeleteOccurrenceRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.DeleteOccurrenceRequest build() { - io.grafeas.v1beta1.DeleteOccurrenceRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.DeleteOccurrenceRequest buildPartial() { - io.grafeas.v1beta1.DeleteOccurrenceRequest result = - new io.grafeas.v1beta1.DeleteOccurrenceRequest(this); - result.name_ = name_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.DeleteOccurrenceRequest) { - return mergeFrom((io.grafeas.v1beta1.DeleteOccurrenceRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.DeleteOccurrenceRequest other) { - if (other == io.grafeas.v1beta1.DeleteOccurrenceRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.DeleteOccurrenceRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.DeleteOccurrenceRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * 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 name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * 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 name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.DeleteOccurrenceRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.DeleteOccurrenceRequest) - private static final io.grafeas.v1beta1.DeleteOccurrenceRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.DeleteOccurrenceRequest(); - } - - public static io.grafeas.v1beta1.DeleteOccurrenceRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public DeleteOccurrenceRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteOccurrenceRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.DeleteOccurrenceRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteOccurrenceRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteOccurrenceRequestOrBuilder.java deleted file mode 100644 index 2a39d9a2..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/DeleteOccurrenceRequestOrBuilder.java +++ /dev/null @@ -1,33 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface DeleteOccurrenceRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.DeleteOccurrenceRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetNoteRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetNoteRequest.java deleted file mode 100644 index 11a205b4..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetNoteRequest.java +++ /dev/null @@ -1,597 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to get a note.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.GetNoteRequest} - */ -public final class GetNoteRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.GetNoteRequest) - GetNoteRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use GetNoteRequest.newBuilder() to construct. - private GetNoteRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private GetNoteRequest() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private GetNoteRequest( - 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; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_GetNoteRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetNoteRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.GetNoteRequest.class, - io.grafeas.v1beta1.GetNoteRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * 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 name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * 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; - } - } - - 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_); - } - 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_); - } - 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 io.grafeas.v1beta1.GetNoteRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.GetNoteRequest other = (io.grafeas.v1beta1.GetNoteRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.GetNoteRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.GetNoteRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.GetNoteRequest parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.GetNoteRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.GetNoteRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.GetNoteRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.GetNoteRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.GetNoteRequest 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 io.grafeas.v1beta1.GetNoteRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.GetNoteRequest 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 io.grafeas.v1beta1.GetNoteRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.GetNoteRequest 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(io.grafeas.v1beta1.GetNoteRequest 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 to get a note.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.GetNoteRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.GetNoteRequest) - io.grafeas.v1beta1.GetNoteRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_GetNoteRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetNoteRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.GetNoteRequest.class, - io.grafeas.v1beta1.GetNoteRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.GetNoteRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_GetNoteRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.GetNoteRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.GetNoteRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.GetNoteRequest build() { - io.grafeas.v1beta1.GetNoteRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.GetNoteRequest buildPartial() { - io.grafeas.v1beta1.GetNoteRequest result = new io.grafeas.v1beta1.GetNoteRequest(this); - result.name_ = name_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.GetNoteRequest) { - return mergeFrom((io.grafeas.v1beta1.GetNoteRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.GetNoteRequest other) { - if (other == io.grafeas.v1beta1.GetNoteRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.GetNoteRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.GetNoteRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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 name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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 name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.GetNoteRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.GetNoteRequest) - private static final io.grafeas.v1beta1.GetNoteRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.GetNoteRequest(); - } - - public static io.grafeas.v1beta1.GetNoteRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetNoteRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new GetNoteRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.GetNoteRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetNoteRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetNoteRequestOrBuilder.java deleted file mode 100644 index b309b243..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetNoteRequestOrBuilder.java +++ /dev/null @@ -1,33 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface GetNoteRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.GetNoteRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceNoteRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceNoteRequest.java deleted file mode 100644 index 23d0ce2a..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceNoteRequest.java +++ /dev/null @@ -1,603 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to get the note to which the specified occurrence is attached.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.GetOccurrenceNoteRequest} - */ -public final class GetOccurrenceNoteRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.GetOccurrenceNoteRequest) - GetOccurrenceNoteRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use GetOccurrenceNoteRequest.newBuilder() to construct. - private GetOccurrenceNoteRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private GetOccurrenceNoteRequest() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private GetOccurrenceNoteRequest( - 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; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetOccurrenceNoteRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetOccurrenceNoteRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.GetOccurrenceNoteRequest.class, - io.grafeas.v1beta1.GetOccurrenceNoteRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * 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 name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * 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; - } - } - - 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_); - } - 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_); - } - 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 io.grafeas.v1beta1.GetOccurrenceNoteRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.GetOccurrenceNoteRequest other = - (io.grafeas.v1beta1.GetOccurrenceNoteRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.GetOccurrenceNoteRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.GetOccurrenceNoteRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.GetOccurrenceNoteRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.GetOccurrenceNoteRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.GetOccurrenceNoteRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.GetOccurrenceNoteRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.GetOccurrenceNoteRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.GetOccurrenceNoteRequest 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 io.grafeas.v1beta1.GetOccurrenceNoteRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.GetOccurrenceNoteRequest 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 io.grafeas.v1beta1.GetOccurrenceNoteRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.GetOccurrenceNoteRequest 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(io.grafeas.v1beta1.GetOccurrenceNoteRequest 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 to get the note to which the specified occurrence is attached.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.GetOccurrenceNoteRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.GetOccurrenceNoteRequest) - io.grafeas.v1beta1.GetOccurrenceNoteRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetOccurrenceNoteRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetOccurrenceNoteRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.GetOccurrenceNoteRequest.class, - io.grafeas.v1beta1.GetOccurrenceNoteRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.GetOccurrenceNoteRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetOccurrenceNoteRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.GetOccurrenceNoteRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.GetOccurrenceNoteRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.GetOccurrenceNoteRequest build() { - io.grafeas.v1beta1.GetOccurrenceNoteRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.GetOccurrenceNoteRequest buildPartial() { - io.grafeas.v1beta1.GetOccurrenceNoteRequest result = - new io.grafeas.v1beta1.GetOccurrenceNoteRequest(this); - result.name_ = name_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.GetOccurrenceNoteRequest) { - return mergeFrom((io.grafeas.v1beta1.GetOccurrenceNoteRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.GetOccurrenceNoteRequest other) { - if (other == io.grafeas.v1beta1.GetOccurrenceNoteRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.GetOccurrenceNoteRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.GetOccurrenceNoteRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * 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 name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * 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 name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.GetOccurrenceNoteRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.GetOccurrenceNoteRequest) - private static final io.grafeas.v1beta1.GetOccurrenceNoteRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.GetOccurrenceNoteRequest(); - } - - public static io.grafeas.v1beta1.GetOccurrenceNoteRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetOccurrenceNoteRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new GetOccurrenceNoteRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.GetOccurrenceNoteRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceNoteRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceNoteRequestOrBuilder.java deleted file mode 100644 index ff2bd141..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceNoteRequestOrBuilder.java +++ /dev/null @@ -1,33 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface GetOccurrenceNoteRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.GetOccurrenceNoteRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceRequest.java deleted file mode 100644 index 2cdd2e65..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceRequest.java +++ /dev/null @@ -1,602 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to get an occurrence.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.GetOccurrenceRequest} - */ -public final class GetOccurrenceRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.GetOccurrenceRequest) - GetOccurrenceRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use GetOccurrenceRequest.newBuilder() to construct. - private GetOccurrenceRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private GetOccurrenceRequest() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private GetOccurrenceRequest( - 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; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetOccurrenceRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetOccurrenceRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.GetOccurrenceRequest.class, - io.grafeas.v1beta1.GetOccurrenceRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * 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 name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * 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; - } - } - - 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_); - } - 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_); - } - 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 io.grafeas.v1beta1.GetOccurrenceRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.GetOccurrenceRequest other = (io.grafeas.v1beta1.GetOccurrenceRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.GetOccurrenceRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.GetOccurrenceRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.GetOccurrenceRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.GetOccurrenceRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.GetOccurrenceRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.GetOccurrenceRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.GetOccurrenceRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.GetOccurrenceRequest 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 io.grafeas.v1beta1.GetOccurrenceRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.GetOccurrenceRequest 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 io.grafeas.v1beta1.GetOccurrenceRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.GetOccurrenceRequest 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(io.grafeas.v1beta1.GetOccurrenceRequest 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 to get an occurrence.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.GetOccurrenceRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.GetOccurrenceRequest) - io.grafeas.v1beta1.GetOccurrenceRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetOccurrenceRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetOccurrenceRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.GetOccurrenceRequest.class, - io.grafeas.v1beta1.GetOccurrenceRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.GetOccurrenceRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetOccurrenceRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.GetOccurrenceRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.GetOccurrenceRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.GetOccurrenceRequest build() { - io.grafeas.v1beta1.GetOccurrenceRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.GetOccurrenceRequest buildPartial() { - io.grafeas.v1beta1.GetOccurrenceRequest result = - new io.grafeas.v1beta1.GetOccurrenceRequest(this); - result.name_ = name_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.GetOccurrenceRequest) { - return mergeFrom((io.grafeas.v1beta1.GetOccurrenceRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.GetOccurrenceRequest other) { - if (other == io.grafeas.v1beta1.GetOccurrenceRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.GetOccurrenceRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.GetOccurrenceRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * 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 name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * 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 name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.GetOccurrenceRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.GetOccurrenceRequest) - private static final io.grafeas.v1beta1.GetOccurrenceRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.GetOccurrenceRequest(); - } - - public static io.grafeas.v1beta1.GetOccurrenceRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetOccurrenceRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new GetOccurrenceRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.GetOccurrenceRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceRequestOrBuilder.java deleted file mode 100644 index e551cfbb..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetOccurrenceRequestOrBuilder.java +++ /dev/null @@ -1,33 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface GetOccurrenceRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.GetOccurrenceRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetVulnerabilityOccurrencesSummaryRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetVulnerabilityOccurrencesSummaryRequest.java deleted file mode 100644 index e42d51e2..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetVulnerabilityOccurrencesSummaryRequest.java +++ /dev/null @@ -1,773 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to get a vulnerability summary for some set of occurrences.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest} - */ -public final class GetVulnerabilityOccurrencesSummaryRequest - extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest) - GetVulnerabilityOccurrencesSummaryRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use GetVulnerabilityOccurrencesSummaryRequest.newBuilder() to construct. - private GetVulnerabilityOccurrencesSummaryRequest( - com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private GetVulnerabilityOccurrencesSummaryRequest() { - parent_ = ""; - filter_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private GetVulnerabilityOccurrencesSummaryRequest( - 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(); - - filter_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetVulnerabilityOccurrencesSummaryRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetVulnerabilityOccurrencesSummaryRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest.class, - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 1; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * The name of the project to get a vulnerability summary for in the form of
-   * `projects/[PROJECT_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; - } - } - /** - * - * - *
-   * The name of the project to get a vulnerability summary for in the form of
-   * `projects/[PROJECT_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 FILTER_FIELD_NUMBER = 2; - private volatile java.lang.Object filter_; - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - 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(); - filter_ = s; - return s; - } - } - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getParentBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); - } - if (!getFilterBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, filter_); - } - 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 (!getFilterBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, filter_); - } - 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 io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest other = - (io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (!getFilter().equals(other.getFilter())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - hash = (37 * hash) + FILTER_FIELD_NUMBER; - hash = (53 * hash) + getFilter().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest 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 io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest 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 io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest 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( - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest 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 to get a vulnerability summary for some set of occurrences.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest) - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetVulnerabilityOccurrencesSummaryRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetVulnerabilityOccurrencesSummaryRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest.class, - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - filter_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_GetVulnerabilityOccurrencesSummaryRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest - getDefaultInstanceForType() { - return io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest build() { - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest buildPartial() { - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest result = - new io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest(this); - result.parent_ = parent_; - result.filter_ = filter_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest) { - return mergeFrom((io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest other) { - if (other - == io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest.getDefaultInstance()) - return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (!other.getFilter().isEmpty()) { - filter_ = other.filter_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * The name of the project to get a vulnerability summary for in the form of
-     * `projects/[PROJECT_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; - } - } - /** - * - * - *
-     * The name of the project to get a vulnerability summary for in the form of
-     * `projects/[PROJECT_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; - } - } - /** - * - * - *
-     * The name of the project to get a vulnerability summary for in the form of
-     * `projects/[PROJECT_ID]`.
-     * 
- * - * string parent = 1; - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project to get a vulnerability summary for in the form of
-     * `projects/[PROJECT_ID]`.
-     * 
- * - * string parent = 1; - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project to get a vulnerability summary for in the form of
-     * `projects/[PROJECT_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 filter_ = ""; - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - filter_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder setFilter(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - filter_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder clearFilter() { - - filter_ = getDefaultInstance().getFilter(); - onChanged(); - return this; - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder setFilterBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - filter_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest) - private static final io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest(); - } - - public static io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetVulnerabilityOccurrencesSummaryRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new GetVulnerabilityOccurrencesSummaryRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetVulnerabilityOccurrencesSummaryRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetVulnerabilityOccurrencesSummaryRequestOrBuilder.java deleted file mode 100644 index 9517305b..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/GetVulnerabilityOccurrencesSummaryRequestOrBuilder.java +++ /dev/null @@ -1,54 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface GetVulnerabilityOccurrencesSummaryRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.GetVulnerabilityOccurrencesSummaryRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the project to get a vulnerability summary for in the form of
-   * `projects/[PROJECT_ID]`.
-   * 
- * - * string parent = 1; - */ - java.lang.String getParent(); - /** - * - * - *
-   * The name of the project to get a vulnerability summary for in the form of
-   * `projects/[PROJECT_ID]`.
-   * 
- * - * string parent = 1; - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - java.lang.String getFilter(); - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - com.google.protobuf.ByteString getFilterBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Grafeas.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Grafeas.java deleted file mode 100644 index 1e985fa9..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Grafeas.java +++ /dev/null @@ -1,583 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public final class Grafeas { - private Grafeas() {} - - 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_grafeas_v1beta1_Occurrence_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_Occurrence_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_Resource_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_Resource_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_Note_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_Note_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_GetOccurrenceRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_GetOccurrenceRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_ListOccurrencesRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_ListOccurrencesRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_ListOccurrencesResponse_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_ListOccurrencesResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_DeleteOccurrenceRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_DeleteOccurrenceRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_CreateOccurrenceRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_CreateOccurrenceRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_UpdateOccurrenceRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_UpdateOccurrenceRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_GetNoteRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_GetNoteRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_GetOccurrenceNoteRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_GetOccurrenceNoteRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_ListNotesRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_ListNotesRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_ListNotesResponse_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_ListNotesResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_DeleteNoteRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_DeleteNoteRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_CreateNoteRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_CreateNoteRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_UpdateNoteRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_UpdateNoteRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_ListNoteOccurrencesRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_ListNoteOccurrencesRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_ListNoteOccurrencesResponse_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_ListNoteOccurrencesResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_BatchCreateNotesRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_BatchCreateNotesRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_BatchCreateNotesRequest_NotesEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_BatchCreateNotesRequest_NotesEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_BatchCreateNotesResponse_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_BatchCreateNotesResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_BatchCreateOccurrencesRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_BatchCreateOccurrencesRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_BatchCreateOccurrencesResponse_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_BatchCreateOccurrencesResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_GetVulnerabilityOccurrencesSummaryRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_GetVulnerabilityOccurrencesSummaryRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_FixableTotalByDigest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_FixableTotalByDigest_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/devtools/containeranalysis/v1be" - + "ta1/grafeas/grafeas.proto\022\017grafeas.v1bet" - + "a1\032\034google/api/annotations.proto\032Ggoogle" - + "/devtools/containeranalysis/v1beta1/atte" - + "station/attestation.proto\032;google/devtoo" - + "ls/containeranalysis/v1beta1/build/build" - + ".proto\032=google/devtools/containeranalysi" - + "s/v1beta1/common/common.proto\032Egoogle/de" - + "vtools/containeranalysis/v1beta1/deploym" - + "ent/deployment.proto\032Cgoogle/devtools/co" - + "ntaineranalysis/v1beta1/discovery/discov" - + "ery.proto\032;google/devtools/containeranal" - + "ysis/v1beta1/image/image.proto\032?google/d" - + "evtools/containeranalysis/v1beta1/packag" - + "e/package.proto\032Egoogle/devtools/contain" - + "eranalysis/v1beta1/provenance/provenance" - + ".proto\032Kgoogle/devtools/containeranalysi" - + "s/v1beta1/vulnerability/vulnerability.pr" - + "oto\032\033google/protobuf/empty.proto\032 google" - + "/protobuf/field_mask.proto\032\037google/proto" - + "buf/timestamp.proto\"\234\005\n\nOccurrence\022\014\n\004na" - + "me\030\001 \001(\t\022+\n\010resource\030\002 \001(\0132\031.grafeas.v1b" - + "eta1.Resource\022\021\n\tnote_name\030\003 \001(\t\022\'\n\004kind" - + "\030\004 \001(\0162\031.grafeas.v1beta1.NoteKind\022\023\n\013rem" - + "ediation\030\005 \001(\t\022/\n\013create_time\030\006 \001(\0132\032.go" - + "ogle.protobuf.Timestamp\022/\n\013update_time\030\007" - + " \001(\0132\032.google.protobuf.Timestamp\022?\n\rvuln" - + "erability\030\010 \001(\0132&.grafeas.v1beta1.vulner" - + "ability.DetailsH\000\022/\n\005build\030\t \001(\0132\036.grafe" - + "as.v1beta1.build.DetailsH\000\0227\n\rderived_im" - + "age\030\n \001(\0132\036.grafeas.v1beta1.image.Detail" - + "sH\000\0228\n\014installation\030\013 \001(\0132 .grafeas.v1be" - + "ta1.package.DetailsH\000\0229\n\ndeployment\030\014 \001(" - + "\0132#.grafeas.v1beta1.deployment.DetailsH\000" - + "\0228\n\ndiscovered\030\r \001(\0132\".grafeas.v1beta1.d" - + "iscovery.DetailsH\000\022;\n\013attestation\030\016 \001(\0132" - + "$.grafeas.v1beta1.attestation.DetailsH\000B" - + "\t\n\007details\"]\n\010Resource\022\014\n\004name\030\001 \001(\t\022\013\n\003" - + "uri\030\002 \001(\t\0226\n\014content_hash\030\003 \001(\0132 .grafea" - + "s.v1beta1.provenance.Hash\"\200\006\n\004Note\022\014\n\004na" - + "me\030\001 \001(\t\022\031\n\021short_description\030\002 \001(\t\022\030\n\020l" - + "ong_description\030\003 \001(\t\022\'\n\004kind\030\004 \001(\0162\031.gr" - + "afeas.v1beta1.NoteKind\0220\n\013related_url\030\005 " - + "\003(\0132\033.grafeas.v1beta1.RelatedUrl\0223\n\017expi" - + "ration_time\030\006 \001(\0132\032.google.protobuf.Time" - + "stamp\022/\n\013create_time\030\007 \001(\0132\032.google.prot" - + "obuf.Timestamp\022/\n\013update_time\030\010 \001(\0132\032.go" - + "ogle.protobuf.Timestamp\022\032\n\022related_note_" - + "names\030\t \003(\t\022E\n\rvulnerability\030\n \001(\0132,.gra" - + "feas.v1beta1.vulnerability.Vulnerability" - + "H\000\022-\n\005build\030\013 \001(\0132\034.grafeas.v1beta1.buil" - + "d.BuildH\000\0222\n\nbase_image\030\014 \001(\0132\034.grafeas." - + "v1beta1.image.BasisH\000\0223\n\007package\030\r \001(\0132 " - + ".grafeas.v1beta1.package.PackageH\000\022<\n\nde" - + "ployable\030\016 \001(\0132&.grafeas.v1beta1.deploym" - + "ent.DeployableH\000\0229\n\tdiscovery\030\017 \001(\0132$.gr" - + "afeas.v1beta1.discovery.DiscoveryH\000\022G\n\025a" - + "ttestation_authority\030\020 \001(\0132&.grafeas.v1b" - + "eta1.attestation.AuthorityH\000B\006\n\004type\"$\n\024" - + "GetOccurrenceRequest\022\014\n\004name\030\001 \001(\t\"_\n\026Li" - + "stOccurrencesRequest\022\016\n\006parent\030\001 \001(\t\022\016\n\006" - + "filter\030\002 \001(\t\022\021\n\tpage_size\030\003 \001(\005\022\022\n\npage_" - + "token\030\004 \001(\t\"d\n\027ListOccurrencesResponse\0220" - + "\n\013occurrences\030\001 \003(\0132\033.grafeas.v1beta1.Oc" - + "currence\022\027\n\017next_page_token\030\002 \001(\t\"\'\n\027Del" - + "eteOccurrenceRequest\022\014\n\004name\030\001 \001(\t\"Z\n\027Cr" - + "eateOccurrenceRequest\022\016\n\006parent\030\001 \001(\t\022/\n" - + "\noccurrence\030\002 \001(\0132\033.grafeas.v1beta1.Occu" - + "rrence\"\211\001\n\027UpdateOccurrenceRequest\022\014\n\004na" - + "me\030\001 \001(\t\022/\n\noccurrence\030\002 \001(\0132\033.grafeas.v" - + "1beta1.Occurrence\022/\n\013update_mask\030\003 \001(\0132\032" - + ".google.protobuf.FieldMask\"\036\n\016GetNoteReq" - + "uest\022\014\n\004name\030\001 \001(\t\"(\n\030GetOccurrenceNoteR" - + "equest\022\014\n\004name\030\001 \001(\t\"Y\n\020ListNotesRequest" - + "\022\016\n\006parent\030\001 \001(\t\022\016\n\006filter\030\002 \001(\t\022\021\n\tpage" - + "_size\030\003 \001(\005\022\022\n\npage_token\030\004 \001(\t\"R\n\021ListN" - + "otesResponse\022$\n\005notes\030\001 \003(\0132\025.grafeas.v1" - + "beta1.Note\022\027\n\017next_page_token\030\002 \001(\t\"!\n\021D" - + "eleteNoteRequest\022\014\n\004name\030\001 \001(\t\"Y\n\021Create" - + "NoteRequest\022\016\n\006parent\030\001 \001(\t\022\017\n\007note_id\030\002" - + " \001(\t\022#\n\004note\030\003 \001(\0132\025.grafeas.v1beta1.Not" - + "e\"w\n\021UpdateNoteRequest\022\014\n\004name\030\001 \001(\t\022#\n\004" - + "note\030\002 \001(\0132\025.grafeas.v1beta1.Note\022/\n\013upd" - + "ate_mask\030\003 \001(\0132\032.google.protobuf.FieldMa" - + "sk\"a\n\032ListNoteOccurrencesRequest\022\014\n\004name" - + "\030\001 \001(\t\022\016\n\006filter\030\002 \001(\t\022\021\n\tpage_size\030\003 \001(" - + "\005\022\022\n\npage_token\030\004 \001(\t\"h\n\033ListNoteOccurre" - + "ncesResponse\0220\n\013occurrences\030\001 \003(\0132\033.graf" - + "eas.v1beta1.Occurrence\022\027\n\017next_page_toke" - + "n\030\002 \001(\t\"\262\001\n\027BatchCreateNotesRequest\022\016\n\006p" - + "arent\030\001 \001(\t\022B\n\005notes\030\002 \003(\01323.grafeas.v1b" - + "eta1.BatchCreateNotesRequest.NotesEntry\032" - + "C\n\nNotesEntry\022\013\n\003key\030\001 \001(\t\022$\n\005value\030\002 \001(" - + "\0132\025.grafeas.v1beta1.Note:\0028\001\"@\n\030BatchCre" - + "ateNotesResponse\022$\n\005notes\030\001 \003(\0132\025.grafea" - + "s.v1beta1.Note\"a\n\035BatchCreateOccurrences" - + "Request\022\016\n\006parent\030\001 \001(\t\0220\n\013occurrences\030\002" - + " \003(\0132\033.grafeas.v1beta1.Occurrence\"R\n\036Bat" - + "chCreateOccurrencesResponse\0220\n\013occurrenc" - + "es\030\001 \003(\0132\033.grafeas.v1beta1.Occurrence\"K\n" - + ")GetVulnerabilityOccurrencesSummaryReque" - + "st\022\016\n\006parent\030\001 \001(\t\022\016\n\006filter\030\002 \001(\t\"\245\002\n\037V" - + "ulnerabilityOccurrencesSummary\022U\n\006counts" - + "\030\001 \003(\0132E.grafeas.v1beta1.VulnerabilityOc" - + "currencesSummary.FixableTotalByDigest\032\252\001" - + "\n\024FixableTotalByDigest\022+\n\010resource\030\001 \001(\013" - + "2\031.grafeas.v1beta1.Resource\0229\n\010severity\030" - + "\002 \001(\0162\'.grafeas.v1beta1.vulnerability.Se" - + "verity\022\025\n\rfixable_count\030\003 \001(\003\022\023\n\013total_c" - + "ount\030\004 \001(\0032\302\021\n\016GrafeasV1Beta1\022\205\001\n\rGetOcc" - + "urrence\022%.grafeas.v1beta1.GetOccurrenceR" - + "equest\032\033.grafeas.v1beta1.Occurrence\"0\202\323\344" - + "\223\002*\022(/v1beta1/{name=projects/*/occurrenc" - + "es/*}\022\226\001\n\017ListOccurrences\022\'.grafeas.v1be" - + "ta1.ListOccurrencesRequest\032(.grafeas.v1b" - + "eta1.ListOccurrencesResponse\"0\202\323\344\223\002*\022(/v" - + "1beta1/{parent=projects/*}/occurrences\022\206" - + "\001\n\020DeleteOccurrence\022(.grafeas.v1beta1.De" - + "leteOccurrenceRequest\032\026.google.protobuf." - + "Empty\"0\202\323\344\223\002**(/v1beta1/{name=projects/*" - + "/occurrences/*}\022\227\001\n\020CreateOccurrence\022(.g" - + "rafeas.v1beta1.CreateOccurrenceRequest\032\033" - + ".grafeas.v1beta1.Occurrence\"<\202\323\344\223\0026\"(/v1" - + "beta1/{parent=projects/*}/occurrences:\no" - + "ccurrence\022\272\001\n\026BatchCreateOccurrences\022..g" - + "rafeas.v1beta1.BatchCreateOccurrencesReq" - + "uest\032/.grafeas.v1beta1.BatchCreateOccurr" - + "encesResponse\"?\202\323\344\223\0029\"4/v1beta1/{parent=" - + "projects/*}/occurrences:batchCreate:\001*\022\227" - + "\001\n\020UpdateOccurrence\022(.grafeas.v1beta1.Up" - + "dateOccurrenceRequest\032\033.grafeas.v1beta1." - + "Occurrence\"<\202\323\344\223\00262(/v1beta1/{name=proje" - + "cts/*/occurrences/*}:\noccurrence\022\215\001\n\021Get" - + "OccurrenceNote\022).grafeas.v1beta1.GetOccu" - + "rrenceNoteRequest\032\025.grafeas.v1beta1.Note" - + "\"6\202\323\344\223\0020\022./v1beta1/{name=projects/*/occu" - + "rrences/*}/notes\022m\n\007GetNote\022\037.grafeas.v1" - + "beta1.GetNoteRequest\032\025.grafeas.v1beta1.N" - + "ote\"*\202\323\344\223\002$\022\"/v1beta1/{name=projects/*/n" - + "otes/*}\022~\n\tListNotes\022!.grafeas.v1beta1.L" - + "istNotesRequest\032\".grafeas.v1beta1.ListNo" - + "tesResponse\"*\202\323\344\223\002$\022\"/v1beta1/{parent=pr" - + "ojects/*}/notes\022t\n\nDeleteNote\022\".grafeas." - + "v1beta1.DeleteNoteRequest\032\026.google.proto" - + "buf.Empty\"*\202\323\344\223\002$*\"/v1beta1/{name=projec" - + "ts/*/notes/*}\022y\n\nCreateNote\022\".grafeas.v1" - + "beta1.CreateNoteRequest\032\025.grafeas.v1beta" - + "1.Note\"0\202\323\344\223\002*\"\"/v1beta1/{parent=project" - + "s/*}/notes:\004note\022\242\001\n\020BatchCreateNotes\022(." - + "grafeas.v1beta1.BatchCreateNotesRequest\032" - + ").grafeas.v1beta1.BatchCreateNotesRespon" - + "se\"9\202\323\344\223\0023\"./v1beta1/{parent=projects/*}" - + "/notes:batchCreate:\001*\022y\n\nUpdateNote\022\".gr" - + "afeas.v1beta1.UpdateNoteRequest\032\025.grafea" - + "s.v1beta1.Note\"0\202\323\344\223\002*2\"/v1beta1/{name=p" - + "rojects/*/notes/*}:\004note\022\250\001\n\023ListNoteOcc" - + "urrences\022+.grafeas.v1beta1.ListNoteOccur" - + "rencesRequest\032,.grafeas.v1beta1.ListNote" - + "OccurrencesResponse\"6\202\323\344\223\0020\022./v1beta1/{n" - + "ame=projects/*/notes/*}/occurrences\022\331\001\n\"" - + "GetVulnerabilityOccurrencesSummary\022:.gra" - + "feas.v1beta1.GetVulnerabilityOccurrences" - + "SummaryRequest\0320.grafeas.v1beta1.Vulnera" - + "bilityOccurrencesSummary\"E\202\323\344\223\002?\022=/v1bet" - + "a1/{parent=projects/*}/occurrences:vulne" - + "rabilitySummaryBv\n\022io.grafeas.v1beta1P\001Z" - + "Xgoogle.golang.org/genproto/googleapis/d" - + "evtools/containeranalysis/v1beta1/grafea" - + "s;grafeas\242\002\003GRAb\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(), - io.grafeas.v1beta1.attestation.AttestationOuterClass.getDescriptor(), - io.grafeas.v1beta1.build.BuildOuterClass.getDescriptor(), - io.grafeas.v1beta1.common.Common.getDescriptor(), - io.grafeas.v1beta1.deployment.DeploymentOuterClass.getDescriptor(), - io.grafeas.v1beta1.discovery.DiscoveryOuterClass.getDescriptor(), - io.grafeas.v1beta1.image.Image.getDescriptor(), - io.grafeas.v1beta1.pkg.PackageOuterClass.getDescriptor(), - io.grafeas.v1beta1.provenance.Provenance.getDescriptor(), - io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass.getDescriptor(), - com.google.protobuf.EmptyProto.getDescriptor(), - com.google.protobuf.FieldMaskProto.getDescriptor(), - com.google.protobuf.TimestampProto.getDescriptor(), - }, - assigner); - internal_static_grafeas_v1beta1_Occurrence_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_grafeas_v1beta1_Occurrence_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_Occurrence_descriptor, - new java.lang.String[] { - "Name", - "Resource", - "NoteName", - "Kind", - "Remediation", - "CreateTime", - "UpdateTime", - "Vulnerability", - "Build", - "DerivedImage", - "Installation", - "Deployment", - "Discovered", - "Attestation", - "Details", - }); - internal_static_grafeas_v1beta1_Resource_descriptor = getDescriptor().getMessageTypes().get(1); - internal_static_grafeas_v1beta1_Resource_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_Resource_descriptor, - new java.lang.String[] { - "Name", "Uri", "ContentHash", - }); - internal_static_grafeas_v1beta1_Note_descriptor = getDescriptor().getMessageTypes().get(2); - internal_static_grafeas_v1beta1_Note_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_Note_descriptor, - new java.lang.String[] { - "Name", - "ShortDescription", - "LongDescription", - "Kind", - "RelatedUrl", - "ExpirationTime", - "CreateTime", - "UpdateTime", - "RelatedNoteNames", - "Vulnerability", - "Build", - "BaseImage", - "Package", - "Deployable", - "Discovery", - "AttestationAuthority", - "Type", - }); - internal_static_grafeas_v1beta1_GetOccurrenceRequest_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_grafeas_v1beta1_GetOccurrenceRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_GetOccurrenceRequest_descriptor, - new java.lang.String[] { - "Name", - }); - internal_static_grafeas_v1beta1_ListOccurrencesRequest_descriptor = - getDescriptor().getMessageTypes().get(4); - internal_static_grafeas_v1beta1_ListOccurrencesRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_ListOccurrencesRequest_descriptor, - new java.lang.String[] { - "Parent", "Filter", "PageSize", "PageToken", - }); - internal_static_grafeas_v1beta1_ListOccurrencesResponse_descriptor = - getDescriptor().getMessageTypes().get(5); - internal_static_grafeas_v1beta1_ListOccurrencesResponse_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_ListOccurrencesResponse_descriptor, - new java.lang.String[] { - "Occurrences", "NextPageToken", - }); - internal_static_grafeas_v1beta1_DeleteOccurrenceRequest_descriptor = - getDescriptor().getMessageTypes().get(6); - internal_static_grafeas_v1beta1_DeleteOccurrenceRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_DeleteOccurrenceRequest_descriptor, - new java.lang.String[] { - "Name", - }); - internal_static_grafeas_v1beta1_CreateOccurrenceRequest_descriptor = - getDescriptor().getMessageTypes().get(7); - internal_static_grafeas_v1beta1_CreateOccurrenceRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_CreateOccurrenceRequest_descriptor, - new java.lang.String[] { - "Parent", "Occurrence", - }); - internal_static_grafeas_v1beta1_UpdateOccurrenceRequest_descriptor = - getDescriptor().getMessageTypes().get(8); - internal_static_grafeas_v1beta1_UpdateOccurrenceRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_UpdateOccurrenceRequest_descriptor, - new java.lang.String[] { - "Name", "Occurrence", "UpdateMask", - }); - internal_static_grafeas_v1beta1_GetNoteRequest_descriptor = - getDescriptor().getMessageTypes().get(9); - internal_static_grafeas_v1beta1_GetNoteRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_GetNoteRequest_descriptor, - new java.lang.String[] { - "Name", - }); - internal_static_grafeas_v1beta1_GetOccurrenceNoteRequest_descriptor = - getDescriptor().getMessageTypes().get(10); - internal_static_grafeas_v1beta1_GetOccurrenceNoteRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_GetOccurrenceNoteRequest_descriptor, - new java.lang.String[] { - "Name", - }); - internal_static_grafeas_v1beta1_ListNotesRequest_descriptor = - getDescriptor().getMessageTypes().get(11); - internal_static_grafeas_v1beta1_ListNotesRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_ListNotesRequest_descriptor, - new java.lang.String[] { - "Parent", "Filter", "PageSize", "PageToken", - }); - internal_static_grafeas_v1beta1_ListNotesResponse_descriptor = - getDescriptor().getMessageTypes().get(12); - internal_static_grafeas_v1beta1_ListNotesResponse_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_ListNotesResponse_descriptor, - new java.lang.String[] { - "Notes", "NextPageToken", - }); - internal_static_grafeas_v1beta1_DeleteNoteRequest_descriptor = - getDescriptor().getMessageTypes().get(13); - internal_static_grafeas_v1beta1_DeleteNoteRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_DeleteNoteRequest_descriptor, - new java.lang.String[] { - "Name", - }); - internal_static_grafeas_v1beta1_CreateNoteRequest_descriptor = - getDescriptor().getMessageTypes().get(14); - internal_static_grafeas_v1beta1_CreateNoteRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_CreateNoteRequest_descriptor, - new java.lang.String[] { - "Parent", "NoteId", "Note", - }); - internal_static_grafeas_v1beta1_UpdateNoteRequest_descriptor = - getDescriptor().getMessageTypes().get(15); - internal_static_grafeas_v1beta1_UpdateNoteRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_UpdateNoteRequest_descriptor, - new java.lang.String[] { - "Name", "Note", "UpdateMask", - }); - internal_static_grafeas_v1beta1_ListNoteOccurrencesRequest_descriptor = - getDescriptor().getMessageTypes().get(16); - internal_static_grafeas_v1beta1_ListNoteOccurrencesRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_ListNoteOccurrencesRequest_descriptor, - new java.lang.String[] { - "Name", "Filter", "PageSize", "PageToken", - }); - internal_static_grafeas_v1beta1_ListNoteOccurrencesResponse_descriptor = - getDescriptor().getMessageTypes().get(17); - internal_static_grafeas_v1beta1_ListNoteOccurrencesResponse_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_ListNoteOccurrencesResponse_descriptor, - new java.lang.String[] { - "Occurrences", "NextPageToken", - }); - internal_static_grafeas_v1beta1_BatchCreateNotesRequest_descriptor = - getDescriptor().getMessageTypes().get(18); - internal_static_grafeas_v1beta1_BatchCreateNotesRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_BatchCreateNotesRequest_descriptor, - new java.lang.String[] { - "Parent", "Notes", - }); - internal_static_grafeas_v1beta1_BatchCreateNotesRequest_NotesEntry_descriptor = - internal_static_grafeas_v1beta1_BatchCreateNotesRequest_descriptor.getNestedTypes().get(0); - internal_static_grafeas_v1beta1_BatchCreateNotesRequest_NotesEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_BatchCreateNotesRequest_NotesEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_grafeas_v1beta1_BatchCreateNotesResponse_descriptor = - getDescriptor().getMessageTypes().get(19); - internal_static_grafeas_v1beta1_BatchCreateNotesResponse_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_BatchCreateNotesResponse_descriptor, - new java.lang.String[] { - "Notes", - }); - internal_static_grafeas_v1beta1_BatchCreateOccurrencesRequest_descriptor = - getDescriptor().getMessageTypes().get(20); - internal_static_grafeas_v1beta1_BatchCreateOccurrencesRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_BatchCreateOccurrencesRequest_descriptor, - new java.lang.String[] { - "Parent", "Occurrences", - }); - internal_static_grafeas_v1beta1_BatchCreateOccurrencesResponse_descriptor = - getDescriptor().getMessageTypes().get(21); - internal_static_grafeas_v1beta1_BatchCreateOccurrencesResponse_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_BatchCreateOccurrencesResponse_descriptor, - new java.lang.String[] { - "Occurrences", - }); - internal_static_grafeas_v1beta1_GetVulnerabilityOccurrencesSummaryRequest_descriptor = - getDescriptor().getMessageTypes().get(22); - internal_static_grafeas_v1beta1_GetVulnerabilityOccurrencesSummaryRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_GetVulnerabilityOccurrencesSummaryRequest_descriptor, - new java.lang.String[] { - "Parent", "Filter", - }); - internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_descriptor = - getDescriptor().getMessageTypes().get(23); - internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_descriptor, - new java.lang.String[] { - "Counts", - }); - internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_FixableTotalByDigest_descriptor = - internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_descriptor - .getNestedTypes() - .get(0); - internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_FixableTotalByDigest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_FixableTotalByDigest_descriptor, - new java.lang.String[] { - "Resource", "Severity", "FixableCount", "TotalCount", - }); - com.google.protobuf.ExtensionRegistry registry = - com.google.protobuf.ExtensionRegistry.newInstance(); - registry.add(com.google.api.AnnotationsProto.http); - com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( - descriptor, registry); - com.google.api.AnnotationsProto.getDescriptor(); - io.grafeas.v1beta1.attestation.AttestationOuterClass.getDescriptor(); - io.grafeas.v1beta1.build.BuildOuterClass.getDescriptor(); - io.grafeas.v1beta1.common.Common.getDescriptor(); - io.grafeas.v1beta1.deployment.DeploymentOuterClass.getDescriptor(); - io.grafeas.v1beta1.discovery.DiscoveryOuterClass.getDescriptor(); - io.grafeas.v1beta1.image.Image.getDescriptor(); - io.grafeas.v1beta1.pkg.PackageOuterClass.getDescriptor(); - io.grafeas.v1beta1.provenance.Provenance.getDescriptor(); - io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass.getDescriptor(); - com.google.protobuf.EmptyProto.getDescriptor(); - com.google.protobuf.FieldMaskProto.getDescriptor(); - com.google.protobuf.TimestampProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/IamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/IamResourceName.java deleted file mode 100644 index 09c7d936..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/IamResourceName.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * 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 io.grafeas.v1beta1; - -import com.google.api.resourcenames.ResourceName; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public abstract class IamResourceName implements ResourceName { - protected IamResourceName() {} -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/IamResourceNames.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/IamResourceNames.java deleted file mode 100644 index 1e64f793..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/IamResourceNames.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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 io.grafeas.v1beta1; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class IamResourceNames { - private IamResourceNames() {} - - public static IamResourceName parse(String resourceNameString) { - if (NoteName.isParsableFrom(resourceNameString)) { - return NoteName.parse(resourceNameString); - } - if (OccurrenceName.isParsableFrom(resourceNameString)) { - return OccurrenceName.parse(resourceNameString); - } - return UntypedIamResourceName.parse(resourceNameString); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesRequest.java deleted file mode 100644 index bda62926..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesRequest.java +++ /dev/null @@ -1,1004 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to list occurrences for a note.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.ListNoteOccurrencesRequest} - */ -public final class ListNoteOccurrencesRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.ListNoteOccurrencesRequest) - ListNoteOccurrencesRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListNoteOccurrencesRequest.newBuilder() to construct. - private ListNoteOccurrencesRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListNoteOccurrencesRequest() { - name_ = ""; - filter_ = ""; - pageToken_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ListNoteOccurrencesRequest( - 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(); - - filter_ = s; - break; - } - case 24: - { - pageSize_ = input.readInt32(); - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNoteOccurrencesRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNoteOccurrencesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.ListNoteOccurrencesRequest.class, - io.grafeas.v1beta1.ListNoteOccurrencesRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the note to list occurrences for in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * 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 name of the note to list occurrences for in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * 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 FILTER_FIELD_NUMBER = 2; - private volatile java.lang.Object filter_; - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - 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(); - filter_ = s; - return s; - } - } - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PAGE_SIZE_FIELD_NUMBER = 3; - private int pageSize_; - /** - * - * - *
-   * Number of occurrences to return in the list.
-   * 
- * - * int32 page_size = 3; - */ - public int getPageSize() { - return pageSize_; - } - - public static final int PAGE_TOKEN_FIELD_NUMBER = 4; - private volatile java.lang.Object pageToken_; - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - 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(); - pageToken_ = s; - return s; - } - } - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - if (!getFilterBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, filter_); - } - if (pageSize_ != 0) { - output.writeInt32(3, pageSize_); - } - if (!getPageTokenBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, pageToken_); - } - 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 (!getFilterBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, filter_); - } - if (pageSize_ != 0) { - size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, pageSize_); - } - if (!getPageTokenBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, pageToken_); - } - 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 io.grafeas.v1beta1.ListNoteOccurrencesRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.ListNoteOccurrencesRequest other = - (io.grafeas.v1beta1.ListNoteOccurrencesRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!getFilter().equals(other.getFilter())) return false; - if (getPageSize() != other.getPageSize()) return false; - if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + FILTER_FIELD_NUMBER; - hash = (53 * hash) + getFilter().hashCode(); - hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; - hash = (53 * hash) + getPageSize(); - hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesRequest 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 io.grafeas.v1beta1.ListNoteOccurrencesRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesRequest 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 io.grafeas.v1beta1.ListNoteOccurrencesRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesRequest 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(io.grafeas.v1beta1.ListNoteOccurrencesRequest 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 to list occurrences for a note.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.ListNoteOccurrencesRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.ListNoteOccurrencesRequest) - io.grafeas.v1beta1.ListNoteOccurrencesRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNoteOccurrencesRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNoteOccurrencesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.ListNoteOccurrencesRequest.class, - io.grafeas.v1beta1.ListNoteOccurrencesRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.ListNoteOccurrencesRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - filter_ = ""; - - pageSize_ = 0; - - pageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNoteOccurrencesRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNoteOccurrencesRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.ListNoteOccurrencesRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNoteOccurrencesRequest build() { - io.grafeas.v1beta1.ListNoteOccurrencesRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNoteOccurrencesRequest buildPartial() { - io.grafeas.v1beta1.ListNoteOccurrencesRequest result = - new io.grafeas.v1beta1.ListNoteOccurrencesRequest(this); - result.name_ = name_; - result.filter_ = filter_; - result.pageSize_ = pageSize_; - result.pageToken_ = pageToken_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.ListNoteOccurrencesRequest) { - return mergeFrom((io.grafeas.v1beta1.ListNoteOccurrencesRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.ListNoteOccurrencesRequest other) { - if (other == io.grafeas.v1beta1.ListNoteOccurrencesRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getFilter().isEmpty()) { - filter_ = other.filter_; - onChanged(); - } - if (other.getPageSize() != 0) { - setPageSize(other.getPageSize()); - } - if (!other.getPageToken().isEmpty()) { - pageToken_ = other.pageToken_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.ListNoteOccurrencesRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.ListNoteOccurrencesRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the note to list occurrences for in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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 name of the note to list occurrences for in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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 name of the note to list occurrences for in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the note to list occurrences for in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the note to list occurrences for in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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 java.lang.Object filter_ = ""; - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - filter_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder setFilter(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - filter_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder clearFilter() { - - filter_ = getDefaultInstance().getFilter(); - onChanged(); - return this; - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder setFilterBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - filter_ = value; - onChanged(); - return this; - } - - private int pageSize_; - /** - * - * - *
-     * Number of occurrences to return in the list.
-     * 
- * - * int32 page_size = 3; - */ - public int getPageSize() { - return pageSize_; - } - /** - * - * - *
-     * Number of occurrences to return in the list.
-     * 
- * - * int32 page_size = 3; - */ - public Builder setPageSize(int value) { - - pageSize_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Number of occurrences to return in the list.
-     * 
- * - * int32 page_size = 3; - */ - public Builder clearPageSize() { - - pageSize_ = 0; - onChanged(); - return this; - } - - private java.lang.Object pageToken_ = ""; - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - pageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public Builder setPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - pageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public Builder clearPageToken() { - - pageToken_ = getDefaultInstance().getPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - pageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.ListNoteOccurrencesRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.ListNoteOccurrencesRequest) - private static final io.grafeas.v1beta1.ListNoteOccurrencesRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.ListNoteOccurrencesRequest(); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListNoteOccurrencesRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListNoteOccurrencesRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNoteOccurrencesRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesRequestOrBuilder.java deleted file mode 100644 index 6fbaa2df..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesRequestOrBuilder.java +++ /dev/null @@ -1,86 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface ListNoteOccurrencesRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.ListNoteOccurrencesRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the note to list occurrences for in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the note to list occurrences for in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - java.lang.String getFilter(); - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - com.google.protobuf.ByteString getFilterBytes(); - - /** - * - * - *
-   * Number of occurrences to return in the list.
-   * 
- * - * int32 page_size = 3; - */ - int getPageSize(); - - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - java.lang.String getPageToken(); - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - com.google.protobuf.ByteString getPageTokenBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesResponse.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesResponse.java deleted file mode 100644 index 22ce63b2..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesResponse.java +++ /dev/null @@ -1,1083 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Response for listing occurrences for a note.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.ListNoteOccurrencesResponse} - */ -public final class ListNoteOccurrencesResponse extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.ListNoteOccurrencesResponse) - ListNoteOccurrencesResponseOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListNoteOccurrencesResponse.newBuilder() to construct. - private ListNoteOccurrencesResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListNoteOccurrencesResponse() { - occurrences_ = java.util.Collections.emptyList(); - nextPageToken_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ListNoteOccurrencesResponse( - 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: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - occurrences_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - occurrences_.add( - input.readMessage(io.grafeas.v1beta1.Occurrence.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000001) != 0)) { - occurrences_ = java.util.Collections.unmodifiableList(occurrences_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNoteOccurrencesResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNoteOccurrencesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.ListNoteOccurrencesResponse.class, - io.grafeas.v1beta1.ListNoteOccurrencesResponse.Builder.class); - } - - private int bitField0_; - public static final int OCCURRENCES_FIELD_NUMBER = 1; - private java.util.List occurrences_; - /** - * - * - *
-   * The occurrences attached to the specified note.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List getOccurrencesList() { - return occurrences_; - } - /** - * - * - *
-   * The occurrences attached to the specified note.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List - getOccurrencesOrBuilderList() { - return occurrences_; - } - /** - * - * - *
-   * The occurrences attached to the specified note.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public int getOccurrencesCount() { - return occurrences_.size(); - } - /** - * - * - *
-   * The occurrences attached to the specified note.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence getOccurrences(int index) { - return occurrences_.get(index); - } - /** - * - * - *
-   * The occurrences attached to the specified note.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrencesOrBuilder(int index) { - return occurrences_.get(index); - } - - public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; - private volatile java.lang.Object nextPageToken_; - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string next_page_token = 2; - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - 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(); - nextPageToken_ = s; - return s; - } - } - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string next_page_token = 2; - */ - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < occurrences_.size(); i++) { - output.writeMessage(1, occurrences_.get(i)); - } - if (!getNextPageTokenBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < occurrences_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, occurrences_.get(i)); - } - if (!getNextPageTokenBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); - } - 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 io.grafeas.v1beta1.ListNoteOccurrencesResponse)) { - return super.equals(obj); - } - io.grafeas.v1beta1.ListNoteOccurrencesResponse other = - (io.grafeas.v1beta1.ListNoteOccurrencesResponse) obj; - - if (!getOccurrencesList().equals(other.getOccurrencesList())) return false; - if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getOccurrencesCount() > 0) { - hash = (37 * hash) + OCCURRENCES_FIELD_NUMBER; - hash = (53 * hash) + getOccurrencesList().hashCode(); - } - hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesResponse parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesResponse parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesResponse parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesResponse parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesResponse 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 io.grafeas.v1beta1.ListNoteOccurrencesResponse parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesResponse 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 io.grafeas.v1beta1.ListNoteOccurrencesResponse parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesResponse 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(io.grafeas.v1beta1.ListNoteOccurrencesResponse 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; - } - /** - * - * - *
-   * Response for listing occurrences for a note.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.ListNoteOccurrencesResponse} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.ListNoteOccurrencesResponse) - io.grafeas.v1beta1.ListNoteOccurrencesResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNoteOccurrencesResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNoteOccurrencesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.ListNoteOccurrencesResponse.class, - io.grafeas.v1beta1.ListNoteOccurrencesResponse.Builder.class); - } - - // Construct using io.grafeas.v1beta1.ListNoteOccurrencesResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getOccurrencesFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (occurrencesBuilder_ == null) { - occurrences_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - occurrencesBuilder_.clear(); - } - nextPageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNoteOccurrencesResponse_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNoteOccurrencesResponse getDefaultInstanceForType() { - return io.grafeas.v1beta1.ListNoteOccurrencesResponse.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNoteOccurrencesResponse build() { - io.grafeas.v1beta1.ListNoteOccurrencesResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNoteOccurrencesResponse buildPartial() { - io.grafeas.v1beta1.ListNoteOccurrencesResponse result = - new io.grafeas.v1beta1.ListNoteOccurrencesResponse(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (occurrencesBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - occurrences_ = java.util.Collections.unmodifiableList(occurrences_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.occurrences_ = occurrences_; - } else { - result.occurrences_ = occurrencesBuilder_.build(); - } - result.nextPageToken_ = nextPageToken_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.ListNoteOccurrencesResponse) { - return mergeFrom((io.grafeas.v1beta1.ListNoteOccurrencesResponse) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.ListNoteOccurrencesResponse other) { - if (other == io.grafeas.v1beta1.ListNoteOccurrencesResponse.getDefaultInstance()) return this; - if (occurrencesBuilder_ == null) { - if (!other.occurrences_.isEmpty()) { - if (occurrences_.isEmpty()) { - occurrences_ = other.occurrences_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureOccurrencesIsMutable(); - occurrences_.addAll(other.occurrences_); - } - onChanged(); - } - } else { - if (!other.occurrences_.isEmpty()) { - if (occurrencesBuilder_.isEmpty()) { - occurrencesBuilder_.dispose(); - occurrencesBuilder_ = null; - occurrences_ = other.occurrences_; - bitField0_ = (bitField0_ & ~0x00000001); - occurrencesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getOccurrencesFieldBuilder() - : null; - } else { - occurrencesBuilder_.addAllMessages(other.occurrences_); - } - } - } - if (!other.getNextPageToken().isEmpty()) { - nextPageToken_ = other.nextPageToken_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.ListNoteOccurrencesResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.ListNoteOccurrencesResponse) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.util.List occurrences_ = - java.util.Collections.emptyList(); - - private void ensureOccurrencesIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - occurrences_ = new java.util.ArrayList(occurrences_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder> - occurrencesBuilder_; - - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List getOccurrencesList() { - if (occurrencesBuilder_ == null) { - return java.util.Collections.unmodifiableList(occurrences_); - } else { - return occurrencesBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public int getOccurrencesCount() { - if (occurrencesBuilder_ == null) { - return occurrences_.size(); - } else { - return occurrencesBuilder_.getCount(); - } - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence getOccurrences(int index) { - if (occurrencesBuilder_ == null) { - return occurrences_.get(index); - } else { - return occurrencesBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder setOccurrences(int index, io.grafeas.v1beta1.Occurrence value) { - if (occurrencesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureOccurrencesIsMutable(); - occurrences_.set(index, value); - onChanged(); - } else { - occurrencesBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder setOccurrences( - int index, io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.set(index, builderForValue.build()); - onChanged(); - } else { - occurrencesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addOccurrences(io.grafeas.v1beta1.Occurrence value) { - if (occurrencesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureOccurrencesIsMutable(); - occurrences_.add(value); - onChanged(); - } else { - occurrencesBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addOccurrences(int index, io.grafeas.v1beta1.Occurrence value) { - if (occurrencesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureOccurrencesIsMutable(); - occurrences_.add(index, value); - onChanged(); - } else { - occurrencesBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addOccurrences(io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.add(builderForValue.build()); - onChanged(); - } else { - occurrencesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addOccurrences( - int index, io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.add(index, builderForValue.build()); - onChanged(); - } else { - occurrencesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addAllOccurrences( - java.lang.Iterable values) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, occurrences_); - onChanged(); - } else { - occurrencesBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder clearOccurrences() { - if (occurrencesBuilder_ == null) { - occurrences_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - occurrencesBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder removeOccurrences(int index) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.remove(index); - onChanged(); - } else { - occurrencesBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence.Builder getOccurrencesBuilder(int index) { - return getOccurrencesFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrencesOrBuilder(int index) { - if (occurrencesBuilder_ == null) { - return occurrences_.get(index); - } else { - return occurrencesBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List - getOccurrencesOrBuilderList() { - if (occurrencesBuilder_ != null) { - return occurrencesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(occurrences_); - } - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence.Builder addOccurrencesBuilder() { - return getOccurrencesFieldBuilder() - .addBuilder(io.grafeas.v1beta1.Occurrence.getDefaultInstance()); - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence.Builder addOccurrencesBuilder(int index) { - return getOccurrencesFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.Occurrence.getDefaultInstance()); - } - /** - * - * - *
-     * The occurrences attached to the specified note.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List getOccurrencesBuilderList() { - return getOccurrencesFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder> - getOccurrencesFieldBuilder() { - if (occurrencesBuilder_ == null) { - occurrencesBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder>( - occurrences_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - occurrences_ = null; - } - return occurrencesBuilder_; - } - - private java.lang.Object nextPageToken_ = ""; - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string next_page_token = 2; - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextPageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string next_page_token = 2; - */ - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string next_page_token = 2; - */ - public Builder setNextPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - nextPageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string next_page_token = 2; - */ - public Builder clearNextPageToken() { - - nextPageToken_ = getDefaultInstance().getNextPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string next_page_token = 2; - */ - public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - nextPageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.ListNoteOccurrencesResponse) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.ListNoteOccurrencesResponse) - private static final io.grafeas.v1beta1.ListNoteOccurrencesResponse DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.ListNoteOccurrencesResponse(); - } - - public static io.grafeas.v1beta1.ListNoteOccurrencesResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListNoteOccurrencesResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListNoteOccurrencesResponse(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNoteOccurrencesResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesResponseOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesResponseOrBuilder.java deleted file mode 100644 index a3b022b2..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNoteOccurrencesResponseOrBuilder.java +++ /dev/null @@ -1,82 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface ListNoteOccurrencesResponseOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.ListNoteOccurrencesResponse) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The occurrences attached to the specified note.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - java.util.List getOccurrencesList(); - /** - * - * - *
-   * The occurrences attached to the specified note.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - io.grafeas.v1beta1.Occurrence getOccurrences(int index); - /** - * - * - *
-   * The occurrences attached to the specified note.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - int getOccurrencesCount(); - /** - * - * - *
-   * The occurrences attached to the specified note.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - java.util.List getOccurrencesOrBuilderList(); - /** - * - * - *
-   * The occurrences attached to the specified note.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrencesOrBuilder(int index); - - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string next_page_token = 2; - */ - java.lang.String getNextPageToken(); - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string next_page_token = 2; - */ - com.google.protobuf.ByteString getNextPageTokenBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesRequest.java deleted file mode 100644 index 47aaa518..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesRequest.java +++ /dev/null @@ -1,998 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to list notes.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.ListNotesRequest} - */ -public final class ListNotesRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.ListNotesRequest) - ListNotesRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListNotesRequest.newBuilder() to construct. - private ListNotesRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListNotesRequest() { - parent_ = ""; - filter_ = ""; - pageToken_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ListNotesRequest( - 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(); - - filter_ = s; - break; - } - case 24: - { - pageSize_ = input.readInt32(); - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_ListNotesRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNotesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.ListNotesRequest.class, - io.grafeas.v1beta1.ListNotesRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 1; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * The name of the project to list notes for in the form of
-   * `projects/[PROJECT_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; - } - } - /** - * - * - *
-   * The name of the project to list notes for in the form of
-   * `projects/[PROJECT_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 FILTER_FIELD_NUMBER = 2; - private volatile java.lang.Object filter_; - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - 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(); - filter_ = s; - return s; - } - } - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PAGE_SIZE_FIELD_NUMBER = 3; - private int pageSize_; - /** - * - * - *
-   * Number of notes to return in the list.
-   * 
- * - * int32 page_size = 3; - */ - public int getPageSize() { - return pageSize_; - } - - public static final int PAGE_TOKEN_FIELD_NUMBER = 4; - private volatile java.lang.Object pageToken_; - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - 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(); - pageToken_ = s; - return s; - } - } - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getParentBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); - } - if (!getFilterBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, filter_); - } - if (pageSize_ != 0) { - output.writeInt32(3, pageSize_); - } - if (!getPageTokenBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, pageToken_); - } - 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 (!getFilterBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, filter_); - } - if (pageSize_ != 0) { - size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, pageSize_); - } - if (!getPageTokenBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, pageToken_); - } - 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 io.grafeas.v1beta1.ListNotesRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.ListNotesRequest other = (io.grafeas.v1beta1.ListNotesRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (!getFilter().equals(other.getFilter())) return false; - if (getPageSize() != other.getPageSize()) return false; - if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - hash = (37 * hash) + FILTER_FIELD_NUMBER; - hash = (53 * hash) + getFilter().hashCode(); - hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; - hash = (53 * hash) + getPageSize(); - hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.ListNotesRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListNotesRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListNotesRequest parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListNotesRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListNotesRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListNotesRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListNotesRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListNotesRequest 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 io.grafeas.v1beta1.ListNotesRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListNotesRequest 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 io.grafeas.v1beta1.ListNotesRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListNotesRequest 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(io.grafeas.v1beta1.ListNotesRequest 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 to list notes.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.ListNotesRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.ListNotesRequest) - io.grafeas.v1beta1.ListNotesRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_ListNotesRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNotesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.ListNotesRequest.class, - io.grafeas.v1beta1.ListNotesRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.ListNotesRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - filter_ = ""; - - pageSize_ = 0; - - pageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_ListNotesRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNotesRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.ListNotesRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNotesRequest build() { - io.grafeas.v1beta1.ListNotesRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNotesRequest buildPartial() { - io.grafeas.v1beta1.ListNotesRequest result = new io.grafeas.v1beta1.ListNotesRequest(this); - result.parent_ = parent_; - result.filter_ = filter_; - result.pageSize_ = pageSize_; - result.pageToken_ = pageToken_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.ListNotesRequest) { - return mergeFrom((io.grafeas.v1beta1.ListNotesRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.ListNotesRequest other) { - if (other == io.grafeas.v1beta1.ListNotesRequest.getDefaultInstance()) return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (!other.getFilter().isEmpty()) { - filter_ = other.filter_; - onChanged(); - } - if (other.getPageSize() != 0) { - setPageSize(other.getPageSize()); - } - if (!other.getPageToken().isEmpty()) { - pageToken_ = other.pageToken_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.ListNotesRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.ListNotesRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * The name of the project to list notes for in the form of
-     * `projects/[PROJECT_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; - } - } - /** - * - * - *
-     * The name of the project to list notes for in the form of
-     * `projects/[PROJECT_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; - } - } - /** - * - * - *
-     * The name of the project to list notes for in the form of
-     * `projects/[PROJECT_ID]`.
-     * 
- * - * string parent = 1; - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project to list notes for in the form of
-     * `projects/[PROJECT_ID]`.
-     * 
- * - * string parent = 1; - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project to list notes for in the form of
-     * `projects/[PROJECT_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 filter_ = ""; - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - filter_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder setFilter(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - filter_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder clearFilter() { - - filter_ = getDefaultInstance().getFilter(); - onChanged(); - return this; - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder setFilterBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - filter_ = value; - onChanged(); - return this; - } - - private int pageSize_; - /** - * - * - *
-     * Number of notes to return in the list.
-     * 
- * - * int32 page_size = 3; - */ - public int getPageSize() { - return pageSize_; - } - /** - * - * - *
-     * Number of notes to return in the list.
-     * 
- * - * int32 page_size = 3; - */ - public Builder setPageSize(int value) { - - pageSize_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Number of notes to return in the list.
-     * 
- * - * int32 page_size = 3; - */ - public Builder clearPageSize() { - - pageSize_ = 0; - onChanged(); - return this; - } - - private java.lang.Object pageToken_ = ""; - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - pageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public Builder setPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - pageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public Builder clearPageToken() { - - pageToken_ = getDefaultInstance().getPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - pageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.ListNotesRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.ListNotesRequest) - private static final io.grafeas.v1beta1.ListNotesRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.ListNotesRequest(); - } - - public static io.grafeas.v1beta1.ListNotesRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListNotesRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListNotesRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNotesRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesRequestOrBuilder.java deleted file mode 100644 index 70959457..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesRequestOrBuilder.java +++ /dev/null @@ -1,86 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface ListNotesRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.ListNotesRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the project to list notes for in the form of
-   * `projects/[PROJECT_ID]`.
-   * 
- * - * string parent = 1; - */ - java.lang.String getParent(); - /** - * - * - *
-   * The name of the project to list notes for in the form of
-   * `projects/[PROJECT_ID]`.
-   * 
- * - * string parent = 1; - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - java.lang.String getFilter(); - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - com.google.protobuf.ByteString getFilterBytes(); - - /** - * - * - *
-   * Number of notes to return in the list.
-   * 
- * - * int32 page_size = 3; - */ - int getPageSize(); - - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - java.lang.String getPageToken(); - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - com.google.protobuf.ByteString getPageTokenBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesResponse.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesResponse.java deleted file mode 100644 index 17dc2542..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesResponse.java +++ /dev/null @@ -1,1084 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Response for listing notes.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.ListNotesResponse} - */ -public final class ListNotesResponse extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.ListNotesResponse) - ListNotesResponseOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListNotesResponse.newBuilder() to construct. - private ListNotesResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListNotesResponse() { - notes_ = java.util.Collections.emptyList(); - nextPageToken_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ListNotesResponse( - 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: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - notes_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - notes_.add(input.readMessage(io.grafeas.v1beta1.Note.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000001) != 0)) { - notes_ = java.util.Collections.unmodifiableList(notes_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_ListNotesResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNotesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.ListNotesResponse.class, - io.grafeas.v1beta1.ListNotesResponse.Builder.class); - } - - private int bitField0_; - public static final int NOTES_FIELD_NUMBER = 1; - private java.util.List notes_; - /** - * - * - *
-   * The notes requested.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public java.util.List getNotesList() { - return notes_; - } - /** - * - * - *
-   * The notes requested.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public java.util.List getNotesOrBuilderList() { - return notes_; - } - /** - * - * - *
-   * The notes requested.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public int getNotesCount() { - return notes_.size(); - } - /** - * - * - *
-   * The notes requested.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.Note getNotes(int index) { - return notes_.get(index); - } - /** - * - * - *
-   * The notes requested.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.NoteOrBuilder getNotesOrBuilder(int index) { - return notes_.get(index); - } - - public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; - private volatile java.lang.Object nextPageToken_; - /** - * - * - *
-   * The next pagination token in the list response. It should be used as
-   * `page_token` for the following request. An empty value means no more
-   * results.
-   * 
- * - * string next_page_token = 2; - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - 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(); - nextPageToken_ = s; - return s; - } - } - /** - * - * - *
-   * The next pagination token in the list response. It should be used as
-   * `page_token` for the following request. An empty value means no more
-   * results.
-   * 
- * - * string next_page_token = 2; - */ - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < notes_.size(); i++) { - output.writeMessage(1, notes_.get(i)); - } - if (!getNextPageTokenBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < notes_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, notes_.get(i)); - } - if (!getNextPageTokenBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); - } - 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 io.grafeas.v1beta1.ListNotesResponse)) { - return super.equals(obj); - } - io.grafeas.v1beta1.ListNotesResponse other = (io.grafeas.v1beta1.ListNotesResponse) obj; - - if (!getNotesList().equals(other.getNotesList())) return false; - if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getNotesCount() > 0) { - hash = (37 * hash) + NOTES_FIELD_NUMBER; - hash = (53 * hash) + getNotesList().hashCode(); - } - hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.ListNotesResponse parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListNotesResponse parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListNotesResponse parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListNotesResponse parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListNotesResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListNotesResponse parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListNotesResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListNotesResponse 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 io.grafeas.v1beta1.ListNotesResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListNotesResponse 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 io.grafeas.v1beta1.ListNotesResponse parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListNotesResponse 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(io.grafeas.v1beta1.ListNotesResponse 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; - } - /** - * - * - *
-   * Response for listing notes.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.ListNotesResponse} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.ListNotesResponse) - io.grafeas.v1beta1.ListNotesResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNotesResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNotesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.ListNotesResponse.class, - io.grafeas.v1beta1.ListNotesResponse.Builder.class); - } - - // Construct using io.grafeas.v1beta1.ListNotesResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getNotesFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (notesBuilder_ == null) { - notes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - notesBuilder_.clear(); - } - nextPageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListNotesResponse_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNotesResponse getDefaultInstanceForType() { - return io.grafeas.v1beta1.ListNotesResponse.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNotesResponse build() { - io.grafeas.v1beta1.ListNotesResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNotesResponse buildPartial() { - io.grafeas.v1beta1.ListNotesResponse result = new io.grafeas.v1beta1.ListNotesResponse(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (notesBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - notes_ = java.util.Collections.unmodifiableList(notes_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.notes_ = notes_; - } else { - result.notes_ = notesBuilder_.build(); - } - result.nextPageToken_ = nextPageToken_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.ListNotesResponse) { - return mergeFrom((io.grafeas.v1beta1.ListNotesResponse) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.ListNotesResponse other) { - if (other == io.grafeas.v1beta1.ListNotesResponse.getDefaultInstance()) return this; - if (notesBuilder_ == null) { - if (!other.notes_.isEmpty()) { - if (notes_.isEmpty()) { - notes_ = other.notes_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureNotesIsMutable(); - notes_.addAll(other.notes_); - } - onChanged(); - } - } else { - if (!other.notes_.isEmpty()) { - if (notesBuilder_.isEmpty()) { - notesBuilder_.dispose(); - notesBuilder_ = null; - notes_ = other.notes_; - bitField0_ = (bitField0_ & ~0x00000001); - notesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getNotesFieldBuilder() - : null; - } else { - notesBuilder_.addAllMessages(other.notes_); - } - } - } - if (!other.getNextPageToken().isEmpty()) { - nextPageToken_ = other.nextPageToken_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.ListNotesResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.ListNotesResponse) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.util.List notes_ = java.util.Collections.emptyList(); - - private void ensureNotesIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - notes_ = new java.util.ArrayList(notes_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Note, - io.grafeas.v1beta1.Note.Builder, - io.grafeas.v1beta1.NoteOrBuilder> - notesBuilder_; - - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public java.util.List getNotesList() { - if (notesBuilder_ == null) { - return java.util.Collections.unmodifiableList(notes_); - } else { - return notesBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public int getNotesCount() { - if (notesBuilder_ == null) { - return notes_.size(); - } else { - return notesBuilder_.getCount(); - } - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.Note getNotes(int index) { - if (notesBuilder_ == null) { - return notes_.get(index); - } else { - return notesBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder setNotes(int index, io.grafeas.v1beta1.Note value) { - if (notesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureNotesIsMutable(); - notes_.set(index, value); - onChanged(); - } else { - notesBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder setNotes(int index, io.grafeas.v1beta1.Note.Builder builderForValue) { - if (notesBuilder_ == null) { - ensureNotesIsMutable(); - notes_.set(index, builderForValue.build()); - onChanged(); - } else { - notesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder addNotes(io.grafeas.v1beta1.Note value) { - if (notesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureNotesIsMutable(); - notes_.add(value); - onChanged(); - } else { - notesBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder addNotes(int index, io.grafeas.v1beta1.Note value) { - if (notesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureNotesIsMutable(); - notes_.add(index, value); - onChanged(); - } else { - notesBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder addNotes(io.grafeas.v1beta1.Note.Builder builderForValue) { - if (notesBuilder_ == null) { - ensureNotesIsMutable(); - notes_.add(builderForValue.build()); - onChanged(); - } else { - notesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder addNotes(int index, io.grafeas.v1beta1.Note.Builder builderForValue) { - if (notesBuilder_ == null) { - ensureNotesIsMutable(); - notes_.add(index, builderForValue.build()); - onChanged(); - } else { - notesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder addAllNotes(java.lang.Iterable values) { - if (notesBuilder_ == null) { - ensureNotesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, notes_); - onChanged(); - } else { - notesBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder clearNotes() { - if (notesBuilder_ == null) { - notes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - notesBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public Builder removeNotes(int index) { - if (notesBuilder_ == null) { - ensureNotesIsMutable(); - notes_.remove(index); - onChanged(); - } else { - notesBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.Note.Builder getNotesBuilder(int index) { - return getNotesFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.NoteOrBuilder getNotesOrBuilder(int index) { - if (notesBuilder_ == null) { - return notes_.get(index); - } else { - return notesBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public java.util.List getNotesOrBuilderList() { - if (notesBuilder_ != null) { - return notesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(notes_); - } - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.Note.Builder addNotesBuilder() { - return getNotesFieldBuilder().addBuilder(io.grafeas.v1beta1.Note.getDefaultInstance()); - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public io.grafeas.v1beta1.Note.Builder addNotesBuilder(int index) { - return getNotesFieldBuilder().addBuilder(index, io.grafeas.v1beta1.Note.getDefaultInstance()); - } - /** - * - * - *
-     * The notes requested.
-     * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - public java.util.List getNotesBuilderList() { - return getNotesFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Note, - io.grafeas.v1beta1.Note.Builder, - io.grafeas.v1beta1.NoteOrBuilder> - getNotesFieldBuilder() { - if (notesBuilder_ == null) { - notesBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Note, - io.grafeas.v1beta1.Note.Builder, - io.grafeas.v1beta1.NoteOrBuilder>( - notes_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - notes_ = null; - } - return notesBuilder_; - } - - private java.lang.Object nextPageToken_ = ""; - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextPageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public Builder setNextPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - nextPageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public Builder clearNextPageToken() { - - nextPageToken_ = getDefaultInstance().getNextPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - nextPageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.ListNotesResponse) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.ListNotesResponse) - private static final io.grafeas.v1beta1.ListNotesResponse DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.ListNotesResponse(); - } - - public static io.grafeas.v1beta1.ListNotesResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListNotesResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListNotesResponse(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListNotesResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesResponseOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesResponseOrBuilder.java deleted file mode 100644 index 1b0b048d..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListNotesResponseOrBuilder.java +++ /dev/null @@ -1,86 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface ListNotesResponseOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.ListNotesResponse) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The notes requested.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - java.util.List getNotesList(); - /** - * - * - *
-   * The notes requested.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - io.grafeas.v1beta1.Note getNotes(int index); - /** - * - * - *
-   * The notes requested.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - int getNotesCount(); - /** - * - * - *
-   * The notes requested.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - java.util.List getNotesOrBuilderList(); - /** - * - * - *
-   * The notes requested.
-   * 
- * - * repeated .grafeas.v1beta1.Note notes = 1; - */ - io.grafeas.v1beta1.NoteOrBuilder getNotesOrBuilder(int index); - - /** - * - * - *
-   * The next pagination token in the list response. It should be used as
-   * `page_token` for the following request. An empty value means no more
-   * results.
-   * 
- * - * string next_page_token = 2; - */ - java.lang.String getNextPageToken(); - /** - * - * - *
-   * The next pagination token in the list response. It should be used as
-   * `page_token` for the following request. An empty value means no more
-   * results.
-   * 
- * - * string next_page_token = 2; - */ - com.google.protobuf.ByteString getNextPageTokenBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesRequest.java deleted file mode 100644 index cd0a582d..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesRequest.java +++ /dev/null @@ -1,1004 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to list occurrences.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.ListOccurrencesRequest} - */ -public final class ListOccurrencesRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.ListOccurrencesRequest) - ListOccurrencesRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListOccurrencesRequest.newBuilder() to construct. - private ListOccurrencesRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListOccurrencesRequest() { - parent_ = ""; - filter_ = ""; - pageToken_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ListOccurrencesRequest( - 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(); - - filter_ = s; - break; - } - case 24: - { - pageSize_ = input.readInt32(); - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListOccurrencesRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListOccurrencesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.ListOccurrencesRequest.class, - io.grafeas.v1beta1.ListOccurrencesRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 1; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * The name of the project to list occurrences for in the form of
-   * `projects/[PROJECT_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; - } - } - /** - * - * - *
-   * The name of the project to list occurrences for in the form of
-   * `projects/[PROJECT_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 FILTER_FIELD_NUMBER = 2; - private volatile java.lang.Object filter_; - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - 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(); - filter_ = s; - return s; - } - } - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PAGE_SIZE_FIELD_NUMBER = 3; - private int pageSize_; - /** - * - * - *
-   * Number of occurrences to return in the list.
-   * 
- * - * int32 page_size = 3; - */ - public int getPageSize() { - return pageSize_; - } - - public static final int PAGE_TOKEN_FIELD_NUMBER = 4; - private volatile java.lang.Object pageToken_; - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - 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(); - pageToken_ = s; - return s; - } - } - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getParentBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); - } - if (!getFilterBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, filter_); - } - if (pageSize_ != 0) { - output.writeInt32(3, pageSize_); - } - if (!getPageTokenBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, pageToken_); - } - 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 (!getFilterBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, filter_); - } - if (pageSize_ != 0) { - size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, pageSize_); - } - if (!getPageTokenBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, pageToken_); - } - 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 io.grafeas.v1beta1.ListOccurrencesRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.ListOccurrencesRequest other = - (io.grafeas.v1beta1.ListOccurrencesRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (!getFilter().equals(other.getFilter())) return false; - if (getPageSize() != other.getPageSize()) return false; - if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - hash = (37 * hash) + FILTER_FIELD_NUMBER; - hash = (53 * hash) + getFilter().hashCode(); - hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; - hash = (53 * hash) + getPageSize(); - hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.ListOccurrencesRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListOccurrencesRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListOccurrencesRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListOccurrencesRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListOccurrencesRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListOccurrencesRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListOccurrencesRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListOccurrencesRequest 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 io.grafeas.v1beta1.ListOccurrencesRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListOccurrencesRequest 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 io.grafeas.v1beta1.ListOccurrencesRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListOccurrencesRequest 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(io.grafeas.v1beta1.ListOccurrencesRequest 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 to list occurrences.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.ListOccurrencesRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.ListOccurrencesRequest) - io.grafeas.v1beta1.ListOccurrencesRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListOccurrencesRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListOccurrencesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.ListOccurrencesRequest.class, - io.grafeas.v1beta1.ListOccurrencesRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.ListOccurrencesRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - filter_ = ""; - - pageSize_ = 0; - - pageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListOccurrencesRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListOccurrencesRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.ListOccurrencesRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.ListOccurrencesRequest build() { - io.grafeas.v1beta1.ListOccurrencesRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListOccurrencesRequest buildPartial() { - io.grafeas.v1beta1.ListOccurrencesRequest result = - new io.grafeas.v1beta1.ListOccurrencesRequest(this); - result.parent_ = parent_; - result.filter_ = filter_; - result.pageSize_ = pageSize_; - result.pageToken_ = pageToken_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.ListOccurrencesRequest) { - return mergeFrom((io.grafeas.v1beta1.ListOccurrencesRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.ListOccurrencesRequest other) { - if (other == io.grafeas.v1beta1.ListOccurrencesRequest.getDefaultInstance()) return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (!other.getFilter().isEmpty()) { - filter_ = other.filter_; - onChanged(); - } - if (other.getPageSize() != 0) { - setPageSize(other.getPageSize()); - } - if (!other.getPageToken().isEmpty()) { - pageToken_ = other.pageToken_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.ListOccurrencesRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.ListOccurrencesRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * The name of the project to list occurrences for in the form of
-     * `projects/[PROJECT_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; - } - } - /** - * - * - *
-     * The name of the project to list occurrences for in the form of
-     * `projects/[PROJECT_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; - } - } - /** - * - * - *
-     * The name of the project to list occurrences for in the form of
-     * `projects/[PROJECT_ID]`.
-     * 
- * - * string parent = 1; - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project to list occurrences for in the form of
-     * `projects/[PROJECT_ID]`.
-     * 
- * - * string parent = 1; - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the project to list occurrences for in the form of
-     * `projects/[PROJECT_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 filter_ = ""; - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - filter_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder setFilter(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - filter_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder clearFilter() { - - filter_ = getDefaultInstance().getFilter(); - onChanged(); - return this; - } - /** - * - * - *
-     * The filter expression.
-     * 
- * - * string filter = 2; - */ - public Builder setFilterBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - filter_ = value; - onChanged(); - return this; - } - - private int pageSize_; - /** - * - * - *
-     * Number of occurrences to return in the list.
-     * 
- * - * int32 page_size = 3; - */ - public int getPageSize() { - return pageSize_; - } - /** - * - * - *
-     * Number of occurrences to return in the list.
-     * 
- * - * int32 page_size = 3; - */ - public Builder setPageSize(int value) { - - pageSize_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Number of occurrences to return in the list.
-     * 
- * - * int32 page_size = 3; - */ - public Builder clearPageSize() { - - pageSize_ = 0; - onChanged(); - return this; - } - - private java.lang.Object pageToken_ = ""; - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - pageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public Builder setPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - pageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public Builder clearPageToken() { - - pageToken_ = getDefaultInstance().getPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 4; - */ - public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - pageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.ListOccurrencesRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.ListOccurrencesRequest) - private static final io.grafeas.v1beta1.ListOccurrencesRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.ListOccurrencesRequest(); - } - - public static io.grafeas.v1beta1.ListOccurrencesRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListOccurrencesRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListOccurrencesRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListOccurrencesRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesRequestOrBuilder.java deleted file mode 100644 index 15f9f196..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesRequestOrBuilder.java +++ /dev/null @@ -1,86 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface ListOccurrencesRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.ListOccurrencesRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the project to list occurrences for in the form of
-   * `projects/[PROJECT_ID]`.
-   * 
- * - * string parent = 1; - */ - java.lang.String getParent(); - /** - * - * - *
-   * The name of the project to list occurrences for in the form of
-   * `projects/[PROJECT_ID]`.
-   * 
- * - * string parent = 1; - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - java.lang.String getFilter(); - /** - * - * - *
-   * The filter expression.
-   * 
- * - * string filter = 2; - */ - com.google.protobuf.ByteString getFilterBytes(); - - /** - * - * - *
-   * Number of occurrences to return in the list.
-   * 
- * - * int32 page_size = 3; - */ - int getPageSize(); - - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - java.lang.String getPageToken(); - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 4; - */ - com.google.protobuf.ByteString getPageTokenBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesResponse.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesResponse.java deleted file mode 100644 index dc7b034a..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesResponse.java +++ /dev/null @@ -1,1097 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Response for listing occurrences.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.ListOccurrencesResponse} - */ -public final class ListOccurrencesResponse extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.ListOccurrencesResponse) - ListOccurrencesResponseOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListOccurrencesResponse.newBuilder() to construct. - private ListOccurrencesResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListOccurrencesResponse() { - occurrences_ = java.util.Collections.emptyList(); - nextPageToken_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ListOccurrencesResponse( - 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: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - occurrences_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - occurrences_.add( - input.readMessage(io.grafeas.v1beta1.Occurrence.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000001) != 0)) { - occurrences_ = java.util.Collections.unmodifiableList(occurrences_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListOccurrencesResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListOccurrencesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.ListOccurrencesResponse.class, - io.grafeas.v1beta1.ListOccurrencesResponse.Builder.class); - } - - private int bitField0_; - public static final int OCCURRENCES_FIELD_NUMBER = 1; - private java.util.List occurrences_; - /** - * - * - *
-   * The occurrences requested.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List getOccurrencesList() { - return occurrences_; - } - /** - * - * - *
-   * The occurrences requested.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List - getOccurrencesOrBuilderList() { - return occurrences_; - } - /** - * - * - *
-   * The occurrences requested.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public int getOccurrencesCount() { - return occurrences_.size(); - } - /** - * - * - *
-   * The occurrences requested.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence getOccurrences(int index) { - return occurrences_.get(index); - } - /** - * - * - *
-   * The occurrences requested.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrencesOrBuilder(int index) { - return occurrences_.get(index); - } - - public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; - private volatile java.lang.Object nextPageToken_; - /** - * - * - *
-   * The next pagination token in the list response. It should be used as
-   * `page_token` for the following request. An empty value means no more
-   * results.
-   * 
- * - * string next_page_token = 2; - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - 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(); - nextPageToken_ = s; - return s; - } - } - /** - * - * - *
-   * The next pagination token in the list response. It should be used as
-   * `page_token` for the following request. An empty value means no more
-   * results.
-   * 
- * - * string next_page_token = 2; - */ - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < occurrences_.size(); i++) { - output.writeMessage(1, occurrences_.get(i)); - } - if (!getNextPageTokenBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < occurrences_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, occurrences_.get(i)); - } - if (!getNextPageTokenBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); - } - 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 io.grafeas.v1beta1.ListOccurrencesResponse)) { - return super.equals(obj); - } - io.grafeas.v1beta1.ListOccurrencesResponse other = - (io.grafeas.v1beta1.ListOccurrencesResponse) obj; - - if (!getOccurrencesList().equals(other.getOccurrencesList())) return false; - if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getOccurrencesCount() > 0) { - hash = (37 * hash) + OCCURRENCES_FIELD_NUMBER; - hash = (53 * hash) + getOccurrencesList().hashCode(); - } - hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.ListOccurrencesResponse parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListOccurrencesResponse parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListOccurrencesResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListOccurrencesResponse parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListOccurrencesResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.ListOccurrencesResponse parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.ListOccurrencesResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListOccurrencesResponse 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 io.grafeas.v1beta1.ListOccurrencesResponse parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListOccurrencesResponse 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 io.grafeas.v1beta1.ListOccurrencesResponse parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.ListOccurrencesResponse 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(io.grafeas.v1beta1.ListOccurrencesResponse 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; - } - /** - * - * - *
-   * Response for listing occurrences.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.ListOccurrencesResponse} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.ListOccurrencesResponse) - io.grafeas.v1beta1.ListOccurrencesResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListOccurrencesResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListOccurrencesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.ListOccurrencesResponse.class, - io.grafeas.v1beta1.ListOccurrencesResponse.Builder.class); - } - - // Construct using io.grafeas.v1beta1.ListOccurrencesResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getOccurrencesFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (occurrencesBuilder_ == null) { - occurrences_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - occurrencesBuilder_.clear(); - } - nextPageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_ListOccurrencesResponse_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListOccurrencesResponse getDefaultInstanceForType() { - return io.grafeas.v1beta1.ListOccurrencesResponse.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.ListOccurrencesResponse build() { - io.grafeas.v1beta1.ListOccurrencesResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListOccurrencesResponse buildPartial() { - io.grafeas.v1beta1.ListOccurrencesResponse result = - new io.grafeas.v1beta1.ListOccurrencesResponse(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (occurrencesBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - occurrences_ = java.util.Collections.unmodifiableList(occurrences_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.occurrences_ = occurrences_; - } else { - result.occurrences_ = occurrencesBuilder_.build(); - } - result.nextPageToken_ = nextPageToken_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.ListOccurrencesResponse) { - return mergeFrom((io.grafeas.v1beta1.ListOccurrencesResponse) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.ListOccurrencesResponse other) { - if (other == io.grafeas.v1beta1.ListOccurrencesResponse.getDefaultInstance()) return this; - if (occurrencesBuilder_ == null) { - if (!other.occurrences_.isEmpty()) { - if (occurrences_.isEmpty()) { - occurrences_ = other.occurrences_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureOccurrencesIsMutable(); - occurrences_.addAll(other.occurrences_); - } - onChanged(); - } - } else { - if (!other.occurrences_.isEmpty()) { - if (occurrencesBuilder_.isEmpty()) { - occurrencesBuilder_.dispose(); - occurrencesBuilder_ = null; - occurrences_ = other.occurrences_; - bitField0_ = (bitField0_ & ~0x00000001); - occurrencesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getOccurrencesFieldBuilder() - : null; - } else { - occurrencesBuilder_.addAllMessages(other.occurrences_); - } - } - } - if (!other.getNextPageToken().isEmpty()) { - nextPageToken_ = other.nextPageToken_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.ListOccurrencesResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.ListOccurrencesResponse) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.util.List occurrences_ = - java.util.Collections.emptyList(); - - private void ensureOccurrencesIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - occurrences_ = new java.util.ArrayList(occurrences_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder> - occurrencesBuilder_; - - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List getOccurrencesList() { - if (occurrencesBuilder_ == null) { - return java.util.Collections.unmodifiableList(occurrences_); - } else { - return occurrencesBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public int getOccurrencesCount() { - if (occurrencesBuilder_ == null) { - return occurrences_.size(); - } else { - return occurrencesBuilder_.getCount(); - } - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence getOccurrences(int index) { - if (occurrencesBuilder_ == null) { - return occurrences_.get(index); - } else { - return occurrencesBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder setOccurrences(int index, io.grafeas.v1beta1.Occurrence value) { - if (occurrencesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureOccurrencesIsMutable(); - occurrences_.set(index, value); - onChanged(); - } else { - occurrencesBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder setOccurrences( - int index, io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.set(index, builderForValue.build()); - onChanged(); - } else { - occurrencesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addOccurrences(io.grafeas.v1beta1.Occurrence value) { - if (occurrencesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureOccurrencesIsMutable(); - occurrences_.add(value); - onChanged(); - } else { - occurrencesBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addOccurrences(int index, io.grafeas.v1beta1.Occurrence value) { - if (occurrencesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureOccurrencesIsMutable(); - occurrences_.add(index, value); - onChanged(); - } else { - occurrencesBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addOccurrences(io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.add(builderForValue.build()); - onChanged(); - } else { - occurrencesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addOccurrences( - int index, io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.add(index, builderForValue.build()); - onChanged(); - } else { - occurrencesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder addAllOccurrences( - java.lang.Iterable values) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, occurrences_); - onChanged(); - } else { - occurrencesBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder clearOccurrences() { - if (occurrencesBuilder_ == null) { - occurrences_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - occurrencesBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public Builder removeOccurrences(int index) { - if (occurrencesBuilder_ == null) { - ensureOccurrencesIsMutable(); - occurrences_.remove(index); - onChanged(); - } else { - occurrencesBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence.Builder getOccurrencesBuilder(int index) { - return getOccurrencesFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrencesOrBuilder(int index) { - if (occurrencesBuilder_ == null) { - return occurrences_.get(index); - } else { - return occurrencesBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List - getOccurrencesOrBuilderList() { - if (occurrencesBuilder_ != null) { - return occurrencesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(occurrences_); - } - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence.Builder addOccurrencesBuilder() { - return getOccurrencesFieldBuilder() - .addBuilder(io.grafeas.v1beta1.Occurrence.getDefaultInstance()); - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public io.grafeas.v1beta1.Occurrence.Builder addOccurrencesBuilder(int index) { - return getOccurrencesFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.Occurrence.getDefaultInstance()); - } - /** - * - * - *
-     * The occurrences requested.
-     * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - public java.util.List getOccurrencesBuilderList() { - return getOccurrencesFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder> - getOccurrencesFieldBuilder() { - if (occurrencesBuilder_ == null) { - occurrencesBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder>( - occurrences_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - occurrences_ = null; - } - return occurrencesBuilder_; - } - - private java.lang.Object nextPageToken_ = ""; - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextPageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public Builder setNextPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - nextPageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public Builder clearNextPageToken() { - - nextPageToken_ = getDefaultInstance().getNextPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * The next pagination token in the list response. It should be used as
-     * `page_token` for the following request. An empty value means no more
-     * results.
-     * 
- * - * string next_page_token = 2; - */ - public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - nextPageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.ListOccurrencesResponse) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.ListOccurrencesResponse) - private static final io.grafeas.v1beta1.ListOccurrencesResponse DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.ListOccurrencesResponse(); - } - - public static io.grafeas.v1beta1.ListOccurrencesResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListOccurrencesResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListOccurrencesResponse(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.ListOccurrencesResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesResponseOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesResponseOrBuilder.java deleted file mode 100644 index 07a778b3..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ListOccurrencesResponseOrBuilder.java +++ /dev/null @@ -1,86 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface ListOccurrencesResponseOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.ListOccurrencesResponse) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The occurrences requested.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - java.util.List getOccurrencesList(); - /** - * - * - *
-   * The occurrences requested.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - io.grafeas.v1beta1.Occurrence getOccurrences(int index); - /** - * - * - *
-   * The occurrences requested.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - int getOccurrencesCount(); - /** - * - * - *
-   * The occurrences requested.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - java.util.List getOccurrencesOrBuilderList(); - /** - * - * - *
-   * The occurrences requested.
-   * 
- * - * repeated .grafeas.v1beta1.Occurrence occurrences = 1; - */ - io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrencesOrBuilder(int index); - - /** - * - * - *
-   * The next pagination token in the list response. It should be used as
-   * `page_token` for the following request. An empty value means no more
-   * results.
-   * 
- * - * string next_page_token = 2; - */ - java.lang.String getNextPageToken(); - /** - * - * - *
-   * The next pagination token in the list response. It should be used as
-   * `page_token` for the following request. An empty value means no more
-   * results.
-   * 
- * - * string next_page_token = 2; - */ - com.google.protobuf.ByteString getNextPageTokenBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Note.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Note.java deleted file mode 100644 index 29084fc4..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Note.java +++ /dev/null @@ -1,4674 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * A type of analysis that can be done for a resource.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.Note} - */ -public final class Note extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.Note) - NoteOrBuilder { - private static final long serialVersionUID = 0L; - // Use Note.newBuilder() to construct. - private Note(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Note() { - name_ = ""; - shortDescription_ = ""; - longDescription_ = ""; - kind_ = 0; - relatedUrl_ = java.util.Collections.emptyList(); - relatedNoteNames_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Note( - 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(); - - shortDescription_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - longDescription_ = s; - break; - } - case 32: - { - int rawValue = input.readEnum(); - - kind_ = rawValue; - break; - } - case 42: - { - if (!((mutable_bitField0_ & 0x00000010) != 0)) { - relatedUrl_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000010; - } - relatedUrl_.add( - input.readMessage( - io.grafeas.v1beta1.common.RelatedUrl.parser(), extensionRegistry)); - break; - } - case 50: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (expirationTime_ != null) { - subBuilder = expirationTime_.toBuilder(); - } - expirationTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(expirationTime_); - expirationTime_ = subBuilder.buildPartial(); - } - - break; - } - case 58: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 66: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (updateTime_ != null) { - subBuilder = updateTime_.toBuilder(); - } - updateTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateTime_); - updateTime_ = subBuilder.buildPartial(); - } - - break; - } - case 74: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000100) != 0)) { - relatedNoteNames_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000100; - } - relatedNoteNames_.add(s); - break; - } - case 82: - { - io.grafeas.v1beta1.vulnerability.Vulnerability.Builder subBuilder = null; - if (typeCase_ == 10) { - subBuilder = ((io.grafeas.v1beta1.vulnerability.Vulnerability) type_).toBuilder(); - } - type_ = - input.readMessage( - io.grafeas.v1beta1.vulnerability.Vulnerability.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.vulnerability.Vulnerability) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 10; - break; - } - case 90: - { - io.grafeas.v1beta1.build.Build.Builder subBuilder = null; - if (typeCase_ == 11) { - subBuilder = ((io.grafeas.v1beta1.build.Build) type_).toBuilder(); - } - type_ = input.readMessage(io.grafeas.v1beta1.build.Build.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.build.Build) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 11; - break; - } - case 98: - { - io.grafeas.v1beta1.image.Basis.Builder subBuilder = null; - if (typeCase_ == 12) { - subBuilder = ((io.grafeas.v1beta1.image.Basis) type_).toBuilder(); - } - type_ = input.readMessage(io.grafeas.v1beta1.image.Basis.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.image.Basis) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 12; - break; - } - case 106: - { - io.grafeas.v1beta1.pkg.Package.Builder subBuilder = null; - if (typeCase_ == 13) { - subBuilder = ((io.grafeas.v1beta1.pkg.Package) type_).toBuilder(); - } - type_ = input.readMessage(io.grafeas.v1beta1.pkg.Package.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.pkg.Package) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 13; - break; - } - case 114: - { - io.grafeas.v1beta1.deployment.Deployable.Builder subBuilder = null; - if (typeCase_ == 14) { - subBuilder = ((io.grafeas.v1beta1.deployment.Deployable) type_).toBuilder(); - } - type_ = - input.readMessage( - io.grafeas.v1beta1.deployment.Deployable.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.deployment.Deployable) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 14; - break; - } - case 122: - { - io.grafeas.v1beta1.discovery.Discovery.Builder subBuilder = null; - if (typeCase_ == 15) { - subBuilder = ((io.grafeas.v1beta1.discovery.Discovery) type_).toBuilder(); - } - type_ = - input.readMessage( - io.grafeas.v1beta1.discovery.Discovery.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.discovery.Discovery) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 15; - break; - } - case 130: - { - io.grafeas.v1beta1.attestation.Authority.Builder subBuilder = null; - if (typeCase_ == 16) { - subBuilder = ((io.grafeas.v1beta1.attestation.Authority) type_).toBuilder(); - } - type_ = - input.readMessage( - io.grafeas.v1beta1.attestation.Authority.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.attestation.Authority) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 16; - break; - } - default: - { - if (!parseUnknownField(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) != 0)) { - relatedUrl_ = java.util.Collections.unmodifiableList(relatedUrl_); - } - if (((mutable_bitField0_ & 0x00000100) != 0)) { - relatedNoteNames_ = relatedNoteNames_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Note_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Note_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.Note.class, io.grafeas.v1beta1.Note.Builder.class); - } - - private int bitField0_; - private int typeCase_ = 0; - private java.lang.Object type_; - - public enum TypeCase implements com.google.protobuf.Internal.EnumLite { - VULNERABILITY(10), - BUILD(11), - BASE_IMAGE(12), - PACKAGE(13), - DEPLOYABLE(14), - DISCOVERY(15), - ATTESTATION_AUTHORITY(16), - TYPE_NOT_SET(0); - private final int value; - - private TypeCase(int value) { - this.value = value; - } - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static TypeCase valueOf(int value) { - return forNumber(value); - } - - public static TypeCase forNumber(int value) { - switch (value) { - case 10: - return VULNERABILITY; - case 11: - return BUILD; - case 12: - return BASE_IMAGE; - case 13: - return PACKAGE; - case 14: - return DEPLOYABLE; - case 15: - return DISCOVERY; - case 16: - return ATTESTATION_AUTHORITY; - case 0: - return TYPE_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public TypeCase getTypeCase() { - return TypeCase.forNumber(typeCase_); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Output only. The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * 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; - } - } - /** - * - * - *
-   * Output only. The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * 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 SHORT_DESCRIPTION_FIELD_NUMBER = 2; - private volatile java.lang.Object shortDescription_; - /** - * - * - *
-   * A one sentence description of this note.
-   * 
- * - * string short_description = 2; - */ - public java.lang.String getShortDescription() { - java.lang.Object ref = shortDescription_; - 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(); - shortDescription_ = s; - return s; - } - } - /** - * - * - *
-   * A one sentence description of this note.
-   * 
- * - * string short_description = 2; - */ - public com.google.protobuf.ByteString getShortDescriptionBytes() { - java.lang.Object ref = shortDescription_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - shortDescription_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int LONG_DESCRIPTION_FIELD_NUMBER = 3; - private volatile java.lang.Object longDescription_; - /** - * - * - *
-   * A detailed description of this note.
-   * 
- * - * string long_description = 3; - */ - public java.lang.String getLongDescription() { - java.lang.Object ref = longDescription_; - 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(); - longDescription_ = s; - return s; - } - } - /** - * - * - *
-   * A detailed description of this note.
-   * 
- * - * string long_description = 3; - */ - public com.google.protobuf.ByteString getLongDescriptionBytes() { - java.lang.Object ref = longDescription_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - longDescription_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int KIND_FIELD_NUMBER = 4; - private int kind_; - /** - * - * - *
-   * Output only. The type of analysis. This field can be used as a filter in
-   * list requests.
-   * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public int getKindValue() { - return kind_; - } - /** - * - * - *
-   * Output only. The type of analysis. This field can be used as a filter in
-   * list requests.
-   * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public io.grafeas.v1beta1.common.NoteKind getKind() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.common.NoteKind result = io.grafeas.v1beta1.common.NoteKind.valueOf(kind_); - return result == null ? io.grafeas.v1beta1.common.NoteKind.UNRECOGNIZED : result; - } - - public static final int RELATED_URL_FIELD_NUMBER = 5; - private java.util.List relatedUrl_; - /** - * - * - *
-   * URLs associated with this note.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public java.util.List getRelatedUrlList() { - return relatedUrl_; - } - /** - * - * - *
-   * URLs associated with this note.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public java.util.List - getRelatedUrlOrBuilderList() { - return relatedUrl_; - } - /** - * - * - *
-   * URLs associated with this note.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public int getRelatedUrlCount() { - return relatedUrl_.size(); - } - /** - * - * - *
-   * URLs associated with this note.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public io.grafeas.v1beta1.common.RelatedUrl getRelatedUrl(int index) { - return relatedUrl_.get(index); - } - /** - * - * - *
-   * URLs associated with this note.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public io.grafeas.v1beta1.common.RelatedUrlOrBuilder getRelatedUrlOrBuilder(int index) { - return relatedUrl_.get(index); - } - - public static final int EXPIRATION_TIME_FIELD_NUMBER = 6; - private com.google.protobuf.Timestamp expirationTime_; - /** - * - * - *
-   * Time of expiration for this note. Empty if note does not expire.
-   * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - public boolean hasExpirationTime() { - return expirationTime_ != null; - } - /** - * - * - *
-   * Time of expiration for this note. Empty if note does not expire.
-   * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - public com.google.protobuf.Timestamp getExpirationTime() { - return expirationTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : expirationTime_; - } - /** - * - * - *
-   * Time of expiration for this note. Empty if note does not expire.
-   * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - public com.google.protobuf.TimestampOrBuilder getExpirationTimeOrBuilder() { - return getExpirationTime(); - } - - public static final int CREATE_TIME_FIELD_NUMBER = 7; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-   * Output only. The time this note was created. This field can be used as a
-   * filter in list requests.
-   * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-   * Output only. The time this note was created. This field can be used as a
-   * filter in list requests.
-   * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-   * Output only. The time this note was created. This field can be used as a
-   * filter in list requests.
-   * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int UPDATE_TIME_FIELD_NUMBER = 8; - private com.google.protobuf.Timestamp updateTime_; - /** - * - * - *
-   * Output only. The time this note was last updated. This field can be used as
-   * a filter in list requests.
-   * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - public boolean hasUpdateTime() { - return updateTime_ != null; - } - /** - * - * - *
-   * Output only. The time this note was last updated. This field can be used as
-   * a filter in list requests.
-   * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - public com.google.protobuf.Timestamp getUpdateTime() { - return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; - } - /** - * - * - *
-   * Output only. The time this note was last updated. This field can be used as
-   * a filter in list requests.
-   * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - return getUpdateTime(); - } - - public static final int RELATED_NOTE_NAMES_FIELD_NUMBER = 9; - private com.google.protobuf.LazyStringList relatedNoteNames_; - /** - * - * - *
-   * Other notes related to this note.
-   * 
- * - * repeated string related_note_names = 9; - */ - public com.google.protobuf.ProtocolStringList getRelatedNoteNamesList() { - return relatedNoteNames_; - } - /** - * - * - *
-   * Other notes related to this note.
-   * 
- * - * repeated string related_note_names = 9; - */ - public int getRelatedNoteNamesCount() { - return relatedNoteNames_.size(); - } - /** - * - * - *
-   * Other notes related to this note.
-   * 
- * - * repeated string related_note_names = 9; - */ - public java.lang.String getRelatedNoteNames(int index) { - return relatedNoteNames_.get(index); - } - /** - * - * - *
-   * Other notes related to this note.
-   * 
- * - * repeated string related_note_names = 9; - */ - public com.google.protobuf.ByteString getRelatedNoteNamesBytes(int index) { - return relatedNoteNames_.getByteString(index); - } - - public static final int VULNERABILITY_FIELD_NUMBER = 10; - /** - * - * - *
-   * A note describing a package vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - public boolean hasVulnerability() { - return typeCase_ == 10; - } - /** - * - * - *
-   * A note describing a package vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - public io.grafeas.v1beta1.vulnerability.Vulnerability getVulnerability() { - if (typeCase_ == 10) { - return (io.grafeas.v1beta1.vulnerability.Vulnerability) type_; - } - return io.grafeas.v1beta1.vulnerability.Vulnerability.getDefaultInstance(); - } - /** - * - * - *
-   * A note describing a package vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityOrBuilder getVulnerabilityOrBuilder() { - if (typeCase_ == 10) { - return (io.grafeas.v1beta1.vulnerability.Vulnerability) type_; - } - return io.grafeas.v1beta1.vulnerability.Vulnerability.getDefaultInstance(); - } - - public static final int BUILD_FIELD_NUMBER = 11; - /** - * - * - *
-   * A note describing build provenance for a verifiable build.
-   * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - public boolean hasBuild() { - return typeCase_ == 11; - } - /** - * - * - *
-   * A note describing build provenance for a verifiable build.
-   * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - public io.grafeas.v1beta1.build.Build getBuild() { - if (typeCase_ == 11) { - return (io.grafeas.v1beta1.build.Build) type_; - } - return io.grafeas.v1beta1.build.Build.getDefaultInstance(); - } - /** - * - * - *
-   * A note describing build provenance for a verifiable build.
-   * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - public io.grafeas.v1beta1.build.BuildOrBuilder getBuildOrBuilder() { - if (typeCase_ == 11) { - return (io.grafeas.v1beta1.build.Build) type_; - } - return io.grafeas.v1beta1.build.Build.getDefaultInstance(); - } - - public static final int BASE_IMAGE_FIELD_NUMBER = 12; - /** - * - * - *
-   * A note describing a base image.
-   * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - public boolean hasBaseImage() { - return typeCase_ == 12; - } - /** - * - * - *
-   * A note describing a base image.
-   * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - public io.grafeas.v1beta1.image.Basis getBaseImage() { - if (typeCase_ == 12) { - return (io.grafeas.v1beta1.image.Basis) type_; - } - return io.grafeas.v1beta1.image.Basis.getDefaultInstance(); - } - /** - * - * - *
-   * A note describing a base image.
-   * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - public io.grafeas.v1beta1.image.BasisOrBuilder getBaseImageOrBuilder() { - if (typeCase_ == 12) { - return (io.grafeas.v1beta1.image.Basis) type_; - } - return io.grafeas.v1beta1.image.Basis.getDefaultInstance(); - } - - public static final int PACKAGE_FIELD_NUMBER = 13; - /** - * - * - *
-   * A note describing a package hosted by various package managers.
-   * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - public boolean hasPackage() { - return typeCase_ == 13; - } - /** - * - * - *
-   * A note describing a package hosted by various package managers.
-   * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - public io.grafeas.v1beta1.pkg.Package getPackage() { - if (typeCase_ == 13) { - return (io.grafeas.v1beta1.pkg.Package) type_; - } - return io.grafeas.v1beta1.pkg.Package.getDefaultInstance(); - } - /** - * - * - *
-   * A note describing a package hosted by various package managers.
-   * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - public io.grafeas.v1beta1.pkg.PackageOrBuilder getPackageOrBuilder() { - if (typeCase_ == 13) { - return (io.grafeas.v1beta1.pkg.Package) type_; - } - return io.grafeas.v1beta1.pkg.Package.getDefaultInstance(); - } - - public static final int DEPLOYABLE_FIELD_NUMBER = 14; - /** - * - * - *
-   * A note describing something that can be deployed.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - public boolean hasDeployable() { - return typeCase_ == 14; - } - /** - * - * - *
-   * A note describing something that can be deployed.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - public io.grafeas.v1beta1.deployment.Deployable getDeployable() { - if (typeCase_ == 14) { - return (io.grafeas.v1beta1.deployment.Deployable) type_; - } - return io.grafeas.v1beta1.deployment.Deployable.getDefaultInstance(); - } - /** - * - * - *
-   * A note describing something that can be deployed.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - public io.grafeas.v1beta1.deployment.DeployableOrBuilder getDeployableOrBuilder() { - if (typeCase_ == 14) { - return (io.grafeas.v1beta1.deployment.Deployable) type_; - } - return io.grafeas.v1beta1.deployment.Deployable.getDefaultInstance(); - } - - public static final int DISCOVERY_FIELD_NUMBER = 15; - /** - * - * - *
-   * A note describing the initial analysis of a resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - public boolean hasDiscovery() { - return typeCase_ == 15; - } - /** - * - * - *
-   * A note describing the initial analysis of a resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - public io.grafeas.v1beta1.discovery.Discovery getDiscovery() { - if (typeCase_ == 15) { - return (io.grafeas.v1beta1.discovery.Discovery) type_; - } - return io.grafeas.v1beta1.discovery.Discovery.getDefaultInstance(); - } - /** - * - * - *
-   * A note describing the initial analysis of a resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - public io.grafeas.v1beta1.discovery.DiscoveryOrBuilder getDiscoveryOrBuilder() { - if (typeCase_ == 15) { - return (io.grafeas.v1beta1.discovery.Discovery) type_; - } - return io.grafeas.v1beta1.discovery.Discovery.getDefaultInstance(); - } - - public static final int ATTESTATION_AUTHORITY_FIELD_NUMBER = 16; - /** - * - * - *
-   * A note describing an attestation role.
-   * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - public boolean hasAttestationAuthority() { - return typeCase_ == 16; - } - /** - * - * - *
-   * A note describing an attestation role.
-   * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - public io.grafeas.v1beta1.attestation.Authority getAttestationAuthority() { - if (typeCase_ == 16) { - return (io.grafeas.v1beta1.attestation.Authority) type_; - } - return io.grafeas.v1beta1.attestation.Authority.getDefaultInstance(); - } - /** - * - * - *
-   * A note describing an attestation role.
-   * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - public io.grafeas.v1beta1.attestation.AuthorityOrBuilder getAttestationAuthorityOrBuilder() { - if (typeCase_ == 16) { - return (io.grafeas.v1beta1.attestation.Authority) type_; - } - return io.grafeas.v1beta1.attestation.Authority.getDefaultInstance(); - } - - 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 (!getShortDescriptionBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, shortDescription_); - } - if (!getLongDescriptionBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, longDescription_); - } - if (kind_ != io.grafeas.v1beta1.common.NoteKind.NOTE_KIND_UNSPECIFIED.getNumber()) { - output.writeEnum(4, kind_); - } - for (int i = 0; i < relatedUrl_.size(); i++) { - output.writeMessage(5, relatedUrl_.get(i)); - } - if (expirationTime_ != null) { - output.writeMessage(6, getExpirationTime()); - } - if (createTime_ != null) { - output.writeMessage(7, getCreateTime()); - } - if (updateTime_ != null) { - output.writeMessage(8, getUpdateTime()); - } - for (int i = 0; i < relatedNoteNames_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 9, relatedNoteNames_.getRaw(i)); - } - if (typeCase_ == 10) { - output.writeMessage(10, (io.grafeas.v1beta1.vulnerability.Vulnerability) type_); - } - if (typeCase_ == 11) { - output.writeMessage(11, (io.grafeas.v1beta1.build.Build) type_); - } - if (typeCase_ == 12) { - output.writeMessage(12, (io.grafeas.v1beta1.image.Basis) type_); - } - if (typeCase_ == 13) { - output.writeMessage(13, (io.grafeas.v1beta1.pkg.Package) type_); - } - if (typeCase_ == 14) { - output.writeMessage(14, (io.grafeas.v1beta1.deployment.Deployable) type_); - } - if (typeCase_ == 15) { - output.writeMessage(15, (io.grafeas.v1beta1.discovery.Discovery) type_); - } - if (typeCase_ == 16) { - output.writeMessage(16, (io.grafeas.v1beta1.attestation.Authority) type_); - } - 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 (!getShortDescriptionBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, shortDescription_); - } - if (!getLongDescriptionBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, longDescription_); - } - if (kind_ != io.grafeas.v1beta1.common.NoteKind.NOTE_KIND_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, kind_); - } - for (int i = 0; i < relatedUrl_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, relatedUrl_.get(i)); - } - if (expirationTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getExpirationTime()); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getCreateTime()); - } - if (updateTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getUpdateTime()); - } - { - int dataSize = 0; - for (int i = 0; i < relatedNoteNames_.size(); i++) { - dataSize += computeStringSizeNoTag(relatedNoteNames_.getRaw(i)); - } - size += dataSize; - size += 1 * getRelatedNoteNamesList().size(); - } - if (typeCase_ == 10) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 10, (io.grafeas.v1beta1.vulnerability.Vulnerability) type_); - } - if (typeCase_ == 11) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 11, (io.grafeas.v1beta1.build.Build) type_); - } - if (typeCase_ == 12) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 12, (io.grafeas.v1beta1.image.Basis) type_); - } - if (typeCase_ == 13) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 13, (io.grafeas.v1beta1.pkg.Package) type_); - } - if (typeCase_ == 14) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 14, (io.grafeas.v1beta1.deployment.Deployable) type_); - } - if (typeCase_ == 15) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 15, (io.grafeas.v1beta1.discovery.Discovery) type_); - } - if (typeCase_ == 16) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 16, (io.grafeas.v1beta1.attestation.Authority) type_); - } - 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 io.grafeas.v1beta1.Note)) { - return super.equals(obj); - } - io.grafeas.v1beta1.Note other = (io.grafeas.v1beta1.Note) obj; - - if (!getName().equals(other.getName())) return false; - if (!getShortDescription().equals(other.getShortDescription())) return false; - if (!getLongDescription().equals(other.getLongDescription())) return false; - if (kind_ != other.kind_) return false; - if (!getRelatedUrlList().equals(other.getRelatedUrlList())) return false; - if (hasExpirationTime() != other.hasExpirationTime()) return false; - if (hasExpirationTime()) { - if (!getExpirationTime().equals(other.getExpirationTime())) return false; - } - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasUpdateTime() != other.hasUpdateTime()) return false; - if (hasUpdateTime()) { - if (!getUpdateTime().equals(other.getUpdateTime())) return false; - } - if (!getRelatedNoteNamesList().equals(other.getRelatedNoteNamesList())) return false; - if (!getTypeCase().equals(other.getTypeCase())) return false; - switch (typeCase_) { - case 10: - if (!getVulnerability().equals(other.getVulnerability())) return false; - break; - case 11: - if (!getBuild().equals(other.getBuild())) return false; - break; - case 12: - if (!getBaseImage().equals(other.getBaseImage())) return false; - break; - case 13: - if (!getPackage().equals(other.getPackage())) return false; - break; - case 14: - if (!getDeployable().equals(other.getDeployable())) return false; - break; - case 15: - if (!getDiscovery().equals(other.getDiscovery())) return false; - break; - case 16: - if (!getAttestationAuthority().equals(other.getAttestationAuthority())) return false; - break; - case 0: - default: - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + SHORT_DESCRIPTION_FIELD_NUMBER; - hash = (53 * hash) + getShortDescription().hashCode(); - hash = (37 * hash) + LONG_DESCRIPTION_FIELD_NUMBER; - hash = (53 * hash) + getLongDescription().hashCode(); - hash = (37 * hash) + KIND_FIELD_NUMBER; - hash = (53 * hash) + kind_; - if (getRelatedUrlCount() > 0) { - hash = (37 * hash) + RELATED_URL_FIELD_NUMBER; - hash = (53 * hash) + getRelatedUrlList().hashCode(); - } - if (hasExpirationTime()) { - hash = (37 * hash) + EXPIRATION_TIME_FIELD_NUMBER; - hash = (53 * hash) + getExpirationTime().hashCode(); - } - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasUpdateTime()) { - hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getUpdateTime().hashCode(); - } - if (getRelatedNoteNamesCount() > 0) { - hash = (37 * hash) + RELATED_NOTE_NAMES_FIELD_NUMBER; - hash = (53 * hash) + getRelatedNoteNamesList().hashCode(); - } - switch (typeCase_) { - case 10: - hash = (37 * hash) + VULNERABILITY_FIELD_NUMBER; - hash = (53 * hash) + getVulnerability().hashCode(); - break; - case 11: - hash = (37 * hash) + BUILD_FIELD_NUMBER; - hash = (53 * hash) + getBuild().hashCode(); - break; - case 12: - hash = (37 * hash) + BASE_IMAGE_FIELD_NUMBER; - hash = (53 * hash) + getBaseImage().hashCode(); - break; - case 13: - hash = (37 * hash) + PACKAGE_FIELD_NUMBER; - hash = (53 * hash) + getPackage().hashCode(); - break; - case 14: - hash = (37 * hash) + DEPLOYABLE_FIELD_NUMBER; - hash = (53 * hash) + getDeployable().hashCode(); - break; - case 15: - hash = (37 * hash) + DISCOVERY_FIELD_NUMBER; - hash = (53 * hash) + getDiscovery().hashCode(); - break; - case 16: - hash = (37 * hash) + ATTESTATION_AUTHORITY_FIELD_NUMBER; - hash = (53 * hash) + getAttestationAuthority().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.Note parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.Note parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.Note parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.Note parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.Note parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.Note parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.Note parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.Note 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 io.grafeas.v1beta1.Note parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.Note 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 io.grafeas.v1beta1.Note parseFrom(com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.Note 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(io.grafeas.v1beta1.Note prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A type of analysis that can be done for a resource.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.Note} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.Note) - io.grafeas.v1beta1.NoteOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Note_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Note_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.Note.class, io.grafeas.v1beta1.Note.Builder.class); - } - - // Construct using io.grafeas.v1beta1.Note.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getRelatedUrlFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - shortDescription_ = ""; - - longDescription_ = ""; - - kind_ = 0; - - if (relatedUrlBuilder_ == null) { - relatedUrl_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000010); - } else { - relatedUrlBuilder_.clear(); - } - if (expirationTimeBuilder_ == null) { - expirationTime_ = null; - } else { - expirationTime_ = null; - expirationTimeBuilder_ = null; - } - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (updateTimeBuilder_ == null) { - updateTime_ = null; - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - relatedNoteNames_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000100); - typeCase_ = 0; - type_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Note_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.Note getDefaultInstanceForType() { - return io.grafeas.v1beta1.Note.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.Note build() { - io.grafeas.v1beta1.Note result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.Note buildPartial() { - io.grafeas.v1beta1.Note result = new io.grafeas.v1beta1.Note(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.name_ = name_; - result.shortDescription_ = shortDescription_; - result.longDescription_ = longDescription_; - result.kind_ = kind_; - if (relatedUrlBuilder_ == null) { - if (((bitField0_ & 0x00000010) != 0)) { - relatedUrl_ = java.util.Collections.unmodifiableList(relatedUrl_); - bitField0_ = (bitField0_ & ~0x00000010); - } - result.relatedUrl_ = relatedUrl_; - } else { - result.relatedUrl_ = relatedUrlBuilder_.build(); - } - if (expirationTimeBuilder_ == null) { - result.expirationTime_ = expirationTime_; - } else { - result.expirationTime_ = expirationTimeBuilder_.build(); - } - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (updateTimeBuilder_ == null) { - result.updateTime_ = updateTime_; - } else { - result.updateTime_ = updateTimeBuilder_.build(); - } - if (((bitField0_ & 0x00000100) != 0)) { - relatedNoteNames_ = relatedNoteNames_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000100); - } - result.relatedNoteNames_ = relatedNoteNames_; - if (typeCase_ == 10) { - if (vulnerabilityBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = vulnerabilityBuilder_.build(); - } - } - if (typeCase_ == 11) { - if (buildBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = buildBuilder_.build(); - } - } - if (typeCase_ == 12) { - if (baseImageBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = baseImageBuilder_.build(); - } - } - if (typeCase_ == 13) { - if (packageBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = packageBuilder_.build(); - } - } - if (typeCase_ == 14) { - if (deployableBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = deployableBuilder_.build(); - } - } - if (typeCase_ == 15) { - if (discoveryBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = discoveryBuilder_.build(); - } - } - if (typeCase_ == 16) { - if (attestationAuthorityBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = attestationAuthorityBuilder_.build(); - } - } - result.bitField0_ = to_bitField0_; - result.typeCase_ = typeCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.Note) { - return mergeFrom((io.grafeas.v1beta1.Note) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.Note other) { - if (other == io.grafeas.v1beta1.Note.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getShortDescription().isEmpty()) { - shortDescription_ = other.shortDescription_; - onChanged(); - } - if (!other.getLongDescription().isEmpty()) { - longDescription_ = other.longDescription_; - onChanged(); - } - if (other.kind_ != 0) { - setKindValue(other.getKindValue()); - } - if (relatedUrlBuilder_ == null) { - if (!other.relatedUrl_.isEmpty()) { - if (relatedUrl_.isEmpty()) { - relatedUrl_ = other.relatedUrl_; - bitField0_ = (bitField0_ & ~0x00000010); - } else { - ensureRelatedUrlIsMutable(); - relatedUrl_.addAll(other.relatedUrl_); - } - onChanged(); - } - } else { - if (!other.relatedUrl_.isEmpty()) { - if (relatedUrlBuilder_.isEmpty()) { - relatedUrlBuilder_.dispose(); - relatedUrlBuilder_ = null; - relatedUrl_ = other.relatedUrl_; - bitField0_ = (bitField0_ & ~0x00000010); - relatedUrlBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getRelatedUrlFieldBuilder() - : null; - } else { - relatedUrlBuilder_.addAllMessages(other.relatedUrl_); - } - } - } - if (other.hasExpirationTime()) { - mergeExpirationTime(other.getExpirationTime()); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasUpdateTime()) { - mergeUpdateTime(other.getUpdateTime()); - } - if (!other.relatedNoteNames_.isEmpty()) { - if (relatedNoteNames_.isEmpty()) { - relatedNoteNames_ = other.relatedNoteNames_; - bitField0_ = (bitField0_ & ~0x00000100); - } else { - ensureRelatedNoteNamesIsMutable(); - relatedNoteNames_.addAll(other.relatedNoteNames_); - } - onChanged(); - } - switch (other.getTypeCase()) { - case VULNERABILITY: - { - mergeVulnerability(other.getVulnerability()); - break; - } - case BUILD: - { - mergeBuild(other.getBuild()); - break; - } - case BASE_IMAGE: - { - mergeBaseImage(other.getBaseImage()); - break; - } - case PACKAGE: - { - mergePackage(other.getPackage()); - break; - } - case DEPLOYABLE: - { - mergeDeployable(other.getDeployable()); - break; - } - case DISCOVERY: - { - mergeDiscovery(other.getDiscovery()); - break; - } - case ATTESTATION_AUTHORITY: - { - mergeAttestationAuthority(other.getAttestationAuthority()); - break; - } - case TYPE_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.Note parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.Note) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int typeCase_ = 0; - private java.lang.Object type_; - - public TypeCase getTypeCase() { - return TypeCase.forNumber(typeCase_); - } - - public Builder clearType() { - typeCase_ = 0; - type_ = null; - onChanged(); - return this; - } - - private int bitField0_; - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Output only. The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * Output only. The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * Output only. The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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 java.lang.Object shortDescription_ = ""; - /** - * - * - *
-     * A one sentence description of this note.
-     * 
- * - * string short_description = 2; - */ - public java.lang.String getShortDescription() { - java.lang.Object ref = shortDescription_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - shortDescription_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * A one sentence description of this note.
-     * 
- * - * string short_description = 2; - */ - public com.google.protobuf.ByteString getShortDescriptionBytes() { - java.lang.Object ref = shortDescription_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - shortDescription_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * A one sentence description of this note.
-     * 
- * - * string short_description = 2; - */ - public Builder setShortDescription(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - shortDescription_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * A one sentence description of this note.
-     * 
- * - * string short_description = 2; - */ - public Builder clearShortDescription() { - - shortDescription_ = getDefaultInstance().getShortDescription(); - onChanged(); - return this; - } - /** - * - * - *
-     * A one sentence description of this note.
-     * 
- * - * string short_description = 2; - */ - public Builder setShortDescriptionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - shortDescription_ = value; - onChanged(); - return this; - } - - private java.lang.Object longDescription_ = ""; - /** - * - * - *
-     * A detailed description of this note.
-     * 
- * - * string long_description = 3; - */ - public java.lang.String getLongDescription() { - java.lang.Object ref = longDescription_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - longDescription_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * A detailed description of this note.
-     * 
- * - * string long_description = 3; - */ - public com.google.protobuf.ByteString getLongDescriptionBytes() { - java.lang.Object ref = longDescription_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - longDescription_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * A detailed description of this note.
-     * 
- * - * string long_description = 3; - */ - public Builder setLongDescription(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - longDescription_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * A detailed description of this note.
-     * 
- * - * string long_description = 3; - */ - public Builder clearLongDescription() { - - longDescription_ = getDefaultInstance().getLongDescription(); - onChanged(); - return this; - } - /** - * - * - *
-     * A detailed description of this note.
-     * 
- * - * string long_description = 3; - */ - public Builder setLongDescriptionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - longDescription_ = value; - onChanged(); - return this; - } - - private int kind_ = 0; - /** - * - * - *
-     * Output only. The type of analysis. This field can be used as a filter in
-     * list requests.
-     * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public int getKindValue() { - return kind_; - } - /** - * - * - *
-     * Output only. The type of analysis. This field can be used as a filter in
-     * list requests.
-     * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public Builder setKindValue(int value) { - kind_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The type of analysis. This field can be used as a filter in
-     * list requests.
-     * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public io.grafeas.v1beta1.common.NoteKind getKind() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.common.NoteKind result = io.grafeas.v1beta1.common.NoteKind.valueOf(kind_); - return result == null ? io.grafeas.v1beta1.common.NoteKind.UNRECOGNIZED : result; - } - /** - * - * - *
-     * Output only. The type of analysis. This field can be used as a filter in
-     * list requests.
-     * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public Builder setKind(io.grafeas.v1beta1.common.NoteKind value) { - if (value == null) { - throw new NullPointerException(); - } - - kind_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The type of analysis. This field can be used as a filter in
-     * list requests.
-     * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public Builder clearKind() { - - kind_ = 0; - onChanged(); - return this; - } - - private java.util.List relatedUrl_ = - java.util.Collections.emptyList(); - - private void ensureRelatedUrlIsMutable() { - if (!((bitField0_ & 0x00000010) != 0)) { - relatedUrl_ = new java.util.ArrayList(relatedUrl_); - bitField0_ |= 0x00000010; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.common.RelatedUrl, - io.grafeas.v1beta1.common.RelatedUrl.Builder, - io.grafeas.v1beta1.common.RelatedUrlOrBuilder> - relatedUrlBuilder_; - - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public java.util.List getRelatedUrlList() { - if (relatedUrlBuilder_ == null) { - return java.util.Collections.unmodifiableList(relatedUrl_); - } else { - return relatedUrlBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public int getRelatedUrlCount() { - if (relatedUrlBuilder_ == null) { - return relatedUrl_.size(); - } else { - return relatedUrlBuilder_.getCount(); - } - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public io.grafeas.v1beta1.common.RelatedUrl getRelatedUrl(int index) { - if (relatedUrlBuilder_ == null) { - return relatedUrl_.get(index); - } else { - return relatedUrlBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public Builder setRelatedUrl(int index, io.grafeas.v1beta1.common.RelatedUrl value) { - if (relatedUrlBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureRelatedUrlIsMutable(); - relatedUrl_.set(index, value); - onChanged(); - } else { - relatedUrlBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public Builder setRelatedUrl( - int index, io.grafeas.v1beta1.common.RelatedUrl.Builder builderForValue) { - if (relatedUrlBuilder_ == null) { - ensureRelatedUrlIsMutable(); - relatedUrl_.set(index, builderForValue.build()); - onChanged(); - } else { - relatedUrlBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public Builder addRelatedUrl(io.grafeas.v1beta1.common.RelatedUrl value) { - if (relatedUrlBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureRelatedUrlIsMutable(); - relatedUrl_.add(value); - onChanged(); - } else { - relatedUrlBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public Builder addRelatedUrl(int index, io.grafeas.v1beta1.common.RelatedUrl value) { - if (relatedUrlBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureRelatedUrlIsMutable(); - relatedUrl_.add(index, value); - onChanged(); - } else { - relatedUrlBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public Builder addRelatedUrl(io.grafeas.v1beta1.common.RelatedUrl.Builder builderForValue) { - if (relatedUrlBuilder_ == null) { - ensureRelatedUrlIsMutable(); - relatedUrl_.add(builderForValue.build()); - onChanged(); - } else { - relatedUrlBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public Builder addRelatedUrl( - int index, io.grafeas.v1beta1.common.RelatedUrl.Builder builderForValue) { - if (relatedUrlBuilder_ == null) { - ensureRelatedUrlIsMutable(); - relatedUrl_.add(index, builderForValue.build()); - onChanged(); - } else { - relatedUrlBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public Builder addAllRelatedUrl( - java.lang.Iterable values) { - if (relatedUrlBuilder_ == null) { - ensureRelatedUrlIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, relatedUrl_); - onChanged(); - } else { - relatedUrlBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public Builder clearRelatedUrl() { - if (relatedUrlBuilder_ == null) { - relatedUrl_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000010); - onChanged(); - } else { - relatedUrlBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public Builder removeRelatedUrl(int index) { - if (relatedUrlBuilder_ == null) { - ensureRelatedUrlIsMutable(); - relatedUrl_.remove(index); - onChanged(); - } else { - relatedUrlBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public io.grafeas.v1beta1.common.RelatedUrl.Builder getRelatedUrlBuilder(int index) { - return getRelatedUrlFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public io.grafeas.v1beta1.common.RelatedUrlOrBuilder getRelatedUrlOrBuilder(int index) { - if (relatedUrlBuilder_ == null) { - return relatedUrl_.get(index); - } else { - return relatedUrlBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public java.util.List - getRelatedUrlOrBuilderList() { - if (relatedUrlBuilder_ != null) { - return relatedUrlBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(relatedUrl_); - } - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public io.grafeas.v1beta1.common.RelatedUrl.Builder addRelatedUrlBuilder() { - return getRelatedUrlFieldBuilder() - .addBuilder(io.grafeas.v1beta1.common.RelatedUrl.getDefaultInstance()); - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public io.grafeas.v1beta1.common.RelatedUrl.Builder addRelatedUrlBuilder(int index) { - return getRelatedUrlFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.common.RelatedUrl.getDefaultInstance()); - } - /** - * - * - *
-     * URLs associated with this note.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - public java.util.List getRelatedUrlBuilderList() { - return getRelatedUrlFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.common.RelatedUrl, - io.grafeas.v1beta1.common.RelatedUrl.Builder, - io.grafeas.v1beta1.common.RelatedUrlOrBuilder> - getRelatedUrlFieldBuilder() { - if (relatedUrlBuilder_ == null) { - relatedUrlBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.common.RelatedUrl, - io.grafeas.v1beta1.common.RelatedUrl.Builder, - io.grafeas.v1beta1.common.RelatedUrlOrBuilder>( - relatedUrl_, ((bitField0_ & 0x00000010) != 0), getParentForChildren(), isClean()); - relatedUrl_ = null; - } - return relatedUrlBuilder_; - } - - private com.google.protobuf.Timestamp expirationTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - expirationTimeBuilder_; - /** - * - * - *
-     * Time of expiration for this note. Empty if note does not expire.
-     * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - public boolean hasExpirationTime() { - return expirationTimeBuilder_ != null || expirationTime_ != null; - } - /** - * - * - *
-     * Time of expiration for this note. Empty if note does not expire.
-     * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - public com.google.protobuf.Timestamp getExpirationTime() { - if (expirationTimeBuilder_ == null) { - return expirationTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : expirationTime_; - } else { - return expirationTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Time of expiration for this note. Empty if note does not expire.
-     * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - public Builder setExpirationTime(com.google.protobuf.Timestamp value) { - if (expirationTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - expirationTime_ = value; - onChanged(); - } else { - expirationTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Time of expiration for this note. Empty if note does not expire.
-     * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - public Builder setExpirationTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (expirationTimeBuilder_ == null) { - expirationTime_ = builderForValue.build(); - onChanged(); - } else { - expirationTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Time of expiration for this note. Empty if note does not expire.
-     * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - public Builder mergeExpirationTime(com.google.protobuf.Timestamp value) { - if (expirationTimeBuilder_ == null) { - if (expirationTime_ != null) { - expirationTime_ = - com.google.protobuf.Timestamp.newBuilder(expirationTime_) - .mergeFrom(value) - .buildPartial(); - } else { - expirationTime_ = value; - } - onChanged(); - } else { - expirationTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Time of expiration for this note. Empty if note does not expire.
-     * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - public Builder clearExpirationTime() { - if (expirationTimeBuilder_ == null) { - expirationTime_ = null; - onChanged(); - } else { - expirationTime_ = null; - expirationTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Time of expiration for this note. Empty if note does not expire.
-     * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - public com.google.protobuf.Timestamp.Builder getExpirationTimeBuilder() { - - onChanged(); - return getExpirationTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Time of expiration for this note. Empty if note does not expire.
-     * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - public com.google.protobuf.TimestampOrBuilder getExpirationTimeOrBuilder() { - if (expirationTimeBuilder_ != null) { - return expirationTimeBuilder_.getMessageOrBuilder(); - } else { - return expirationTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : expirationTime_; - } - } - /** - * - * - *
-     * Time of expiration for this note. Empty if note does not expire.
-     * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getExpirationTimeFieldBuilder() { - if (expirationTimeBuilder_ == null) { - expirationTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getExpirationTime(), getParentForChildren(), isClean()); - expirationTime_ = null; - } - return expirationTimeBuilder_; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-     * Output only. The time this note was created. This field can be used as a
-     * filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-     * Output only. The time this note was created. This field can be used as a
-     * filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. The time this note was created. This field can be used as a
-     * filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - 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; - } - /** - * - * - *
-     * Output only. The time this note was created. This field can be used as a
-     * filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. The time this note was created. This field can be used as a
-     * filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - 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; - } - /** - * - * - *
-     * Output only. The time this note was created. This field can be used as a
-     * filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. The time this note was created. This field can be used as a
-     * filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. The time this note was created. This field can be used as a
-     * filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-     * Output only. The time this note was created. This field can be used as a
-     * filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - 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_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - updateTimeBuilder_; - /** - * - * - *
-     * Output only. The time this note was last updated. This field can be used as
-     * a filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - public boolean hasUpdateTime() { - return updateTimeBuilder_ != null || updateTime_ != null; - } - /** - * - * - *
-     * Output only. The time this note was last updated. This field can be used as
-     * a filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - public com.google.protobuf.Timestamp getUpdateTime() { - if (updateTimeBuilder_ == null) { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } else { - return updateTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. The time this note was last updated. This field can be used as
-     * a filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - 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; - } - /** - * - * - *
-     * Output only. The time this note was last updated. This field can be used as
-     * a filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (updateTimeBuilder_ == null) { - updateTime_ = builderForValue.build(); - onChanged(); - } else { - updateTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. The time this note was last updated. This field can be used as
-     * a filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - 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; - } - /** - * - * - *
-     * Output only. The time this note was last updated. This field can be used as
-     * a filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - public Builder clearUpdateTime() { - if (updateTimeBuilder_ == null) { - updateTime_ = null; - onChanged(); - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. The time this note was last updated. This field can be used as
-     * a filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - - onChanged(); - return getUpdateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. The time this note was last updated. This field can be used as
-     * a filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - if (updateTimeBuilder_ != null) { - return updateTimeBuilder_.getMessageOrBuilder(); - } else { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } - } - /** - * - * - *
-     * Output only. The time this note was last updated. This field can be used as
-     * a filter in list requests.
-     * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - 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_; - } - - private com.google.protobuf.LazyStringList relatedNoteNames_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureRelatedNoteNamesIsMutable() { - if (!((bitField0_ & 0x00000100) != 0)) { - relatedNoteNames_ = new com.google.protobuf.LazyStringArrayList(relatedNoteNames_); - bitField0_ |= 0x00000100; - } - } - /** - * - * - *
-     * Other notes related to this note.
-     * 
- * - * repeated string related_note_names = 9; - */ - public com.google.protobuf.ProtocolStringList getRelatedNoteNamesList() { - return relatedNoteNames_.getUnmodifiableView(); - } - /** - * - * - *
-     * Other notes related to this note.
-     * 
- * - * repeated string related_note_names = 9; - */ - public int getRelatedNoteNamesCount() { - return relatedNoteNames_.size(); - } - /** - * - * - *
-     * Other notes related to this note.
-     * 
- * - * repeated string related_note_names = 9; - */ - public java.lang.String getRelatedNoteNames(int index) { - return relatedNoteNames_.get(index); - } - /** - * - * - *
-     * Other notes related to this note.
-     * 
- * - * repeated string related_note_names = 9; - */ - public com.google.protobuf.ByteString getRelatedNoteNamesBytes(int index) { - return relatedNoteNames_.getByteString(index); - } - /** - * - * - *
-     * Other notes related to this note.
-     * 
- * - * repeated string related_note_names = 9; - */ - public Builder setRelatedNoteNames(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureRelatedNoteNamesIsMutable(); - relatedNoteNames_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * Other notes related to this note.
-     * 
- * - * repeated string related_note_names = 9; - */ - public Builder addRelatedNoteNames(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureRelatedNoteNamesIsMutable(); - relatedNoteNames_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * Other notes related to this note.
-     * 
- * - * repeated string related_note_names = 9; - */ - public Builder addAllRelatedNoteNames(java.lang.Iterable values) { - ensureRelatedNoteNamesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, relatedNoteNames_); - onChanged(); - return this; - } - /** - * - * - *
-     * Other notes related to this note.
-     * 
- * - * repeated string related_note_names = 9; - */ - public Builder clearRelatedNoteNames() { - relatedNoteNames_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000100); - onChanged(); - return this; - } - /** - * - * - *
-     * Other notes related to this note.
-     * 
- * - * repeated string related_note_names = 9; - */ - public Builder addRelatedNoteNamesBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureRelatedNoteNamesIsMutable(); - relatedNoteNames_.add(value); - onChanged(); - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.Vulnerability, - io.grafeas.v1beta1.vulnerability.Vulnerability.Builder, - io.grafeas.v1beta1.vulnerability.VulnerabilityOrBuilder> - vulnerabilityBuilder_; - /** - * - * - *
-     * A note describing a package vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - public boolean hasVulnerability() { - return typeCase_ == 10; - } - /** - * - * - *
-     * A note describing a package vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - public io.grafeas.v1beta1.vulnerability.Vulnerability getVulnerability() { - if (vulnerabilityBuilder_ == null) { - if (typeCase_ == 10) { - return (io.grafeas.v1beta1.vulnerability.Vulnerability) type_; - } - return io.grafeas.v1beta1.vulnerability.Vulnerability.getDefaultInstance(); - } else { - if (typeCase_ == 10) { - return vulnerabilityBuilder_.getMessage(); - } - return io.grafeas.v1beta1.vulnerability.Vulnerability.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing a package vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - public Builder setVulnerability(io.grafeas.v1beta1.vulnerability.Vulnerability value) { - if (vulnerabilityBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - vulnerabilityBuilder_.setMessage(value); - } - typeCase_ = 10; - return this; - } - /** - * - * - *
-     * A note describing a package vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - public Builder setVulnerability( - io.grafeas.v1beta1.vulnerability.Vulnerability.Builder builderForValue) { - if (vulnerabilityBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - vulnerabilityBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 10; - return this; - } - /** - * - * - *
-     * A note describing a package vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - public Builder mergeVulnerability(io.grafeas.v1beta1.vulnerability.Vulnerability value) { - if (vulnerabilityBuilder_ == null) { - if (typeCase_ == 10 - && type_ != io.grafeas.v1beta1.vulnerability.Vulnerability.getDefaultInstance()) { - type_ = - io.grafeas.v1beta1.vulnerability.Vulnerability.newBuilder( - (io.grafeas.v1beta1.vulnerability.Vulnerability) type_) - .mergeFrom(value) - .buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 10) { - vulnerabilityBuilder_.mergeFrom(value); - } - vulnerabilityBuilder_.setMessage(value); - } - typeCase_ = 10; - return this; - } - /** - * - * - *
-     * A note describing a package vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - public Builder clearVulnerability() { - if (vulnerabilityBuilder_ == null) { - if (typeCase_ == 10) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 10) { - typeCase_ = 0; - type_ = null; - } - vulnerabilityBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A note describing a package vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - public io.grafeas.v1beta1.vulnerability.Vulnerability.Builder getVulnerabilityBuilder() { - return getVulnerabilityFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A note describing a package vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityOrBuilder getVulnerabilityOrBuilder() { - if ((typeCase_ == 10) && (vulnerabilityBuilder_ != null)) { - return vulnerabilityBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 10) { - return (io.grafeas.v1beta1.vulnerability.Vulnerability) type_; - } - return io.grafeas.v1beta1.vulnerability.Vulnerability.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing a package vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.Vulnerability, - io.grafeas.v1beta1.vulnerability.Vulnerability.Builder, - io.grafeas.v1beta1.vulnerability.VulnerabilityOrBuilder> - getVulnerabilityFieldBuilder() { - if (vulnerabilityBuilder_ == null) { - if (!(typeCase_ == 10)) { - type_ = io.grafeas.v1beta1.vulnerability.Vulnerability.getDefaultInstance(); - } - vulnerabilityBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.Vulnerability, - io.grafeas.v1beta1.vulnerability.Vulnerability.Builder, - io.grafeas.v1beta1.vulnerability.VulnerabilityOrBuilder>( - (io.grafeas.v1beta1.vulnerability.Vulnerability) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 10; - onChanged(); - ; - return vulnerabilityBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.build.Build, - io.grafeas.v1beta1.build.Build.Builder, - io.grafeas.v1beta1.build.BuildOrBuilder> - buildBuilder_; - /** - * - * - *
-     * A note describing build provenance for a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - public boolean hasBuild() { - return typeCase_ == 11; - } - /** - * - * - *
-     * A note describing build provenance for a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - public io.grafeas.v1beta1.build.Build getBuild() { - if (buildBuilder_ == null) { - if (typeCase_ == 11) { - return (io.grafeas.v1beta1.build.Build) type_; - } - return io.grafeas.v1beta1.build.Build.getDefaultInstance(); - } else { - if (typeCase_ == 11) { - return buildBuilder_.getMessage(); - } - return io.grafeas.v1beta1.build.Build.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing build provenance for a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - public Builder setBuild(io.grafeas.v1beta1.build.Build value) { - if (buildBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - buildBuilder_.setMessage(value); - } - typeCase_ = 11; - return this; - } - /** - * - * - *
-     * A note describing build provenance for a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - public Builder setBuild(io.grafeas.v1beta1.build.Build.Builder builderForValue) { - if (buildBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - buildBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 11; - return this; - } - /** - * - * - *
-     * A note describing build provenance for a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - public Builder mergeBuild(io.grafeas.v1beta1.build.Build value) { - if (buildBuilder_ == null) { - if (typeCase_ == 11 && type_ != io.grafeas.v1beta1.build.Build.getDefaultInstance()) { - type_ = - io.grafeas.v1beta1.build.Build.newBuilder((io.grafeas.v1beta1.build.Build) type_) - .mergeFrom(value) - .buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 11) { - buildBuilder_.mergeFrom(value); - } - buildBuilder_.setMessage(value); - } - typeCase_ = 11; - return this; - } - /** - * - * - *
-     * A note describing build provenance for a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - public Builder clearBuild() { - if (buildBuilder_ == null) { - if (typeCase_ == 11) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 11) { - typeCase_ = 0; - type_ = null; - } - buildBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A note describing build provenance for a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - public io.grafeas.v1beta1.build.Build.Builder getBuildBuilder() { - return getBuildFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A note describing build provenance for a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - public io.grafeas.v1beta1.build.BuildOrBuilder getBuildOrBuilder() { - if ((typeCase_ == 11) && (buildBuilder_ != null)) { - return buildBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 11) { - return (io.grafeas.v1beta1.build.Build) type_; - } - return io.grafeas.v1beta1.build.Build.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing build provenance for a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.build.Build, - io.grafeas.v1beta1.build.Build.Builder, - io.grafeas.v1beta1.build.BuildOrBuilder> - getBuildFieldBuilder() { - if (buildBuilder_ == null) { - if (!(typeCase_ == 11)) { - type_ = io.grafeas.v1beta1.build.Build.getDefaultInstance(); - } - buildBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.build.Build, - io.grafeas.v1beta1.build.Build.Builder, - io.grafeas.v1beta1.build.BuildOrBuilder>( - (io.grafeas.v1beta1.build.Build) type_, getParentForChildren(), isClean()); - type_ = null; - } - typeCase_ = 11; - onChanged(); - ; - return buildBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Basis, - io.grafeas.v1beta1.image.Basis.Builder, - io.grafeas.v1beta1.image.BasisOrBuilder> - baseImageBuilder_; - /** - * - * - *
-     * A note describing a base image.
-     * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - public boolean hasBaseImage() { - return typeCase_ == 12; - } - /** - * - * - *
-     * A note describing a base image.
-     * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - public io.grafeas.v1beta1.image.Basis getBaseImage() { - if (baseImageBuilder_ == null) { - if (typeCase_ == 12) { - return (io.grafeas.v1beta1.image.Basis) type_; - } - return io.grafeas.v1beta1.image.Basis.getDefaultInstance(); - } else { - if (typeCase_ == 12) { - return baseImageBuilder_.getMessage(); - } - return io.grafeas.v1beta1.image.Basis.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing a base image.
-     * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - public Builder setBaseImage(io.grafeas.v1beta1.image.Basis value) { - if (baseImageBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - baseImageBuilder_.setMessage(value); - } - typeCase_ = 12; - return this; - } - /** - * - * - *
-     * A note describing a base image.
-     * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - public Builder setBaseImage(io.grafeas.v1beta1.image.Basis.Builder builderForValue) { - if (baseImageBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - baseImageBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 12; - return this; - } - /** - * - * - *
-     * A note describing a base image.
-     * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - public Builder mergeBaseImage(io.grafeas.v1beta1.image.Basis value) { - if (baseImageBuilder_ == null) { - if (typeCase_ == 12 && type_ != io.grafeas.v1beta1.image.Basis.getDefaultInstance()) { - type_ = - io.grafeas.v1beta1.image.Basis.newBuilder((io.grafeas.v1beta1.image.Basis) type_) - .mergeFrom(value) - .buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 12) { - baseImageBuilder_.mergeFrom(value); - } - baseImageBuilder_.setMessage(value); - } - typeCase_ = 12; - return this; - } - /** - * - * - *
-     * A note describing a base image.
-     * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - public Builder clearBaseImage() { - if (baseImageBuilder_ == null) { - if (typeCase_ == 12) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 12) { - typeCase_ = 0; - type_ = null; - } - baseImageBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A note describing a base image.
-     * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - public io.grafeas.v1beta1.image.Basis.Builder getBaseImageBuilder() { - return getBaseImageFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A note describing a base image.
-     * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - public io.grafeas.v1beta1.image.BasisOrBuilder getBaseImageOrBuilder() { - if ((typeCase_ == 12) && (baseImageBuilder_ != null)) { - return baseImageBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 12) { - return (io.grafeas.v1beta1.image.Basis) type_; - } - return io.grafeas.v1beta1.image.Basis.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing a base image.
-     * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Basis, - io.grafeas.v1beta1.image.Basis.Builder, - io.grafeas.v1beta1.image.BasisOrBuilder> - getBaseImageFieldBuilder() { - if (baseImageBuilder_ == null) { - if (!(typeCase_ == 12)) { - type_ = io.grafeas.v1beta1.image.Basis.getDefaultInstance(); - } - baseImageBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Basis, - io.grafeas.v1beta1.image.Basis.Builder, - io.grafeas.v1beta1.image.BasisOrBuilder>( - (io.grafeas.v1beta1.image.Basis) type_, getParentForChildren(), isClean()); - type_ = null; - } - typeCase_ = 12; - onChanged(); - ; - return baseImageBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Package, - io.grafeas.v1beta1.pkg.Package.Builder, - io.grafeas.v1beta1.pkg.PackageOrBuilder> - packageBuilder_; - /** - * - * - *
-     * A note describing a package hosted by various package managers.
-     * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - public boolean hasPackage() { - return typeCase_ == 13; - } - /** - * - * - *
-     * A note describing a package hosted by various package managers.
-     * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - public io.grafeas.v1beta1.pkg.Package getPackage() { - if (packageBuilder_ == null) { - if (typeCase_ == 13) { - return (io.grafeas.v1beta1.pkg.Package) type_; - } - return io.grafeas.v1beta1.pkg.Package.getDefaultInstance(); - } else { - if (typeCase_ == 13) { - return packageBuilder_.getMessage(); - } - return io.grafeas.v1beta1.pkg.Package.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing a package hosted by various package managers.
-     * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - public Builder setPackage(io.grafeas.v1beta1.pkg.Package value) { - if (packageBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - packageBuilder_.setMessage(value); - } - typeCase_ = 13; - return this; - } - /** - * - * - *
-     * A note describing a package hosted by various package managers.
-     * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - public Builder setPackage(io.grafeas.v1beta1.pkg.Package.Builder builderForValue) { - if (packageBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - packageBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 13; - return this; - } - /** - * - * - *
-     * A note describing a package hosted by various package managers.
-     * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - public Builder mergePackage(io.grafeas.v1beta1.pkg.Package value) { - if (packageBuilder_ == null) { - if (typeCase_ == 13 && type_ != io.grafeas.v1beta1.pkg.Package.getDefaultInstance()) { - type_ = - io.grafeas.v1beta1.pkg.Package.newBuilder((io.grafeas.v1beta1.pkg.Package) type_) - .mergeFrom(value) - .buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 13) { - packageBuilder_.mergeFrom(value); - } - packageBuilder_.setMessage(value); - } - typeCase_ = 13; - return this; - } - /** - * - * - *
-     * A note describing a package hosted by various package managers.
-     * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - public Builder clearPackage() { - if (packageBuilder_ == null) { - if (typeCase_ == 13) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 13) { - typeCase_ = 0; - type_ = null; - } - packageBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A note describing a package hosted by various package managers.
-     * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - public io.grafeas.v1beta1.pkg.Package.Builder getPackageBuilder() { - return getPackageFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A note describing a package hosted by various package managers.
-     * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - public io.grafeas.v1beta1.pkg.PackageOrBuilder getPackageOrBuilder() { - if ((typeCase_ == 13) && (packageBuilder_ != null)) { - return packageBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 13) { - return (io.grafeas.v1beta1.pkg.Package) type_; - } - return io.grafeas.v1beta1.pkg.Package.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing a package hosted by various package managers.
-     * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Package, - io.grafeas.v1beta1.pkg.Package.Builder, - io.grafeas.v1beta1.pkg.PackageOrBuilder> - getPackageFieldBuilder() { - if (packageBuilder_ == null) { - if (!(typeCase_ == 13)) { - type_ = io.grafeas.v1beta1.pkg.Package.getDefaultInstance(); - } - packageBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Package, - io.grafeas.v1beta1.pkg.Package.Builder, - io.grafeas.v1beta1.pkg.PackageOrBuilder>( - (io.grafeas.v1beta1.pkg.Package) type_, getParentForChildren(), isClean()); - type_ = null; - } - typeCase_ = 13; - onChanged(); - ; - return packageBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.deployment.Deployable, - io.grafeas.v1beta1.deployment.Deployable.Builder, - io.grafeas.v1beta1.deployment.DeployableOrBuilder> - deployableBuilder_; - /** - * - * - *
-     * A note describing something that can be deployed.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - public boolean hasDeployable() { - return typeCase_ == 14; - } - /** - * - * - *
-     * A note describing something that can be deployed.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - public io.grafeas.v1beta1.deployment.Deployable getDeployable() { - if (deployableBuilder_ == null) { - if (typeCase_ == 14) { - return (io.grafeas.v1beta1.deployment.Deployable) type_; - } - return io.grafeas.v1beta1.deployment.Deployable.getDefaultInstance(); - } else { - if (typeCase_ == 14) { - return deployableBuilder_.getMessage(); - } - return io.grafeas.v1beta1.deployment.Deployable.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing something that can be deployed.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - public Builder setDeployable(io.grafeas.v1beta1.deployment.Deployable value) { - if (deployableBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - deployableBuilder_.setMessage(value); - } - typeCase_ = 14; - return this; - } - /** - * - * - *
-     * A note describing something that can be deployed.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - public Builder setDeployable(io.grafeas.v1beta1.deployment.Deployable.Builder builderForValue) { - if (deployableBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - deployableBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 14; - return this; - } - /** - * - * - *
-     * A note describing something that can be deployed.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - public Builder mergeDeployable(io.grafeas.v1beta1.deployment.Deployable value) { - if (deployableBuilder_ == null) { - if (typeCase_ == 14 - && type_ != io.grafeas.v1beta1.deployment.Deployable.getDefaultInstance()) { - type_ = - io.grafeas.v1beta1.deployment.Deployable.newBuilder( - (io.grafeas.v1beta1.deployment.Deployable) type_) - .mergeFrom(value) - .buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 14) { - deployableBuilder_.mergeFrom(value); - } - deployableBuilder_.setMessage(value); - } - typeCase_ = 14; - return this; - } - /** - * - * - *
-     * A note describing something that can be deployed.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - public Builder clearDeployable() { - if (deployableBuilder_ == null) { - if (typeCase_ == 14) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 14) { - typeCase_ = 0; - type_ = null; - } - deployableBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A note describing something that can be deployed.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - public io.grafeas.v1beta1.deployment.Deployable.Builder getDeployableBuilder() { - return getDeployableFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A note describing something that can be deployed.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - public io.grafeas.v1beta1.deployment.DeployableOrBuilder getDeployableOrBuilder() { - if ((typeCase_ == 14) && (deployableBuilder_ != null)) { - return deployableBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 14) { - return (io.grafeas.v1beta1.deployment.Deployable) type_; - } - return io.grafeas.v1beta1.deployment.Deployable.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing something that can be deployed.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.deployment.Deployable, - io.grafeas.v1beta1.deployment.Deployable.Builder, - io.grafeas.v1beta1.deployment.DeployableOrBuilder> - getDeployableFieldBuilder() { - if (deployableBuilder_ == null) { - if (!(typeCase_ == 14)) { - type_ = io.grafeas.v1beta1.deployment.Deployable.getDefaultInstance(); - } - deployableBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.deployment.Deployable, - io.grafeas.v1beta1.deployment.Deployable.Builder, - io.grafeas.v1beta1.deployment.DeployableOrBuilder>( - (io.grafeas.v1beta1.deployment.Deployable) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 14; - onChanged(); - ; - return deployableBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.discovery.Discovery, - io.grafeas.v1beta1.discovery.Discovery.Builder, - io.grafeas.v1beta1.discovery.DiscoveryOrBuilder> - discoveryBuilder_; - /** - * - * - *
-     * A note describing the initial analysis of a resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - public boolean hasDiscovery() { - return typeCase_ == 15; - } - /** - * - * - *
-     * A note describing the initial analysis of a resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - public io.grafeas.v1beta1.discovery.Discovery getDiscovery() { - if (discoveryBuilder_ == null) { - if (typeCase_ == 15) { - return (io.grafeas.v1beta1.discovery.Discovery) type_; - } - return io.grafeas.v1beta1.discovery.Discovery.getDefaultInstance(); - } else { - if (typeCase_ == 15) { - return discoveryBuilder_.getMessage(); - } - return io.grafeas.v1beta1.discovery.Discovery.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing the initial analysis of a resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - public Builder setDiscovery(io.grafeas.v1beta1.discovery.Discovery value) { - if (discoveryBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - discoveryBuilder_.setMessage(value); - } - typeCase_ = 15; - return this; - } - /** - * - * - *
-     * A note describing the initial analysis of a resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - public Builder setDiscovery(io.grafeas.v1beta1.discovery.Discovery.Builder builderForValue) { - if (discoveryBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - discoveryBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 15; - return this; - } - /** - * - * - *
-     * A note describing the initial analysis of a resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - public Builder mergeDiscovery(io.grafeas.v1beta1.discovery.Discovery value) { - if (discoveryBuilder_ == null) { - if (typeCase_ == 15 - && type_ != io.grafeas.v1beta1.discovery.Discovery.getDefaultInstance()) { - type_ = - io.grafeas.v1beta1.discovery.Discovery.newBuilder( - (io.grafeas.v1beta1.discovery.Discovery) type_) - .mergeFrom(value) - .buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 15) { - discoveryBuilder_.mergeFrom(value); - } - discoveryBuilder_.setMessage(value); - } - typeCase_ = 15; - return this; - } - /** - * - * - *
-     * A note describing the initial analysis of a resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - public Builder clearDiscovery() { - if (discoveryBuilder_ == null) { - if (typeCase_ == 15) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 15) { - typeCase_ = 0; - type_ = null; - } - discoveryBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A note describing the initial analysis of a resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - public io.grafeas.v1beta1.discovery.Discovery.Builder getDiscoveryBuilder() { - return getDiscoveryFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A note describing the initial analysis of a resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - public io.grafeas.v1beta1.discovery.DiscoveryOrBuilder getDiscoveryOrBuilder() { - if ((typeCase_ == 15) && (discoveryBuilder_ != null)) { - return discoveryBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 15) { - return (io.grafeas.v1beta1.discovery.Discovery) type_; - } - return io.grafeas.v1beta1.discovery.Discovery.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing the initial analysis of a resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.discovery.Discovery, - io.grafeas.v1beta1.discovery.Discovery.Builder, - io.grafeas.v1beta1.discovery.DiscoveryOrBuilder> - getDiscoveryFieldBuilder() { - if (discoveryBuilder_ == null) { - if (!(typeCase_ == 15)) { - type_ = io.grafeas.v1beta1.discovery.Discovery.getDefaultInstance(); - } - discoveryBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.discovery.Discovery, - io.grafeas.v1beta1.discovery.Discovery.Builder, - io.grafeas.v1beta1.discovery.DiscoveryOrBuilder>( - (io.grafeas.v1beta1.discovery.Discovery) type_, getParentForChildren(), isClean()); - type_ = null; - } - typeCase_ = 15; - onChanged(); - ; - return discoveryBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.Authority, - io.grafeas.v1beta1.attestation.Authority.Builder, - io.grafeas.v1beta1.attestation.AuthorityOrBuilder> - attestationAuthorityBuilder_; - /** - * - * - *
-     * A note describing an attestation role.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - public boolean hasAttestationAuthority() { - return typeCase_ == 16; - } - /** - * - * - *
-     * A note describing an attestation role.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - public io.grafeas.v1beta1.attestation.Authority getAttestationAuthority() { - if (attestationAuthorityBuilder_ == null) { - if (typeCase_ == 16) { - return (io.grafeas.v1beta1.attestation.Authority) type_; - } - return io.grafeas.v1beta1.attestation.Authority.getDefaultInstance(); - } else { - if (typeCase_ == 16) { - return attestationAuthorityBuilder_.getMessage(); - } - return io.grafeas.v1beta1.attestation.Authority.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing an attestation role.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - public Builder setAttestationAuthority(io.grafeas.v1beta1.attestation.Authority value) { - if (attestationAuthorityBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - attestationAuthorityBuilder_.setMessage(value); - } - typeCase_ = 16; - return this; - } - /** - * - * - *
-     * A note describing an attestation role.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - public Builder setAttestationAuthority( - io.grafeas.v1beta1.attestation.Authority.Builder builderForValue) { - if (attestationAuthorityBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - attestationAuthorityBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 16; - return this; - } - /** - * - * - *
-     * A note describing an attestation role.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - public Builder mergeAttestationAuthority(io.grafeas.v1beta1.attestation.Authority value) { - if (attestationAuthorityBuilder_ == null) { - if (typeCase_ == 16 - && type_ != io.grafeas.v1beta1.attestation.Authority.getDefaultInstance()) { - type_ = - io.grafeas.v1beta1.attestation.Authority.newBuilder( - (io.grafeas.v1beta1.attestation.Authority) type_) - .mergeFrom(value) - .buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 16) { - attestationAuthorityBuilder_.mergeFrom(value); - } - attestationAuthorityBuilder_.setMessage(value); - } - typeCase_ = 16; - return this; - } - /** - * - * - *
-     * A note describing an attestation role.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - public Builder clearAttestationAuthority() { - if (attestationAuthorityBuilder_ == null) { - if (typeCase_ == 16) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 16) { - typeCase_ = 0; - type_ = null; - } - attestationAuthorityBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A note describing an attestation role.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - public io.grafeas.v1beta1.attestation.Authority.Builder getAttestationAuthorityBuilder() { - return getAttestationAuthorityFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A note describing an attestation role.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - public io.grafeas.v1beta1.attestation.AuthorityOrBuilder getAttestationAuthorityOrBuilder() { - if ((typeCase_ == 16) && (attestationAuthorityBuilder_ != null)) { - return attestationAuthorityBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 16) { - return (io.grafeas.v1beta1.attestation.Authority) type_; - } - return io.grafeas.v1beta1.attestation.Authority.getDefaultInstance(); - } - } - /** - * - * - *
-     * A note describing an attestation role.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.Authority, - io.grafeas.v1beta1.attestation.Authority.Builder, - io.grafeas.v1beta1.attestation.AuthorityOrBuilder> - getAttestationAuthorityFieldBuilder() { - if (attestationAuthorityBuilder_ == null) { - if (!(typeCase_ == 16)) { - type_ = io.grafeas.v1beta1.attestation.Authority.getDefaultInstance(); - } - attestationAuthorityBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.Authority, - io.grafeas.v1beta1.attestation.Authority.Builder, - io.grafeas.v1beta1.attestation.AuthorityOrBuilder>( - (io.grafeas.v1beta1.attestation.Authority) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 16; - onChanged(); - ; - return attestationAuthorityBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.Note) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.Note) - private static final io.grafeas.v1beta1.Note DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.Note(); - } - - public static io.grafeas.v1beta1.Note getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Note parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Note(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.Note getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/NoteName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/NoteName.java deleted file mode 100644 index 440e7ce4..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/NoteName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class NoteName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/notes/{note}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/NoteOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/NoteOrBuilder.java deleted file mode 100644 index 9bd9e520..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/NoteOrBuilder.java +++ /dev/null @@ -1,509 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface NoteOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.Note) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Output only. The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * Output only. The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * A one sentence description of this note.
-   * 
- * - * string short_description = 2; - */ - java.lang.String getShortDescription(); - /** - * - * - *
-   * A one sentence description of this note.
-   * 
- * - * string short_description = 2; - */ - com.google.protobuf.ByteString getShortDescriptionBytes(); - - /** - * - * - *
-   * A detailed description of this note.
-   * 
- * - * string long_description = 3; - */ - java.lang.String getLongDescription(); - /** - * - * - *
-   * A detailed description of this note.
-   * 
- * - * string long_description = 3; - */ - com.google.protobuf.ByteString getLongDescriptionBytes(); - - /** - * - * - *
-   * Output only. The type of analysis. This field can be used as a filter in
-   * list requests.
-   * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - int getKindValue(); - /** - * - * - *
-   * Output only. The type of analysis. This field can be used as a filter in
-   * list requests.
-   * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - io.grafeas.v1beta1.common.NoteKind getKind(); - - /** - * - * - *
-   * URLs associated with this note.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - java.util.List getRelatedUrlList(); - /** - * - * - *
-   * URLs associated with this note.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - io.grafeas.v1beta1.common.RelatedUrl getRelatedUrl(int index); - /** - * - * - *
-   * URLs associated with this note.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - int getRelatedUrlCount(); - /** - * - * - *
-   * URLs associated with this note.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - java.util.List - getRelatedUrlOrBuilderList(); - /** - * - * - *
-   * URLs associated with this note.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_url = 5; - */ - io.grafeas.v1beta1.common.RelatedUrlOrBuilder getRelatedUrlOrBuilder(int index); - - /** - * - * - *
-   * Time of expiration for this note. Empty if note does not expire.
-   * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - boolean hasExpirationTime(); - /** - * - * - *
-   * Time of expiration for this note. Empty if note does not expire.
-   * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - com.google.protobuf.Timestamp getExpirationTime(); - /** - * - * - *
-   * Time of expiration for this note. Empty if note does not expire.
-   * 
- * - * .google.protobuf.Timestamp expiration_time = 6; - */ - com.google.protobuf.TimestampOrBuilder getExpirationTimeOrBuilder(); - - /** - * - * - *
-   * Output only. The time this note was created. This field can be used as a
-   * filter in list requests.
-   * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - boolean hasCreateTime(); - /** - * - * - *
-   * Output only. The time this note was created. This field can be used as a
-   * filter in list requests.
-   * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-   * Output only. The time this note was created. This field can be used as a
-   * filter in list requests.
-   * 
- * - * .google.protobuf.Timestamp create_time = 7; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-   * Output only. The time this note was last updated. This field can be used as
-   * a filter in list requests.
-   * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - boolean hasUpdateTime(); - /** - * - * - *
-   * Output only. The time this note was last updated. This field can be used as
-   * a filter in list requests.
-   * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - com.google.protobuf.Timestamp getUpdateTime(); - /** - * - * - *
-   * Output only. The time this note was last updated. This field can be used as
-   * a filter in list requests.
-   * 
- * - * .google.protobuf.Timestamp update_time = 8; - */ - com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); - - /** - * - * - *
-   * Other notes related to this note.
-   * 
- * - * repeated string related_note_names = 9; - */ - java.util.List getRelatedNoteNamesList(); - /** - * - * - *
-   * Other notes related to this note.
-   * 
- * - * repeated string related_note_names = 9; - */ - int getRelatedNoteNamesCount(); - /** - * - * - *
-   * Other notes related to this note.
-   * 
- * - * repeated string related_note_names = 9; - */ - java.lang.String getRelatedNoteNames(int index); - /** - * - * - *
-   * Other notes related to this note.
-   * 
- * - * repeated string related_note_names = 9; - */ - com.google.protobuf.ByteString getRelatedNoteNamesBytes(int index); - - /** - * - * - *
-   * A note describing a package vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - boolean hasVulnerability(); - /** - * - * - *
-   * A note describing a package vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - io.grafeas.v1beta1.vulnerability.Vulnerability getVulnerability(); - /** - * - * - *
-   * A note describing a package vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - */ - io.grafeas.v1beta1.vulnerability.VulnerabilityOrBuilder getVulnerabilityOrBuilder(); - - /** - * - * - *
-   * A note describing build provenance for a verifiable build.
-   * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - boolean hasBuild(); - /** - * - * - *
-   * A note describing build provenance for a verifiable build.
-   * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - io.grafeas.v1beta1.build.Build getBuild(); - /** - * - * - *
-   * A note describing build provenance for a verifiable build.
-   * 
- * - * .grafeas.v1beta1.build.Build build = 11; - */ - io.grafeas.v1beta1.build.BuildOrBuilder getBuildOrBuilder(); - - /** - * - * - *
-   * A note describing a base image.
-   * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - boolean hasBaseImage(); - /** - * - * - *
-   * A note describing a base image.
-   * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - io.grafeas.v1beta1.image.Basis getBaseImage(); - /** - * - * - *
-   * A note describing a base image.
-   * 
- * - * .grafeas.v1beta1.image.Basis base_image = 12; - */ - io.grafeas.v1beta1.image.BasisOrBuilder getBaseImageOrBuilder(); - - /** - * - * - *
-   * A note describing a package hosted by various package managers.
-   * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - boolean hasPackage(); - /** - * - * - *
-   * A note describing a package hosted by various package managers.
-   * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - io.grafeas.v1beta1.pkg.Package getPackage(); - /** - * - * - *
-   * A note describing a package hosted by various package managers.
-   * 
- * - * .grafeas.v1beta1.package.Package package = 13; - */ - io.grafeas.v1beta1.pkg.PackageOrBuilder getPackageOrBuilder(); - - /** - * - * - *
-   * A note describing something that can be deployed.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - boolean hasDeployable(); - /** - * - * - *
-   * A note describing something that can be deployed.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - io.grafeas.v1beta1.deployment.Deployable getDeployable(); - /** - * - * - *
-   * A note describing something that can be deployed.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployable deployable = 14; - */ - io.grafeas.v1beta1.deployment.DeployableOrBuilder getDeployableOrBuilder(); - - /** - * - * - *
-   * A note describing the initial analysis of a resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - boolean hasDiscovery(); - /** - * - * - *
-   * A note describing the initial analysis of a resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - io.grafeas.v1beta1.discovery.Discovery getDiscovery(); - /** - * - * - *
-   * A note describing the initial analysis of a resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovery discovery = 15; - */ - io.grafeas.v1beta1.discovery.DiscoveryOrBuilder getDiscoveryOrBuilder(); - - /** - * - * - *
-   * A note describing an attestation role.
-   * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - boolean hasAttestationAuthority(); - /** - * - * - *
-   * A note describing an attestation role.
-   * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - io.grafeas.v1beta1.attestation.Authority getAttestationAuthority(); - /** - * - * - *
-   * A note describing an attestation role.
-   * 
- * - * .grafeas.v1beta1.attestation.Authority attestation_authority = 16; - */ - io.grafeas.v1beta1.attestation.AuthorityOrBuilder getAttestationAuthorityOrBuilder(); - - public io.grafeas.v1beta1.Note.TypeCase getTypeCase(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Occurrence.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Occurrence.java deleted file mode 100644 index 69216d56..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Occurrence.java +++ /dev/null @@ -1,3946 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * An instance of an analysis type that has been found on a resource.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.Occurrence} - */ -public final class Occurrence extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.Occurrence) - OccurrenceOrBuilder { - private static final long serialVersionUID = 0L; - // Use Occurrence.newBuilder() to construct. - private Occurrence(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Occurrence() { - name_ = ""; - noteName_ = ""; - kind_ = 0; - remediation_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Occurrence( - 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: - { - io.grafeas.v1beta1.Resource.Builder subBuilder = null; - if (resource_ != null) { - subBuilder = resource_.toBuilder(); - } - resource_ = - input.readMessage(io.grafeas.v1beta1.Resource.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(resource_); - resource_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - noteName_ = s; - break; - } - case 32: - { - int rawValue = input.readEnum(); - - kind_ = rawValue; - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - remediation_ = s; - break; - } - case 50: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 58: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (updateTime_ != null) { - subBuilder = updateTime_.toBuilder(); - } - updateTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateTime_); - updateTime_ = subBuilder.buildPartial(); - } - - break; - } - case 66: - { - io.grafeas.v1beta1.vulnerability.Details.Builder subBuilder = null; - if (detailsCase_ == 8) { - subBuilder = ((io.grafeas.v1beta1.vulnerability.Details) details_).toBuilder(); - } - details_ = - input.readMessage( - io.grafeas.v1beta1.vulnerability.Details.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.vulnerability.Details) details_); - details_ = subBuilder.buildPartial(); - } - detailsCase_ = 8; - break; - } - case 74: - { - io.grafeas.v1beta1.build.Details.Builder subBuilder = null; - if (detailsCase_ == 9) { - subBuilder = ((io.grafeas.v1beta1.build.Details) details_).toBuilder(); - } - details_ = - input.readMessage(io.grafeas.v1beta1.build.Details.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.build.Details) details_); - details_ = subBuilder.buildPartial(); - } - detailsCase_ = 9; - break; - } - case 82: - { - io.grafeas.v1beta1.image.Details.Builder subBuilder = null; - if (detailsCase_ == 10) { - subBuilder = ((io.grafeas.v1beta1.image.Details) details_).toBuilder(); - } - details_ = - input.readMessage(io.grafeas.v1beta1.image.Details.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.image.Details) details_); - details_ = subBuilder.buildPartial(); - } - detailsCase_ = 10; - break; - } - case 90: - { - io.grafeas.v1beta1.pkg.Details.Builder subBuilder = null; - if (detailsCase_ == 11) { - subBuilder = ((io.grafeas.v1beta1.pkg.Details) details_).toBuilder(); - } - details_ = - input.readMessage(io.grafeas.v1beta1.pkg.Details.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.pkg.Details) details_); - details_ = subBuilder.buildPartial(); - } - detailsCase_ = 11; - break; - } - case 98: - { - io.grafeas.v1beta1.deployment.Details.Builder subBuilder = null; - if (detailsCase_ == 12) { - subBuilder = ((io.grafeas.v1beta1.deployment.Details) details_).toBuilder(); - } - details_ = - input.readMessage( - io.grafeas.v1beta1.deployment.Details.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.deployment.Details) details_); - details_ = subBuilder.buildPartial(); - } - detailsCase_ = 12; - break; - } - case 106: - { - io.grafeas.v1beta1.discovery.Details.Builder subBuilder = null; - if (detailsCase_ == 13) { - subBuilder = ((io.grafeas.v1beta1.discovery.Details) details_).toBuilder(); - } - details_ = - input.readMessage( - io.grafeas.v1beta1.discovery.Details.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.discovery.Details) details_); - details_ = subBuilder.buildPartial(); - } - detailsCase_ = 13; - break; - } - case 114: - { - io.grafeas.v1beta1.attestation.Details.Builder subBuilder = null; - if (detailsCase_ == 14) { - subBuilder = ((io.grafeas.v1beta1.attestation.Details) details_).toBuilder(); - } - details_ = - input.readMessage( - io.grafeas.v1beta1.attestation.Details.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.attestation.Details) details_); - details_ = subBuilder.buildPartial(); - } - detailsCase_ = 14; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Occurrence_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Occurrence_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.Occurrence.class, io.grafeas.v1beta1.Occurrence.Builder.class); - } - - private int detailsCase_ = 0; - private java.lang.Object details_; - - public enum DetailsCase implements com.google.protobuf.Internal.EnumLite { - VULNERABILITY(8), - BUILD(9), - DERIVED_IMAGE(10), - INSTALLATION(11), - DEPLOYMENT(12), - DISCOVERED(13), - ATTESTATION(14), - DETAILS_NOT_SET(0); - private final int value; - - private DetailsCase(int value) { - this.value = value; - } - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static DetailsCase valueOf(int value) { - return forNumber(value); - } - - public static DetailsCase forNumber(int value) { - switch (value) { - case 8: - return VULNERABILITY; - case 9: - return BUILD; - case 10: - return DERIVED_IMAGE; - case 11: - return INSTALLATION; - case 12: - return DEPLOYMENT; - case 13: - return DISCOVERED; - case 14: - return ATTESTATION; - case 0: - return DETAILS_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public DetailsCase getDetailsCase() { - return DetailsCase.forNumber(detailsCase_); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Output only. The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * 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; - } - } - /** - * - * - *
-   * Output only. The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * 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 RESOURCE_FIELD_NUMBER = 2; - private io.grafeas.v1beta1.Resource resource_; - /** - * - * - *
-   * Required. Immutable. The resource for which the occurrence applies.
-   * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - public boolean hasResource() { - return resource_ != null; - } - /** - * - * - *
-   * Required. Immutable. The resource for which the occurrence applies.
-   * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - public io.grafeas.v1beta1.Resource getResource() { - return resource_ == null ? io.grafeas.v1beta1.Resource.getDefaultInstance() : resource_; - } - /** - * - * - *
-   * Required. Immutable. The resource for which the occurrence applies.
-   * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - public io.grafeas.v1beta1.ResourceOrBuilder getResourceOrBuilder() { - return getResource(); - } - - public static final int NOTE_NAME_FIELD_NUMBER = 3; - private volatile java.lang.Object noteName_; - /** - * - * - *
-   * Required. Immutable. The analysis note associated with this occurrence, in
-   * the form of `projects[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used
-   * as a filter in list requests.
-   * 
- * - * string note_name = 3; - */ - public java.lang.String getNoteName() { - java.lang.Object ref = noteName_; - 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(); - noteName_ = s; - return s; - } - } - /** - * - * - *
-   * Required. Immutable. The analysis note associated with this occurrence, in
-   * the form of `projects[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used
-   * as a filter in list requests.
-   * 
- * - * string note_name = 3; - */ - public com.google.protobuf.ByteString getNoteNameBytes() { - java.lang.Object ref = noteName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - noteName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int KIND_FIELD_NUMBER = 4; - private int kind_; - /** - * - * - *
-   * Output only. This explicitly denotes which of the occurrence details are
-   * specified. This field can be used as a filter in list requests.
-   * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public int getKindValue() { - return kind_; - } - /** - * - * - *
-   * Output only. This explicitly denotes which of the occurrence details are
-   * specified. This field can be used as a filter in list requests.
-   * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public io.grafeas.v1beta1.common.NoteKind getKind() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.common.NoteKind result = io.grafeas.v1beta1.common.NoteKind.valueOf(kind_); - return result == null ? io.grafeas.v1beta1.common.NoteKind.UNRECOGNIZED : result; - } - - public static final int REMEDIATION_FIELD_NUMBER = 5; - private volatile java.lang.Object remediation_; - /** - * - * - *
-   * A description of actions that can be taken to remedy the note.
-   * 
- * - * string remediation = 5; - */ - public java.lang.String getRemediation() { - java.lang.Object ref = remediation_; - 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(); - remediation_ = s; - return s; - } - } - /** - * - * - *
-   * A description of actions that can be taken to remedy the note.
-   * 
- * - * string remediation = 5; - */ - public com.google.protobuf.ByteString getRemediationBytes() { - java.lang.Object ref = remediation_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - remediation_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CREATE_TIME_FIELD_NUMBER = 6; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-   * Output only. The time this occurrence was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-   * Output only. The time this occurrence was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-   * Output only. The time this occurrence was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int UPDATE_TIME_FIELD_NUMBER = 7; - private com.google.protobuf.Timestamp updateTime_; - /** - * - * - *
-   * Output only. The time this occurrence was last updated.
-   * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public boolean hasUpdateTime() { - return updateTime_ != null; - } - /** - * - * - *
-   * Output only. The time this occurrence was last updated.
-   * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public com.google.protobuf.Timestamp getUpdateTime() { - return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; - } - /** - * - * - *
-   * Output only. The time this occurrence was last updated.
-   * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - return getUpdateTime(); - } - - public static final int VULNERABILITY_FIELD_NUMBER = 8; - /** - * - * - *
-   * Describes a security vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - public boolean hasVulnerability() { - return detailsCase_ == 8; - } - /** - * - * - *
-   * Describes a security vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - public io.grafeas.v1beta1.vulnerability.Details getVulnerability() { - if (detailsCase_ == 8) { - return (io.grafeas.v1beta1.vulnerability.Details) details_; - } - return io.grafeas.v1beta1.vulnerability.Details.getDefaultInstance(); - } - /** - * - * - *
-   * Describes a security vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - public io.grafeas.v1beta1.vulnerability.DetailsOrBuilder getVulnerabilityOrBuilder() { - if (detailsCase_ == 8) { - return (io.grafeas.v1beta1.vulnerability.Details) details_; - } - return io.grafeas.v1beta1.vulnerability.Details.getDefaultInstance(); - } - - public static final int BUILD_FIELD_NUMBER = 9; - /** - * - * - *
-   * Describes a verifiable build.
-   * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - public boolean hasBuild() { - return detailsCase_ == 9; - } - /** - * - * - *
-   * Describes a verifiable build.
-   * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - public io.grafeas.v1beta1.build.Details getBuild() { - if (detailsCase_ == 9) { - return (io.grafeas.v1beta1.build.Details) details_; - } - return io.grafeas.v1beta1.build.Details.getDefaultInstance(); - } - /** - * - * - *
-   * Describes a verifiable build.
-   * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - public io.grafeas.v1beta1.build.DetailsOrBuilder getBuildOrBuilder() { - if (detailsCase_ == 9) { - return (io.grafeas.v1beta1.build.Details) details_; - } - return io.grafeas.v1beta1.build.Details.getDefaultInstance(); - } - - public static final int DERIVED_IMAGE_FIELD_NUMBER = 10; - /** - * - * - *
-   * Describes how this resource derives from the basis in the associated
-   * note.
-   * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - public boolean hasDerivedImage() { - return detailsCase_ == 10; - } - /** - * - * - *
-   * Describes how this resource derives from the basis in the associated
-   * note.
-   * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - public io.grafeas.v1beta1.image.Details getDerivedImage() { - if (detailsCase_ == 10) { - return (io.grafeas.v1beta1.image.Details) details_; - } - return io.grafeas.v1beta1.image.Details.getDefaultInstance(); - } - /** - * - * - *
-   * Describes how this resource derives from the basis in the associated
-   * note.
-   * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - public io.grafeas.v1beta1.image.DetailsOrBuilder getDerivedImageOrBuilder() { - if (detailsCase_ == 10) { - return (io.grafeas.v1beta1.image.Details) details_; - } - return io.grafeas.v1beta1.image.Details.getDefaultInstance(); - } - - public static final int INSTALLATION_FIELD_NUMBER = 11; - /** - * - * - *
-   * Describes the installation of a package on the linked resource.
-   * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - public boolean hasInstallation() { - return detailsCase_ == 11; - } - /** - * - * - *
-   * Describes the installation of a package on the linked resource.
-   * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - public io.grafeas.v1beta1.pkg.Details getInstallation() { - if (detailsCase_ == 11) { - return (io.grafeas.v1beta1.pkg.Details) details_; - } - return io.grafeas.v1beta1.pkg.Details.getDefaultInstance(); - } - /** - * - * - *
-   * Describes the installation of a package on the linked resource.
-   * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - public io.grafeas.v1beta1.pkg.DetailsOrBuilder getInstallationOrBuilder() { - if (detailsCase_ == 11) { - return (io.grafeas.v1beta1.pkg.Details) details_; - } - return io.grafeas.v1beta1.pkg.Details.getDefaultInstance(); - } - - public static final int DEPLOYMENT_FIELD_NUMBER = 12; - /** - * - * - *
-   * Describes the deployment of an artifact on a runtime.
-   * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - public boolean hasDeployment() { - return detailsCase_ == 12; - } - /** - * - * - *
-   * Describes the deployment of an artifact on a runtime.
-   * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - public io.grafeas.v1beta1.deployment.Details getDeployment() { - if (detailsCase_ == 12) { - return (io.grafeas.v1beta1.deployment.Details) details_; - } - return io.grafeas.v1beta1.deployment.Details.getDefaultInstance(); - } - /** - * - * - *
-   * Describes the deployment of an artifact on a runtime.
-   * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - public io.grafeas.v1beta1.deployment.DetailsOrBuilder getDeploymentOrBuilder() { - if (detailsCase_ == 12) { - return (io.grafeas.v1beta1.deployment.Details) details_; - } - return io.grafeas.v1beta1.deployment.Details.getDefaultInstance(); - } - - public static final int DISCOVERED_FIELD_NUMBER = 13; - /** - * - * - *
-   * Describes when a resource was discovered.
-   * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - public boolean hasDiscovered() { - return detailsCase_ == 13; - } - /** - * - * - *
-   * Describes when a resource was discovered.
-   * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - public io.grafeas.v1beta1.discovery.Details getDiscovered() { - if (detailsCase_ == 13) { - return (io.grafeas.v1beta1.discovery.Details) details_; - } - return io.grafeas.v1beta1.discovery.Details.getDefaultInstance(); - } - /** - * - * - *
-   * Describes when a resource was discovered.
-   * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - public io.grafeas.v1beta1.discovery.DetailsOrBuilder getDiscoveredOrBuilder() { - if (detailsCase_ == 13) { - return (io.grafeas.v1beta1.discovery.Details) details_; - } - return io.grafeas.v1beta1.discovery.Details.getDefaultInstance(); - } - - public static final int ATTESTATION_FIELD_NUMBER = 14; - /** - * - * - *
-   * Describes an attestation of an artifact.
-   * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - public boolean hasAttestation() { - return detailsCase_ == 14; - } - /** - * - * - *
-   * Describes an attestation of an artifact.
-   * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - public io.grafeas.v1beta1.attestation.Details getAttestation() { - if (detailsCase_ == 14) { - return (io.grafeas.v1beta1.attestation.Details) details_; - } - return io.grafeas.v1beta1.attestation.Details.getDefaultInstance(); - } - /** - * - * - *
-   * Describes an attestation of an artifact.
-   * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - public io.grafeas.v1beta1.attestation.DetailsOrBuilder getAttestationOrBuilder() { - if (detailsCase_ == 14) { - return (io.grafeas.v1beta1.attestation.Details) details_; - } - return io.grafeas.v1beta1.attestation.Details.getDefaultInstance(); - } - - 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 (resource_ != null) { - output.writeMessage(2, getResource()); - } - if (!getNoteNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, noteName_); - } - if (kind_ != io.grafeas.v1beta1.common.NoteKind.NOTE_KIND_UNSPECIFIED.getNumber()) { - output.writeEnum(4, kind_); - } - if (!getRemediationBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, remediation_); - } - if (createTime_ != null) { - output.writeMessage(6, getCreateTime()); - } - if (updateTime_ != null) { - output.writeMessage(7, getUpdateTime()); - } - if (detailsCase_ == 8) { - output.writeMessage(8, (io.grafeas.v1beta1.vulnerability.Details) details_); - } - if (detailsCase_ == 9) { - output.writeMessage(9, (io.grafeas.v1beta1.build.Details) details_); - } - if (detailsCase_ == 10) { - output.writeMessage(10, (io.grafeas.v1beta1.image.Details) details_); - } - if (detailsCase_ == 11) { - output.writeMessage(11, (io.grafeas.v1beta1.pkg.Details) details_); - } - if (detailsCase_ == 12) { - output.writeMessage(12, (io.grafeas.v1beta1.deployment.Details) details_); - } - if (detailsCase_ == 13) { - output.writeMessage(13, (io.grafeas.v1beta1.discovery.Details) details_); - } - if (detailsCase_ == 14) { - output.writeMessage(14, (io.grafeas.v1beta1.attestation.Details) details_); - } - 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 (resource_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getResource()); - } - if (!getNoteNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, noteName_); - } - if (kind_ != io.grafeas.v1beta1.common.NoteKind.NOTE_KIND_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, kind_); - } - if (!getRemediationBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, remediation_); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getCreateTime()); - } - if (updateTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getUpdateTime()); - } - if (detailsCase_ == 8) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 8, (io.grafeas.v1beta1.vulnerability.Details) details_); - } - if (detailsCase_ == 9) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 9, (io.grafeas.v1beta1.build.Details) details_); - } - if (detailsCase_ == 10) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 10, (io.grafeas.v1beta1.image.Details) details_); - } - if (detailsCase_ == 11) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 11, (io.grafeas.v1beta1.pkg.Details) details_); - } - if (detailsCase_ == 12) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 12, (io.grafeas.v1beta1.deployment.Details) details_); - } - if (detailsCase_ == 13) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 13, (io.grafeas.v1beta1.discovery.Details) details_); - } - if (detailsCase_ == 14) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 14, (io.grafeas.v1beta1.attestation.Details) details_); - } - 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 io.grafeas.v1beta1.Occurrence)) { - return super.equals(obj); - } - io.grafeas.v1beta1.Occurrence other = (io.grafeas.v1beta1.Occurrence) obj; - - if (!getName().equals(other.getName())) return false; - if (hasResource() != other.hasResource()) return false; - if (hasResource()) { - if (!getResource().equals(other.getResource())) return false; - } - if (!getNoteName().equals(other.getNoteName())) return false; - if (kind_ != other.kind_) return false; - if (!getRemediation().equals(other.getRemediation())) return false; - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasUpdateTime() != other.hasUpdateTime()) return false; - if (hasUpdateTime()) { - if (!getUpdateTime().equals(other.getUpdateTime())) return false; - } - if (!getDetailsCase().equals(other.getDetailsCase())) return false; - switch (detailsCase_) { - case 8: - if (!getVulnerability().equals(other.getVulnerability())) return false; - break; - case 9: - if (!getBuild().equals(other.getBuild())) return false; - break; - case 10: - if (!getDerivedImage().equals(other.getDerivedImage())) return false; - break; - case 11: - if (!getInstallation().equals(other.getInstallation())) return false; - break; - case 12: - if (!getDeployment().equals(other.getDeployment())) return false; - break; - case 13: - if (!getDiscovered().equals(other.getDiscovered())) return false; - break; - case 14: - if (!getAttestation().equals(other.getAttestation())) return false; - break; - case 0: - default: - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - if (hasResource()) { - hash = (37 * hash) + RESOURCE_FIELD_NUMBER; - hash = (53 * hash) + getResource().hashCode(); - } - hash = (37 * hash) + NOTE_NAME_FIELD_NUMBER; - hash = (53 * hash) + getNoteName().hashCode(); - hash = (37 * hash) + KIND_FIELD_NUMBER; - hash = (53 * hash) + kind_; - hash = (37 * hash) + REMEDIATION_FIELD_NUMBER; - hash = (53 * hash) + getRemediation().hashCode(); - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasUpdateTime()) { - hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getUpdateTime().hashCode(); - } - switch (detailsCase_) { - case 8: - hash = (37 * hash) + VULNERABILITY_FIELD_NUMBER; - hash = (53 * hash) + getVulnerability().hashCode(); - break; - case 9: - hash = (37 * hash) + BUILD_FIELD_NUMBER; - hash = (53 * hash) + getBuild().hashCode(); - break; - case 10: - hash = (37 * hash) + DERIVED_IMAGE_FIELD_NUMBER; - hash = (53 * hash) + getDerivedImage().hashCode(); - break; - case 11: - hash = (37 * hash) + INSTALLATION_FIELD_NUMBER; - hash = (53 * hash) + getInstallation().hashCode(); - break; - case 12: - hash = (37 * hash) + DEPLOYMENT_FIELD_NUMBER; - hash = (53 * hash) + getDeployment().hashCode(); - break; - case 13: - hash = (37 * hash) + DISCOVERED_FIELD_NUMBER; - hash = (53 * hash) + getDiscovered().hashCode(); - break; - case 14: - hash = (37 * hash) + ATTESTATION_FIELD_NUMBER; - hash = (53 * hash) + getAttestation().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.Occurrence parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.Occurrence parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.Occurrence parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.Occurrence parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.Occurrence parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.Occurrence parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.Occurrence parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.Occurrence 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 io.grafeas.v1beta1.Occurrence parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.Occurrence 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 io.grafeas.v1beta1.Occurrence parseFrom(com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.Occurrence 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(io.grafeas.v1beta1.Occurrence 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; - } - /** - * - * - *
-   * An instance of an analysis type that has been found on a resource.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.Occurrence} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.Occurrence) - io.grafeas.v1beta1.OccurrenceOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Occurrence_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_Occurrence_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.Occurrence.class, io.grafeas.v1beta1.Occurrence.Builder.class); - } - - // Construct using io.grafeas.v1beta1.Occurrence.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - if (resourceBuilder_ == null) { - resource_ = null; - } else { - resource_ = null; - resourceBuilder_ = null; - } - noteName_ = ""; - - kind_ = 0; - - remediation_ = ""; - - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (updateTimeBuilder_ == null) { - updateTime_ = null; - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - detailsCase_ = 0; - details_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Occurrence_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.Occurrence getDefaultInstanceForType() { - return io.grafeas.v1beta1.Occurrence.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.Occurrence build() { - io.grafeas.v1beta1.Occurrence result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.Occurrence buildPartial() { - io.grafeas.v1beta1.Occurrence result = new io.grafeas.v1beta1.Occurrence(this); - result.name_ = name_; - if (resourceBuilder_ == null) { - result.resource_ = resource_; - } else { - result.resource_ = resourceBuilder_.build(); - } - result.noteName_ = noteName_; - result.kind_ = kind_; - result.remediation_ = remediation_; - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (updateTimeBuilder_ == null) { - result.updateTime_ = updateTime_; - } else { - result.updateTime_ = updateTimeBuilder_.build(); - } - if (detailsCase_ == 8) { - if (vulnerabilityBuilder_ == null) { - result.details_ = details_; - } else { - result.details_ = vulnerabilityBuilder_.build(); - } - } - if (detailsCase_ == 9) { - if (buildBuilder_ == null) { - result.details_ = details_; - } else { - result.details_ = buildBuilder_.build(); - } - } - if (detailsCase_ == 10) { - if (derivedImageBuilder_ == null) { - result.details_ = details_; - } else { - result.details_ = derivedImageBuilder_.build(); - } - } - if (detailsCase_ == 11) { - if (installationBuilder_ == null) { - result.details_ = details_; - } else { - result.details_ = installationBuilder_.build(); - } - } - if (detailsCase_ == 12) { - if (deploymentBuilder_ == null) { - result.details_ = details_; - } else { - result.details_ = deploymentBuilder_.build(); - } - } - if (detailsCase_ == 13) { - if (discoveredBuilder_ == null) { - result.details_ = details_; - } else { - result.details_ = discoveredBuilder_.build(); - } - } - if (detailsCase_ == 14) { - if (attestationBuilder_ == null) { - result.details_ = details_; - } else { - result.details_ = attestationBuilder_.build(); - } - } - result.detailsCase_ = detailsCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.Occurrence) { - return mergeFrom((io.grafeas.v1beta1.Occurrence) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.Occurrence other) { - if (other == io.grafeas.v1beta1.Occurrence.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (other.hasResource()) { - mergeResource(other.getResource()); - } - if (!other.getNoteName().isEmpty()) { - noteName_ = other.noteName_; - onChanged(); - } - if (other.kind_ != 0) { - setKindValue(other.getKindValue()); - } - if (!other.getRemediation().isEmpty()) { - remediation_ = other.remediation_; - onChanged(); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasUpdateTime()) { - mergeUpdateTime(other.getUpdateTime()); - } - switch (other.getDetailsCase()) { - case VULNERABILITY: - { - mergeVulnerability(other.getVulnerability()); - break; - } - case BUILD: - { - mergeBuild(other.getBuild()); - break; - } - case DERIVED_IMAGE: - { - mergeDerivedImage(other.getDerivedImage()); - break; - } - case INSTALLATION: - { - mergeInstallation(other.getInstallation()); - break; - } - case DEPLOYMENT: - { - mergeDeployment(other.getDeployment()); - break; - } - case DISCOVERED: - { - mergeDiscovered(other.getDiscovered()); - break; - } - case ATTESTATION: - { - mergeAttestation(other.getAttestation()); - break; - } - case DETAILS_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.Occurrence parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.Occurrence) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int detailsCase_ = 0; - private java.lang.Object details_; - - public DetailsCase getDetailsCase() { - return DetailsCase.forNumber(detailsCase_); - } - - public Builder clearDetails() { - detailsCase_ = 0; - details_ = null; - onChanged(); - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Output only. The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * Output only. The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * Output only. The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * 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 io.grafeas.v1beta1.Resource resource_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Resource, - io.grafeas.v1beta1.Resource.Builder, - io.grafeas.v1beta1.ResourceOrBuilder> - resourceBuilder_; - /** - * - * - *
-     * Required. Immutable. The resource for which the occurrence applies.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - public boolean hasResource() { - return resourceBuilder_ != null || resource_ != null; - } - /** - * - * - *
-     * Required. Immutable. The resource for which the occurrence applies.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - public io.grafeas.v1beta1.Resource getResource() { - if (resourceBuilder_ == null) { - return resource_ == null ? io.grafeas.v1beta1.Resource.getDefaultInstance() : resource_; - } else { - return resourceBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Required. Immutable. The resource for which the occurrence applies.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - public Builder setResource(io.grafeas.v1beta1.Resource value) { - if (resourceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - resource_ = value; - onChanged(); - } else { - resourceBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Required. Immutable. The resource for which the occurrence applies.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - public Builder setResource(io.grafeas.v1beta1.Resource.Builder builderForValue) { - if (resourceBuilder_ == null) { - resource_ = builderForValue.build(); - onChanged(); - } else { - resourceBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Required. Immutable. The resource for which the occurrence applies.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - public Builder mergeResource(io.grafeas.v1beta1.Resource value) { - if (resourceBuilder_ == null) { - if (resource_ != null) { - resource_ = - io.grafeas.v1beta1.Resource.newBuilder(resource_).mergeFrom(value).buildPartial(); - } else { - resource_ = value; - } - onChanged(); - } else { - resourceBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Required. Immutable. The resource for which the occurrence applies.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - public Builder clearResource() { - if (resourceBuilder_ == null) { - resource_ = null; - onChanged(); - } else { - resource_ = null; - resourceBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Required. Immutable. The resource for which the occurrence applies.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - public io.grafeas.v1beta1.Resource.Builder getResourceBuilder() { - - onChanged(); - return getResourceFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Required. Immutable. The resource for which the occurrence applies.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - public io.grafeas.v1beta1.ResourceOrBuilder getResourceOrBuilder() { - if (resourceBuilder_ != null) { - return resourceBuilder_.getMessageOrBuilder(); - } else { - return resource_ == null ? io.grafeas.v1beta1.Resource.getDefaultInstance() : resource_; - } - } - /** - * - * - *
-     * Required. Immutable. The resource for which the occurrence applies.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Resource, - io.grafeas.v1beta1.Resource.Builder, - io.grafeas.v1beta1.ResourceOrBuilder> - getResourceFieldBuilder() { - if (resourceBuilder_ == null) { - resourceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Resource, - io.grafeas.v1beta1.Resource.Builder, - io.grafeas.v1beta1.ResourceOrBuilder>( - getResource(), getParentForChildren(), isClean()); - resource_ = null; - } - return resourceBuilder_; - } - - private java.lang.Object noteName_ = ""; - /** - * - * - *
-     * Required. Immutable. The analysis note associated with this occurrence, in
-     * the form of `projects[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used
-     * as a filter in list requests.
-     * 
- * - * string note_name = 3; - */ - public java.lang.String getNoteName() { - java.lang.Object ref = noteName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - noteName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. Immutable. The analysis note associated with this occurrence, in
-     * the form of `projects[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used
-     * as a filter in list requests.
-     * 
- * - * string note_name = 3; - */ - public com.google.protobuf.ByteString getNoteNameBytes() { - java.lang.Object ref = noteName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - noteName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. Immutable. The analysis note associated with this occurrence, in
-     * the form of `projects[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used
-     * as a filter in list requests.
-     * 
- * - * string note_name = 3; - */ - public Builder setNoteName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - noteName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. Immutable. The analysis note associated with this occurrence, in
-     * the form of `projects[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used
-     * as a filter in list requests.
-     * 
- * - * string note_name = 3; - */ - public Builder clearNoteName() { - - noteName_ = getDefaultInstance().getNoteName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. Immutable. The analysis note associated with this occurrence, in
-     * the form of `projects[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used
-     * as a filter in list requests.
-     * 
- * - * string note_name = 3; - */ - public Builder setNoteNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - noteName_ = value; - onChanged(); - return this; - } - - private int kind_ = 0; - /** - * - * - *
-     * Output only. This explicitly denotes which of the occurrence details are
-     * specified. This field can be used as a filter in list requests.
-     * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public int getKindValue() { - return kind_; - } - /** - * - * - *
-     * Output only. This explicitly denotes which of the occurrence details are
-     * specified. This field can be used as a filter in list requests.
-     * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public Builder setKindValue(int value) { - kind_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. This explicitly denotes which of the occurrence details are
-     * specified. This field can be used as a filter in list requests.
-     * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public io.grafeas.v1beta1.common.NoteKind getKind() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.common.NoteKind result = io.grafeas.v1beta1.common.NoteKind.valueOf(kind_); - return result == null ? io.grafeas.v1beta1.common.NoteKind.UNRECOGNIZED : result; - } - /** - * - * - *
-     * Output only. This explicitly denotes which of the occurrence details are
-     * specified. This field can be used as a filter in list requests.
-     * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public Builder setKind(io.grafeas.v1beta1.common.NoteKind value) { - if (value == null) { - throw new NullPointerException(); - } - - kind_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. This explicitly denotes which of the occurrence details are
-     * specified. This field can be used as a filter in list requests.
-     * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - public Builder clearKind() { - - kind_ = 0; - onChanged(); - return this; - } - - private java.lang.Object remediation_ = ""; - /** - * - * - *
-     * A description of actions that can be taken to remedy the note.
-     * 
- * - * string remediation = 5; - */ - public java.lang.String getRemediation() { - java.lang.Object ref = remediation_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - remediation_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * A description of actions that can be taken to remedy the note.
-     * 
- * - * string remediation = 5; - */ - public com.google.protobuf.ByteString getRemediationBytes() { - java.lang.Object ref = remediation_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - remediation_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * A description of actions that can be taken to remedy the note.
-     * 
- * - * string remediation = 5; - */ - public Builder setRemediation(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - remediation_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * A description of actions that can be taken to remedy the note.
-     * 
- * - * string remediation = 5; - */ - public Builder clearRemediation() { - - remediation_ = getDefaultInstance().getRemediation(); - onChanged(); - return this; - } - /** - * - * - *
-     * A description of actions that can be taken to remedy the note.
-     * 
- * - * string remediation = 5; - */ - public Builder setRemediationBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - remediation_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-     * Output only. The time this occurrence was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-     * Output only. The time this occurrence was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. The time this occurrence was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - 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; - } - /** - * - * - *
-     * Output only. The time this occurrence was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. The time this occurrence was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - 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; - } - /** - * - * - *
-     * Output only. The time this occurrence was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. The time this occurrence was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. The time this occurrence was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-     * Output only. The time this occurrence was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - 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_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - updateTimeBuilder_; - /** - * - * - *
-     * Output only. The time this occurrence was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public boolean hasUpdateTime() { - return updateTimeBuilder_ != null || updateTime_ != null; - } - /** - * - * - *
-     * Output only. The time this occurrence was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public com.google.protobuf.Timestamp getUpdateTime() { - if (updateTimeBuilder_ == null) { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } else { - return updateTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. The time this occurrence was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - 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; - } - /** - * - * - *
-     * Output only. The time this occurrence was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (updateTimeBuilder_ == null) { - updateTime_ = builderForValue.build(); - onChanged(); - } else { - updateTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. The time this occurrence was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - 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; - } - /** - * - * - *
-     * Output only. The time this occurrence was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public Builder clearUpdateTime() { - if (updateTimeBuilder_ == null) { - updateTime_ = null; - onChanged(); - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. The time this occurrence was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - - onChanged(); - return getUpdateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. The time this occurrence was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - if (updateTimeBuilder_ != null) { - return updateTimeBuilder_.getMessageOrBuilder(); - } else { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } - } - /** - * - * - *
-     * Output only. The time this occurrence was last updated.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - 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_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.Details, - io.grafeas.v1beta1.vulnerability.Details.Builder, - io.grafeas.v1beta1.vulnerability.DetailsOrBuilder> - vulnerabilityBuilder_; - /** - * - * - *
-     * Describes a security vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - public boolean hasVulnerability() { - return detailsCase_ == 8; - } - /** - * - * - *
-     * Describes a security vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - public io.grafeas.v1beta1.vulnerability.Details getVulnerability() { - if (vulnerabilityBuilder_ == null) { - if (detailsCase_ == 8) { - return (io.grafeas.v1beta1.vulnerability.Details) details_; - } - return io.grafeas.v1beta1.vulnerability.Details.getDefaultInstance(); - } else { - if (detailsCase_ == 8) { - return vulnerabilityBuilder_.getMessage(); - } - return io.grafeas.v1beta1.vulnerability.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes a security vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - public Builder setVulnerability(io.grafeas.v1beta1.vulnerability.Details value) { - if (vulnerabilityBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - details_ = value; - onChanged(); - } else { - vulnerabilityBuilder_.setMessage(value); - } - detailsCase_ = 8; - return this; - } - /** - * - * - *
-     * Describes a security vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - public Builder setVulnerability( - io.grafeas.v1beta1.vulnerability.Details.Builder builderForValue) { - if (vulnerabilityBuilder_ == null) { - details_ = builderForValue.build(); - onChanged(); - } else { - vulnerabilityBuilder_.setMessage(builderForValue.build()); - } - detailsCase_ = 8; - return this; - } - /** - * - * - *
-     * Describes a security vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - public Builder mergeVulnerability(io.grafeas.v1beta1.vulnerability.Details value) { - if (vulnerabilityBuilder_ == null) { - if (detailsCase_ == 8 - && details_ != io.grafeas.v1beta1.vulnerability.Details.getDefaultInstance()) { - details_ = - io.grafeas.v1beta1.vulnerability.Details.newBuilder( - (io.grafeas.v1beta1.vulnerability.Details) details_) - .mergeFrom(value) - .buildPartial(); - } else { - details_ = value; - } - onChanged(); - } else { - if (detailsCase_ == 8) { - vulnerabilityBuilder_.mergeFrom(value); - } - vulnerabilityBuilder_.setMessage(value); - } - detailsCase_ = 8; - return this; - } - /** - * - * - *
-     * Describes a security vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - public Builder clearVulnerability() { - if (vulnerabilityBuilder_ == null) { - if (detailsCase_ == 8) { - detailsCase_ = 0; - details_ = null; - onChanged(); - } - } else { - if (detailsCase_ == 8) { - detailsCase_ = 0; - details_ = null; - } - vulnerabilityBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Describes a security vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - public io.grafeas.v1beta1.vulnerability.Details.Builder getVulnerabilityBuilder() { - return getVulnerabilityFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Describes a security vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - public io.grafeas.v1beta1.vulnerability.DetailsOrBuilder getVulnerabilityOrBuilder() { - if ((detailsCase_ == 8) && (vulnerabilityBuilder_ != null)) { - return vulnerabilityBuilder_.getMessageOrBuilder(); - } else { - if (detailsCase_ == 8) { - return (io.grafeas.v1beta1.vulnerability.Details) details_; - } - return io.grafeas.v1beta1.vulnerability.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes a security vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.Details, - io.grafeas.v1beta1.vulnerability.Details.Builder, - io.grafeas.v1beta1.vulnerability.DetailsOrBuilder> - getVulnerabilityFieldBuilder() { - if (vulnerabilityBuilder_ == null) { - if (!(detailsCase_ == 8)) { - details_ = io.grafeas.v1beta1.vulnerability.Details.getDefaultInstance(); - } - vulnerabilityBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.Details, - io.grafeas.v1beta1.vulnerability.Details.Builder, - io.grafeas.v1beta1.vulnerability.DetailsOrBuilder>( - (io.grafeas.v1beta1.vulnerability.Details) details_, - getParentForChildren(), - isClean()); - details_ = null; - } - detailsCase_ = 8; - onChanged(); - ; - return vulnerabilityBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.build.Details, - io.grafeas.v1beta1.build.Details.Builder, - io.grafeas.v1beta1.build.DetailsOrBuilder> - buildBuilder_; - /** - * - * - *
-     * Describes a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - public boolean hasBuild() { - return detailsCase_ == 9; - } - /** - * - * - *
-     * Describes a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - public io.grafeas.v1beta1.build.Details getBuild() { - if (buildBuilder_ == null) { - if (detailsCase_ == 9) { - return (io.grafeas.v1beta1.build.Details) details_; - } - return io.grafeas.v1beta1.build.Details.getDefaultInstance(); - } else { - if (detailsCase_ == 9) { - return buildBuilder_.getMessage(); - } - return io.grafeas.v1beta1.build.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - public Builder setBuild(io.grafeas.v1beta1.build.Details value) { - if (buildBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - details_ = value; - onChanged(); - } else { - buildBuilder_.setMessage(value); - } - detailsCase_ = 9; - return this; - } - /** - * - * - *
-     * Describes a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - public Builder setBuild(io.grafeas.v1beta1.build.Details.Builder builderForValue) { - if (buildBuilder_ == null) { - details_ = builderForValue.build(); - onChanged(); - } else { - buildBuilder_.setMessage(builderForValue.build()); - } - detailsCase_ = 9; - return this; - } - /** - * - * - *
-     * Describes a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - public Builder mergeBuild(io.grafeas.v1beta1.build.Details value) { - if (buildBuilder_ == null) { - if (detailsCase_ == 9 - && details_ != io.grafeas.v1beta1.build.Details.getDefaultInstance()) { - details_ = - io.grafeas.v1beta1.build.Details.newBuilder( - (io.grafeas.v1beta1.build.Details) details_) - .mergeFrom(value) - .buildPartial(); - } else { - details_ = value; - } - onChanged(); - } else { - if (detailsCase_ == 9) { - buildBuilder_.mergeFrom(value); - } - buildBuilder_.setMessage(value); - } - detailsCase_ = 9; - return this; - } - /** - * - * - *
-     * Describes a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - public Builder clearBuild() { - if (buildBuilder_ == null) { - if (detailsCase_ == 9) { - detailsCase_ = 0; - details_ = null; - onChanged(); - } - } else { - if (detailsCase_ == 9) { - detailsCase_ = 0; - details_ = null; - } - buildBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Describes a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - public io.grafeas.v1beta1.build.Details.Builder getBuildBuilder() { - return getBuildFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Describes a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - public io.grafeas.v1beta1.build.DetailsOrBuilder getBuildOrBuilder() { - if ((detailsCase_ == 9) && (buildBuilder_ != null)) { - return buildBuilder_.getMessageOrBuilder(); - } else { - if (detailsCase_ == 9) { - return (io.grafeas.v1beta1.build.Details) details_; - } - return io.grafeas.v1beta1.build.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes a verifiable build.
-     * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.build.Details, - io.grafeas.v1beta1.build.Details.Builder, - io.grafeas.v1beta1.build.DetailsOrBuilder> - getBuildFieldBuilder() { - if (buildBuilder_ == null) { - if (!(detailsCase_ == 9)) { - details_ = io.grafeas.v1beta1.build.Details.getDefaultInstance(); - } - buildBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.build.Details, - io.grafeas.v1beta1.build.Details.Builder, - io.grafeas.v1beta1.build.DetailsOrBuilder>( - (io.grafeas.v1beta1.build.Details) details_, getParentForChildren(), isClean()); - details_ = null; - } - detailsCase_ = 9; - onChanged(); - ; - return buildBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Details, - io.grafeas.v1beta1.image.Details.Builder, - io.grafeas.v1beta1.image.DetailsOrBuilder> - derivedImageBuilder_; - /** - * - * - *
-     * Describes how this resource derives from the basis in the associated
-     * note.
-     * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - public boolean hasDerivedImage() { - return detailsCase_ == 10; - } - /** - * - * - *
-     * Describes how this resource derives from the basis in the associated
-     * note.
-     * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - public io.grafeas.v1beta1.image.Details getDerivedImage() { - if (derivedImageBuilder_ == null) { - if (detailsCase_ == 10) { - return (io.grafeas.v1beta1.image.Details) details_; - } - return io.grafeas.v1beta1.image.Details.getDefaultInstance(); - } else { - if (detailsCase_ == 10) { - return derivedImageBuilder_.getMessage(); - } - return io.grafeas.v1beta1.image.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes how this resource derives from the basis in the associated
-     * note.
-     * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - public Builder setDerivedImage(io.grafeas.v1beta1.image.Details value) { - if (derivedImageBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - details_ = value; - onChanged(); - } else { - derivedImageBuilder_.setMessage(value); - } - detailsCase_ = 10; - return this; - } - /** - * - * - *
-     * Describes how this resource derives from the basis in the associated
-     * note.
-     * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - public Builder setDerivedImage(io.grafeas.v1beta1.image.Details.Builder builderForValue) { - if (derivedImageBuilder_ == null) { - details_ = builderForValue.build(); - onChanged(); - } else { - derivedImageBuilder_.setMessage(builderForValue.build()); - } - detailsCase_ = 10; - return this; - } - /** - * - * - *
-     * Describes how this resource derives from the basis in the associated
-     * note.
-     * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - public Builder mergeDerivedImage(io.grafeas.v1beta1.image.Details value) { - if (derivedImageBuilder_ == null) { - if (detailsCase_ == 10 - && details_ != io.grafeas.v1beta1.image.Details.getDefaultInstance()) { - details_ = - io.grafeas.v1beta1.image.Details.newBuilder( - (io.grafeas.v1beta1.image.Details) details_) - .mergeFrom(value) - .buildPartial(); - } else { - details_ = value; - } - onChanged(); - } else { - if (detailsCase_ == 10) { - derivedImageBuilder_.mergeFrom(value); - } - derivedImageBuilder_.setMessage(value); - } - detailsCase_ = 10; - return this; - } - /** - * - * - *
-     * Describes how this resource derives from the basis in the associated
-     * note.
-     * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - public Builder clearDerivedImage() { - if (derivedImageBuilder_ == null) { - if (detailsCase_ == 10) { - detailsCase_ = 0; - details_ = null; - onChanged(); - } - } else { - if (detailsCase_ == 10) { - detailsCase_ = 0; - details_ = null; - } - derivedImageBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Describes how this resource derives from the basis in the associated
-     * note.
-     * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - public io.grafeas.v1beta1.image.Details.Builder getDerivedImageBuilder() { - return getDerivedImageFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Describes how this resource derives from the basis in the associated
-     * note.
-     * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - public io.grafeas.v1beta1.image.DetailsOrBuilder getDerivedImageOrBuilder() { - if ((detailsCase_ == 10) && (derivedImageBuilder_ != null)) { - return derivedImageBuilder_.getMessageOrBuilder(); - } else { - if (detailsCase_ == 10) { - return (io.grafeas.v1beta1.image.Details) details_; - } - return io.grafeas.v1beta1.image.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes how this resource derives from the basis in the associated
-     * note.
-     * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Details, - io.grafeas.v1beta1.image.Details.Builder, - io.grafeas.v1beta1.image.DetailsOrBuilder> - getDerivedImageFieldBuilder() { - if (derivedImageBuilder_ == null) { - if (!(detailsCase_ == 10)) { - details_ = io.grafeas.v1beta1.image.Details.getDefaultInstance(); - } - derivedImageBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Details, - io.grafeas.v1beta1.image.Details.Builder, - io.grafeas.v1beta1.image.DetailsOrBuilder>( - (io.grafeas.v1beta1.image.Details) details_, getParentForChildren(), isClean()); - details_ = null; - } - detailsCase_ = 10; - onChanged(); - ; - return derivedImageBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Details, - io.grafeas.v1beta1.pkg.Details.Builder, - io.grafeas.v1beta1.pkg.DetailsOrBuilder> - installationBuilder_; - /** - * - * - *
-     * Describes the installation of a package on the linked resource.
-     * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - public boolean hasInstallation() { - return detailsCase_ == 11; - } - /** - * - * - *
-     * Describes the installation of a package on the linked resource.
-     * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - public io.grafeas.v1beta1.pkg.Details getInstallation() { - if (installationBuilder_ == null) { - if (detailsCase_ == 11) { - return (io.grafeas.v1beta1.pkg.Details) details_; - } - return io.grafeas.v1beta1.pkg.Details.getDefaultInstance(); - } else { - if (detailsCase_ == 11) { - return installationBuilder_.getMessage(); - } - return io.grafeas.v1beta1.pkg.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes the installation of a package on the linked resource.
-     * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - public Builder setInstallation(io.grafeas.v1beta1.pkg.Details value) { - if (installationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - details_ = value; - onChanged(); - } else { - installationBuilder_.setMessage(value); - } - detailsCase_ = 11; - return this; - } - /** - * - * - *
-     * Describes the installation of a package on the linked resource.
-     * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - public Builder setInstallation(io.grafeas.v1beta1.pkg.Details.Builder builderForValue) { - if (installationBuilder_ == null) { - details_ = builderForValue.build(); - onChanged(); - } else { - installationBuilder_.setMessage(builderForValue.build()); - } - detailsCase_ = 11; - return this; - } - /** - * - * - *
-     * Describes the installation of a package on the linked resource.
-     * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - public Builder mergeInstallation(io.grafeas.v1beta1.pkg.Details value) { - if (installationBuilder_ == null) { - if (detailsCase_ == 11 && details_ != io.grafeas.v1beta1.pkg.Details.getDefaultInstance()) { - details_ = - io.grafeas.v1beta1.pkg.Details.newBuilder((io.grafeas.v1beta1.pkg.Details) details_) - .mergeFrom(value) - .buildPartial(); - } else { - details_ = value; - } - onChanged(); - } else { - if (detailsCase_ == 11) { - installationBuilder_.mergeFrom(value); - } - installationBuilder_.setMessage(value); - } - detailsCase_ = 11; - return this; - } - /** - * - * - *
-     * Describes the installation of a package on the linked resource.
-     * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - public Builder clearInstallation() { - if (installationBuilder_ == null) { - if (detailsCase_ == 11) { - detailsCase_ = 0; - details_ = null; - onChanged(); - } - } else { - if (detailsCase_ == 11) { - detailsCase_ = 0; - details_ = null; - } - installationBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Describes the installation of a package on the linked resource.
-     * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - public io.grafeas.v1beta1.pkg.Details.Builder getInstallationBuilder() { - return getInstallationFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Describes the installation of a package on the linked resource.
-     * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - public io.grafeas.v1beta1.pkg.DetailsOrBuilder getInstallationOrBuilder() { - if ((detailsCase_ == 11) && (installationBuilder_ != null)) { - return installationBuilder_.getMessageOrBuilder(); - } else { - if (detailsCase_ == 11) { - return (io.grafeas.v1beta1.pkg.Details) details_; - } - return io.grafeas.v1beta1.pkg.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes the installation of a package on the linked resource.
-     * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Details, - io.grafeas.v1beta1.pkg.Details.Builder, - io.grafeas.v1beta1.pkg.DetailsOrBuilder> - getInstallationFieldBuilder() { - if (installationBuilder_ == null) { - if (!(detailsCase_ == 11)) { - details_ = io.grafeas.v1beta1.pkg.Details.getDefaultInstance(); - } - installationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Details, - io.grafeas.v1beta1.pkg.Details.Builder, - io.grafeas.v1beta1.pkg.DetailsOrBuilder>( - (io.grafeas.v1beta1.pkg.Details) details_, getParentForChildren(), isClean()); - details_ = null; - } - detailsCase_ = 11; - onChanged(); - ; - return installationBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.deployment.Details, - io.grafeas.v1beta1.deployment.Details.Builder, - io.grafeas.v1beta1.deployment.DetailsOrBuilder> - deploymentBuilder_; - /** - * - * - *
-     * Describes the deployment of an artifact on a runtime.
-     * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - public boolean hasDeployment() { - return detailsCase_ == 12; - } - /** - * - * - *
-     * Describes the deployment of an artifact on a runtime.
-     * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - public io.grafeas.v1beta1.deployment.Details getDeployment() { - if (deploymentBuilder_ == null) { - if (detailsCase_ == 12) { - return (io.grafeas.v1beta1.deployment.Details) details_; - } - return io.grafeas.v1beta1.deployment.Details.getDefaultInstance(); - } else { - if (detailsCase_ == 12) { - return deploymentBuilder_.getMessage(); - } - return io.grafeas.v1beta1.deployment.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes the deployment of an artifact on a runtime.
-     * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - public Builder setDeployment(io.grafeas.v1beta1.deployment.Details value) { - if (deploymentBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - details_ = value; - onChanged(); - } else { - deploymentBuilder_.setMessage(value); - } - detailsCase_ = 12; - return this; - } - /** - * - * - *
-     * Describes the deployment of an artifact on a runtime.
-     * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - public Builder setDeployment(io.grafeas.v1beta1.deployment.Details.Builder builderForValue) { - if (deploymentBuilder_ == null) { - details_ = builderForValue.build(); - onChanged(); - } else { - deploymentBuilder_.setMessage(builderForValue.build()); - } - detailsCase_ = 12; - return this; - } - /** - * - * - *
-     * Describes the deployment of an artifact on a runtime.
-     * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - public Builder mergeDeployment(io.grafeas.v1beta1.deployment.Details value) { - if (deploymentBuilder_ == null) { - if (detailsCase_ == 12 - && details_ != io.grafeas.v1beta1.deployment.Details.getDefaultInstance()) { - details_ = - io.grafeas.v1beta1.deployment.Details.newBuilder( - (io.grafeas.v1beta1.deployment.Details) details_) - .mergeFrom(value) - .buildPartial(); - } else { - details_ = value; - } - onChanged(); - } else { - if (detailsCase_ == 12) { - deploymentBuilder_.mergeFrom(value); - } - deploymentBuilder_.setMessage(value); - } - detailsCase_ = 12; - return this; - } - /** - * - * - *
-     * Describes the deployment of an artifact on a runtime.
-     * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - public Builder clearDeployment() { - if (deploymentBuilder_ == null) { - if (detailsCase_ == 12) { - detailsCase_ = 0; - details_ = null; - onChanged(); - } - } else { - if (detailsCase_ == 12) { - detailsCase_ = 0; - details_ = null; - } - deploymentBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Describes the deployment of an artifact on a runtime.
-     * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - public io.grafeas.v1beta1.deployment.Details.Builder getDeploymentBuilder() { - return getDeploymentFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Describes the deployment of an artifact on a runtime.
-     * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - public io.grafeas.v1beta1.deployment.DetailsOrBuilder getDeploymentOrBuilder() { - if ((detailsCase_ == 12) && (deploymentBuilder_ != null)) { - return deploymentBuilder_.getMessageOrBuilder(); - } else { - if (detailsCase_ == 12) { - return (io.grafeas.v1beta1.deployment.Details) details_; - } - return io.grafeas.v1beta1.deployment.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes the deployment of an artifact on a runtime.
-     * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.deployment.Details, - io.grafeas.v1beta1.deployment.Details.Builder, - io.grafeas.v1beta1.deployment.DetailsOrBuilder> - getDeploymentFieldBuilder() { - if (deploymentBuilder_ == null) { - if (!(detailsCase_ == 12)) { - details_ = io.grafeas.v1beta1.deployment.Details.getDefaultInstance(); - } - deploymentBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.deployment.Details, - io.grafeas.v1beta1.deployment.Details.Builder, - io.grafeas.v1beta1.deployment.DetailsOrBuilder>( - (io.grafeas.v1beta1.deployment.Details) details_, - getParentForChildren(), - isClean()); - details_ = null; - } - detailsCase_ = 12; - onChanged(); - ; - return deploymentBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.discovery.Details, - io.grafeas.v1beta1.discovery.Details.Builder, - io.grafeas.v1beta1.discovery.DetailsOrBuilder> - discoveredBuilder_; - /** - * - * - *
-     * Describes when a resource was discovered.
-     * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - public boolean hasDiscovered() { - return detailsCase_ == 13; - } - /** - * - * - *
-     * Describes when a resource was discovered.
-     * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - public io.grafeas.v1beta1.discovery.Details getDiscovered() { - if (discoveredBuilder_ == null) { - if (detailsCase_ == 13) { - return (io.grafeas.v1beta1.discovery.Details) details_; - } - return io.grafeas.v1beta1.discovery.Details.getDefaultInstance(); - } else { - if (detailsCase_ == 13) { - return discoveredBuilder_.getMessage(); - } - return io.grafeas.v1beta1.discovery.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes when a resource was discovered.
-     * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - public Builder setDiscovered(io.grafeas.v1beta1.discovery.Details value) { - if (discoveredBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - details_ = value; - onChanged(); - } else { - discoveredBuilder_.setMessage(value); - } - detailsCase_ = 13; - return this; - } - /** - * - * - *
-     * Describes when a resource was discovered.
-     * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - public Builder setDiscovered(io.grafeas.v1beta1.discovery.Details.Builder builderForValue) { - if (discoveredBuilder_ == null) { - details_ = builderForValue.build(); - onChanged(); - } else { - discoveredBuilder_.setMessage(builderForValue.build()); - } - detailsCase_ = 13; - return this; - } - /** - * - * - *
-     * Describes when a resource was discovered.
-     * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - public Builder mergeDiscovered(io.grafeas.v1beta1.discovery.Details value) { - if (discoveredBuilder_ == null) { - if (detailsCase_ == 13 - && details_ != io.grafeas.v1beta1.discovery.Details.getDefaultInstance()) { - details_ = - io.grafeas.v1beta1.discovery.Details.newBuilder( - (io.grafeas.v1beta1.discovery.Details) details_) - .mergeFrom(value) - .buildPartial(); - } else { - details_ = value; - } - onChanged(); - } else { - if (detailsCase_ == 13) { - discoveredBuilder_.mergeFrom(value); - } - discoveredBuilder_.setMessage(value); - } - detailsCase_ = 13; - return this; - } - /** - * - * - *
-     * Describes when a resource was discovered.
-     * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - public Builder clearDiscovered() { - if (discoveredBuilder_ == null) { - if (detailsCase_ == 13) { - detailsCase_ = 0; - details_ = null; - onChanged(); - } - } else { - if (detailsCase_ == 13) { - detailsCase_ = 0; - details_ = null; - } - discoveredBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Describes when a resource was discovered.
-     * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - public io.grafeas.v1beta1.discovery.Details.Builder getDiscoveredBuilder() { - return getDiscoveredFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Describes when a resource was discovered.
-     * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - public io.grafeas.v1beta1.discovery.DetailsOrBuilder getDiscoveredOrBuilder() { - if ((detailsCase_ == 13) && (discoveredBuilder_ != null)) { - return discoveredBuilder_.getMessageOrBuilder(); - } else { - if (detailsCase_ == 13) { - return (io.grafeas.v1beta1.discovery.Details) details_; - } - return io.grafeas.v1beta1.discovery.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes when a resource was discovered.
-     * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.discovery.Details, - io.grafeas.v1beta1.discovery.Details.Builder, - io.grafeas.v1beta1.discovery.DetailsOrBuilder> - getDiscoveredFieldBuilder() { - if (discoveredBuilder_ == null) { - if (!(detailsCase_ == 13)) { - details_ = io.grafeas.v1beta1.discovery.Details.getDefaultInstance(); - } - discoveredBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.discovery.Details, - io.grafeas.v1beta1.discovery.Details.Builder, - io.grafeas.v1beta1.discovery.DetailsOrBuilder>( - (io.grafeas.v1beta1.discovery.Details) details_, getParentForChildren(), isClean()); - details_ = null; - } - detailsCase_ = 13; - onChanged(); - ; - return discoveredBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.Details, - io.grafeas.v1beta1.attestation.Details.Builder, - io.grafeas.v1beta1.attestation.DetailsOrBuilder> - attestationBuilder_; - /** - * - * - *
-     * Describes an attestation of an artifact.
-     * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - public boolean hasAttestation() { - return detailsCase_ == 14; - } - /** - * - * - *
-     * Describes an attestation of an artifact.
-     * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - public io.grafeas.v1beta1.attestation.Details getAttestation() { - if (attestationBuilder_ == null) { - if (detailsCase_ == 14) { - return (io.grafeas.v1beta1.attestation.Details) details_; - } - return io.grafeas.v1beta1.attestation.Details.getDefaultInstance(); - } else { - if (detailsCase_ == 14) { - return attestationBuilder_.getMessage(); - } - return io.grafeas.v1beta1.attestation.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes an attestation of an artifact.
-     * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - public Builder setAttestation(io.grafeas.v1beta1.attestation.Details value) { - if (attestationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - details_ = value; - onChanged(); - } else { - attestationBuilder_.setMessage(value); - } - detailsCase_ = 14; - return this; - } - /** - * - * - *
-     * Describes an attestation of an artifact.
-     * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - public Builder setAttestation(io.grafeas.v1beta1.attestation.Details.Builder builderForValue) { - if (attestationBuilder_ == null) { - details_ = builderForValue.build(); - onChanged(); - } else { - attestationBuilder_.setMessage(builderForValue.build()); - } - detailsCase_ = 14; - return this; - } - /** - * - * - *
-     * Describes an attestation of an artifact.
-     * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - public Builder mergeAttestation(io.grafeas.v1beta1.attestation.Details value) { - if (attestationBuilder_ == null) { - if (detailsCase_ == 14 - && details_ != io.grafeas.v1beta1.attestation.Details.getDefaultInstance()) { - details_ = - io.grafeas.v1beta1.attestation.Details.newBuilder( - (io.grafeas.v1beta1.attestation.Details) details_) - .mergeFrom(value) - .buildPartial(); - } else { - details_ = value; - } - onChanged(); - } else { - if (detailsCase_ == 14) { - attestationBuilder_.mergeFrom(value); - } - attestationBuilder_.setMessage(value); - } - detailsCase_ = 14; - return this; - } - /** - * - * - *
-     * Describes an attestation of an artifact.
-     * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - public Builder clearAttestation() { - if (attestationBuilder_ == null) { - if (detailsCase_ == 14) { - detailsCase_ = 0; - details_ = null; - onChanged(); - } - } else { - if (detailsCase_ == 14) { - detailsCase_ = 0; - details_ = null; - } - attestationBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Describes an attestation of an artifact.
-     * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - public io.grafeas.v1beta1.attestation.Details.Builder getAttestationBuilder() { - return getAttestationFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Describes an attestation of an artifact.
-     * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - public io.grafeas.v1beta1.attestation.DetailsOrBuilder getAttestationOrBuilder() { - if ((detailsCase_ == 14) && (attestationBuilder_ != null)) { - return attestationBuilder_.getMessageOrBuilder(); - } else { - if (detailsCase_ == 14) { - return (io.grafeas.v1beta1.attestation.Details) details_; - } - return io.grafeas.v1beta1.attestation.Details.getDefaultInstance(); - } - } - /** - * - * - *
-     * Describes an attestation of an artifact.
-     * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.Details, - io.grafeas.v1beta1.attestation.Details.Builder, - io.grafeas.v1beta1.attestation.DetailsOrBuilder> - getAttestationFieldBuilder() { - if (attestationBuilder_ == null) { - if (!(detailsCase_ == 14)) { - details_ = io.grafeas.v1beta1.attestation.Details.getDefaultInstance(); - } - attestationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.Details, - io.grafeas.v1beta1.attestation.Details.Builder, - io.grafeas.v1beta1.attestation.DetailsOrBuilder>( - (io.grafeas.v1beta1.attestation.Details) details_, - getParentForChildren(), - isClean()); - details_ = null; - } - detailsCase_ = 14; - onChanged(); - ; - return attestationBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.Occurrence) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.Occurrence) - private static final io.grafeas.v1beta1.Occurrence DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.Occurrence(); - } - - public static io.grafeas.v1beta1.Occurrence getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Occurrence parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Occurrence(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.Occurrence getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/OccurrenceName.java deleted file mode 100644 index 7748b495..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/OccurrenceOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/OccurrenceOrBuilder.java deleted file mode 100644 index 335aa365..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/OccurrenceOrBuilder.java +++ /dev/null @@ -1,417 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface OccurrenceOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.Occurrence) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Output only. The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * Output only. The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Required. Immutable. The resource for which the occurrence applies.
-   * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - boolean hasResource(); - /** - * - * - *
-   * Required. Immutable. The resource for which the occurrence applies.
-   * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - io.grafeas.v1beta1.Resource getResource(); - /** - * - * - *
-   * Required. Immutable. The resource for which the occurrence applies.
-   * 
- * - * .grafeas.v1beta1.Resource resource = 2; - */ - io.grafeas.v1beta1.ResourceOrBuilder getResourceOrBuilder(); - - /** - * - * - *
-   * Required. Immutable. The analysis note associated with this occurrence, in
-   * the form of `projects[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used
-   * as a filter in list requests.
-   * 
- * - * string note_name = 3; - */ - java.lang.String getNoteName(); - /** - * - * - *
-   * Required. Immutable. The analysis note associated with this occurrence, in
-   * the form of `projects[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used
-   * as a filter in list requests.
-   * 
- * - * string note_name = 3; - */ - com.google.protobuf.ByteString getNoteNameBytes(); - - /** - * - * - *
-   * Output only. This explicitly denotes which of the occurrence details are
-   * specified. This field can be used as a filter in list requests.
-   * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - int getKindValue(); - /** - * - * - *
-   * Output only. This explicitly denotes which of the occurrence details are
-   * specified. This field can be used as a filter in list requests.
-   * 
- * - * .grafeas.v1beta1.NoteKind kind = 4; - */ - io.grafeas.v1beta1.common.NoteKind getKind(); - - /** - * - * - *
-   * A description of actions that can be taken to remedy the note.
-   * 
- * - * string remediation = 5; - */ - java.lang.String getRemediation(); - /** - * - * - *
-   * A description of actions that can be taken to remedy the note.
-   * 
- * - * string remediation = 5; - */ - com.google.protobuf.ByteString getRemediationBytes(); - - /** - * - * - *
-   * Output only. The time this occurrence was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - boolean hasCreateTime(); - /** - * - * - *
-   * Output only. The time this occurrence was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-   * Output only. The time this occurrence was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-   * Output only. The time this occurrence was last updated.
-   * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - boolean hasUpdateTime(); - /** - * - * - *
-   * Output only. The time this occurrence was last updated.
-   * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - com.google.protobuf.Timestamp getUpdateTime(); - /** - * - * - *
-   * Output only. The time this occurrence was last updated.
-   * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); - - /** - * - * - *
-   * Describes a security vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - boolean hasVulnerability(); - /** - * - * - *
-   * Describes a security vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - io.grafeas.v1beta1.vulnerability.Details getVulnerability(); - /** - * - * - *
-   * Describes a security vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Details vulnerability = 8; - */ - io.grafeas.v1beta1.vulnerability.DetailsOrBuilder getVulnerabilityOrBuilder(); - - /** - * - * - *
-   * Describes a verifiable build.
-   * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - boolean hasBuild(); - /** - * - * - *
-   * Describes a verifiable build.
-   * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - io.grafeas.v1beta1.build.Details getBuild(); - /** - * - * - *
-   * Describes a verifiable build.
-   * 
- * - * .grafeas.v1beta1.build.Details build = 9; - */ - io.grafeas.v1beta1.build.DetailsOrBuilder getBuildOrBuilder(); - - /** - * - * - *
-   * Describes how this resource derives from the basis in the associated
-   * note.
-   * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - boolean hasDerivedImage(); - /** - * - * - *
-   * Describes how this resource derives from the basis in the associated
-   * note.
-   * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - io.grafeas.v1beta1.image.Details getDerivedImage(); - /** - * - * - *
-   * Describes how this resource derives from the basis in the associated
-   * note.
-   * 
- * - * .grafeas.v1beta1.image.Details derived_image = 10; - */ - io.grafeas.v1beta1.image.DetailsOrBuilder getDerivedImageOrBuilder(); - - /** - * - * - *
-   * Describes the installation of a package on the linked resource.
-   * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - boolean hasInstallation(); - /** - * - * - *
-   * Describes the installation of a package on the linked resource.
-   * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - io.grafeas.v1beta1.pkg.Details getInstallation(); - /** - * - * - *
-   * Describes the installation of a package on the linked resource.
-   * 
- * - * .grafeas.v1beta1.package.Details installation = 11; - */ - io.grafeas.v1beta1.pkg.DetailsOrBuilder getInstallationOrBuilder(); - - /** - * - * - *
-   * Describes the deployment of an artifact on a runtime.
-   * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - boolean hasDeployment(); - /** - * - * - *
-   * Describes the deployment of an artifact on a runtime.
-   * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - io.grafeas.v1beta1.deployment.Details getDeployment(); - /** - * - * - *
-   * Describes the deployment of an artifact on a runtime.
-   * 
- * - * .grafeas.v1beta1.deployment.Details deployment = 12; - */ - io.grafeas.v1beta1.deployment.DetailsOrBuilder getDeploymentOrBuilder(); - - /** - * - * - *
-   * Describes when a resource was discovered.
-   * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - boolean hasDiscovered(); - /** - * - * - *
-   * Describes when a resource was discovered.
-   * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - io.grafeas.v1beta1.discovery.Details getDiscovered(); - /** - * - * - *
-   * Describes when a resource was discovered.
-   * 
- * - * .grafeas.v1beta1.discovery.Details discovered = 13; - */ - io.grafeas.v1beta1.discovery.DetailsOrBuilder getDiscoveredOrBuilder(); - - /** - * - * - *
-   * Describes an attestation of an artifact.
-   * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - boolean hasAttestation(); - /** - * - * - *
-   * Describes an attestation of an artifact.
-   * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - io.grafeas.v1beta1.attestation.Details getAttestation(); - /** - * - * - *
-   * Describes an attestation of an artifact.
-   * 
- * - * .grafeas.v1beta1.attestation.Details attestation = 14; - */ - io.grafeas.v1beta1.attestation.DetailsOrBuilder getAttestationOrBuilder(); - - public io.grafeas.v1beta1.Occurrence.DetailsCase getDetailsCase(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ProjectName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ProjectName.java deleted file mode 100644 index f3eaf6f0..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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 io.grafeas.v1beta1; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Resource.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Resource.java deleted file mode 100644 index 4a8906f7..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/Resource.java +++ /dev/null @@ -1,1026 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * An entity that can have metadata. For example, a Docker image.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.Resource} - */ -public final class Resource extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.Resource) - ResourceOrBuilder { - private static final long serialVersionUID = 0L; - // Use Resource.newBuilder() to construct. - private Resource(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Resource() { - name_ = ""; - uri_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Resource( - 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(); - - uri_ = s; - break; - } - case 26: - { - io.grafeas.v1beta1.provenance.Hash.Builder subBuilder = null; - if (contentHash_ != null) { - subBuilder = contentHash_.toBuilder(); - } - contentHash_ = - input.readMessage(io.grafeas.v1beta1.provenance.Hash.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(contentHash_); - contentHash_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Resource_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Resource_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.Resource.class, io.grafeas.v1beta1.Resource.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the resource. For example, the name of a Docker image -
-   * "Debian".
-   * 
- * - * 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 name of the resource. For example, the name of a Docker image -
-   * "Debian".
-   * 
- * - * 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 URI_FIELD_NUMBER = 2; - private volatile java.lang.Object uri_; - /** - * - * - *
-   * The unique URI of the resource. For example,
-   * `https://gcr.io/project/image@sha256:foo` for a Docker image.
-   * 
- * - * string uri = 2; - */ - public java.lang.String getUri() { - java.lang.Object ref = uri_; - 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(); - uri_ = s; - return s; - } - } - /** - * - * - *
-   * The unique URI of the resource. For example,
-   * `https://gcr.io/project/image@sha256:foo` for a Docker image.
-   * 
- * - * string uri = 2; - */ - public com.google.protobuf.ByteString getUriBytes() { - java.lang.Object ref = uri_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - uri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CONTENT_HASH_FIELD_NUMBER = 3; - private io.grafeas.v1beta1.provenance.Hash contentHash_; - /** - * - * - *
-   * The hash of the resource content. For example, the Docker digest.
-   * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - public boolean hasContentHash() { - return contentHash_ != null; - } - /** - * - * - *
-   * The hash of the resource content. For example, the Docker digest.
-   * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - public io.grafeas.v1beta1.provenance.Hash getContentHash() { - return contentHash_ == null - ? io.grafeas.v1beta1.provenance.Hash.getDefaultInstance() - : contentHash_; - } - /** - * - * - *
-   * The hash of the resource content. For example, the Docker digest.
-   * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - public io.grafeas.v1beta1.provenance.HashOrBuilder getContentHashOrBuilder() { - return getContentHash(); - } - - 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 (!getUriBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, uri_); - } - if (contentHash_ != null) { - output.writeMessage(3, getContentHash()); - } - 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 (!getUriBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, uri_); - } - if (contentHash_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getContentHash()); - } - 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 io.grafeas.v1beta1.Resource)) { - return super.equals(obj); - } - io.grafeas.v1beta1.Resource other = (io.grafeas.v1beta1.Resource) obj; - - if (!getName().equals(other.getName())) return false; - if (!getUri().equals(other.getUri())) return false; - if (hasContentHash() != other.hasContentHash()) return false; - if (hasContentHash()) { - if (!getContentHash().equals(other.getContentHash())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + URI_FIELD_NUMBER; - hash = (53 * hash) + getUri().hashCode(); - if (hasContentHash()) { - hash = (37 * hash) + CONTENT_HASH_FIELD_NUMBER; - hash = (53 * hash) + getContentHash().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.Resource parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.Resource parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.Resource parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.Resource parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.Resource parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.Resource parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.Resource parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.Resource 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 io.grafeas.v1beta1.Resource parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.Resource 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 io.grafeas.v1beta1.Resource parseFrom(com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.Resource 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(io.grafeas.v1beta1.Resource 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; - } - /** - * - * - *
-   * An entity that can have metadata. For example, a Docker image.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.Resource} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.Resource) - io.grafeas.v1beta1.ResourceOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Resource_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Resource_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.Resource.class, io.grafeas.v1beta1.Resource.Builder.class); - } - - // Construct using io.grafeas.v1beta1.Resource.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - uri_ = ""; - - if (contentHashBuilder_ == null) { - contentHash_ = null; - } else { - contentHash_ = null; - contentHashBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_Resource_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.Resource getDefaultInstanceForType() { - return io.grafeas.v1beta1.Resource.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.Resource build() { - io.grafeas.v1beta1.Resource result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.Resource buildPartial() { - io.grafeas.v1beta1.Resource result = new io.grafeas.v1beta1.Resource(this); - result.name_ = name_; - result.uri_ = uri_; - if (contentHashBuilder_ == null) { - result.contentHash_ = contentHash_; - } else { - result.contentHash_ = contentHashBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.Resource) { - return mergeFrom((io.grafeas.v1beta1.Resource) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.Resource other) { - if (other == io.grafeas.v1beta1.Resource.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getUri().isEmpty()) { - uri_ = other.uri_; - onChanged(); - } - if (other.hasContentHash()) { - mergeContentHash(other.getContentHash()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.Resource parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.Resource) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the resource. For example, the name of a Docker image -
-     * "Debian".
-     * 
- * - * 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 name of the resource. For example, the name of a Docker image -
-     * "Debian".
-     * 
- * - * 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 name of the resource. For example, the name of a Docker image -
-     * "Debian".
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the resource. For example, the name of a Docker image -
-     * "Debian".
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the resource. For example, the name of a Docker image -
-     * "Debian".
-     * 
- * - * 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 java.lang.Object uri_ = ""; - /** - * - * - *
-     * The unique URI of the resource. For example,
-     * `https://gcr.io/project/image@sha256:foo` for a Docker image.
-     * 
- * - * string uri = 2; - */ - public java.lang.String getUri() { - java.lang.Object ref = uri_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - uri_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The unique URI of the resource. For example,
-     * `https://gcr.io/project/image@sha256:foo` for a Docker image.
-     * 
- * - * string uri = 2; - */ - public com.google.protobuf.ByteString getUriBytes() { - java.lang.Object ref = uri_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - uri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The unique URI of the resource. For example,
-     * `https://gcr.io/project/image@sha256:foo` for a Docker image.
-     * 
- * - * string uri = 2; - */ - public Builder setUri(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - uri_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The unique URI of the resource. For example,
-     * `https://gcr.io/project/image@sha256:foo` for a Docker image.
-     * 
- * - * string uri = 2; - */ - public Builder clearUri() { - - uri_ = getDefaultInstance().getUri(); - onChanged(); - return this; - } - /** - * - * - *
-     * The unique URI of the resource. For example,
-     * `https://gcr.io/project/image@sha256:foo` for a Docker image.
-     * 
- * - * string uri = 2; - */ - public Builder setUriBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - uri_ = value; - onChanged(); - return this; - } - - private io.grafeas.v1beta1.provenance.Hash contentHash_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.provenance.Hash, - io.grafeas.v1beta1.provenance.Hash.Builder, - io.grafeas.v1beta1.provenance.HashOrBuilder> - contentHashBuilder_; - /** - * - * - *
-     * The hash of the resource content. For example, the Docker digest.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - public boolean hasContentHash() { - return contentHashBuilder_ != null || contentHash_ != null; - } - /** - * - * - *
-     * The hash of the resource content. For example, the Docker digest.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - public io.grafeas.v1beta1.provenance.Hash getContentHash() { - if (contentHashBuilder_ == null) { - return contentHash_ == null - ? io.grafeas.v1beta1.provenance.Hash.getDefaultInstance() - : contentHash_; - } else { - return contentHashBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The hash of the resource content. For example, the Docker digest.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - public Builder setContentHash(io.grafeas.v1beta1.provenance.Hash value) { - if (contentHashBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - contentHash_ = value; - onChanged(); - } else { - contentHashBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The hash of the resource content. For example, the Docker digest.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - public Builder setContentHash(io.grafeas.v1beta1.provenance.Hash.Builder builderForValue) { - if (contentHashBuilder_ == null) { - contentHash_ = builderForValue.build(); - onChanged(); - } else { - contentHashBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The hash of the resource content. For example, the Docker digest.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - public Builder mergeContentHash(io.grafeas.v1beta1.provenance.Hash value) { - if (contentHashBuilder_ == null) { - if (contentHash_ != null) { - contentHash_ = - io.grafeas.v1beta1.provenance.Hash.newBuilder(contentHash_) - .mergeFrom(value) - .buildPartial(); - } else { - contentHash_ = value; - } - onChanged(); - } else { - contentHashBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The hash of the resource content. For example, the Docker digest.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - public Builder clearContentHash() { - if (contentHashBuilder_ == null) { - contentHash_ = null; - onChanged(); - } else { - contentHash_ = null; - contentHashBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The hash of the resource content. For example, the Docker digest.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - public io.grafeas.v1beta1.provenance.Hash.Builder getContentHashBuilder() { - - onChanged(); - return getContentHashFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The hash of the resource content. For example, the Docker digest.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - public io.grafeas.v1beta1.provenance.HashOrBuilder getContentHashOrBuilder() { - if (contentHashBuilder_ != null) { - return contentHashBuilder_.getMessageOrBuilder(); - } else { - return contentHash_ == null - ? io.grafeas.v1beta1.provenance.Hash.getDefaultInstance() - : contentHash_; - } - } - /** - * - * - *
-     * The hash of the resource content. For example, the Docker digest.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.provenance.Hash, - io.grafeas.v1beta1.provenance.Hash.Builder, - io.grafeas.v1beta1.provenance.HashOrBuilder> - getContentHashFieldBuilder() { - if (contentHashBuilder_ == null) { - contentHashBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.provenance.Hash, - io.grafeas.v1beta1.provenance.Hash.Builder, - io.grafeas.v1beta1.provenance.HashOrBuilder>( - getContentHash(), getParentForChildren(), isClean()); - contentHash_ = null; - } - return contentHashBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.Resource) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.Resource) - private static final io.grafeas.v1beta1.Resource DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.Resource(); - } - - public static io.grafeas.v1beta1.Resource getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Resource parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Resource(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.Resource getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ResourceOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ResourceOrBuilder.java deleted file mode 100644 index c21d7650..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ResourceOrBuilder.java +++ /dev/null @@ -1,87 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface ResourceOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.Resource) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the resource. For example, the name of a Docker image -
-   * "Debian".
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the resource. For example, the name of a Docker image -
-   * "Debian".
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * The unique URI of the resource. For example,
-   * `https://gcr.io/project/image@sha256:foo` for a Docker image.
-   * 
- * - * string uri = 2; - */ - java.lang.String getUri(); - /** - * - * - *
-   * The unique URI of the resource. For example,
-   * `https://gcr.io/project/image@sha256:foo` for a Docker image.
-   * 
- * - * string uri = 2; - */ - com.google.protobuf.ByteString getUriBytes(); - - /** - * - * - *
-   * The hash of the resource content. For example, the Docker digest.
-   * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - boolean hasContentHash(); - /** - * - * - *
-   * The hash of the resource content. For example, the Docker digest.
-   * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - io.grafeas.v1beta1.provenance.Hash getContentHash(); - /** - * - * - *
-   * The hash of the resource content. For example, the Docker digest.
-   * 
- * - * .grafeas.v1beta1.provenance.Hash content_hash = 3; - */ - io.grafeas.v1beta1.provenance.HashOrBuilder getContentHashOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ScanConfigName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ScanConfigName.java deleted file mode 100644 index 73cf1c66..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/ScanConfigName.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * 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 io.grafeas.v1beta1; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ScanConfigName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ScanConfigName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - scanConfig = Preconditions.checkNotNull(builder.getScanConfig()); - } - - public static ScanConfigName of(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build(); - } - - public static String format(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build().toString(); - } - - public static ScanConfigName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ScanConfigName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("scan_config")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ScanConfigName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("scanConfig", scanConfig); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "scan_config", scanConfig); - } - - /** Builder for ScanConfigName. */ - public static class Builder { - - private String project; - private String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setScanConfig(String scanConfig) { - this.scanConfig = scanConfig; - return this; - } - - private Builder() {} - - private Builder(ScanConfigName scanConfigName) { - project = scanConfigName.project; - scanConfig = scanConfigName.scanConfig; - } - - public ScanConfigName build() { - return new ScanConfigName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ScanConfigName) { - ScanConfigName that = (ScanConfigName) o; - return (this.project.equals(that.project)) && (this.scanConfig.equals(that.scanConfig)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= scanConfig.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UntypedIamResourceName.java deleted file mode 100644 index 033a4ae9..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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 io.grafeas.v1beta1; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateNoteRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateNoteRequest.java deleted file mode 100644 index d693f718..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateNoteRequest.java +++ /dev/null @@ -1,1114 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to update a note.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.UpdateNoteRequest} - */ -public final class UpdateNoteRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.UpdateNoteRequest) - UpdateNoteRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use UpdateNoteRequest.newBuilder() to construct. - private UpdateNoteRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private UpdateNoteRequest() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private UpdateNoteRequest( - 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: - { - io.grafeas.v1beta1.Note.Builder subBuilder = null; - if (note_ != null) { - subBuilder = note_.toBuilder(); - } - note_ = input.readMessage(io.grafeas.v1beta1.Note.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(note_); - note_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.FieldMask.Builder subBuilder = null; - if (updateMask_ != null) { - subBuilder = updateMask_.toBuilder(); - } - updateMask_ = - input.readMessage(com.google.protobuf.FieldMask.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateMask_); - updateMask_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas.internal_static_grafeas_v1beta1_UpdateNoteRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_UpdateNoteRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.UpdateNoteRequest.class, - io.grafeas.v1beta1.UpdateNoteRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * 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 name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * 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 NOTE_FIELD_NUMBER = 2; - private io.grafeas.v1beta1.Note note_; - /** - * - * - *
-   * The updated note.
-   * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - public boolean hasNote() { - return note_ != null; - } - /** - * - * - *
-   * The updated note.
-   * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - public io.grafeas.v1beta1.Note getNote() { - return note_ == null ? io.grafeas.v1beta1.Note.getDefaultInstance() : note_; - } - /** - * - * - *
-   * The updated note.
-   * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - public io.grafeas.v1beta1.NoteOrBuilder getNoteOrBuilder() { - return getNote(); - } - - public static final int UPDATE_MASK_FIELD_NUMBER = 3; - private com.google.protobuf.FieldMask updateMask_; - /** - * - * - *
-   * The fields to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public boolean hasUpdateMask() { - return updateMask_ != null; - } - /** - * - * - *
-   * The fields to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public com.google.protobuf.FieldMask getUpdateMask() { - return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; - } - /** - * - * - *
-   * The fields to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { - return getUpdateMask(); - } - - 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 (note_ != null) { - output.writeMessage(2, getNote()); - } - if (updateMask_ != null) { - output.writeMessage(3, getUpdateMask()); - } - 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 (note_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getNote()); - } - if (updateMask_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getUpdateMask()); - } - 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 io.grafeas.v1beta1.UpdateNoteRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.UpdateNoteRequest other = (io.grafeas.v1beta1.UpdateNoteRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (hasNote() != other.hasNote()) return false; - if (hasNote()) { - if (!getNote().equals(other.getNote())) return false; - } - if (hasUpdateMask() != other.hasUpdateMask()) return false; - if (hasUpdateMask()) { - if (!getUpdateMask().equals(other.getUpdateMask())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - if (hasNote()) { - hash = (37 * hash) + NOTE_FIELD_NUMBER; - hash = (53 * hash) + getNote().hashCode(); - } - if (hasUpdateMask()) { - hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; - hash = (53 * hash) + getUpdateMask().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.UpdateNoteRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.UpdateNoteRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.UpdateNoteRequest parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.UpdateNoteRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.UpdateNoteRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.UpdateNoteRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.UpdateNoteRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.UpdateNoteRequest 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 io.grafeas.v1beta1.UpdateNoteRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.UpdateNoteRequest 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 io.grafeas.v1beta1.UpdateNoteRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.UpdateNoteRequest 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(io.grafeas.v1beta1.UpdateNoteRequest 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 to update a note.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.UpdateNoteRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.UpdateNoteRequest) - io.grafeas.v1beta1.UpdateNoteRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_UpdateNoteRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_UpdateNoteRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.UpdateNoteRequest.class, - io.grafeas.v1beta1.UpdateNoteRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.UpdateNoteRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - if (noteBuilder_ == null) { - note_ = null; - } else { - note_ = null; - noteBuilder_ = null; - } - if (updateMaskBuilder_ == null) { - updateMask_ = null; - } else { - updateMask_ = null; - updateMaskBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_UpdateNoteRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.UpdateNoteRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.UpdateNoteRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.UpdateNoteRequest build() { - io.grafeas.v1beta1.UpdateNoteRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.UpdateNoteRequest buildPartial() { - io.grafeas.v1beta1.UpdateNoteRequest result = new io.grafeas.v1beta1.UpdateNoteRequest(this); - result.name_ = name_; - if (noteBuilder_ == null) { - result.note_ = note_; - } else { - result.note_ = noteBuilder_.build(); - } - if (updateMaskBuilder_ == null) { - result.updateMask_ = updateMask_; - } else { - result.updateMask_ = updateMaskBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.UpdateNoteRequest) { - return mergeFrom((io.grafeas.v1beta1.UpdateNoteRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.UpdateNoteRequest other) { - if (other == io.grafeas.v1beta1.UpdateNoteRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (other.hasNote()) { - mergeNote(other.getNote()); - } - if (other.hasUpdateMask()) { - mergeUpdateMask(other.getUpdateMask()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.UpdateNoteRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.UpdateNoteRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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 name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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 name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the note in the form of
-     * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-     * 
- * - * 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 io.grafeas.v1beta1.Note note_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Note, - io.grafeas.v1beta1.Note.Builder, - io.grafeas.v1beta1.NoteOrBuilder> - noteBuilder_; - /** - * - * - *
-     * The updated note.
-     * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - public boolean hasNote() { - return noteBuilder_ != null || note_ != null; - } - /** - * - * - *
-     * The updated note.
-     * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - public io.grafeas.v1beta1.Note getNote() { - if (noteBuilder_ == null) { - return note_ == null ? io.grafeas.v1beta1.Note.getDefaultInstance() : note_; - } else { - return noteBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The updated note.
-     * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - public Builder setNote(io.grafeas.v1beta1.Note value) { - if (noteBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - note_ = value; - onChanged(); - } else { - noteBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The updated note.
-     * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - public Builder setNote(io.grafeas.v1beta1.Note.Builder builderForValue) { - if (noteBuilder_ == null) { - note_ = builderForValue.build(); - onChanged(); - } else { - noteBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The updated note.
-     * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - public Builder mergeNote(io.grafeas.v1beta1.Note value) { - if (noteBuilder_ == null) { - if (note_ != null) { - note_ = io.grafeas.v1beta1.Note.newBuilder(note_).mergeFrom(value).buildPartial(); - } else { - note_ = value; - } - onChanged(); - } else { - noteBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The updated note.
-     * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - public Builder clearNote() { - if (noteBuilder_ == null) { - note_ = null; - onChanged(); - } else { - note_ = null; - noteBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The updated note.
-     * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - public io.grafeas.v1beta1.Note.Builder getNoteBuilder() { - - onChanged(); - return getNoteFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The updated note.
-     * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - public io.grafeas.v1beta1.NoteOrBuilder getNoteOrBuilder() { - if (noteBuilder_ != null) { - return noteBuilder_.getMessageOrBuilder(); - } else { - return note_ == null ? io.grafeas.v1beta1.Note.getDefaultInstance() : note_; - } - } - /** - * - * - *
-     * The updated note.
-     * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Note, - io.grafeas.v1beta1.Note.Builder, - io.grafeas.v1beta1.NoteOrBuilder> - getNoteFieldBuilder() { - if (noteBuilder_ == null) { - noteBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Note, - io.grafeas.v1beta1.Note.Builder, - io.grafeas.v1beta1.NoteOrBuilder>(getNote(), getParentForChildren(), isClean()); - note_ = null; - } - return noteBuilder_; - } - - private com.google.protobuf.FieldMask updateMask_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.FieldMask, - com.google.protobuf.FieldMask.Builder, - com.google.protobuf.FieldMaskOrBuilder> - updateMaskBuilder_; - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public boolean hasUpdateMask() { - return updateMaskBuilder_ != null || updateMask_ != null; - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public com.google.protobuf.FieldMask getUpdateMask() { - if (updateMaskBuilder_ == null) { - return updateMask_ == null - ? com.google.protobuf.FieldMask.getDefaultInstance() - : updateMask_; - } else { - return updateMaskBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public Builder setUpdateMask(com.google.protobuf.FieldMask value) { - if (updateMaskBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - updateMask_ = value; - onChanged(); - } else { - updateMaskBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { - if (updateMaskBuilder_ == null) { - updateMask_ = builderForValue.build(); - onChanged(); - } else { - updateMaskBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { - if (updateMaskBuilder_ == null) { - if (updateMask_ != null) { - updateMask_ = - com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial(); - } else { - updateMask_ = value; - } - onChanged(); - } else { - updateMaskBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public Builder clearUpdateMask() { - if (updateMaskBuilder_ == null) { - updateMask_ = null; - onChanged(); - } else { - updateMask_ = null; - updateMaskBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { - - onChanged(); - return getUpdateMaskFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { - if (updateMaskBuilder_ != null) { - return updateMaskBuilder_.getMessageOrBuilder(); - } else { - return updateMask_ == null - ? com.google.protobuf.FieldMask.getDefaultInstance() - : updateMask_; - } - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.FieldMask, - com.google.protobuf.FieldMask.Builder, - com.google.protobuf.FieldMaskOrBuilder> - getUpdateMaskFieldBuilder() { - if (updateMaskBuilder_ == null) { - updateMaskBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.FieldMask, - com.google.protobuf.FieldMask.Builder, - com.google.protobuf.FieldMaskOrBuilder>( - getUpdateMask(), getParentForChildren(), isClean()); - updateMask_ = null; - } - return updateMaskBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.UpdateNoteRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.UpdateNoteRequest) - private static final io.grafeas.v1beta1.UpdateNoteRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.UpdateNoteRequest(); - } - - public static io.grafeas.v1beta1.UpdateNoteRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public UpdateNoteRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new UpdateNoteRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.UpdateNoteRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateNoteRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateNoteRequestOrBuilder.java deleted file mode 100644 index 24183f32..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateNoteRequestOrBuilder.java +++ /dev/null @@ -1,95 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface UpdateNoteRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.UpdateNoteRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the note in the form of
-   * `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * The updated note.
-   * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - boolean hasNote(); - /** - * - * - *
-   * The updated note.
-   * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - io.grafeas.v1beta1.Note getNote(); - /** - * - * - *
-   * The updated note.
-   * 
- * - * .grafeas.v1beta1.Note note = 2; - */ - io.grafeas.v1beta1.NoteOrBuilder getNoteOrBuilder(); - - /** - * - * - *
-   * The fields to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - boolean hasUpdateMask(); - /** - * - * - *
-   * The fields to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - com.google.protobuf.FieldMask getUpdateMask(); - /** - * - * - *
-   * The fields to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateOccurrenceRequest.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateOccurrenceRequest.java deleted file mode 100644 index 833710d9..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateOccurrenceRequest.java +++ /dev/null @@ -1,1125 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * Request to update an occurrence.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.UpdateOccurrenceRequest} - */ -public final class UpdateOccurrenceRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.UpdateOccurrenceRequest) - UpdateOccurrenceRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use UpdateOccurrenceRequest.newBuilder() to construct. - private UpdateOccurrenceRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private UpdateOccurrenceRequest() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private UpdateOccurrenceRequest( - 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: - { - io.grafeas.v1beta1.Occurrence.Builder subBuilder = null; - if (occurrence_ != null) { - subBuilder = occurrence_.toBuilder(); - } - occurrence_ = - input.readMessage(io.grafeas.v1beta1.Occurrence.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(occurrence_); - occurrence_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.FieldMask.Builder subBuilder = null; - if (updateMask_ != null) { - subBuilder = updateMask_.toBuilder(); - } - updateMask_ = - input.readMessage(com.google.protobuf.FieldMask.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateMask_); - updateMask_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_UpdateOccurrenceRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_UpdateOccurrenceRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.UpdateOccurrenceRequest.class, - io.grafeas.v1beta1.UpdateOccurrenceRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * 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 name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * 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 OCCURRENCE_FIELD_NUMBER = 2; - private io.grafeas.v1beta1.Occurrence occurrence_; - /** - * - * - *
-   * The updated occurrence.
-   * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public boolean hasOccurrence() { - return occurrence_ != null; - } - /** - * - * - *
-   * The updated occurrence.
-   * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public io.grafeas.v1beta1.Occurrence getOccurrence() { - return occurrence_ == null ? io.grafeas.v1beta1.Occurrence.getDefaultInstance() : occurrence_; - } - /** - * - * - *
-   * The updated occurrence.
-   * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrenceOrBuilder() { - return getOccurrence(); - } - - public static final int UPDATE_MASK_FIELD_NUMBER = 3; - private com.google.protobuf.FieldMask updateMask_; - /** - * - * - *
-   * The fields to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public boolean hasUpdateMask() { - return updateMask_ != null; - } - /** - * - * - *
-   * The fields to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public com.google.protobuf.FieldMask getUpdateMask() { - return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; - } - /** - * - * - *
-   * The fields to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { - return getUpdateMask(); - } - - 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 (occurrence_ != null) { - output.writeMessage(2, getOccurrence()); - } - if (updateMask_ != null) { - output.writeMessage(3, getUpdateMask()); - } - 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 (occurrence_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getOccurrence()); - } - if (updateMask_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getUpdateMask()); - } - 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 io.grafeas.v1beta1.UpdateOccurrenceRequest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.UpdateOccurrenceRequest other = - (io.grafeas.v1beta1.UpdateOccurrenceRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (hasOccurrence() != other.hasOccurrence()) return false; - if (hasOccurrence()) { - if (!getOccurrence().equals(other.getOccurrence())) return false; - } - if (hasUpdateMask() != other.hasUpdateMask()) return false; - if (hasUpdateMask()) { - if (!getUpdateMask().equals(other.getUpdateMask())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - if (hasOccurrence()) { - hash = (37 * hash) + OCCURRENCE_FIELD_NUMBER; - hash = (53 * hash) + getOccurrence().hashCode(); - } - if (hasUpdateMask()) { - hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; - hash = (53 * hash) + getUpdateMask().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.UpdateOccurrenceRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.UpdateOccurrenceRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.UpdateOccurrenceRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.UpdateOccurrenceRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.UpdateOccurrenceRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.UpdateOccurrenceRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.UpdateOccurrenceRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.UpdateOccurrenceRequest 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 io.grafeas.v1beta1.UpdateOccurrenceRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.UpdateOccurrenceRequest 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 io.grafeas.v1beta1.UpdateOccurrenceRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.UpdateOccurrenceRequest 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(io.grafeas.v1beta1.UpdateOccurrenceRequest 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 to update an occurrence.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.UpdateOccurrenceRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.UpdateOccurrenceRequest) - io.grafeas.v1beta1.UpdateOccurrenceRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_UpdateOccurrenceRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_UpdateOccurrenceRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.UpdateOccurrenceRequest.class, - io.grafeas.v1beta1.UpdateOccurrenceRequest.Builder.class); - } - - // Construct using io.grafeas.v1beta1.UpdateOccurrenceRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - if (occurrenceBuilder_ == null) { - occurrence_ = null; - } else { - occurrence_ = null; - occurrenceBuilder_ = null; - } - if (updateMaskBuilder_ == null) { - updateMask_ = null; - } else { - updateMask_ = null; - updateMaskBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_UpdateOccurrenceRequest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.UpdateOccurrenceRequest getDefaultInstanceForType() { - return io.grafeas.v1beta1.UpdateOccurrenceRequest.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.UpdateOccurrenceRequest build() { - io.grafeas.v1beta1.UpdateOccurrenceRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.UpdateOccurrenceRequest buildPartial() { - io.grafeas.v1beta1.UpdateOccurrenceRequest result = - new io.grafeas.v1beta1.UpdateOccurrenceRequest(this); - result.name_ = name_; - if (occurrenceBuilder_ == null) { - result.occurrence_ = occurrence_; - } else { - result.occurrence_ = occurrenceBuilder_.build(); - } - if (updateMaskBuilder_ == null) { - result.updateMask_ = updateMask_; - } else { - result.updateMask_ = updateMaskBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.UpdateOccurrenceRequest) { - return mergeFrom((io.grafeas.v1beta1.UpdateOccurrenceRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.UpdateOccurrenceRequest other) { - if (other == io.grafeas.v1beta1.UpdateOccurrenceRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (other.hasOccurrence()) { - mergeOccurrence(other.getOccurrence()); - } - if (other.hasUpdateMask()) { - mergeUpdateMask(other.getUpdateMask()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.UpdateOccurrenceRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.UpdateOccurrenceRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * 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 name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * 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 name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the occurrence in the form of
-     * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-     * 
- * - * 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 io.grafeas.v1beta1.Occurrence occurrence_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder> - occurrenceBuilder_; - /** - * - * - *
-     * The updated occurrence.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public boolean hasOccurrence() { - return occurrenceBuilder_ != null || occurrence_ != null; - } - /** - * - * - *
-     * The updated occurrence.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public io.grafeas.v1beta1.Occurrence getOccurrence() { - if (occurrenceBuilder_ == null) { - return occurrence_ == null - ? io.grafeas.v1beta1.Occurrence.getDefaultInstance() - : occurrence_; - } else { - return occurrenceBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The updated occurrence.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public Builder setOccurrence(io.grafeas.v1beta1.Occurrence value) { - if (occurrenceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - occurrence_ = value; - onChanged(); - } else { - occurrenceBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The updated occurrence.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public Builder setOccurrence(io.grafeas.v1beta1.Occurrence.Builder builderForValue) { - if (occurrenceBuilder_ == null) { - occurrence_ = builderForValue.build(); - onChanged(); - } else { - occurrenceBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The updated occurrence.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public Builder mergeOccurrence(io.grafeas.v1beta1.Occurrence value) { - if (occurrenceBuilder_ == null) { - if (occurrence_ != null) { - occurrence_ = - io.grafeas.v1beta1.Occurrence.newBuilder(occurrence_).mergeFrom(value).buildPartial(); - } else { - occurrence_ = value; - } - onChanged(); - } else { - occurrenceBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The updated occurrence.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public Builder clearOccurrence() { - if (occurrenceBuilder_ == null) { - occurrence_ = null; - onChanged(); - } else { - occurrence_ = null; - occurrenceBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The updated occurrence.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public io.grafeas.v1beta1.Occurrence.Builder getOccurrenceBuilder() { - - onChanged(); - return getOccurrenceFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The updated occurrence.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - public io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrenceOrBuilder() { - if (occurrenceBuilder_ != null) { - return occurrenceBuilder_.getMessageOrBuilder(); - } else { - return occurrence_ == null - ? io.grafeas.v1beta1.Occurrence.getDefaultInstance() - : occurrence_; - } - } - /** - * - * - *
-     * The updated occurrence.
-     * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder> - getOccurrenceFieldBuilder() { - if (occurrenceBuilder_ == null) { - occurrenceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Occurrence, - io.grafeas.v1beta1.Occurrence.Builder, - io.grafeas.v1beta1.OccurrenceOrBuilder>( - getOccurrence(), getParentForChildren(), isClean()); - occurrence_ = null; - } - return occurrenceBuilder_; - } - - private com.google.protobuf.FieldMask updateMask_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.FieldMask, - com.google.protobuf.FieldMask.Builder, - com.google.protobuf.FieldMaskOrBuilder> - updateMaskBuilder_; - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public boolean hasUpdateMask() { - return updateMaskBuilder_ != null || updateMask_ != null; - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public com.google.protobuf.FieldMask getUpdateMask() { - if (updateMaskBuilder_ == null) { - return updateMask_ == null - ? com.google.protobuf.FieldMask.getDefaultInstance() - : updateMask_; - } else { - return updateMaskBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public Builder setUpdateMask(com.google.protobuf.FieldMask value) { - if (updateMaskBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - updateMask_ = value; - onChanged(); - } else { - updateMaskBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { - if (updateMaskBuilder_ == null) { - updateMask_ = builderForValue.build(); - onChanged(); - } else { - updateMaskBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { - if (updateMaskBuilder_ == null) { - if (updateMask_ != null) { - updateMask_ = - com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial(); - } else { - updateMask_ = value; - } - onChanged(); - } else { - updateMaskBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public Builder clearUpdateMask() { - if (updateMaskBuilder_ == null) { - updateMask_ = null; - onChanged(); - } else { - updateMask_ = null; - updateMaskBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { - - onChanged(); - return getUpdateMaskFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { - if (updateMaskBuilder_ != null) { - return updateMaskBuilder_.getMessageOrBuilder(); - } else { - return updateMask_ == null - ? com.google.protobuf.FieldMask.getDefaultInstance() - : updateMask_; - } - } - /** - * - * - *
-     * The fields to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.FieldMask, - com.google.protobuf.FieldMask.Builder, - com.google.protobuf.FieldMaskOrBuilder> - getUpdateMaskFieldBuilder() { - if (updateMaskBuilder_ == null) { - updateMaskBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.FieldMask, - com.google.protobuf.FieldMask.Builder, - com.google.protobuf.FieldMaskOrBuilder>( - getUpdateMask(), getParentForChildren(), isClean()); - updateMask_ = null; - } - return updateMaskBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.UpdateOccurrenceRequest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.UpdateOccurrenceRequest) - private static final io.grafeas.v1beta1.UpdateOccurrenceRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.UpdateOccurrenceRequest(); - } - - public static io.grafeas.v1beta1.UpdateOccurrenceRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public UpdateOccurrenceRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new UpdateOccurrenceRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.UpdateOccurrenceRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateOccurrenceRequestOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateOccurrenceRequestOrBuilder.java deleted file mode 100644 index 4536559d..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/UpdateOccurrenceRequestOrBuilder.java +++ /dev/null @@ -1,95 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface UpdateOccurrenceRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.UpdateOccurrenceRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the occurrence in the form of
-   * `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * The updated occurrence.
-   * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - boolean hasOccurrence(); - /** - * - * - *
-   * The updated occurrence.
-   * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - io.grafeas.v1beta1.Occurrence getOccurrence(); - /** - * - * - *
-   * The updated occurrence.
-   * 
- * - * .grafeas.v1beta1.Occurrence occurrence = 2; - */ - io.grafeas.v1beta1.OccurrenceOrBuilder getOccurrenceOrBuilder(); - - /** - * - * - *
-   * The fields to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - boolean hasUpdateMask(); - /** - * - * - *
-   * The fields to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - com.google.protobuf.FieldMask getUpdateMask(); - /** - * - * - *
-   * The fields to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 3; - */ - com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/VulnerabilityOccurrencesSummary.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/VulnerabilityOccurrencesSummary.java deleted file mode 100644 index a5bd7391..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/VulnerabilityOccurrencesSummary.java +++ /dev/null @@ -1,2099 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -/** - * - * - *
- * A summary of how many vulnerability occurrences there are per resource and
- * severity type.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.VulnerabilityOccurrencesSummary} - */ -public final class VulnerabilityOccurrencesSummary extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.VulnerabilityOccurrencesSummary) - VulnerabilityOccurrencesSummaryOrBuilder { - private static final long serialVersionUID = 0L; - // Use VulnerabilityOccurrencesSummary.newBuilder() to construct. - private VulnerabilityOccurrencesSummary( - com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private VulnerabilityOccurrencesSummary() { - counts_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private VulnerabilityOccurrencesSummary( - 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: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - counts_ = - new java.util.ArrayList< - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest>(); - mutable_bitField0_ |= 0x00000001; - } - counts_.add( - input.readMessage( - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest - .parser(), - extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000001) != 0)) { - counts_ = java.util.Collections.unmodifiableList(counts_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.class, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.Builder.class); - } - - public interface FixableTotalByDigestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * The affected resource.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - boolean hasResource(); - /** - * - * - *
-     * The affected resource.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - io.grafeas.v1beta1.Resource getResource(); - /** - * - * - *
-     * The affected resource.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - io.grafeas.v1beta1.ResourceOrBuilder getResourceOrBuilder(); - - /** - * - * - *
-     * The severity for this count. SEVERITY_UNSPECIFIED indicates total across
-     * all severities.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - int getSeverityValue(); - /** - * - * - *
-     * The severity for this count. SEVERITY_UNSPECIFIED indicates total across
-     * all severities.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - io.grafeas.v1beta1.vulnerability.Severity getSeverity(); - - /** - * - * - *
-     * The number of fixable vulnerabilities associated with this resource.
-     * 
- * - * int64 fixable_count = 3; - */ - long getFixableCount(); - - /** - * - * - *
-     * The total number of vulnerabilities associated with this resource.
-     * 
- * - * int64 total_count = 4; - */ - long getTotalCount(); - } - /** - * - * - *
-   * Per resource and severity counts of fixable and total vulnerabilites.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest} - */ - public static final class FixableTotalByDigest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest) - FixableTotalByDigestOrBuilder { - private static final long serialVersionUID = 0L; - // Use FixableTotalByDigest.newBuilder() to construct. - private FixableTotalByDigest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private FixableTotalByDigest() { - severity_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private FixableTotalByDigest( - 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: - { - io.grafeas.v1beta1.Resource.Builder subBuilder = null; - if (resource_ != null) { - subBuilder = resource_.toBuilder(); - } - resource_ = - input.readMessage(io.grafeas.v1beta1.Resource.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(resource_); - resource_ = subBuilder.buildPartial(); - } - - break; - } - case 16: - { - int rawValue = input.readEnum(); - - severity_ = rawValue; - break; - } - case 24: - { - fixableCount_ = input.readInt64(); - break; - } - case 32: - { - totalCount_ = input.readInt64(); - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_FixableTotalByDigest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_FixableTotalByDigest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.class, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.Builder - .class); - } - - public static final int RESOURCE_FIELD_NUMBER = 1; - private io.grafeas.v1beta1.Resource resource_; - /** - * - * - *
-     * The affected resource.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - public boolean hasResource() { - return resource_ != null; - } - /** - * - * - *
-     * The affected resource.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - public io.grafeas.v1beta1.Resource getResource() { - return resource_ == null ? io.grafeas.v1beta1.Resource.getDefaultInstance() : resource_; - } - /** - * - * - *
-     * The affected resource.
-     * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - public io.grafeas.v1beta1.ResourceOrBuilder getResourceOrBuilder() { - return getResource(); - } - - public static final int SEVERITY_FIELD_NUMBER = 2; - private int severity_; - /** - * - * - *
-     * The severity for this count. SEVERITY_UNSPECIFIED indicates total across
-     * all severities.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public int getSeverityValue() { - return severity_; - } - /** - * - * - *
-     * The severity for this count. SEVERITY_UNSPECIFIED indicates total across
-     * all severities.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public io.grafeas.v1beta1.vulnerability.Severity getSeverity() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.vulnerability.Severity result = - io.grafeas.v1beta1.vulnerability.Severity.valueOf(severity_); - return result == null ? io.grafeas.v1beta1.vulnerability.Severity.UNRECOGNIZED : result; - } - - public static final int FIXABLE_COUNT_FIELD_NUMBER = 3; - private long fixableCount_; - /** - * - * - *
-     * The number of fixable vulnerabilities associated with this resource.
-     * 
- * - * int64 fixable_count = 3; - */ - public long getFixableCount() { - return fixableCount_; - } - - public static final int TOTAL_COUNT_FIELD_NUMBER = 4; - private long totalCount_; - /** - * - * - *
-     * The total number of vulnerabilities associated with this resource.
-     * 
- * - * int64 total_count = 4; - */ - public long getTotalCount() { - return totalCount_; - } - - 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 (resource_ != null) { - output.writeMessage(1, getResource()); - } - if (severity_ != io.grafeas.v1beta1.vulnerability.Severity.SEVERITY_UNSPECIFIED.getNumber()) { - output.writeEnum(2, severity_); - } - if (fixableCount_ != 0L) { - output.writeInt64(3, fixableCount_); - } - if (totalCount_ != 0L) { - output.writeInt64(4, totalCount_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (resource_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getResource()); - } - if (severity_ != io.grafeas.v1beta1.vulnerability.Severity.SEVERITY_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, severity_); - } - if (fixableCount_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(3, fixableCount_); - } - if (totalCount_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(4, totalCount_); - } - 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 io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest)) { - return super.equals(obj); - } - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest other = - (io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest) obj; - - if (hasResource() != other.hasResource()) return false; - if (hasResource()) { - if (!getResource().equals(other.getResource())) return false; - } - if (severity_ != other.severity_) return false; - if (getFixableCount() != other.getFixableCount()) return false; - if (getTotalCount() != other.getTotalCount()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasResource()) { - hash = (37 * hash) + RESOURCE_FIELD_NUMBER; - hash = (53 * hash) + getResource().hashCode(); - } - hash = (37 * hash) + SEVERITY_FIELD_NUMBER; - hash = (53 * hash) + severity_; - hash = (37 * hash) + FIXABLE_COUNT_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getFixableCount()); - hash = (37 * hash) + TOTAL_COUNT_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTotalCount()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest 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 io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest - parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest - 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 io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest 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( - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest 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; - } - /** - * - * - *
-     * Per resource and severity counts of fixable and total vulnerabilites.
-     * 
- * - * Protobuf type {@code grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest) - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_FixableTotalByDigest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_FixableTotalByDigest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.class, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.Builder - .class); - } - - // Construct using - // io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (resourceBuilder_ == null) { - resource_ = null; - } else { - resource_ = null; - resourceBuilder_ = null; - } - severity_ = 0; - - fixableCount_ = 0L; - - totalCount_ = 0L; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_FixableTotalByDigest_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest - getDefaultInstanceForType() { - return io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest - .getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest build() { - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest result = - buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest - buildPartial() { - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest result = - new io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest(this); - if (resourceBuilder_ == null) { - result.resource_ = resource_; - } else { - result.resource_ = resourceBuilder_.build(); - } - result.severity_ = severity_; - result.fixableCount_ = fixableCount_; - result.totalCount_ = totalCount_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other - instanceof io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest) { - return mergeFrom( - (io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom( - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest other) { - if (other - == io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest - .getDefaultInstance()) return this; - if (other.hasResource()) { - mergeResource(other.getResource()); - } - if (other.severity_ != 0) { - setSeverityValue(other.getSeverityValue()); - } - if (other.getFixableCount() != 0L) { - setFixableCount(other.getFixableCount()); - } - if (other.getTotalCount() != 0L) { - setTotalCount(other.getTotalCount()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest parsedMessage = - null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private io.grafeas.v1beta1.Resource resource_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Resource, - io.grafeas.v1beta1.Resource.Builder, - io.grafeas.v1beta1.ResourceOrBuilder> - resourceBuilder_; - /** - * - * - *
-       * The affected resource.
-       * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - public boolean hasResource() { - return resourceBuilder_ != null || resource_ != null; - } - /** - * - * - *
-       * The affected resource.
-       * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - public io.grafeas.v1beta1.Resource getResource() { - if (resourceBuilder_ == null) { - return resource_ == null ? io.grafeas.v1beta1.Resource.getDefaultInstance() : resource_; - } else { - return resourceBuilder_.getMessage(); - } - } - /** - * - * - *
-       * The affected resource.
-       * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - public Builder setResource(io.grafeas.v1beta1.Resource value) { - if (resourceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - resource_ = value; - onChanged(); - } else { - resourceBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * The affected resource.
-       * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - public Builder setResource(io.grafeas.v1beta1.Resource.Builder builderForValue) { - if (resourceBuilder_ == null) { - resource_ = builderForValue.build(); - onChanged(); - } else { - resourceBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * The affected resource.
-       * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - public Builder mergeResource(io.grafeas.v1beta1.Resource value) { - if (resourceBuilder_ == null) { - if (resource_ != null) { - resource_ = - io.grafeas.v1beta1.Resource.newBuilder(resource_).mergeFrom(value).buildPartial(); - } else { - resource_ = value; - } - onChanged(); - } else { - resourceBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * The affected resource.
-       * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - public Builder clearResource() { - if (resourceBuilder_ == null) { - resource_ = null; - onChanged(); - } else { - resource_ = null; - resourceBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * The affected resource.
-       * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - public io.grafeas.v1beta1.Resource.Builder getResourceBuilder() { - - onChanged(); - return getResourceFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * The affected resource.
-       * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - public io.grafeas.v1beta1.ResourceOrBuilder getResourceOrBuilder() { - if (resourceBuilder_ != null) { - return resourceBuilder_.getMessageOrBuilder(); - } else { - return resource_ == null ? io.grafeas.v1beta1.Resource.getDefaultInstance() : resource_; - } - } - /** - * - * - *
-       * The affected resource.
-       * 
- * - * .grafeas.v1beta1.Resource resource = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Resource, - io.grafeas.v1beta1.Resource.Builder, - io.grafeas.v1beta1.ResourceOrBuilder> - getResourceFieldBuilder() { - if (resourceBuilder_ == null) { - resourceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.Resource, - io.grafeas.v1beta1.Resource.Builder, - io.grafeas.v1beta1.ResourceOrBuilder>( - getResource(), getParentForChildren(), isClean()); - resource_ = null; - } - return resourceBuilder_; - } - - private int severity_ = 0; - /** - * - * - *
-       * The severity for this count. SEVERITY_UNSPECIFIED indicates total across
-       * all severities.
-       * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public int getSeverityValue() { - return severity_; - } - /** - * - * - *
-       * The severity for this count. SEVERITY_UNSPECIFIED indicates total across
-       * all severities.
-       * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public Builder setSeverityValue(int value) { - severity_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The severity for this count. SEVERITY_UNSPECIFIED indicates total across
-       * all severities.
-       * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public io.grafeas.v1beta1.vulnerability.Severity getSeverity() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.vulnerability.Severity result = - io.grafeas.v1beta1.vulnerability.Severity.valueOf(severity_); - return result == null ? io.grafeas.v1beta1.vulnerability.Severity.UNRECOGNIZED : result; - } - /** - * - * - *
-       * The severity for this count. SEVERITY_UNSPECIFIED indicates total across
-       * all severities.
-       * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public Builder setSeverity(io.grafeas.v1beta1.vulnerability.Severity value) { - if (value == null) { - throw new NullPointerException(); - } - - severity_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * The severity for this count. SEVERITY_UNSPECIFIED indicates total across
-       * all severities.
-       * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public Builder clearSeverity() { - - severity_ = 0; - onChanged(); - return this; - } - - private long fixableCount_; - /** - * - * - *
-       * The number of fixable vulnerabilities associated with this resource.
-       * 
- * - * int64 fixable_count = 3; - */ - public long getFixableCount() { - return fixableCount_; - } - /** - * - * - *
-       * The number of fixable vulnerabilities associated with this resource.
-       * 
- * - * int64 fixable_count = 3; - */ - public Builder setFixableCount(long value) { - - fixableCount_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The number of fixable vulnerabilities associated with this resource.
-       * 
- * - * int64 fixable_count = 3; - */ - public Builder clearFixableCount() { - - fixableCount_ = 0L; - onChanged(); - return this; - } - - private long totalCount_; - /** - * - * - *
-       * The total number of vulnerabilities associated with this resource.
-       * 
- * - * int64 total_count = 4; - */ - public long getTotalCount() { - return totalCount_; - } - /** - * - * - *
-       * The total number of vulnerabilities associated with this resource.
-       * 
- * - * int64 total_count = 4; - */ - public Builder setTotalCount(long value) { - - totalCount_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The total number of vulnerabilities associated with this resource.
-       * 
- * - * int64 total_count = 4; - */ - public Builder clearTotalCount() { - - totalCount_ = 0L; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest) - private static final io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = - new io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest(); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public FixableTotalByDigest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new FixableTotalByDigest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public static final int COUNTS_FIELD_NUMBER = 1; - private java.util.List - counts_; - /** - * - * - *
-   * A listing by resource of the number of fixable and total vulnerabilities.
-   * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public java.util.List - getCountsList() { - return counts_; - } - /** - * - * - *
-   * A listing by resource of the number of fixable and total vulnerabilities.
-   * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public java.util.List< - ? extends - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigestOrBuilder> - getCountsOrBuilderList() { - return counts_; - } - /** - * - * - *
-   * A listing by resource of the number of fixable and total vulnerabilities.
-   * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public int getCountsCount() { - return counts_.size(); - } - /** - * - * - *
-   * A listing by resource of the number of fixable and total vulnerabilities.
-   * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest getCounts( - int index) { - return counts_.get(index); - } - /** - * - * - *
-   * A listing by resource of the number of fixable and total vulnerabilities.
-   * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigestOrBuilder - getCountsOrBuilder(int index) { - return counts_.get(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 { - for (int i = 0; i < counts_.size(); i++) { - output.writeMessage(1, counts_.get(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < counts_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, counts_.get(i)); - } - 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 io.grafeas.v1beta1.VulnerabilityOccurrencesSummary)) { - return super.equals(obj); - } - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary other = - (io.grafeas.v1beta1.VulnerabilityOccurrencesSummary) obj; - - if (!getCountsList().equals(other.getCountsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getCountsCount() > 0) { - hash = (37 * hash) + COUNTS_FIELD_NUMBER; - hash = (53 * hash) + getCountsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary 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 io.grafeas.v1beta1.VulnerabilityOccurrencesSummary parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary 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 io.grafeas.v1beta1.VulnerabilityOccurrencesSummary parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary 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(io.grafeas.v1beta1.VulnerabilityOccurrencesSummary prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A summary of how many vulnerability occurrences there are per resource and
-   * severity type.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.VulnerabilityOccurrencesSummary} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.VulnerabilityOccurrencesSummary) - io.grafeas.v1beta1.VulnerabilityOccurrencesSummaryOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.class, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.Builder.class); - } - - // Construct using io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getCountsFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (countsBuilder_ == null) { - counts_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - countsBuilder_.clear(); - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.Grafeas - .internal_static_grafeas_v1beta1_VulnerabilityOccurrencesSummary_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary getDefaultInstanceForType() { - return io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary build() { - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary buildPartial() { - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary result = - new io.grafeas.v1beta1.VulnerabilityOccurrencesSummary(this); - int from_bitField0_ = bitField0_; - if (countsBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - counts_ = java.util.Collections.unmodifiableList(counts_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.counts_ = counts_; - } else { - result.counts_ = countsBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.VulnerabilityOccurrencesSummary) { - return mergeFrom((io.grafeas.v1beta1.VulnerabilityOccurrencesSummary) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.VulnerabilityOccurrencesSummary other) { - if (other == io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.getDefaultInstance()) - return this; - if (countsBuilder_ == null) { - if (!other.counts_.isEmpty()) { - if (counts_.isEmpty()) { - counts_ = other.counts_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureCountsIsMutable(); - counts_.addAll(other.counts_); - } - onChanged(); - } - } else { - if (!other.counts_.isEmpty()) { - if (countsBuilder_.isEmpty()) { - countsBuilder_.dispose(); - countsBuilder_ = null; - counts_ = other.counts_; - bitField0_ = (bitField0_ & ~0x00000001); - countsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getCountsFieldBuilder() - : null; - } else { - countsBuilder_.addAllMessages(other.counts_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (io.grafeas.v1beta1.VulnerabilityOccurrencesSummary) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.util.List - counts_ = java.util.Collections.emptyList(); - - private void ensureCountsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - counts_ = - new java.util.ArrayList< - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest>(counts_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.Builder, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigestOrBuilder> - countsBuilder_; - - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public java.util.List - getCountsList() { - if (countsBuilder_ == null) { - return java.util.Collections.unmodifiableList(counts_); - } else { - return countsBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public int getCountsCount() { - if (countsBuilder_ == null) { - return counts_.size(); - } else { - return countsBuilder_.getCount(); - } - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest getCounts( - int index) { - if (countsBuilder_ == null) { - return counts_.get(index); - } else { - return countsBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public Builder setCounts( - int index, io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest value) { - if (countsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCountsIsMutable(); - counts_.set(index, value); - onChanged(); - } else { - countsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public Builder setCounts( - int index, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.Builder - builderForValue) { - if (countsBuilder_ == null) { - ensureCountsIsMutable(); - counts_.set(index, builderForValue.build()); - onChanged(); - } else { - countsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public Builder addCounts( - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest value) { - if (countsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCountsIsMutable(); - counts_.add(value); - onChanged(); - } else { - countsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public Builder addCounts( - int index, io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest value) { - if (countsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCountsIsMutable(); - counts_.add(index, value); - onChanged(); - } else { - countsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public Builder addCounts( - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.Builder - builderForValue) { - if (countsBuilder_ == null) { - ensureCountsIsMutable(); - counts_.add(builderForValue.build()); - onChanged(); - } else { - countsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public Builder addCounts( - int index, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.Builder - builderForValue) { - if (countsBuilder_ == null) { - ensureCountsIsMutable(); - counts_.add(index, builderForValue.build()); - onChanged(); - } else { - countsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public Builder addAllCounts( - java.lang.Iterable< - ? extends io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest> - values) { - if (countsBuilder_ == null) { - ensureCountsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, counts_); - onChanged(); - } else { - countsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public Builder clearCounts() { - if (countsBuilder_ == null) { - counts_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - countsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public Builder removeCounts(int index) { - if (countsBuilder_ == null) { - ensureCountsIsMutable(); - counts_.remove(index); - onChanged(); - } else { - countsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.Builder - getCountsBuilder(int index) { - return getCountsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigestOrBuilder - getCountsOrBuilder(int index) { - if (countsBuilder_ == null) { - return counts_.get(index); - } else { - return countsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public java.util.List< - ? extends - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigestOrBuilder> - getCountsOrBuilderList() { - if (countsBuilder_ != null) { - return countsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(counts_); - } - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.Builder - addCountsBuilder() { - return getCountsFieldBuilder() - .addBuilder( - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest - .getDefaultInstance()); - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.Builder - addCountsBuilder(int index) { - return getCountsFieldBuilder() - .addBuilder( - index, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest - .getDefaultInstance()); - } - /** - * - * - *
-     * A listing by resource of the number of fixable and total vulnerabilities.
-     * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - public java.util.List< - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.Builder> - getCountsBuilderList() { - return getCountsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.Builder, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigestOrBuilder> - getCountsFieldBuilder() { - if (countsBuilder_ == null) { - countsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest.Builder, - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigestOrBuilder>( - counts_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - counts_ = null; - } - return countsBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.VulnerabilityOccurrencesSummary) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.VulnerabilityOccurrencesSummary) - private static final io.grafeas.v1beta1.VulnerabilityOccurrencesSummary DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.VulnerabilityOccurrencesSummary(); - } - - public static io.grafeas.v1beta1.VulnerabilityOccurrencesSummary getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public VulnerabilityOccurrencesSummary parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new VulnerabilityOccurrencesSummary(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.VulnerabilityOccurrencesSummary getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/VulnerabilityOccurrencesSummaryOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/VulnerabilityOccurrencesSummaryOrBuilder.java deleted file mode 100644 index c7216c96..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/VulnerabilityOccurrencesSummaryOrBuilder.java +++ /dev/null @@ -1,76 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto - -package io.grafeas.v1beta1; - -public interface VulnerabilityOccurrencesSummaryOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.VulnerabilityOccurrencesSummary) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * A listing by resource of the number of fixable and total vulnerabilities.
-   * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - java.util.List - getCountsList(); - /** - * - * - *
-   * A listing by resource of the number of fixable and total vulnerabilities.
-   * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest getCounts(int index); - /** - * - * - *
-   * A listing by resource of the number of fixable and total vulnerabilities.
-   * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - int getCountsCount(); - /** - * - * - *
-   * A listing by resource of the number of fixable and total vulnerabilities.
-   * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - java.util.List< - ? extends - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigestOrBuilder> - getCountsOrBuilderList(); - /** - * - * - *
-   * A listing by resource of the number of fixable and total vulnerabilities.
-   * 
- * - * - * repeated .grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigest counts = 1; - * - */ - io.grafeas.v1beta1.VulnerabilityOccurrencesSummary.FixableTotalByDigestOrBuilder - getCountsOrBuilder(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/Attestation.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/Attestation.java deleted file mode 100644 index 574901d1..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/Attestation.java +++ /dev/null @@ -1,815 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/attestation/attestation.proto - -package io.grafeas.v1beta1.attestation; - -/** - * - * - *
- * Occurrence that represents a single "attestation". The authenticity of an
- * Attestation can be verified using the attached signature. If the verifier
- * trusts the public key of the signer, then verifying the signature is
- * sufficient to establish trust. In this circumstance, the Authority to which
- * this Attestation is attached is primarily useful for look-up (how to find
- * this Attestation if you already know the Authority and artifact to be
- * verified) and intent (which authority was this attestation intended to sign
- * for).
- * 
- * - * Protobuf type {@code grafeas.v1beta1.attestation.Attestation} - */ -public final class Attestation extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.attestation.Attestation) - AttestationOrBuilder { - private static final long serialVersionUID = 0L; - // Use Attestation.newBuilder() to construct. - private Attestation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Attestation() {} - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Attestation( - 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: - { - io.grafeas.v1beta1.attestation.PgpSignedAttestation.Builder subBuilder = null; - if (signatureCase_ == 1) { - subBuilder = - ((io.grafeas.v1beta1.attestation.PgpSignedAttestation) signature_).toBuilder(); - } - signature_ = - input.readMessage( - io.grafeas.v1beta1.attestation.PgpSignedAttestation.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (io.grafeas.v1beta1.attestation.PgpSignedAttestation) signature_); - signature_ = subBuilder.buildPartial(); - } - signatureCase_ = 1; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Attestation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Attestation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.attestation.Attestation.class, - io.grafeas.v1beta1.attestation.Attestation.Builder.class); - } - - private int signatureCase_ = 0; - private java.lang.Object signature_; - - public enum SignatureCase implements com.google.protobuf.Internal.EnumLite { - PGP_SIGNED_ATTESTATION(1), - SIGNATURE_NOT_SET(0); - private final int value; - - private SignatureCase(int value) { - this.value = value; - } - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static SignatureCase valueOf(int value) { - return forNumber(value); - } - - public static SignatureCase forNumber(int value) { - switch (value) { - case 1: - return PGP_SIGNED_ATTESTATION; - case 0: - return SIGNATURE_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public SignatureCase getSignatureCase() { - return SignatureCase.forNumber(signatureCase_); - } - - public static final int PGP_SIGNED_ATTESTATION_FIELD_NUMBER = 1; - /** - * - * - *
-   * A PGP signed attestation.
-   * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - public boolean hasPgpSignedAttestation() { - return signatureCase_ == 1; - } - /** - * - * - *
-   * A PGP signed attestation.
-   * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - public io.grafeas.v1beta1.attestation.PgpSignedAttestation getPgpSignedAttestation() { - if (signatureCase_ == 1) { - return (io.grafeas.v1beta1.attestation.PgpSignedAttestation) signature_; - } - return io.grafeas.v1beta1.attestation.PgpSignedAttestation.getDefaultInstance(); - } - /** - * - * - *
-   * A PGP signed attestation.
-   * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - public io.grafeas.v1beta1.attestation.PgpSignedAttestationOrBuilder - getPgpSignedAttestationOrBuilder() { - if (signatureCase_ == 1) { - return (io.grafeas.v1beta1.attestation.PgpSignedAttestation) signature_; - } - return io.grafeas.v1beta1.attestation.PgpSignedAttestation.getDefaultInstance(); - } - - 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 (signatureCase_ == 1) { - output.writeMessage(1, (io.grafeas.v1beta1.attestation.PgpSignedAttestation) signature_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (signatureCase_ == 1) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 1, (io.grafeas.v1beta1.attestation.PgpSignedAttestation) signature_); - } - 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 io.grafeas.v1beta1.attestation.Attestation)) { - return super.equals(obj); - } - io.grafeas.v1beta1.attestation.Attestation other = - (io.grafeas.v1beta1.attestation.Attestation) obj; - - if (!getSignatureCase().equals(other.getSignatureCase())) return false; - switch (signatureCase_) { - case 1: - if (!getPgpSignedAttestation().equals(other.getPgpSignedAttestation())) return false; - break; - case 0: - default: - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (signatureCase_) { - case 1: - hash = (37 * hash) + PGP_SIGNED_ATTESTATION_FIELD_NUMBER; - hash = (53 * hash) + getPgpSignedAttestation().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.attestation.Attestation parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.Attestation parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.Attestation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.Attestation parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.Attestation parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.Attestation parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.Attestation parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.Attestation 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 io.grafeas.v1beta1.attestation.Attestation parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.Attestation 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 io.grafeas.v1beta1.attestation.Attestation parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.Attestation 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(io.grafeas.v1beta1.attestation.Attestation 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; - } - /** - * - * - *
-   * Occurrence that represents a single "attestation". The authenticity of an
-   * Attestation can be verified using the attached signature. If the verifier
-   * trusts the public key of the signer, then verifying the signature is
-   * sufficient to establish trust. In this circumstance, the Authority to which
-   * this Attestation is attached is primarily useful for look-up (how to find
-   * this Attestation if you already know the Authority and artifact to be
-   * verified) and intent (which authority was this attestation intended to sign
-   * for).
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.attestation.Attestation} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.attestation.Attestation) - io.grafeas.v1beta1.attestation.AttestationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Attestation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Attestation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.attestation.Attestation.class, - io.grafeas.v1beta1.attestation.Attestation.Builder.class); - } - - // Construct using io.grafeas.v1beta1.attestation.Attestation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - signatureCase_ = 0; - signature_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Attestation_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Attestation getDefaultInstanceForType() { - return io.grafeas.v1beta1.attestation.Attestation.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Attestation build() { - io.grafeas.v1beta1.attestation.Attestation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Attestation buildPartial() { - io.grafeas.v1beta1.attestation.Attestation result = - new io.grafeas.v1beta1.attestation.Attestation(this); - if (signatureCase_ == 1) { - if (pgpSignedAttestationBuilder_ == null) { - result.signature_ = signature_; - } else { - result.signature_ = pgpSignedAttestationBuilder_.build(); - } - } - result.signatureCase_ = signatureCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.attestation.Attestation) { - return mergeFrom((io.grafeas.v1beta1.attestation.Attestation) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.attestation.Attestation other) { - if (other == io.grafeas.v1beta1.attestation.Attestation.getDefaultInstance()) return this; - switch (other.getSignatureCase()) { - case PGP_SIGNED_ATTESTATION: - { - mergePgpSignedAttestation(other.getPgpSignedAttestation()); - break; - } - case SIGNATURE_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.attestation.Attestation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.attestation.Attestation) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int signatureCase_ = 0; - private java.lang.Object signature_; - - public SignatureCase getSignatureCase() { - return SignatureCase.forNumber(signatureCase_); - } - - public Builder clearSignature() { - signatureCase_ = 0; - signature_ = null; - onChanged(); - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.PgpSignedAttestation, - io.grafeas.v1beta1.attestation.PgpSignedAttestation.Builder, - io.grafeas.v1beta1.attestation.PgpSignedAttestationOrBuilder> - pgpSignedAttestationBuilder_; - /** - * - * - *
-     * A PGP signed attestation.
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - public boolean hasPgpSignedAttestation() { - return signatureCase_ == 1; - } - /** - * - * - *
-     * A PGP signed attestation.
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - public io.grafeas.v1beta1.attestation.PgpSignedAttestation getPgpSignedAttestation() { - if (pgpSignedAttestationBuilder_ == null) { - if (signatureCase_ == 1) { - return (io.grafeas.v1beta1.attestation.PgpSignedAttestation) signature_; - } - return io.grafeas.v1beta1.attestation.PgpSignedAttestation.getDefaultInstance(); - } else { - if (signatureCase_ == 1) { - return pgpSignedAttestationBuilder_.getMessage(); - } - return io.grafeas.v1beta1.attestation.PgpSignedAttestation.getDefaultInstance(); - } - } - /** - * - * - *
-     * A PGP signed attestation.
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - public Builder setPgpSignedAttestation( - io.grafeas.v1beta1.attestation.PgpSignedAttestation value) { - if (pgpSignedAttestationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - signature_ = value; - onChanged(); - } else { - pgpSignedAttestationBuilder_.setMessage(value); - } - signatureCase_ = 1; - return this; - } - /** - * - * - *
-     * A PGP signed attestation.
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - public Builder setPgpSignedAttestation( - io.grafeas.v1beta1.attestation.PgpSignedAttestation.Builder builderForValue) { - if (pgpSignedAttestationBuilder_ == null) { - signature_ = builderForValue.build(); - onChanged(); - } else { - pgpSignedAttestationBuilder_.setMessage(builderForValue.build()); - } - signatureCase_ = 1; - return this; - } - /** - * - * - *
-     * A PGP signed attestation.
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - public Builder mergePgpSignedAttestation( - io.grafeas.v1beta1.attestation.PgpSignedAttestation value) { - if (pgpSignedAttestationBuilder_ == null) { - if (signatureCase_ == 1 - && signature_ - != io.grafeas.v1beta1.attestation.PgpSignedAttestation.getDefaultInstance()) { - signature_ = - io.grafeas.v1beta1.attestation.PgpSignedAttestation.newBuilder( - (io.grafeas.v1beta1.attestation.PgpSignedAttestation) signature_) - .mergeFrom(value) - .buildPartial(); - } else { - signature_ = value; - } - onChanged(); - } else { - if (signatureCase_ == 1) { - pgpSignedAttestationBuilder_.mergeFrom(value); - } - pgpSignedAttestationBuilder_.setMessage(value); - } - signatureCase_ = 1; - return this; - } - /** - * - * - *
-     * A PGP signed attestation.
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - public Builder clearPgpSignedAttestation() { - if (pgpSignedAttestationBuilder_ == null) { - if (signatureCase_ == 1) { - signatureCase_ = 0; - signature_ = null; - onChanged(); - } - } else { - if (signatureCase_ == 1) { - signatureCase_ = 0; - signature_ = null; - } - pgpSignedAttestationBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A PGP signed attestation.
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - public io.grafeas.v1beta1.attestation.PgpSignedAttestation.Builder - getPgpSignedAttestationBuilder() { - return getPgpSignedAttestationFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A PGP signed attestation.
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - public io.grafeas.v1beta1.attestation.PgpSignedAttestationOrBuilder - getPgpSignedAttestationOrBuilder() { - if ((signatureCase_ == 1) && (pgpSignedAttestationBuilder_ != null)) { - return pgpSignedAttestationBuilder_.getMessageOrBuilder(); - } else { - if (signatureCase_ == 1) { - return (io.grafeas.v1beta1.attestation.PgpSignedAttestation) signature_; - } - return io.grafeas.v1beta1.attestation.PgpSignedAttestation.getDefaultInstance(); - } - } - /** - * - * - *
-     * A PGP signed attestation.
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.PgpSignedAttestation, - io.grafeas.v1beta1.attestation.PgpSignedAttestation.Builder, - io.grafeas.v1beta1.attestation.PgpSignedAttestationOrBuilder> - getPgpSignedAttestationFieldBuilder() { - if (pgpSignedAttestationBuilder_ == null) { - if (!(signatureCase_ == 1)) { - signature_ = io.grafeas.v1beta1.attestation.PgpSignedAttestation.getDefaultInstance(); - } - pgpSignedAttestationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.PgpSignedAttestation, - io.grafeas.v1beta1.attestation.PgpSignedAttestation.Builder, - io.grafeas.v1beta1.attestation.PgpSignedAttestationOrBuilder>( - (io.grafeas.v1beta1.attestation.PgpSignedAttestation) signature_, - getParentForChildren(), - isClean()); - signature_ = null; - } - signatureCase_ = 1; - onChanged(); - ; - return pgpSignedAttestationBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.attestation.Attestation) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.attestation.Attestation) - private static final io.grafeas.v1beta1.attestation.Attestation DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.attestation.Attestation(); - } - - public static io.grafeas.v1beta1.attestation.Attestation getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Attestation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Attestation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Attestation getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/AttestationOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/AttestationOrBuilder.java deleted file mode 100644 index 2a555c8b..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/AttestationOrBuilder.java +++ /dev/null @@ -1,43 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/attestation/attestation.proto - -package io.grafeas.v1beta1.attestation; - -public interface AttestationOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.attestation.Attestation) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * A PGP signed attestation.
-   * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - boolean hasPgpSignedAttestation(); - /** - * - * - *
-   * A PGP signed attestation.
-   * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - io.grafeas.v1beta1.attestation.PgpSignedAttestation getPgpSignedAttestation(); - /** - * - * - *
-   * A PGP signed attestation.
-   * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation pgp_signed_attestation = 1; - */ - io.grafeas.v1beta1.attestation.PgpSignedAttestationOrBuilder getPgpSignedAttestationOrBuilder(); - - public io.grafeas.v1beta1.attestation.Attestation.SignatureCase getSignatureCase(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/AttestationOuterClass.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/AttestationOuterClass.java deleted file mode 100644 index d3727183..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/AttestationOuterClass.java +++ /dev/null @@ -1,118 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/attestation/attestation.proto - -package io.grafeas.v1beta1.attestation; - -public final class AttestationOuterClass { - private AttestationOuterClass() {} - - 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_grafeas_v1beta1_attestation_PgpSignedAttestation_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_attestation_PgpSignedAttestation_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_attestation_Authority_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_attestation_Authority_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_attestation_Authority_Hint_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_attestation_Authority_Hint_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_attestation_Details_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_attestation_Details_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_attestation_Attestation_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_attestation_Attestation_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { - return descriptor; - } - - private static com.google.protobuf.Descriptors.FileDescriptor descriptor; - - static { - java.lang.String[] descriptorData = { - "\nGgoogle/devtools/containeranalysis/v1be" - + "ta1/attestation/attestation.proto\022\033grafe" - + "as.v1beta1.attestation\"\344\001\n\024PgpSignedAtte" - + "station\022\021\n\tsignature\030\001 \001(\t\022S\n\014content_ty" - + "pe\030\003 \001(\0162=.grafeas.v1beta1.attestation.P" - + "gpSignedAttestation.ContentType\022\024\n\npgp_k" - + "ey_id\030\002 \001(\tH\000\"D\n\013ContentType\022\034\n\030CONTENT_" - + "TYPE_UNSPECIFIED\020\000\022\027\n\023SIMPLE_SIGNING_JSO" - + "N\020\001B\010\n\006key_id\"k\n\tAuthority\0229\n\004hint\030\001 \001(\013" - + "2+.grafeas.v1beta1.attestation.Authority" - + ".Hint\032#\n\004Hint\022\033\n\023human_readable_name\030\001 \001" - + "(\t\"H\n\007Details\022=\n\013attestation\030\001 \001(\0132(.gra" - + "feas.v1beta1.attestation.Attestation\"o\n\013" - + "Attestation\022S\n\026pgp_signed_attestation\030\001 " - + "\001(\01321.grafeas.v1beta1.attestation.PgpSig" - + "nedAttestationH\000B\013\n\tsignatureB\212\001\n\036io.gra" - + "feas.v1beta1.attestationP\001Z`google.golan" - + "g.org/genproto/googleapis/devtools/conta" - + "ineranalysis/v1beta1/attestation;attesta" - + "tion\242\002\003GRAb\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[] {}, assigner); - internal_static_grafeas_v1beta1_attestation_PgpSignedAttestation_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_grafeas_v1beta1_attestation_PgpSignedAttestation_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_attestation_PgpSignedAttestation_descriptor, - new java.lang.String[] { - "Signature", "ContentType", "PgpKeyId", "KeyId", - }); - internal_static_grafeas_v1beta1_attestation_Authority_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_grafeas_v1beta1_attestation_Authority_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_attestation_Authority_descriptor, - new java.lang.String[] { - "Hint", - }); - internal_static_grafeas_v1beta1_attestation_Authority_Hint_descriptor = - internal_static_grafeas_v1beta1_attestation_Authority_descriptor.getNestedTypes().get(0); - internal_static_grafeas_v1beta1_attestation_Authority_Hint_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_attestation_Authority_Hint_descriptor, - new java.lang.String[] { - "HumanReadableName", - }); - internal_static_grafeas_v1beta1_attestation_Details_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_grafeas_v1beta1_attestation_Details_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_attestation_Details_descriptor, - new java.lang.String[] { - "Attestation", - }); - internal_static_grafeas_v1beta1_attestation_Attestation_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_grafeas_v1beta1_attestation_Attestation_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_attestation_Attestation_descriptor, - new java.lang.String[] { - "PgpSignedAttestation", "Signature", - }); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/Authority.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/Authority.java deleted file mode 100644 index 04dc3996..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/Authority.java +++ /dev/null @@ -1,1349 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/attestation/attestation.proto - -package io.grafeas.v1beta1.attestation; - -/** - * - * - *
- * Note kind that represents a logical attestation "role" or "authority". For
- * example, an organization might have one `Authority` for "QA" and one for
- * "build". This Note is intended to act strictly as a grouping mechanism for
- * the attached Occurrences (Attestations). This grouping mechanism also
- * provides a security boundary, since IAM ACLs gate the ability for a principle
- * to attach an Occurrence to a given Note. It also provides a single point of
- * lookup to find all attached Attestation Occurrences, even if they don't all
- * live in the same project.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.attestation.Authority} - */ -public final class Authority extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.attestation.Authority) - AuthorityOrBuilder { - private static final long serialVersionUID = 0L; - // Use Authority.newBuilder() to construct. - private Authority(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Authority() {} - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Authority( - 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: - { - io.grafeas.v1beta1.attestation.Authority.Hint.Builder subBuilder = null; - if (hint_ != null) { - subBuilder = hint_.toBuilder(); - } - hint_ = - input.readMessage( - io.grafeas.v1beta1.attestation.Authority.Hint.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(hint_); - hint_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Authority_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Authority_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.attestation.Authority.class, - io.grafeas.v1beta1.attestation.Authority.Builder.class); - } - - public interface HintOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.attestation.Authority.Hint) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * The human readable name of this Attestation Authority, for example "qa".
-     * 
- * - * string human_readable_name = 1; - */ - java.lang.String getHumanReadableName(); - /** - * - * - *
-     * The human readable name of this Attestation Authority, for example "qa".
-     * 
- * - * string human_readable_name = 1; - */ - com.google.protobuf.ByteString getHumanReadableNameBytes(); - } - /** - * - * - *
-   * This submessage provides human-readable hints about the purpose of the
-   * Authority. Because the name of a Note acts as its resource reference, it is
-   * important to disambiguate the canonical name of the Note (which might be a
-   * UUID for security purposes) from "readable" names more suitable for debug
-   * output. Note that these hints should NOT be used to look up authorities in
-   * security sensitive contexts, such as when looking up Attestations to
-   * verify.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.attestation.Authority.Hint} - */ - public static final class Hint extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.attestation.Authority.Hint) - HintOrBuilder { - private static final long serialVersionUID = 0L; - // Use Hint.newBuilder() to construct. - private Hint(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Hint() { - humanReadableName_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Hint( - 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(); - - humanReadableName_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Authority_Hint_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Authority_Hint_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.attestation.Authority.Hint.class, - io.grafeas.v1beta1.attestation.Authority.Hint.Builder.class); - } - - public static final int HUMAN_READABLE_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object humanReadableName_; - /** - * - * - *
-     * The human readable name of this Attestation Authority, for example "qa".
-     * 
- * - * string human_readable_name = 1; - */ - public java.lang.String getHumanReadableName() { - java.lang.Object ref = humanReadableName_; - 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(); - humanReadableName_ = s; - return s; - } - } - /** - * - * - *
-     * The human readable name of this Attestation Authority, for example "qa".
-     * 
- * - * string human_readable_name = 1; - */ - public com.google.protobuf.ByteString getHumanReadableNameBytes() { - java.lang.Object ref = humanReadableName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - humanReadableName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getHumanReadableNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, humanReadableName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getHumanReadableNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, humanReadableName_); - } - 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 io.grafeas.v1beta1.attestation.Authority.Hint)) { - return super.equals(obj); - } - io.grafeas.v1beta1.attestation.Authority.Hint other = - (io.grafeas.v1beta1.attestation.Authority.Hint) obj; - - if (!getHumanReadableName().equals(other.getHumanReadableName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + HUMAN_READABLE_NAME_FIELD_NUMBER; - hash = (53 * hash) + getHumanReadableName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.attestation.Authority.Hint parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.Authority.Hint parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.Authority.Hint parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.Authority.Hint parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.Authority.Hint parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.Authority.Hint parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.Authority.Hint parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.Authority.Hint 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 io.grafeas.v1beta1.attestation.Authority.Hint parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.Authority.Hint 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 io.grafeas.v1beta1.attestation.Authority.Hint parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.Authority.Hint 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(io.grafeas.v1beta1.attestation.Authority.Hint 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; - } - /** - * - * - *
-     * This submessage provides human-readable hints about the purpose of the
-     * Authority. Because the name of a Note acts as its resource reference, it is
-     * important to disambiguate the canonical name of the Note (which might be a
-     * UUID for security purposes) from "readable" names more suitable for debug
-     * output. Note that these hints should NOT be used to look up authorities in
-     * security sensitive contexts, such as when looking up Attestations to
-     * verify.
-     * 
- * - * Protobuf type {@code grafeas.v1beta1.attestation.Authority.Hint} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.attestation.Authority.Hint) - io.grafeas.v1beta1.attestation.Authority.HintOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Authority_Hint_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Authority_Hint_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.attestation.Authority.Hint.class, - io.grafeas.v1beta1.attestation.Authority.Hint.Builder.class); - } - - // Construct using io.grafeas.v1beta1.attestation.Authority.Hint.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - humanReadableName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Authority_Hint_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Authority.Hint getDefaultInstanceForType() { - return io.grafeas.v1beta1.attestation.Authority.Hint.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Authority.Hint build() { - io.grafeas.v1beta1.attestation.Authority.Hint result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Authority.Hint buildPartial() { - io.grafeas.v1beta1.attestation.Authority.Hint result = - new io.grafeas.v1beta1.attestation.Authority.Hint(this); - result.humanReadableName_ = humanReadableName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.attestation.Authority.Hint) { - return mergeFrom((io.grafeas.v1beta1.attestation.Authority.Hint) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.attestation.Authority.Hint other) { - if (other == io.grafeas.v1beta1.attestation.Authority.Hint.getDefaultInstance()) - return this; - if (!other.getHumanReadableName().isEmpty()) { - humanReadableName_ = other.humanReadableName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.attestation.Authority.Hint parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.attestation.Authority.Hint) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object humanReadableName_ = ""; - /** - * - * - *
-       * The human readable name of this Attestation Authority, for example "qa".
-       * 
- * - * string human_readable_name = 1; - */ - public java.lang.String getHumanReadableName() { - java.lang.Object ref = humanReadableName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - humanReadableName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The human readable name of this Attestation Authority, for example "qa".
-       * 
- * - * string human_readable_name = 1; - */ - public com.google.protobuf.ByteString getHumanReadableNameBytes() { - java.lang.Object ref = humanReadableName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - humanReadableName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The human readable name of this Attestation Authority, for example "qa".
-       * 
- * - * string human_readable_name = 1; - */ - public Builder setHumanReadableName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - humanReadableName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The human readable name of this Attestation Authority, for example "qa".
-       * 
- * - * string human_readable_name = 1; - */ - public Builder clearHumanReadableName() { - - humanReadableName_ = getDefaultInstance().getHumanReadableName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The human readable name of this Attestation Authority, for example "qa".
-       * 
- * - * string human_readable_name = 1; - */ - public Builder setHumanReadableNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - humanReadableName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.attestation.Authority.Hint) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.attestation.Authority.Hint) - private static final io.grafeas.v1beta1.attestation.Authority.Hint DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.attestation.Authority.Hint(); - } - - public static io.grafeas.v1beta1.attestation.Authority.Hint getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Hint parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Hint(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Authority.Hint getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public static final int HINT_FIELD_NUMBER = 1; - private io.grafeas.v1beta1.attestation.Authority.Hint hint_; - /** - * - * - *
-   * Hint hints at the purpose of the attestation authority.
-   * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - public boolean hasHint() { - return hint_ != null; - } - /** - * - * - *
-   * Hint hints at the purpose of the attestation authority.
-   * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - public io.grafeas.v1beta1.attestation.Authority.Hint getHint() { - return hint_ == null - ? io.grafeas.v1beta1.attestation.Authority.Hint.getDefaultInstance() - : hint_; - } - /** - * - * - *
-   * Hint hints at the purpose of the attestation authority.
-   * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - public io.grafeas.v1beta1.attestation.Authority.HintOrBuilder getHintOrBuilder() { - return getHint(); - } - - 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 (hint_ != null) { - output.writeMessage(1, getHint()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (hint_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getHint()); - } - 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 io.grafeas.v1beta1.attestation.Authority)) { - return super.equals(obj); - } - io.grafeas.v1beta1.attestation.Authority other = (io.grafeas.v1beta1.attestation.Authority) obj; - - if (hasHint() != other.hasHint()) return false; - if (hasHint()) { - if (!getHint().equals(other.getHint())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasHint()) { - hash = (37 * hash) + HINT_FIELD_NUMBER; - hash = (53 * hash) + getHint().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.attestation.Authority parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.Authority parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.Authority parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.Authority parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.Authority parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.Authority parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.Authority parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.Authority 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 io.grafeas.v1beta1.attestation.Authority parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.Authority 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 io.grafeas.v1beta1.attestation.Authority parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.Authority 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(io.grafeas.v1beta1.attestation.Authority 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; - } - /** - * - * - *
-   * Note kind that represents a logical attestation "role" or "authority". For
-   * example, an organization might have one `Authority` for "QA" and one for
-   * "build". This Note is intended to act strictly as a grouping mechanism for
-   * the attached Occurrences (Attestations). This grouping mechanism also
-   * provides a security boundary, since IAM ACLs gate the ability for a principle
-   * to attach an Occurrence to a given Note. It also provides a single point of
-   * lookup to find all attached Attestation Occurrences, even if they don't all
-   * live in the same project.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.attestation.Authority} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.attestation.Authority) - io.grafeas.v1beta1.attestation.AuthorityOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Authority_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Authority_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.attestation.Authority.class, - io.grafeas.v1beta1.attestation.Authority.Builder.class); - } - - // Construct using io.grafeas.v1beta1.attestation.Authority.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (hintBuilder_ == null) { - hint_ = null; - } else { - hint_ = null; - hintBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Authority_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Authority getDefaultInstanceForType() { - return io.grafeas.v1beta1.attestation.Authority.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Authority build() { - io.grafeas.v1beta1.attestation.Authority result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Authority buildPartial() { - io.grafeas.v1beta1.attestation.Authority result = - new io.grafeas.v1beta1.attestation.Authority(this); - if (hintBuilder_ == null) { - result.hint_ = hint_; - } else { - result.hint_ = hintBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.attestation.Authority) { - return mergeFrom((io.grafeas.v1beta1.attestation.Authority) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.attestation.Authority other) { - if (other == io.grafeas.v1beta1.attestation.Authority.getDefaultInstance()) return this; - if (other.hasHint()) { - mergeHint(other.getHint()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.attestation.Authority parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.attestation.Authority) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private io.grafeas.v1beta1.attestation.Authority.Hint hint_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.Authority.Hint, - io.grafeas.v1beta1.attestation.Authority.Hint.Builder, - io.grafeas.v1beta1.attestation.Authority.HintOrBuilder> - hintBuilder_; - /** - * - * - *
-     * Hint hints at the purpose of the attestation authority.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - public boolean hasHint() { - return hintBuilder_ != null || hint_ != null; - } - /** - * - * - *
-     * Hint hints at the purpose of the attestation authority.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - public io.grafeas.v1beta1.attestation.Authority.Hint getHint() { - if (hintBuilder_ == null) { - return hint_ == null - ? io.grafeas.v1beta1.attestation.Authority.Hint.getDefaultInstance() - : hint_; - } else { - return hintBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Hint hints at the purpose of the attestation authority.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - public Builder setHint(io.grafeas.v1beta1.attestation.Authority.Hint value) { - if (hintBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - hint_ = value; - onChanged(); - } else { - hintBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Hint hints at the purpose of the attestation authority.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - public Builder setHint(io.grafeas.v1beta1.attestation.Authority.Hint.Builder builderForValue) { - if (hintBuilder_ == null) { - hint_ = builderForValue.build(); - onChanged(); - } else { - hintBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Hint hints at the purpose of the attestation authority.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - public Builder mergeHint(io.grafeas.v1beta1.attestation.Authority.Hint value) { - if (hintBuilder_ == null) { - if (hint_ != null) { - hint_ = - io.grafeas.v1beta1.attestation.Authority.Hint.newBuilder(hint_) - .mergeFrom(value) - .buildPartial(); - } else { - hint_ = value; - } - onChanged(); - } else { - hintBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Hint hints at the purpose of the attestation authority.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - public Builder clearHint() { - if (hintBuilder_ == null) { - hint_ = null; - onChanged(); - } else { - hint_ = null; - hintBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Hint hints at the purpose of the attestation authority.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - public io.grafeas.v1beta1.attestation.Authority.Hint.Builder getHintBuilder() { - - onChanged(); - return getHintFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Hint hints at the purpose of the attestation authority.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - public io.grafeas.v1beta1.attestation.Authority.HintOrBuilder getHintOrBuilder() { - if (hintBuilder_ != null) { - return hintBuilder_.getMessageOrBuilder(); - } else { - return hint_ == null - ? io.grafeas.v1beta1.attestation.Authority.Hint.getDefaultInstance() - : hint_; - } - } - /** - * - * - *
-     * Hint hints at the purpose of the attestation authority.
-     * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.Authority.Hint, - io.grafeas.v1beta1.attestation.Authority.Hint.Builder, - io.grafeas.v1beta1.attestation.Authority.HintOrBuilder> - getHintFieldBuilder() { - if (hintBuilder_ == null) { - hintBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.Authority.Hint, - io.grafeas.v1beta1.attestation.Authority.Hint.Builder, - io.grafeas.v1beta1.attestation.Authority.HintOrBuilder>( - getHint(), getParentForChildren(), isClean()); - hint_ = null; - } - return hintBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.attestation.Authority) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.attestation.Authority) - private static final io.grafeas.v1beta1.attestation.Authority DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.attestation.Authority(); - } - - public static io.grafeas.v1beta1.attestation.Authority getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Authority parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Authority(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Authority getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/AuthorityOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/AuthorityOrBuilder.java deleted file mode 100644 index f02c805c..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/AuthorityOrBuilder.java +++ /dev/null @@ -1,41 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/attestation/attestation.proto - -package io.grafeas.v1beta1.attestation; - -public interface AuthorityOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.attestation.Authority) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Hint hints at the purpose of the attestation authority.
-   * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - boolean hasHint(); - /** - * - * - *
-   * Hint hints at the purpose of the attestation authority.
-   * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - io.grafeas.v1beta1.attestation.Authority.Hint getHint(); - /** - * - * - *
-   * Hint hints at the purpose of the attestation authority.
-   * 
- * - * .grafeas.v1beta1.attestation.Authority.Hint hint = 1; - */ - io.grafeas.v1beta1.attestation.Authority.HintOrBuilder getHintOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/Details.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/Details.java deleted file mode 100644 index b9e121ca..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/Details.java +++ /dev/null @@ -1,700 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/attestation/attestation.proto - -package io.grafeas.v1beta1.attestation; - -/** - * - * - *
- * Details of an attestation occurrence.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.attestation.Details} - */ -public final class Details extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.attestation.Details) - DetailsOrBuilder { - private static final long serialVersionUID = 0L; - // Use Details.newBuilder() to construct. - private Details(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Details() {} - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Details( - 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: - { - io.grafeas.v1beta1.attestation.Attestation.Builder subBuilder = null; - if (attestation_ != null) { - subBuilder = attestation_.toBuilder(); - } - attestation_ = - input.readMessage( - io.grafeas.v1beta1.attestation.Attestation.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(attestation_); - attestation_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.attestation.Details.class, - io.grafeas.v1beta1.attestation.Details.Builder.class); - } - - public static final int ATTESTATION_FIELD_NUMBER = 1; - private io.grafeas.v1beta1.attestation.Attestation attestation_; - /** - * - * - *
-   * Attestation for the resource.
-   * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - public boolean hasAttestation() { - return attestation_ != null; - } - /** - * - * - *
-   * Attestation for the resource.
-   * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - public io.grafeas.v1beta1.attestation.Attestation getAttestation() { - return attestation_ == null - ? io.grafeas.v1beta1.attestation.Attestation.getDefaultInstance() - : attestation_; - } - /** - * - * - *
-   * Attestation for the resource.
-   * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - public io.grafeas.v1beta1.attestation.AttestationOrBuilder getAttestationOrBuilder() { - return getAttestation(); - } - - 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 (attestation_ != null) { - output.writeMessage(1, getAttestation()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (attestation_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getAttestation()); - } - 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 io.grafeas.v1beta1.attestation.Details)) { - return super.equals(obj); - } - io.grafeas.v1beta1.attestation.Details other = (io.grafeas.v1beta1.attestation.Details) obj; - - if (hasAttestation() != other.hasAttestation()) return false; - if (hasAttestation()) { - if (!getAttestation().equals(other.getAttestation())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasAttestation()) { - hash = (37 * hash) + ATTESTATION_FIELD_NUMBER; - hash = (53 * hash) + getAttestation().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.attestation.Details parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.Details parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.Details parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.Details parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.Details parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.Details parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.Details parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.Details 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 io.grafeas.v1beta1.attestation.Details parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.Details 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 io.grafeas.v1beta1.attestation.Details parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.Details 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(io.grafeas.v1beta1.attestation.Details 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; - } - /** - * - * - *
-   * Details of an attestation occurrence.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.attestation.Details} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.attestation.Details) - io.grafeas.v1beta1.attestation.DetailsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.attestation.Details.class, - io.grafeas.v1beta1.attestation.Details.Builder.class); - } - - // Construct using io.grafeas.v1beta1.attestation.Details.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (attestationBuilder_ == null) { - attestation_ = null; - } else { - attestation_ = null; - attestationBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_Details_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Details getDefaultInstanceForType() { - return io.grafeas.v1beta1.attestation.Details.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Details build() { - io.grafeas.v1beta1.attestation.Details result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Details buildPartial() { - io.grafeas.v1beta1.attestation.Details result = - new io.grafeas.v1beta1.attestation.Details(this); - if (attestationBuilder_ == null) { - result.attestation_ = attestation_; - } else { - result.attestation_ = attestationBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.attestation.Details) { - return mergeFrom((io.grafeas.v1beta1.attestation.Details) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.attestation.Details other) { - if (other == io.grafeas.v1beta1.attestation.Details.getDefaultInstance()) return this; - if (other.hasAttestation()) { - mergeAttestation(other.getAttestation()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.attestation.Details parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.attestation.Details) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private io.grafeas.v1beta1.attestation.Attestation attestation_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.Attestation, - io.grafeas.v1beta1.attestation.Attestation.Builder, - io.grafeas.v1beta1.attestation.AttestationOrBuilder> - attestationBuilder_; - /** - * - * - *
-     * Attestation for the resource.
-     * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - public boolean hasAttestation() { - return attestationBuilder_ != null || attestation_ != null; - } - /** - * - * - *
-     * Attestation for the resource.
-     * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - public io.grafeas.v1beta1.attestation.Attestation getAttestation() { - if (attestationBuilder_ == null) { - return attestation_ == null - ? io.grafeas.v1beta1.attestation.Attestation.getDefaultInstance() - : attestation_; - } else { - return attestationBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Attestation for the resource.
-     * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - public Builder setAttestation(io.grafeas.v1beta1.attestation.Attestation value) { - if (attestationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - attestation_ = value; - onChanged(); - } else { - attestationBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Attestation for the resource.
-     * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - public Builder setAttestation( - io.grafeas.v1beta1.attestation.Attestation.Builder builderForValue) { - if (attestationBuilder_ == null) { - attestation_ = builderForValue.build(); - onChanged(); - } else { - attestationBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Attestation for the resource.
-     * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - public Builder mergeAttestation(io.grafeas.v1beta1.attestation.Attestation value) { - if (attestationBuilder_ == null) { - if (attestation_ != null) { - attestation_ = - io.grafeas.v1beta1.attestation.Attestation.newBuilder(attestation_) - .mergeFrom(value) - .buildPartial(); - } else { - attestation_ = value; - } - onChanged(); - } else { - attestationBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Attestation for the resource.
-     * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - public Builder clearAttestation() { - if (attestationBuilder_ == null) { - attestation_ = null; - onChanged(); - } else { - attestation_ = null; - attestationBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Attestation for the resource.
-     * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - public io.grafeas.v1beta1.attestation.Attestation.Builder getAttestationBuilder() { - - onChanged(); - return getAttestationFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Attestation for the resource.
-     * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - public io.grafeas.v1beta1.attestation.AttestationOrBuilder getAttestationOrBuilder() { - if (attestationBuilder_ != null) { - return attestationBuilder_.getMessageOrBuilder(); - } else { - return attestation_ == null - ? io.grafeas.v1beta1.attestation.Attestation.getDefaultInstance() - : attestation_; - } - } - /** - * - * - *
-     * Attestation for the resource.
-     * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.Attestation, - io.grafeas.v1beta1.attestation.Attestation.Builder, - io.grafeas.v1beta1.attestation.AttestationOrBuilder> - getAttestationFieldBuilder() { - if (attestationBuilder_ == null) { - attestationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.attestation.Attestation, - io.grafeas.v1beta1.attestation.Attestation.Builder, - io.grafeas.v1beta1.attestation.AttestationOrBuilder>( - getAttestation(), getParentForChildren(), isClean()); - attestation_ = null; - } - return attestationBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.attestation.Details) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.attestation.Details) - private static final io.grafeas.v1beta1.attestation.Details DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.attestation.Details(); - } - - public static io.grafeas.v1beta1.attestation.Details getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser
PARSER = - new com.google.protobuf.AbstractParser
() { - @java.lang.Override - public Details parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Details(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser
parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser
getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.Details getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/DetailsOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/DetailsOrBuilder.java deleted file mode 100644 index d3f288d5..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/DetailsOrBuilder.java +++ /dev/null @@ -1,41 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/attestation/attestation.proto - -package io.grafeas.v1beta1.attestation; - -public interface DetailsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.attestation.Details) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Attestation for the resource.
-   * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - boolean hasAttestation(); - /** - * - * - *
-   * Attestation for the resource.
-   * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - io.grafeas.v1beta1.attestation.Attestation getAttestation(); - /** - * - * - *
-   * Attestation for the resource.
-   * 
- * - * .grafeas.v1beta1.attestation.Attestation attestation = 1; - */ - io.grafeas.v1beta1.attestation.AttestationOrBuilder getAttestationOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/IamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/IamResourceName.java deleted file mode 100644 index ce3df640..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/IamResourceName.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.attestation; - -import com.google.api.resourcenames.ResourceName; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public abstract class IamResourceName implements ResourceName { - protected IamResourceName() {} -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/IamResourceNames.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/IamResourceNames.java deleted file mode 100644 index 0b82968a..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/IamResourceNames.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.attestation; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class IamResourceNames { - private IamResourceNames() {} - - public static IamResourceName parse(String resourceNameString) { - if (NoteName.isParsableFrom(resourceNameString)) { - return NoteName.parse(resourceNameString); - } - if (OccurrenceName.isParsableFrom(resourceNameString)) { - return OccurrenceName.parse(resourceNameString); - } - return UntypedIamResourceName.parse(resourceNameString); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/NoteName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/NoteName.java deleted file mode 100644 index 76c1028b..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/NoteName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.attestation; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class NoteName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/notes/{note}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/OccurrenceName.java deleted file mode 100644 index 38a73b8c..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.attestation; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/PgpSignedAttestation.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/PgpSignedAttestation.java deleted file mode 100644 index aff40b1f..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/PgpSignedAttestation.java +++ /dev/null @@ -1,1309 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/attestation/attestation.proto - -package io.grafeas.v1beta1.attestation; - -/** - * - * - *
- * An attestation wrapper with a PGP-compatible signature. This message only
- * supports `ATTACHED` signatures, where the payload that is signed is included
- * alongside the signature itself in the same file.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.attestation.PgpSignedAttestation} - */ -public final class PgpSignedAttestation extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.attestation.PgpSignedAttestation) - PgpSignedAttestationOrBuilder { - private static final long serialVersionUID = 0L; - // Use PgpSignedAttestation.newBuilder() to construct. - private PgpSignedAttestation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private PgpSignedAttestation() { - signature_ = ""; - contentType_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private PgpSignedAttestation( - 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(); - - signature_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - keyIdCase_ = 2; - keyId_ = s; - break; - } - case 24: - { - int rawValue = input.readEnum(); - - contentType_ = rawValue; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_PgpSignedAttestation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_PgpSignedAttestation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.attestation.PgpSignedAttestation.class, - io.grafeas.v1beta1.attestation.PgpSignedAttestation.Builder.class); - } - - /** - * - * - *
-   * Type (for example schema) of the attestation payload that was signed.
-   * 
- * - * Protobuf enum {@code grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType} - */ - public enum ContentType implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * `ContentType` is not set.
-     * 
- * - * CONTENT_TYPE_UNSPECIFIED = 0; - */ - CONTENT_TYPE_UNSPECIFIED(0), - /** - * - * - *
-     * Atomic format attestation signature. See
-     * https://github.com/containers/image/blob/8a5d2f82a6e3263290c8e0276c3e0f64e77723e7/docs/atomic-signature.md
-     * The payload extracted from `signature` is a JSON blob conforming to the
-     * linked schema.
-     * 
- * - * SIMPLE_SIGNING_JSON = 1; - */ - SIMPLE_SIGNING_JSON(1), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * `ContentType` is not set.
-     * 
- * - * CONTENT_TYPE_UNSPECIFIED = 0; - */ - public static final int CONTENT_TYPE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * Atomic format attestation signature. See
-     * https://github.com/containers/image/blob/8a5d2f82a6e3263290c8e0276c3e0f64e77723e7/docs/atomic-signature.md
-     * The payload extracted from `signature` is a JSON blob conforming to the
-     * linked schema.
-     * 
- * - * SIMPLE_SIGNING_JSON = 1; - */ - public static final int SIMPLE_SIGNING_JSON_VALUE = 1; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static ContentType valueOf(int value) { - return forNumber(value); - } - - public static ContentType forNumber(int value) { - switch (value) { - case 0: - return CONTENT_TYPE_UNSPECIFIED; - case 1: - return SIMPLE_SIGNING_JSON; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public ContentType findValueByNumber(int number) { - return ContentType.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return io.grafeas.v1beta1.attestation.PgpSignedAttestation.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final ContentType[] VALUES = values(); - - public static ContentType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private ContentType(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType) - } - - private int keyIdCase_ = 0; - private java.lang.Object keyId_; - - public enum KeyIdCase implements com.google.protobuf.Internal.EnumLite { - PGP_KEY_ID(2), - KEYID_NOT_SET(0); - private final int value; - - private KeyIdCase(int value) { - this.value = value; - } - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static KeyIdCase valueOf(int value) { - return forNumber(value); - } - - public static KeyIdCase forNumber(int value) { - switch (value) { - case 2: - return PGP_KEY_ID; - case 0: - return KEYID_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public KeyIdCase getKeyIdCase() { - return KeyIdCase.forNumber(keyIdCase_); - } - - public static final int SIGNATURE_FIELD_NUMBER = 1; - private volatile java.lang.Object signature_; - /** - * - * - *
-   * The raw content of the signature, as output by GNU Privacy Guard (GPG) or
-   * equivalent.  Since this message only supports attached signatures, the
-   * payload that was signed must be attached. While the signature format
-   * supported is dependent on the verification implementation, currently only
-   * ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than
-   * `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor
-   * --output=signature.gpg payload.json` will create the signature content
-   * expected in this field in `signature.gpg` for the `payload.json`
-   * attestation payload.
-   * 
- * - * string signature = 1; - */ - public java.lang.String getSignature() { - java.lang.Object ref = signature_; - 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(); - signature_ = s; - return s; - } - } - /** - * - * - *
-   * The raw content of the signature, as output by GNU Privacy Guard (GPG) or
-   * equivalent.  Since this message only supports attached signatures, the
-   * payload that was signed must be attached. While the signature format
-   * supported is dependent on the verification implementation, currently only
-   * ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than
-   * `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor
-   * --output=signature.gpg payload.json` will create the signature content
-   * expected in this field in `signature.gpg` for the `payload.json`
-   * attestation payload.
-   * 
- * - * string signature = 1; - */ - public com.google.protobuf.ByteString getSignatureBytes() { - java.lang.Object ref = signature_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - signature_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CONTENT_TYPE_FIELD_NUMBER = 3; - private int contentType_; - /** - * - * - *
-   * Type (for example schema) of the attestation payload that was signed.
-   * The verifier must ensure that the provided type is one that the verifier
-   * supports, and that the attestation payload is a valid instantiation of that
-   * type (for example by validating a JSON schema).
-   * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType content_type = 3; - */ - public int getContentTypeValue() { - return contentType_; - } - /** - * - * - *
-   * Type (for example schema) of the attestation payload that was signed.
-   * The verifier must ensure that the provided type is one that the verifier
-   * supports, and that the attestation payload is a valid instantiation of that
-   * type (for example by validating a JSON schema).
-   * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType content_type = 3; - */ - public io.grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType getContentType() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType result = - io.grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType.valueOf(contentType_); - return result == null - ? io.grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType.UNRECOGNIZED - : result; - } - - public static final int PGP_KEY_ID_FIELD_NUMBER = 2; - /** - * - * - *
-   * The cryptographic fingerprint of the key used to generate the signature,
-   * as output by, e.g. `gpg --list-keys`. This should be the version 4, full
-   * 160-bit fingerprint, expressed as a 40 character hexidecimal string. See
-   * https://tools.ietf.org/html/rfc4880#section-12.2 for details.
-   * Implementations may choose to acknowledge "LONG", "SHORT", or other
-   * abbreviated key IDs, but only the full fingerprint is guaranteed to work.
-   * In gpg, the full fingerprint can be retrieved from the `fpr` field
-   * returned when calling --list-keys with --with-colons.  For example:
-   * ```
-   * gpg --with-colons --with-fingerprint --force-v4-certs \
-   *     --list-keys attester@example.com
-   * tru::1:1513631572:0:3:1:5
-   * pub:...<SNIP>...
-   * fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB:
-   * ```
-   * Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`.
-   * 
- * - * string pgp_key_id = 2; - */ - public java.lang.String getPgpKeyId() { - java.lang.Object ref = ""; - if (keyIdCase_ == 2) { - ref = keyId_; - } - 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(); - if (keyIdCase_ == 2) { - keyId_ = s; - } - return s; - } - } - /** - * - * - *
-   * The cryptographic fingerprint of the key used to generate the signature,
-   * as output by, e.g. `gpg --list-keys`. This should be the version 4, full
-   * 160-bit fingerprint, expressed as a 40 character hexidecimal string. See
-   * https://tools.ietf.org/html/rfc4880#section-12.2 for details.
-   * Implementations may choose to acknowledge "LONG", "SHORT", or other
-   * abbreviated key IDs, but only the full fingerprint is guaranteed to work.
-   * In gpg, the full fingerprint can be retrieved from the `fpr` field
-   * returned when calling --list-keys with --with-colons.  For example:
-   * ```
-   * gpg --with-colons --with-fingerprint --force-v4-certs \
-   *     --list-keys attester@example.com
-   * tru::1:1513631572:0:3:1:5
-   * pub:...<SNIP>...
-   * fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB:
-   * ```
-   * Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`.
-   * 
- * - * string pgp_key_id = 2; - */ - public com.google.protobuf.ByteString getPgpKeyIdBytes() { - java.lang.Object ref = ""; - if (keyIdCase_ == 2) { - ref = keyId_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (keyIdCase_ == 2) { - keyId_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getSignatureBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, signature_); - } - if (keyIdCase_ == 2) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, keyId_); - } - if (contentType_ - != io.grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType.CONTENT_TYPE_UNSPECIFIED - .getNumber()) { - output.writeEnum(3, contentType_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getSignatureBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, signature_); - } - if (keyIdCase_ == 2) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, keyId_); - } - if (contentType_ - != io.grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType.CONTENT_TYPE_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, contentType_); - } - 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 io.grafeas.v1beta1.attestation.PgpSignedAttestation)) { - return super.equals(obj); - } - io.grafeas.v1beta1.attestation.PgpSignedAttestation other = - (io.grafeas.v1beta1.attestation.PgpSignedAttestation) obj; - - if (!getSignature().equals(other.getSignature())) return false; - if (contentType_ != other.contentType_) return false; - if (!getKeyIdCase().equals(other.getKeyIdCase())) return false; - switch (keyIdCase_) { - case 2: - if (!getPgpKeyId().equals(other.getPgpKeyId())) return false; - break; - case 0: - default: - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + SIGNATURE_FIELD_NUMBER; - hash = (53 * hash) + getSignature().hashCode(); - hash = (37 * hash) + CONTENT_TYPE_FIELD_NUMBER; - hash = (53 * hash) + contentType_; - switch (keyIdCase_) { - case 2: - hash = (37 * hash) + PGP_KEY_ID_FIELD_NUMBER; - hash = (53 * hash) + getPgpKeyId().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.attestation.PgpSignedAttestation parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.PgpSignedAttestation parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.PgpSignedAttestation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.PgpSignedAttestation parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.PgpSignedAttestation parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.attestation.PgpSignedAttestation parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.attestation.PgpSignedAttestation parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.PgpSignedAttestation 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 io.grafeas.v1beta1.attestation.PgpSignedAttestation parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.PgpSignedAttestation 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 io.grafeas.v1beta1.attestation.PgpSignedAttestation parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.attestation.PgpSignedAttestation 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(io.grafeas.v1beta1.attestation.PgpSignedAttestation 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; - } - /** - * - * - *
-   * An attestation wrapper with a PGP-compatible signature. This message only
-   * supports `ATTACHED` signatures, where the payload that is signed is included
-   * alongside the signature itself in the same file.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.attestation.PgpSignedAttestation} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.attestation.PgpSignedAttestation) - io.grafeas.v1beta1.attestation.PgpSignedAttestationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_PgpSignedAttestation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_PgpSignedAttestation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.attestation.PgpSignedAttestation.class, - io.grafeas.v1beta1.attestation.PgpSignedAttestation.Builder.class); - } - - // Construct using io.grafeas.v1beta1.attestation.PgpSignedAttestation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - signature_ = ""; - - contentType_ = 0; - - keyIdCase_ = 0; - keyId_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.attestation.AttestationOuterClass - .internal_static_grafeas_v1beta1_attestation_PgpSignedAttestation_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.PgpSignedAttestation getDefaultInstanceForType() { - return io.grafeas.v1beta1.attestation.PgpSignedAttestation.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.PgpSignedAttestation build() { - io.grafeas.v1beta1.attestation.PgpSignedAttestation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.PgpSignedAttestation buildPartial() { - io.grafeas.v1beta1.attestation.PgpSignedAttestation result = - new io.grafeas.v1beta1.attestation.PgpSignedAttestation(this); - result.signature_ = signature_; - result.contentType_ = contentType_; - if (keyIdCase_ == 2) { - result.keyId_ = keyId_; - } - result.keyIdCase_ = keyIdCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.attestation.PgpSignedAttestation) { - return mergeFrom((io.grafeas.v1beta1.attestation.PgpSignedAttestation) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.attestation.PgpSignedAttestation other) { - if (other == io.grafeas.v1beta1.attestation.PgpSignedAttestation.getDefaultInstance()) - return this; - if (!other.getSignature().isEmpty()) { - signature_ = other.signature_; - onChanged(); - } - if (other.contentType_ != 0) { - setContentTypeValue(other.getContentTypeValue()); - } - switch (other.getKeyIdCase()) { - case PGP_KEY_ID: - { - keyIdCase_ = 2; - keyId_ = other.keyId_; - onChanged(); - break; - } - case KEYID_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.attestation.PgpSignedAttestation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (io.grafeas.v1beta1.attestation.PgpSignedAttestation) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int keyIdCase_ = 0; - private java.lang.Object keyId_; - - public KeyIdCase getKeyIdCase() { - return KeyIdCase.forNumber(keyIdCase_); - } - - public Builder clearKeyId() { - keyIdCase_ = 0; - keyId_ = null; - onChanged(); - return this; - } - - private java.lang.Object signature_ = ""; - /** - * - * - *
-     * The raw content of the signature, as output by GNU Privacy Guard (GPG) or
-     * equivalent.  Since this message only supports attached signatures, the
-     * payload that was signed must be attached. While the signature format
-     * supported is dependent on the verification implementation, currently only
-     * ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than
-     * `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor
-     * --output=signature.gpg payload.json` will create the signature content
-     * expected in this field in `signature.gpg` for the `payload.json`
-     * attestation payload.
-     * 
- * - * string signature = 1; - */ - public java.lang.String getSignature() { - java.lang.Object ref = signature_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - signature_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The raw content of the signature, as output by GNU Privacy Guard (GPG) or
-     * equivalent.  Since this message only supports attached signatures, the
-     * payload that was signed must be attached. While the signature format
-     * supported is dependent on the verification implementation, currently only
-     * ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than
-     * `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor
-     * --output=signature.gpg payload.json` will create the signature content
-     * expected in this field in `signature.gpg` for the `payload.json`
-     * attestation payload.
-     * 
- * - * string signature = 1; - */ - public com.google.protobuf.ByteString getSignatureBytes() { - java.lang.Object ref = signature_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - signature_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The raw content of the signature, as output by GNU Privacy Guard (GPG) or
-     * equivalent.  Since this message only supports attached signatures, the
-     * payload that was signed must be attached. While the signature format
-     * supported is dependent on the verification implementation, currently only
-     * ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than
-     * `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor
-     * --output=signature.gpg payload.json` will create the signature content
-     * expected in this field in `signature.gpg` for the `payload.json`
-     * attestation payload.
-     * 
- * - * string signature = 1; - */ - public Builder setSignature(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - signature_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The raw content of the signature, as output by GNU Privacy Guard (GPG) or
-     * equivalent.  Since this message only supports attached signatures, the
-     * payload that was signed must be attached. While the signature format
-     * supported is dependent on the verification implementation, currently only
-     * ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than
-     * `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor
-     * --output=signature.gpg payload.json` will create the signature content
-     * expected in this field in `signature.gpg` for the `payload.json`
-     * attestation payload.
-     * 
- * - * string signature = 1; - */ - public Builder clearSignature() { - - signature_ = getDefaultInstance().getSignature(); - onChanged(); - return this; - } - /** - * - * - *
-     * The raw content of the signature, as output by GNU Privacy Guard (GPG) or
-     * equivalent.  Since this message only supports attached signatures, the
-     * payload that was signed must be attached. While the signature format
-     * supported is dependent on the verification implementation, currently only
-     * ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than
-     * `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor
-     * --output=signature.gpg payload.json` will create the signature content
-     * expected in this field in `signature.gpg` for the `payload.json`
-     * attestation payload.
-     * 
- * - * string signature = 1; - */ - public Builder setSignatureBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - signature_ = value; - onChanged(); - return this; - } - - private int contentType_ = 0; - /** - * - * - *
-     * Type (for example schema) of the attestation payload that was signed.
-     * The verifier must ensure that the provided type is one that the verifier
-     * supports, and that the attestation payload is a valid instantiation of that
-     * type (for example by validating a JSON schema).
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType content_type = 3; - */ - public int getContentTypeValue() { - return contentType_; - } - /** - * - * - *
-     * Type (for example schema) of the attestation payload that was signed.
-     * The verifier must ensure that the provided type is one that the verifier
-     * supports, and that the attestation payload is a valid instantiation of that
-     * type (for example by validating a JSON schema).
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType content_type = 3; - */ - public Builder setContentTypeValue(int value) { - contentType_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Type (for example schema) of the attestation payload that was signed.
-     * The verifier must ensure that the provided type is one that the verifier
-     * supports, and that the attestation payload is a valid instantiation of that
-     * type (for example by validating a JSON schema).
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType content_type = 3; - */ - public io.grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType getContentType() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType result = - io.grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType.valueOf(contentType_); - return result == null - ? io.grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType.UNRECOGNIZED - : result; - } - /** - * - * - *
-     * Type (for example schema) of the attestation payload that was signed.
-     * The verifier must ensure that the provided type is one that the verifier
-     * supports, and that the attestation payload is a valid instantiation of that
-     * type (for example by validating a JSON schema).
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType content_type = 3; - */ - public Builder setContentType( - io.grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType value) { - if (value == null) { - throw new NullPointerException(); - } - - contentType_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Type (for example schema) of the attestation payload that was signed.
-     * The verifier must ensure that the provided type is one that the verifier
-     * supports, and that the attestation payload is a valid instantiation of that
-     * type (for example by validating a JSON schema).
-     * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType content_type = 3; - */ - public Builder clearContentType() { - - contentType_ = 0; - onChanged(); - return this; - } - - /** - * - * - *
-     * The cryptographic fingerprint of the key used to generate the signature,
-     * as output by, e.g. `gpg --list-keys`. This should be the version 4, full
-     * 160-bit fingerprint, expressed as a 40 character hexidecimal string. See
-     * https://tools.ietf.org/html/rfc4880#section-12.2 for details.
-     * Implementations may choose to acknowledge "LONG", "SHORT", or other
-     * abbreviated key IDs, but only the full fingerprint is guaranteed to work.
-     * In gpg, the full fingerprint can be retrieved from the `fpr` field
-     * returned when calling --list-keys with --with-colons.  For example:
-     * ```
-     * gpg --with-colons --with-fingerprint --force-v4-certs \
-     *     --list-keys attester@example.com
-     * tru::1:1513631572:0:3:1:5
-     * pub:...<SNIP>...
-     * fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB:
-     * ```
-     * Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`.
-     * 
- * - * string pgp_key_id = 2; - */ - public java.lang.String getPgpKeyId() { - java.lang.Object ref = ""; - if (keyIdCase_ == 2) { - ref = keyId_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (keyIdCase_ == 2) { - keyId_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The cryptographic fingerprint of the key used to generate the signature,
-     * as output by, e.g. `gpg --list-keys`. This should be the version 4, full
-     * 160-bit fingerprint, expressed as a 40 character hexidecimal string. See
-     * https://tools.ietf.org/html/rfc4880#section-12.2 for details.
-     * Implementations may choose to acknowledge "LONG", "SHORT", or other
-     * abbreviated key IDs, but only the full fingerprint is guaranteed to work.
-     * In gpg, the full fingerprint can be retrieved from the `fpr` field
-     * returned when calling --list-keys with --with-colons.  For example:
-     * ```
-     * gpg --with-colons --with-fingerprint --force-v4-certs \
-     *     --list-keys attester@example.com
-     * tru::1:1513631572:0:3:1:5
-     * pub:...<SNIP>...
-     * fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB:
-     * ```
-     * Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`.
-     * 
- * - * string pgp_key_id = 2; - */ - public com.google.protobuf.ByteString getPgpKeyIdBytes() { - java.lang.Object ref = ""; - if (keyIdCase_ == 2) { - ref = keyId_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (keyIdCase_ == 2) { - keyId_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The cryptographic fingerprint of the key used to generate the signature,
-     * as output by, e.g. `gpg --list-keys`. This should be the version 4, full
-     * 160-bit fingerprint, expressed as a 40 character hexidecimal string. See
-     * https://tools.ietf.org/html/rfc4880#section-12.2 for details.
-     * Implementations may choose to acknowledge "LONG", "SHORT", or other
-     * abbreviated key IDs, but only the full fingerprint is guaranteed to work.
-     * In gpg, the full fingerprint can be retrieved from the `fpr` field
-     * returned when calling --list-keys with --with-colons.  For example:
-     * ```
-     * gpg --with-colons --with-fingerprint --force-v4-certs \
-     *     --list-keys attester@example.com
-     * tru::1:1513631572:0:3:1:5
-     * pub:...<SNIP>...
-     * fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB:
-     * ```
-     * Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`.
-     * 
- * - * string pgp_key_id = 2; - */ - public Builder setPgpKeyId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - keyIdCase_ = 2; - keyId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The cryptographic fingerprint of the key used to generate the signature,
-     * as output by, e.g. `gpg --list-keys`. This should be the version 4, full
-     * 160-bit fingerprint, expressed as a 40 character hexidecimal string. See
-     * https://tools.ietf.org/html/rfc4880#section-12.2 for details.
-     * Implementations may choose to acknowledge "LONG", "SHORT", or other
-     * abbreviated key IDs, but only the full fingerprint is guaranteed to work.
-     * In gpg, the full fingerprint can be retrieved from the `fpr` field
-     * returned when calling --list-keys with --with-colons.  For example:
-     * ```
-     * gpg --with-colons --with-fingerprint --force-v4-certs \
-     *     --list-keys attester@example.com
-     * tru::1:1513631572:0:3:1:5
-     * pub:...<SNIP>...
-     * fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB:
-     * ```
-     * Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`.
-     * 
- * - * string pgp_key_id = 2; - */ - public Builder clearPgpKeyId() { - if (keyIdCase_ == 2) { - keyIdCase_ = 0; - keyId_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-     * The cryptographic fingerprint of the key used to generate the signature,
-     * as output by, e.g. `gpg --list-keys`. This should be the version 4, full
-     * 160-bit fingerprint, expressed as a 40 character hexidecimal string. See
-     * https://tools.ietf.org/html/rfc4880#section-12.2 for details.
-     * Implementations may choose to acknowledge "LONG", "SHORT", or other
-     * abbreviated key IDs, but only the full fingerprint is guaranteed to work.
-     * In gpg, the full fingerprint can be retrieved from the `fpr` field
-     * returned when calling --list-keys with --with-colons.  For example:
-     * ```
-     * gpg --with-colons --with-fingerprint --force-v4-certs \
-     *     --list-keys attester@example.com
-     * tru::1:1513631572:0:3:1:5
-     * pub:...<SNIP>...
-     * fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB:
-     * ```
-     * Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`.
-     * 
- * - * string pgp_key_id = 2; - */ - public Builder setPgpKeyIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - keyIdCase_ = 2; - keyId_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.attestation.PgpSignedAttestation) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.attestation.PgpSignedAttestation) - private static final io.grafeas.v1beta1.attestation.PgpSignedAttestation DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.attestation.PgpSignedAttestation(); - } - - public static io.grafeas.v1beta1.attestation.PgpSignedAttestation getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public PgpSignedAttestation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new PgpSignedAttestation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.attestation.PgpSignedAttestation getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/PgpSignedAttestationOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/PgpSignedAttestationOrBuilder.java deleted file mode 100644 index b5a53d79..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/PgpSignedAttestationOrBuilder.java +++ /dev/null @@ -1,127 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/attestation/attestation.proto - -package io.grafeas.v1beta1.attestation; - -public interface PgpSignedAttestationOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.attestation.PgpSignedAttestation) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The raw content of the signature, as output by GNU Privacy Guard (GPG) or
-   * equivalent.  Since this message only supports attached signatures, the
-   * payload that was signed must be attached. While the signature format
-   * supported is dependent on the verification implementation, currently only
-   * ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than
-   * `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor
-   * --output=signature.gpg payload.json` will create the signature content
-   * expected in this field in `signature.gpg` for the `payload.json`
-   * attestation payload.
-   * 
- * - * string signature = 1; - */ - java.lang.String getSignature(); - /** - * - * - *
-   * The raw content of the signature, as output by GNU Privacy Guard (GPG) or
-   * equivalent.  Since this message only supports attached signatures, the
-   * payload that was signed must be attached. While the signature format
-   * supported is dependent on the verification implementation, currently only
-   * ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than
-   * `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor
-   * --output=signature.gpg payload.json` will create the signature content
-   * expected in this field in `signature.gpg` for the `payload.json`
-   * attestation payload.
-   * 
- * - * string signature = 1; - */ - com.google.protobuf.ByteString getSignatureBytes(); - - /** - * - * - *
-   * Type (for example schema) of the attestation payload that was signed.
-   * The verifier must ensure that the provided type is one that the verifier
-   * supports, and that the attestation payload is a valid instantiation of that
-   * type (for example by validating a JSON schema).
-   * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType content_type = 3; - */ - int getContentTypeValue(); - /** - * - * - *
-   * Type (for example schema) of the attestation payload that was signed.
-   * The verifier must ensure that the provided type is one that the verifier
-   * supports, and that the attestation payload is a valid instantiation of that
-   * type (for example by validating a JSON schema).
-   * 
- * - * .grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType content_type = 3; - */ - io.grafeas.v1beta1.attestation.PgpSignedAttestation.ContentType getContentType(); - - /** - * - * - *
-   * The cryptographic fingerprint of the key used to generate the signature,
-   * as output by, e.g. `gpg --list-keys`. This should be the version 4, full
-   * 160-bit fingerprint, expressed as a 40 character hexidecimal string. See
-   * https://tools.ietf.org/html/rfc4880#section-12.2 for details.
-   * Implementations may choose to acknowledge "LONG", "SHORT", or other
-   * abbreviated key IDs, but only the full fingerprint is guaranteed to work.
-   * In gpg, the full fingerprint can be retrieved from the `fpr` field
-   * returned when calling --list-keys with --with-colons.  For example:
-   * ```
-   * gpg --with-colons --with-fingerprint --force-v4-certs \
-   *     --list-keys attester@example.com
-   * tru::1:1513631572:0:3:1:5
-   * pub:...<SNIP>...
-   * fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB:
-   * ```
-   * Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`.
-   * 
- * - * string pgp_key_id = 2; - */ - java.lang.String getPgpKeyId(); - /** - * - * - *
-   * The cryptographic fingerprint of the key used to generate the signature,
-   * as output by, e.g. `gpg --list-keys`. This should be the version 4, full
-   * 160-bit fingerprint, expressed as a 40 character hexidecimal string. See
-   * https://tools.ietf.org/html/rfc4880#section-12.2 for details.
-   * Implementations may choose to acknowledge "LONG", "SHORT", or other
-   * abbreviated key IDs, but only the full fingerprint is guaranteed to work.
-   * In gpg, the full fingerprint can be retrieved from the `fpr` field
-   * returned when calling --list-keys with --with-colons.  For example:
-   * ```
-   * gpg --with-colons --with-fingerprint --force-v4-certs \
-   *     --list-keys attester@example.com
-   * tru::1:1513631572:0:3:1:5
-   * pub:...<SNIP>...
-   * fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB:
-   * ```
-   * Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`.
-   * 
- * - * string pgp_key_id = 2; - */ - com.google.protobuf.ByteString getPgpKeyIdBytes(); - - public io.grafeas.v1beta1.attestation.PgpSignedAttestation.KeyIdCase getKeyIdCase(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/ProjectName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/ProjectName.java deleted file mode 100644 index 46f1295a..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.attestation; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/ScanConfigName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/ScanConfigName.java deleted file mode 100644 index be176347..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/ScanConfigName.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.attestation; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ScanConfigName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ScanConfigName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - scanConfig = Preconditions.checkNotNull(builder.getScanConfig()); - } - - public static ScanConfigName of(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build(); - } - - public static String format(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build().toString(); - } - - public static ScanConfigName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ScanConfigName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("scan_config")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ScanConfigName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("scanConfig", scanConfig); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "scan_config", scanConfig); - } - - /** Builder for ScanConfigName. */ - public static class Builder { - - private String project; - private String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setScanConfig(String scanConfig) { - this.scanConfig = scanConfig; - return this; - } - - private Builder() {} - - private Builder(ScanConfigName scanConfigName) { - project = scanConfigName.project; - scanConfig = scanConfigName.scanConfig; - } - - public ScanConfigName build() { - return new ScanConfigName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ScanConfigName) { - ScanConfigName that = (ScanConfigName) o; - return (this.project.equals(that.project)) && (this.scanConfig.equals(that.scanConfig)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= scanConfig.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/UntypedIamResourceName.java deleted file mode 100644 index 98732153..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/attestation/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.attestation; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/Build.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/Build.java deleted file mode 100644 index b57f4d99..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/Build.java +++ /dev/null @@ -1,871 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/build/build.proto - -package io.grafeas.v1beta1.build; - -/** - * - * - *
- * Note holding the version of the provider's builder and the signature of the
- * provenance message in linked BuildDetails.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.build.Build} - */ -public final class Build extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.build.Build) - BuildOrBuilder { - private static final long serialVersionUID = 0L; - // Use Build.newBuilder() to construct. - private Build(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Build() { - builderVersion_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Build( - 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(); - - builderVersion_ = s; - break; - } - case 18: - { - io.grafeas.v1beta1.build.BuildSignature.Builder subBuilder = null; - if (signature_ != null) { - subBuilder = signature_.toBuilder(); - } - signature_ = - input.readMessage( - io.grafeas.v1beta1.build.BuildSignature.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(signature_); - signature_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_Build_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_Build_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.build.Build.class, io.grafeas.v1beta1.build.Build.Builder.class); - } - - public static final int BUILDER_VERSION_FIELD_NUMBER = 1; - private volatile java.lang.Object builderVersion_; - /** - * - * - *
-   * Version of the builder which produced this Note.
-   * 
- * - * string builder_version = 1; - */ - public java.lang.String getBuilderVersion() { - java.lang.Object ref = builderVersion_; - 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(); - builderVersion_ = s; - return s; - } - } - /** - * - * - *
-   * Version of the builder which produced this Note.
-   * 
- * - * string builder_version = 1; - */ - public com.google.protobuf.ByteString getBuilderVersionBytes() { - java.lang.Object ref = builderVersion_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - builderVersion_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SIGNATURE_FIELD_NUMBER = 2; - private io.grafeas.v1beta1.build.BuildSignature signature_; - /** - * - * - *
-   * Signature of the build in Occurrences pointing to the Note containing this
-   * `BuilderDetails`.
-   * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - public boolean hasSignature() { - return signature_ != null; - } - /** - * - * - *
-   * Signature of the build in Occurrences pointing to the Note containing this
-   * `BuilderDetails`.
-   * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - public io.grafeas.v1beta1.build.BuildSignature getSignature() { - return signature_ == null - ? io.grafeas.v1beta1.build.BuildSignature.getDefaultInstance() - : signature_; - } - /** - * - * - *
-   * Signature of the build in Occurrences pointing to the Note containing this
-   * `BuilderDetails`.
-   * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - public io.grafeas.v1beta1.build.BuildSignatureOrBuilder getSignatureOrBuilder() { - return getSignature(); - } - - 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 (!getBuilderVersionBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, builderVersion_); - } - if (signature_ != null) { - output.writeMessage(2, getSignature()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getBuilderVersionBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, builderVersion_); - } - if (signature_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getSignature()); - } - 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 io.grafeas.v1beta1.build.Build)) { - return super.equals(obj); - } - io.grafeas.v1beta1.build.Build other = (io.grafeas.v1beta1.build.Build) obj; - - if (!getBuilderVersion().equals(other.getBuilderVersion())) return false; - if (hasSignature() != other.hasSignature()) return false; - if (hasSignature()) { - if (!getSignature().equals(other.getSignature())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + BUILDER_VERSION_FIELD_NUMBER; - hash = (53 * hash) + getBuilderVersion().hashCode(); - if (hasSignature()) { - hash = (37 * hash) + SIGNATURE_FIELD_NUMBER; - hash = (53 * hash) + getSignature().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.build.Build parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.build.Build parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.build.Build parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.build.Build parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.build.Build parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.build.Build parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.build.Build parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.build.Build 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 io.grafeas.v1beta1.build.Build parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.build.Build 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 io.grafeas.v1beta1.build.Build parseFrom(com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.build.Build 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(io.grafeas.v1beta1.build.Build 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; - } - /** - * - * - *
-   * Note holding the version of the provider's builder and the signature of the
-   * provenance message in linked BuildDetails.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.build.Build} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.build.Build) - io.grafeas.v1beta1.build.BuildOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_Build_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_Build_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.build.Build.class, io.grafeas.v1beta1.build.Build.Builder.class); - } - - // Construct using io.grafeas.v1beta1.build.Build.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - builderVersion_ = ""; - - if (signatureBuilder_ == null) { - signature_ = null; - } else { - signature_ = null; - signatureBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_Build_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.build.Build getDefaultInstanceForType() { - return io.grafeas.v1beta1.build.Build.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.build.Build build() { - io.grafeas.v1beta1.build.Build result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.build.Build buildPartial() { - io.grafeas.v1beta1.build.Build result = new io.grafeas.v1beta1.build.Build(this); - result.builderVersion_ = builderVersion_; - if (signatureBuilder_ == null) { - result.signature_ = signature_; - } else { - result.signature_ = signatureBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.build.Build) { - return mergeFrom((io.grafeas.v1beta1.build.Build) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.build.Build other) { - if (other == io.grafeas.v1beta1.build.Build.getDefaultInstance()) return this; - if (!other.getBuilderVersion().isEmpty()) { - builderVersion_ = other.builderVersion_; - onChanged(); - } - if (other.hasSignature()) { - mergeSignature(other.getSignature()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.build.Build parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.build.Build) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object builderVersion_ = ""; - /** - * - * - *
-     * Version of the builder which produced this Note.
-     * 
- * - * string builder_version = 1; - */ - public java.lang.String getBuilderVersion() { - java.lang.Object ref = builderVersion_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - builderVersion_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Version of the builder which produced this Note.
-     * 
- * - * string builder_version = 1; - */ - public com.google.protobuf.ByteString getBuilderVersionBytes() { - java.lang.Object ref = builderVersion_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - builderVersion_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Version of the builder which produced this Note.
-     * 
- * - * string builder_version = 1; - */ - public Builder setBuilderVersion(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - builderVersion_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Version of the builder which produced this Note.
-     * 
- * - * string builder_version = 1; - */ - public Builder clearBuilderVersion() { - - builderVersion_ = getDefaultInstance().getBuilderVersion(); - onChanged(); - return this; - } - /** - * - * - *
-     * Version of the builder which produced this Note.
-     * 
- * - * string builder_version = 1; - */ - public Builder setBuilderVersionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - builderVersion_ = value; - onChanged(); - return this; - } - - private io.grafeas.v1beta1.build.BuildSignature signature_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.build.BuildSignature, - io.grafeas.v1beta1.build.BuildSignature.Builder, - io.grafeas.v1beta1.build.BuildSignatureOrBuilder> - signatureBuilder_; - /** - * - * - *
-     * Signature of the build in Occurrences pointing to the Note containing this
-     * `BuilderDetails`.
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - public boolean hasSignature() { - return signatureBuilder_ != null || signature_ != null; - } - /** - * - * - *
-     * Signature of the build in Occurrences pointing to the Note containing this
-     * `BuilderDetails`.
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - public io.grafeas.v1beta1.build.BuildSignature getSignature() { - if (signatureBuilder_ == null) { - return signature_ == null - ? io.grafeas.v1beta1.build.BuildSignature.getDefaultInstance() - : signature_; - } else { - return signatureBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Signature of the build in Occurrences pointing to the Note containing this
-     * `BuilderDetails`.
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - public Builder setSignature(io.grafeas.v1beta1.build.BuildSignature value) { - if (signatureBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - signature_ = value; - onChanged(); - } else { - signatureBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Signature of the build in Occurrences pointing to the Note containing this
-     * `BuilderDetails`.
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - public Builder setSignature(io.grafeas.v1beta1.build.BuildSignature.Builder builderForValue) { - if (signatureBuilder_ == null) { - signature_ = builderForValue.build(); - onChanged(); - } else { - signatureBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Signature of the build in Occurrences pointing to the Note containing this
-     * `BuilderDetails`.
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - public Builder mergeSignature(io.grafeas.v1beta1.build.BuildSignature value) { - if (signatureBuilder_ == null) { - if (signature_ != null) { - signature_ = - io.grafeas.v1beta1.build.BuildSignature.newBuilder(signature_) - .mergeFrom(value) - .buildPartial(); - } else { - signature_ = value; - } - onChanged(); - } else { - signatureBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Signature of the build in Occurrences pointing to the Note containing this
-     * `BuilderDetails`.
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - public Builder clearSignature() { - if (signatureBuilder_ == null) { - signature_ = null; - onChanged(); - } else { - signature_ = null; - signatureBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Signature of the build in Occurrences pointing to the Note containing this
-     * `BuilderDetails`.
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - public io.grafeas.v1beta1.build.BuildSignature.Builder getSignatureBuilder() { - - onChanged(); - return getSignatureFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Signature of the build in Occurrences pointing to the Note containing this
-     * `BuilderDetails`.
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - public io.grafeas.v1beta1.build.BuildSignatureOrBuilder getSignatureOrBuilder() { - if (signatureBuilder_ != null) { - return signatureBuilder_.getMessageOrBuilder(); - } else { - return signature_ == null - ? io.grafeas.v1beta1.build.BuildSignature.getDefaultInstance() - : signature_; - } - } - /** - * - * - *
-     * Signature of the build in Occurrences pointing to the Note containing this
-     * `BuilderDetails`.
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.build.BuildSignature, - io.grafeas.v1beta1.build.BuildSignature.Builder, - io.grafeas.v1beta1.build.BuildSignatureOrBuilder> - getSignatureFieldBuilder() { - if (signatureBuilder_ == null) { - signatureBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.build.BuildSignature, - io.grafeas.v1beta1.build.BuildSignature.Builder, - io.grafeas.v1beta1.build.BuildSignatureOrBuilder>( - getSignature(), getParentForChildren(), isClean()); - signature_ = null; - } - return signatureBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.build.Build) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.build.Build) - private static final io.grafeas.v1beta1.build.Build DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.build.Build(); - } - - public static io.grafeas.v1beta1.build.Build getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Build parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Build(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.build.Build getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildOrBuilder.java deleted file mode 100644 index 5ecec343..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildOrBuilder.java +++ /dev/null @@ -1,65 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/build/build.proto - -package io.grafeas.v1beta1.build; - -public interface BuildOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.build.Build) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Version of the builder which produced this Note.
-   * 
- * - * string builder_version = 1; - */ - java.lang.String getBuilderVersion(); - /** - * - * - *
-   * Version of the builder which produced this Note.
-   * 
- * - * string builder_version = 1; - */ - com.google.protobuf.ByteString getBuilderVersionBytes(); - - /** - * - * - *
-   * Signature of the build in Occurrences pointing to the Note containing this
-   * `BuilderDetails`.
-   * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - boolean hasSignature(); - /** - * - * - *
-   * Signature of the build in Occurrences pointing to the Note containing this
-   * `BuilderDetails`.
-   * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - io.grafeas.v1beta1.build.BuildSignature getSignature(); - /** - * - * - *
-   * Signature of the build in Occurrences pointing to the Note containing this
-   * `BuilderDetails`.
-   * 
- * - * .grafeas.v1beta1.build.BuildSignature signature = 2; - */ - io.grafeas.v1beta1.build.BuildSignatureOrBuilder getSignatureOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildOuterClass.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildOuterClass.java deleted file mode 100644 index 7aad8551..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildOuterClass.java +++ /dev/null @@ -1,97 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/build/build.proto - -package io.grafeas.v1beta1.build; - -public final class BuildOuterClass { - private BuildOuterClass() {} - - 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_grafeas_v1beta1_build_Build_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_build_Build_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_build_BuildSignature_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_build_BuildSignature_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_build_Details_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_build_Details_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/devtools/containeranalysis/v1be" - + "ta1/build/build.proto\022\025grafeas.v1beta1.b" - + "uild\032Egoogle/devtools/containeranalysis/" - + "v1beta1/provenance/provenance.proto\"Z\n\005B" - + "uild\022\027\n\017builder_version\030\001 \001(\t\0228\n\tsignatu" - + "re\030\002 \001(\0132%.grafeas.v1beta1.build.BuildSi" - + "gnature\"\322\001\n\016BuildSignature\022\022\n\npublic_key" - + "\030\001 \001(\t\022\021\n\tsignature\030\002 \001(\014\022\016\n\006key_id\030\003 \001(" - + "\t\022?\n\010key_type\030\004 \001(\0162-.grafeas.v1beta1.bu" - + "ild.BuildSignature.KeyType\"H\n\007KeyType\022\030\n" - + "\024KEY_TYPE_UNSPECIFIED\020\000\022\025\n\021PGP_ASCII_ARM" - + "ORED\020\001\022\014\n\010PKIX_PEM\020\002\"d\n\007Details\022?\n\nprove" - + "nance\030\001 \001(\0132+.grafeas.v1beta1.provenance" - + ".BuildProvenance\022\030\n\020provenance_bytes\030\002 \001" - + "(\tBx\n\030io.grafeas.v1beta1.buildP\001ZTgoogle" - + ".golang.org/genproto/googleapis/devtools" - + "/containeranalysis/v1beta1/build;build\242\002" - + "\003GRAb\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[] { - io.grafeas.v1beta1.provenance.Provenance.getDescriptor(), - }, - assigner); - internal_static_grafeas_v1beta1_build_Build_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_grafeas_v1beta1_build_Build_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_build_Build_descriptor, - new java.lang.String[] { - "BuilderVersion", "Signature", - }); - internal_static_grafeas_v1beta1_build_BuildSignature_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_grafeas_v1beta1_build_BuildSignature_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_build_BuildSignature_descriptor, - new java.lang.String[] { - "PublicKey", "Signature", "KeyId", "KeyType", - }); - internal_static_grafeas_v1beta1_build_Details_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_grafeas_v1beta1_build_Details_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_build_Details_descriptor, - new java.lang.String[] { - "Provenance", "ProvenanceBytes", - }); - io.grafeas.v1beta1.provenance.Provenance.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildSignature.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildSignature.java deleted file mode 100644 index 6a7c9581..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildSignature.java +++ /dev/null @@ -1,1217 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/build/build.proto - -package io.grafeas.v1beta1.build; - -/** - * - * - *
- * Message encapsulating the signature of the verified build.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.build.BuildSignature} - */ -public final class BuildSignature extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.build.BuildSignature) - BuildSignatureOrBuilder { - private static final long serialVersionUID = 0L; - // Use BuildSignature.newBuilder() to construct. - private BuildSignature(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BuildSignature() { - publicKey_ = ""; - signature_ = com.google.protobuf.ByteString.EMPTY; - keyId_ = ""; - keyType_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private BuildSignature( - 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(); - - publicKey_ = s; - break; - } - case 18: - { - signature_ = input.readBytes(); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - keyId_ = s; - break; - } - case 32: - { - int rawValue = input.readEnum(); - - keyType_ = rawValue; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_BuildSignature_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_BuildSignature_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.build.BuildSignature.class, - io.grafeas.v1beta1.build.BuildSignature.Builder.class); - } - - /** - * - * - *
-   * Public key formats
-   * 
- * - * Protobuf enum {@code grafeas.v1beta1.build.BuildSignature.KeyType} - */ - public enum KeyType implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * `KeyType` is not set.
-     * 
- * - * KEY_TYPE_UNSPECIFIED = 0; - */ - KEY_TYPE_UNSPECIFIED(0), - /** - * - * - *
-     * `PGP ASCII Armored` public key.
-     * 
- * - * PGP_ASCII_ARMORED = 1; - */ - PGP_ASCII_ARMORED(1), - /** - * - * - *
-     * `PKIX PEM` public key.
-     * 
- * - * PKIX_PEM = 2; - */ - PKIX_PEM(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * `KeyType` is not set.
-     * 
- * - * KEY_TYPE_UNSPECIFIED = 0; - */ - public static final int KEY_TYPE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * `PGP ASCII Armored` public key.
-     * 
- * - * PGP_ASCII_ARMORED = 1; - */ - public static final int PGP_ASCII_ARMORED_VALUE = 1; - /** - * - * - *
-     * `PKIX PEM` public key.
-     * 
- * - * PKIX_PEM = 2; - */ - public static final int PKIX_PEM_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 KeyType valueOf(int value) { - return forNumber(value); - } - - public static KeyType forNumber(int value) { - switch (value) { - case 0: - return KEY_TYPE_UNSPECIFIED; - case 1: - return PGP_ASCII_ARMORED; - case 2: - return PKIX_PEM; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public KeyType findValueByNumber(int number) { - return KeyType.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return io.grafeas.v1beta1.build.BuildSignature.getDescriptor().getEnumTypes().get(0); - } - - private static final KeyType[] VALUES = values(); - - public static KeyType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private KeyType(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:grafeas.v1beta1.build.BuildSignature.KeyType) - } - - public static final int PUBLIC_KEY_FIELD_NUMBER = 1; - private volatile java.lang.Object publicKey_; - /** - * - * - *
-   * Public key of the builder which can be used to verify that the related
-   * findings are valid and unchanged. If `key_type` is empty, this defaults
-   * to PEM encoded public keys.
-   * This field may be empty if `key_id` references an external key.
-   * For Cloud Container Builder based signatures, this is a PEM encoded public
-   * key. To verify the Cloud Container Builder signature, place the contents of
-   * this field into a file (public.pem). The signature field is base64-decoded
-   * into its binary representation in signature.bin, and the provenance bytes
-   * from `BuildDetails` are base64-decoded into a binary representation in
-   * signed.bin. OpenSSL can then verify the signature:
-   * `openssl sha256 -verify public.pem -signature signature.bin signed.bin`
-   * 
- * - * string public_key = 1; - */ - public java.lang.String getPublicKey() { - java.lang.Object ref = publicKey_; - 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(); - publicKey_ = s; - return s; - } - } - /** - * - * - *
-   * Public key of the builder which can be used to verify that the related
-   * findings are valid and unchanged. If `key_type` is empty, this defaults
-   * to PEM encoded public keys.
-   * This field may be empty if `key_id` references an external key.
-   * For Cloud Container Builder based signatures, this is a PEM encoded public
-   * key. To verify the Cloud Container Builder signature, place the contents of
-   * this field into a file (public.pem). The signature field is base64-decoded
-   * into its binary representation in signature.bin, and the provenance bytes
-   * from `BuildDetails` are base64-decoded into a binary representation in
-   * signed.bin. OpenSSL can then verify the signature:
-   * `openssl sha256 -verify public.pem -signature signature.bin signed.bin`
-   * 
- * - * string public_key = 1; - */ - public com.google.protobuf.ByteString getPublicKeyBytes() { - java.lang.Object ref = publicKey_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - publicKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SIGNATURE_FIELD_NUMBER = 2; - private com.google.protobuf.ByteString signature_; - /** - * - * - *
-   * Signature of the related `BuildProvenance`. In JSON, this is base-64
-   * encoded.
-   * 
- * - * bytes signature = 2; - */ - public com.google.protobuf.ByteString getSignature() { - return signature_; - } - - public static final int KEY_ID_FIELD_NUMBER = 3; - private volatile java.lang.Object keyId_; - /** - * - * - *
-   * An ID for the key used to sign. This could be either an Id for the key
-   * stored in `public_key` (such as the Id or fingerprint for a PGP key, or the
-   * CN for a cert), or a reference to an external key (such as a reference to a
-   * key in Cloud Key Management Service).
-   * 
- * - * string key_id = 3; - */ - public java.lang.String getKeyId() { - java.lang.Object ref = keyId_; - 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(); - keyId_ = s; - return s; - } - } - /** - * - * - *
-   * An ID for the key used to sign. This could be either an Id for the key
-   * stored in `public_key` (such as the Id or fingerprint for a PGP key, or the
-   * CN for a cert), or a reference to an external key (such as a reference to a
-   * key in Cloud Key Management Service).
-   * 
- * - * string key_id = 3; - */ - public com.google.protobuf.ByteString getKeyIdBytes() { - java.lang.Object ref = keyId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - keyId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int KEY_TYPE_FIELD_NUMBER = 4; - private int keyType_; - /** - * - * - *
-   * The type of the key, either stored in `public_key` or referenced in
-   * `key_id`
-   * 
- * - * .grafeas.v1beta1.build.BuildSignature.KeyType key_type = 4; - */ - public int getKeyTypeValue() { - return keyType_; - } - /** - * - * - *
-   * The type of the key, either stored in `public_key` or referenced in
-   * `key_id`
-   * 
- * - * .grafeas.v1beta1.build.BuildSignature.KeyType key_type = 4; - */ - public io.grafeas.v1beta1.build.BuildSignature.KeyType getKeyType() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.build.BuildSignature.KeyType result = - io.grafeas.v1beta1.build.BuildSignature.KeyType.valueOf(keyType_); - return result == null ? io.grafeas.v1beta1.build.BuildSignature.KeyType.UNRECOGNIZED : result; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getPublicKeyBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, publicKey_); - } - if (!signature_.isEmpty()) { - output.writeBytes(2, signature_); - } - if (!getKeyIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, keyId_); - } - if (keyType_ - != io.grafeas.v1beta1.build.BuildSignature.KeyType.KEY_TYPE_UNSPECIFIED.getNumber()) { - output.writeEnum(4, keyType_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getPublicKeyBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, publicKey_); - } - if (!signature_.isEmpty()) { - size += com.google.protobuf.CodedOutputStream.computeBytesSize(2, signature_); - } - if (!getKeyIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, keyId_); - } - if (keyType_ - != io.grafeas.v1beta1.build.BuildSignature.KeyType.KEY_TYPE_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, keyType_); - } - 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 io.grafeas.v1beta1.build.BuildSignature)) { - return super.equals(obj); - } - io.grafeas.v1beta1.build.BuildSignature other = (io.grafeas.v1beta1.build.BuildSignature) obj; - - if (!getPublicKey().equals(other.getPublicKey())) return false; - if (!getSignature().equals(other.getSignature())) return false; - if (!getKeyId().equals(other.getKeyId())) return false; - if (keyType_ != other.keyType_) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PUBLIC_KEY_FIELD_NUMBER; - hash = (53 * hash) + getPublicKey().hashCode(); - hash = (37 * hash) + SIGNATURE_FIELD_NUMBER; - hash = (53 * hash) + getSignature().hashCode(); - hash = (37 * hash) + KEY_ID_FIELD_NUMBER; - hash = (53 * hash) + getKeyId().hashCode(); - hash = (37 * hash) + KEY_TYPE_FIELD_NUMBER; - hash = (53 * hash) + keyType_; - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.build.BuildSignature parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.build.BuildSignature parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.build.BuildSignature parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.build.BuildSignature parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.build.BuildSignature parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.build.BuildSignature parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.build.BuildSignature parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.build.BuildSignature 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 io.grafeas.v1beta1.build.BuildSignature parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.build.BuildSignature 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 io.grafeas.v1beta1.build.BuildSignature parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.build.BuildSignature 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(io.grafeas.v1beta1.build.BuildSignature 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; - } - /** - * - * - *
-   * Message encapsulating the signature of the verified build.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.build.BuildSignature} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.build.BuildSignature) - io.grafeas.v1beta1.build.BuildSignatureOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_BuildSignature_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_BuildSignature_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.build.BuildSignature.class, - io.grafeas.v1beta1.build.BuildSignature.Builder.class); - } - - // Construct using io.grafeas.v1beta1.build.BuildSignature.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - publicKey_ = ""; - - signature_ = com.google.protobuf.ByteString.EMPTY; - - keyId_ = ""; - - keyType_ = 0; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_BuildSignature_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.build.BuildSignature getDefaultInstanceForType() { - return io.grafeas.v1beta1.build.BuildSignature.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.build.BuildSignature build() { - io.grafeas.v1beta1.build.BuildSignature result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.build.BuildSignature buildPartial() { - io.grafeas.v1beta1.build.BuildSignature result = - new io.grafeas.v1beta1.build.BuildSignature(this); - result.publicKey_ = publicKey_; - result.signature_ = signature_; - result.keyId_ = keyId_; - result.keyType_ = keyType_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.build.BuildSignature) { - return mergeFrom((io.grafeas.v1beta1.build.BuildSignature) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.build.BuildSignature other) { - if (other == io.grafeas.v1beta1.build.BuildSignature.getDefaultInstance()) return this; - if (!other.getPublicKey().isEmpty()) { - publicKey_ = other.publicKey_; - onChanged(); - } - if (other.getSignature() != com.google.protobuf.ByteString.EMPTY) { - setSignature(other.getSignature()); - } - if (!other.getKeyId().isEmpty()) { - keyId_ = other.keyId_; - onChanged(); - } - if (other.keyType_ != 0) { - setKeyTypeValue(other.getKeyTypeValue()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.build.BuildSignature parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.build.BuildSignature) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object publicKey_ = ""; - /** - * - * - *
-     * Public key of the builder which can be used to verify that the related
-     * findings are valid and unchanged. If `key_type` is empty, this defaults
-     * to PEM encoded public keys.
-     * This field may be empty if `key_id` references an external key.
-     * For Cloud Container Builder based signatures, this is a PEM encoded public
-     * key. To verify the Cloud Container Builder signature, place the contents of
-     * this field into a file (public.pem). The signature field is base64-decoded
-     * into its binary representation in signature.bin, and the provenance bytes
-     * from `BuildDetails` are base64-decoded into a binary representation in
-     * signed.bin. OpenSSL can then verify the signature:
-     * `openssl sha256 -verify public.pem -signature signature.bin signed.bin`
-     * 
- * - * string public_key = 1; - */ - public java.lang.String getPublicKey() { - java.lang.Object ref = publicKey_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - publicKey_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Public key of the builder which can be used to verify that the related
-     * findings are valid and unchanged. If `key_type` is empty, this defaults
-     * to PEM encoded public keys.
-     * This field may be empty if `key_id` references an external key.
-     * For Cloud Container Builder based signatures, this is a PEM encoded public
-     * key. To verify the Cloud Container Builder signature, place the contents of
-     * this field into a file (public.pem). The signature field is base64-decoded
-     * into its binary representation in signature.bin, and the provenance bytes
-     * from `BuildDetails` are base64-decoded into a binary representation in
-     * signed.bin. OpenSSL can then verify the signature:
-     * `openssl sha256 -verify public.pem -signature signature.bin signed.bin`
-     * 
- * - * string public_key = 1; - */ - public com.google.protobuf.ByteString getPublicKeyBytes() { - java.lang.Object ref = publicKey_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - publicKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Public key of the builder which can be used to verify that the related
-     * findings are valid and unchanged. If `key_type` is empty, this defaults
-     * to PEM encoded public keys.
-     * This field may be empty if `key_id` references an external key.
-     * For Cloud Container Builder based signatures, this is a PEM encoded public
-     * key. To verify the Cloud Container Builder signature, place the contents of
-     * this field into a file (public.pem). The signature field is base64-decoded
-     * into its binary representation in signature.bin, and the provenance bytes
-     * from `BuildDetails` are base64-decoded into a binary representation in
-     * signed.bin. OpenSSL can then verify the signature:
-     * `openssl sha256 -verify public.pem -signature signature.bin signed.bin`
-     * 
- * - * string public_key = 1; - */ - public Builder setPublicKey(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - publicKey_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Public key of the builder which can be used to verify that the related
-     * findings are valid and unchanged. If `key_type` is empty, this defaults
-     * to PEM encoded public keys.
-     * This field may be empty if `key_id` references an external key.
-     * For Cloud Container Builder based signatures, this is a PEM encoded public
-     * key. To verify the Cloud Container Builder signature, place the contents of
-     * this field into a file (public.pem). The signature field is base64-decoded
-     * into its binary representation in signature.bin, and the provenance bytes
-     * from `BuildDetails` are base64-decoded into a binary representation in
-     * signed.bin. OpenSSL can then verify the signature:
-     * `openssl sha256 -verify public.pem -signature signature.bin signed.bin`
-     * 
- * - * string public_key = 1; - */ - public Builder clearPublicKey() { - - publicKey_ = getDefaultInstance().getPublicKey(); - onChanged(); - return this; - } - /** - * - * - *
-     * Public key of the builder which can be used to verify that the related
-     * findings are valid and unchanged. If `key_type` is empty, this defaults
-     * to PEM encoded public keys.
-     * This field may be empty if `key_id` references an external key.
-     * For Cloud Container Builder based signatures, this is a PEM encoded public
-     * key. To verify the Cloud Container Builder signature, place the contents of
-     * this field into a file (public.pem). The signature field is base64-decoded
-     * into its binary representation in signature.bin, and the provenance bytes
-     * from `BuildDetails` are base64-decoded into a binary representation in
-     * signed.bin. OpenSSL can then verify the signature:
-     * `openssl sha256 -verify public.pem -signature signature.bin signed.bin`
-     * 
- * - * string public_key = 1; - */ - public Builder setPublicKeyBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - publicKey_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.ByteString signature_ = com.google.protobuf.ByteString.EMPTY; - /** - * - * - *
-     * Signature of the related `BuildProvenance`. In JSON, this is base-64
-     * encoded.
-     * 
- * - * bytes signature = 2; - */ - public com.google.protobuf.ByteString getSignature() { - return signature_; - } - /** - * - * - *
-     * Signature of the related `BuildProvenance`. In JSON, this is base-64
-     * encoded.
-     * 
- * - * bytes signature = 2; - */ - public Builder setSignature(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - - signature_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Signature of the related `BuildProvenance`. In JSON, this is base-64
-     * encoded.
-     * 
- * - * bytes signature = 2; - */ - public Builder clearSignature() { - - signature_ = getDefaultInstance().getSignature(); - onChanged(); - return this; - } - - private java.lang.Object keyId_ = ""; - /** - * - * - *
-     * An ID for the key used to sign. This could be either an Id for the key
-     * stored in `public_key` (such as the Id or fingerprint for a PGP key, or the
-     * CN for a cert), or a reference to an external key (such as a reference to a
-     * key in Cloud Key Management Service).
-     * 
- * - * string key_id = 3; - */ - public java.lang.String getKeyId() { - java.lang.Object ref = keyId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - keyId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * An ID for the key used to sign. This could be either an Id for the key
-     * stored in `public_key` (such as the Id or fingerprint for a PGP key, or the
-     * CN for a cert), or a reference to an external key (such as a reference to a
-     * key in Cloud Key Management Service).
-     * 
- * - * string key_id = 3; - */ - public com.google.protobuf.ByteString getKeyIdBytes() { - java.lang.Object ref = keyId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - keyId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * An ID for the key used to sign. This could be either an Id for the key
-     * stored in `public_key` (such as the Id or fingerprint for a PGP key, or the
-     * CN for a cert), or a reference to an external key (such as a reference to a
-     * key in Cloud Key Management Service).
-     * 
- * - * string key_id = 3; - */ - public Builder setKeyId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - keyId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * An ID for the key used to sign. This could be either an Id for the key
-     * stored in `public_key` (such as the Id or fingerprint for a PGP key, or the
-     * CN for a cert), or a reference to an external key (such as a reference to a
-     * key in Cloud Key Management Service).
-     * 
- * - * string key_id = 3; - */ - public Builder clearKeyId() { - - keyId_ = getDefaultInstance().getKeyId(); - onChanged(); - return this; - } - /** - * - * - *
-     * An ID for the key used to sign. This could be either an Id for the key
-     * stored in `public_key` (such as the Id or fingerprint for a PGP key, or the
-     * CN for a cert), or a reference to an external key (such as a reference to a
-     * key in Cloud Key Management Service).
-     * 
- * - * string key_id = 3; - */ - public Builder setKeyIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - keyId_ = value; - onChanged(); - return this; - } - - private int keyType_ = 0; - /** - * - * - *
-     * The type of the key, either stored in `public_key` or referenced in
-     * `key_id`
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature.KeyType key_type = 4; - */ - public int getKeyTypeValue() { - return keyType_; - } - /** - * - * - *
-     * The type of the key, either stored in `public_key` or referenced in
-     * `key_id`
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature.KeyType key_type = 4; - */ - public Builder setKeyTypeValue(int value) { - keyType_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The type of the key, either stored in `public_key` or referenced in
-     * `key_id`
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature.KeyType key_type = 4; - */ - public io.grafeas.v1beta1.build.BuildSignature.KeyType getKeyType() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.build.BuildSignature.KeyType result = - io.grafeas.v1beta1.build.BuildSignature.KeyType.valueOf(keyType_); - return result == null ? io.grafeas.v1beta1.build.BuildSignature.KeyType.UNRECOGNIZED : result; - } - /** - * - * - *
-     * The type of the key, either stored in `public_key` or referenced in
-     * `key_id`
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature.KeyType key_type = 4; - */ - public Builder setKeyType(io.grafeas.v1beta1.build.BuildSignature.KeyType value) { - if (value == null) { - throw new NullPointerException(); - } - - keyType_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * The type of the key, either stored in `public_key` or referenced in
-     * `key_id`
-     * 
- * - * .grafeas.v1beta1.build.BuildSignature.KeyType key_type = 4; - */ - public Builder clearKeyType() { - - keyType_ = 0; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.build.BuildSignature) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.build.BuildSignature) - private static final io.grafeas.v1beta1.build.BuildSignature DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.build.BuildSignature(); - } - - public static io.grafeas.v1beta1.build.BuildSignature getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BuildSignature parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new BuildSignature(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.build.BuildSignature getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildSignatureOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildSignatureOrBuilder.java deleted file mode 100644 index f5cca178..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/BuildSignatureOrBuilder.java +++ /dev/null @@ -1,113 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/build/build.proto - -package io.grafeas.v1beta1.build; - -public interface BuildSignatureOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.build.BuildSignature) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Public key of the builder which can be used to verify that the related
-   * findings are valid and unchanged. If `key_type` is empty, this defaults
-   * to PEM encoded public keys.
-   * This field may be empty if `key_id` references an external key.
-   * For Cloud Container Builder based signatures, this is a PEM encoded public
-   * key. To verify the Cloud Container Builder signature, place the contents of
-   * this field into a file (public.pem). The signature field is base64-decoded
-   * into its binary representation in signature.bin, and the provenance bytes
-   * from `BuildDetails` are base64-decoded into a binary representation in
-   * signed.bin. OpenSSL can then verify the signature:
-   * `openssl sha256 -verify public.pem -signature signature.bin signed.bin`
-   * 
- * - * string public_key = 1; - */ - java.lang.String getPublicKey(); - /** - * - * - *
-   * Public key of the builder which can be used to verify that the related
-   * findings are valid and unchanged. If `key_type` is empty, this defaults
-   * to PEM encoded public keys.
-   * This field may be empty if `key_id` references an external key.
-   * For Cloud Container Builder based signatures, this is a PEM encoded public
-   * key. To verify the Cloud Container Builder signature, place the contents of
-   * this field into a file (public.pem). The signature field is base64-decoded
-   * into its binary representation in signature.bin, and the provenance bytes
-   * from `BuildDetails` are base64-decoded into a binary representation in
-   * signed.bin. OpenSSL can then verify the signature:
-   * `openssl sha256 -verify public.pem -signature signature.bin signed.bin`
-   * 
- * - * string public_key = 1; - */ - com.google.protobuf.ByteString getPublicKeyBytes(); - - /** - * - * - *
-   * Signature of the related `BuildProvenance`. In JSON, this is base-64
-   * encoded.
-   * 
- * - * bytes signature = 2; - */ - com.google.protobuf.ByteString getSignature(); - - /** - * - * - *
-   * An ID for the key used to sign. This could be either an Id for the key
-   * stored in `public_key` (such as the Id or fingerprint for a PGP key, or the
-   * CN for a cert), or a reference to an external key (such as a reference to a
-   * key in Cloud Key Management Service).
-   * 
- * - * string key_id = 3; - */ - java.lang.String getKeyId(); - /** - * - * - *
-   * An ID for the key used to sign. This could be either an Id for the key
-   * stored in `public_key` (such as the Id or fingerprint for a PGP key, or the
-   * CN for a cert), or a reference to an external key (such as a reference to a
-   * key in Cloud Key Management Service).
-   * 
- * - * string key_id = 3; - */ - com.google.protobuf.ByteString getKeyIdBytes(); - - /** - * - * - *
-   * The type of the key, either stored in `public_key` or referenced in
-   * `key_id`
-   * 
- * - * .grafeas.v1beta1.build.BuildSignature.KeyType key_type = 4; - */ - int getKeyTypeValue(); - /** - * - * - *
-   * The type of the key, either stored in `public_key` or referenced in
-   * `key_id`
-   * 
- * - * .grafeas.v1beta1.build.BuildSignature.KeyType key_type = 4; - */ - io.grafeas.v1beta1.build.BuildSignature.KeyType getKeyType(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/Details.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/Details.java deleted file mode 100644 index 65ef709e..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/Details.java +++ /dev/null @@ -1,922 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/build/build.proto - -package io.grafeas.v1beta1.build; - -/** - * - * - *
- * Details of a build occurrence.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.build.Details} - */ -public final class Details extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.build.Details) - DetailsOrBuilder { - private static final long serialVersionUID = 0L; - // Use Details.newBuilder() to construct. - private Details(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Details() { - provenanceBytes_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Details( - 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: - { - io.grafeas.v1beta1.provenance.BuildProvenance.Builder subBuilder = null; - if (provenance_ != null) { - subBuilder = provenance_.toBuilder(); - } - provenance_ = - input.readMessage( - io.grafeas.v1beta1.provenance.BuildProvenance.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(provenance_); - provenance_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - provenanceBytes_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.build.Details.class, io.grafeas.v1beta1.build.Details.Builder.class); - } - - public static final int PROVENANCE_FIELD_NUMBER = 1; - private io.grafeas.v1beta1.provenance.BuildProvenance provenance_; - /** - * - * - *
-   * The actual provenance for the build.
-   * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - public boolean hasProvenance() { - return provenance_ != null; - } - /** - * - * - *
-   * The actual provenance for the build.
-   * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - public io.grafeas.v1beta1.provenance.BuildProvenance getProvenance() { - return provenance_ == null - ? io.grafeas.v1beta1.provenance.BuildProvenance.getDefaultInstance() - : provenance_; - } - /** - * - * - *
-   * The actual provenance for the build.
-   * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - public io.grafeas.v1beta1.provenance.BuildProvenanceOrBuilder getProvenanceOrBuilder() { - return getProvenance(); - } - - public static final int PROVENANCE_BYTES_FIELD_NUMBER = 2; - private volatile java.lang.Object provenanceBytes_; - /** - * - * - *
-   * Serialized JSON representation of the provenance, used in generating the
-   * `BuildSignature` in the corresponding Result. After verifying the
-   * signature, `provenance_bytes` can be unmarshalled and compared to the
-   * provenance to confirm that it is unchanged. A base64-encoded string
-   * representation of the provenance bytes is used for the signature in order
-   * to interoperate with openssl which expects this format for signature
-   * verification.
-   * The serialized form is captured both to avoid ambiguity in how the
-   * provenance is marshalled to json as well to prevent incompatibilities with
-   * future changes.
-   * 
- * - * string provenance_bytes = 2; - */ - public java.lang.String getProvenanceBytes() { - java.lang.Object ref = provenanceBytes_; - 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(); - provenanceBytes_ = s; - return s; - } - } - /** - * - * - *
-   * Serialized JSON representation of the provenance, used in generating the
-   * `BuildSignature` in the corresponding Result. After verifying the
-   * signature, `provenance_bytes` can be unmarshalled and compared to the
-   * provenance to confirm that it is unchanged. A base64-encoded string
-   * representation of the provenance bytes is used for the signature in order
-   * to interoperate with openssl which expects this format for signature
-   * verification.
-   * The serialized form is captured both to avoid ambiguity in how the
-   * provenance is marshalled to json as well to prevent incompatibilities with
-   * future changes.
-   * 
- * - * string provenance_bytes = 2; - */ - public com.google.protobuf.ByteString getProvenanceBytesBytes() { - java.lang.Object ref = provenanceBytes_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - provenanceBytes_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (provenance_ != null) { - output.writeMessage(1, getProvenance()); - } - if (!getProvenanceBytesBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, provenanceBytes_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (provenance_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getProvenance()); - } - if (!getProvenanceBytesBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, provenanceBytes_); - } - 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 io.grafeas.v1beta1.build.Details)) { - return super.equals(obj); - } - io.grafeas.v1beta1.build.Details other = (io.grafeas.v1beta1.build.Details) obj; - - if (hasProvenance() != other.hasProvenance()) return false; - if (hasProvenance()) { - if (!getProvenance().equals(other.getProvenance())) return false; - } - if (!getProvenanceBytes().equals(other.getProvenanceBytes())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasProvenance()) { - hash = (37 * hash) + PROVENANCE_FIELD_NUMBER; - hash = (53 * hash) + getProvenance().hashCode(); - } - hash = (37 * hash) + PROVENANCE_BYTES_FIELD_NUMBER; - hash = (53 * hash) + getProvenanceBytes().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.build.Details parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.build.Details parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.build.Details parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.build.Details parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.build.Details parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.build.Details parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.build.Details parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.build.Details 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 io.grafeas.v1beta1.build.Details parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.build.Details 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 io.grafeas.v1beta1.build.Details parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.build.Details 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(io.grafeas.v1beta1.build.Details 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; - } - /** - * - * - *
-   * Details of a build occurrence.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.build.Details} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.build.Details) - io.grafeas.v1beta1.build.DetailsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.build.Details.class, - io.grafeas.v1beta1.build.Details.Builder.class); - } - - // Construct using io.grafeas.v1beta1.build.Details.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (provenanceBuilder_ == null) { - provenance_ = null; - } else { - provenance_ = null; - provenanceBuilder_ = null; - } - provenanceBytes_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.build.BuildOuterClass - .internal_static_grafeas_v1beta1_build_Details_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.build.Details getDefaultInstanceForType() { - return io.grafeas.v1beta1.build.Details.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.build.Details build() { - io.grafeas.v1beta1.build.Details result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.build.Details buildPartial() { - io.grafeas.v1beta1.build.Details result = new io.grafeas.v1beta1.build.Details(this); - if (provenanceBuilder_ == null) { - result.provenance_ = provenance_; - } else { - result.provenance_ = provenanceBuilder_.build(); - } - result.provenanceBytes_ = provenanceBytes_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.build.Details) { - return mergeFrom((io.grafeas.v1beta1.build.Details) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.build.Details other) { - if (other == io.grafeas.v1beta1.build.Details.getDefaultInstance()) return this; - if (other.hasProvenance()) { - mergeProvenance(other.getProvenance()); - } - if (!other.getProvenanceBytes().isEmpty()) { - provenanceBytes_ = other.provenanceBytes_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.build.Details parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.build.Details) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private io.grafeas.v1beta1.provenance.BuildProvenance provenance_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.provenance.BuildProvenance, - io.grafeas.v1beta1.provenance.BuildProvenance.Builder, - io.grafeas.v1beta1.provenance.BuildProvenanceOrBuilder> - provenanceBuilder_; - /** - * - * - *
-     * The actual provenance for the build.
-     * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - public boolean hasProvenance() { - return provenanceBuilder_ != null || provenance_ != null; - } - /** - * - * - *
-     * The actual provenance for the build.
-     * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - public io.grafeas.v1beta1.provenance.BuildProvenance getProvenance() { - if (provenanceBuilder_ == null) { - return provenance_ == null - ? io.grafeas.v1beta1.provenance.BuildProvenance.getDefaultInstance() - : provenance_; - } else { - return provenanceBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The actual provenance for the build.
-     * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - public Builder setProvenance(io.grafeas.v1beta1.provenance.BuildProvenance value) { - if (provenanceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - provenance_ = value; - onChanged(); - } else { - provenanceBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The actual provenance for the build.
-     * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - public Builder setProvenance( - io.grafeas.v1beta1.provenance.BuildProvenance.Builder builderForValue) { - if (provenanceBuilder_ == null) { - provenance_ = builderForValue.build(); - onChanged(); - } else { - provenanceBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The actual provenance for the build.
-     * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - public Builder mergeProvenance(io.grafeas.v1beta1.provenance.BuildProvenance value) { - if (provenanceBuilder_ == null) { - if (provenance_ != null) { - provenance_ = - io.grafeas.v1beta1.provenance.BuildProvenance.newBuilder(provenance_) - .mergeFrom(value) - .buildPartial(); - } else { - provenance_ = value; - } - onChanged(); - } else { - provenanceBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The actual provenance for the build.
-     * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - public Builder clearProvenance() { - if (provenanceBuilder_ == null) { - provenance_ = null; - onChanged(); - } else { - provenance_ = null; - provenanceBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The actual provenance for the build.
-     * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - public io.grafeas.v1beta1.provenance.BuildProvenance.Builder getProvenanceBuilder() { - - onChanged(); - return getProvenanceFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The actual provenance for the build.
-     * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - public io.grafeas.v1beta1.provenance.BuildProvenanceOrBuilder getProvenanceOrBuilder() { - if (provenanceBuilder_ != null) { - return provenanceBuilder_.getMessageOrBuilder(); - } else { - return provenance_ == null - ? io.grafeas.v1beta1.provenance.BuildProvenance.getDefaultInstance() - : provenance_; - } - } - /** - * - * - *
-     * The actual provenance for the build.
-     * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.provenance.BuildProvenance, - io.grafeas.v1beta1.provenance.BuildProvenance.Builder, - io.grafeas.v1beta1.provenance.BuildProvenanceOrBuilder> - getProvenanceFieldBuilder() { - if (provenanceBuilder_ == null) { - provenanceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.provenance.BuildProvenance, - io.grafeas.v1beta1.provenance.BuildProvenance.Builder, - io.grafeas.v1beta1.provenance.BuildProvenanceOrBuilder>( - getProvenance(), getParentForChildren(), isClean()); - provenance_ = null; - } - return provenanceBuilder_; - } - - private java.lang.Object provenanceBytes_ = ""; - /** - * - * - *
-     * Serialized JSON representation of the provenance, used in generating the
-     * `BuildSignature` in the corresponding Result. After verifying the
-     * signature, `provenance_bytes` can be unmarshalled and compared to the
-     * provenance to confirm that it is unchanged. A base64-encoded string
-     * representation of the provenance bytes is used for the signature in order
-     * to interoperate with openssl which expects this format for signature
-     * verification.
-     * The serialized form is captured both to avoid ambiguity in how the
-     * provenance is marshalled to json as well to prevent incompatibilities with
-     * future changes.
-     * 
- * - * string provenance_bytes = 2; - */ - public java.lang.String getProvenanceBytes() { - java.lang.Object ref = provenanceBytes_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - provenanceBytes_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Serialized JSON representation of the provenance, used in generating the
-     * `BuildSignature` in the corresponding Result. After verifying the
-     * signature, `provenance_bytes` can be unmarshalled and compared to the
-     * provenance to confirm that it is unchanged. A base64-encoded string
-     * representation of the provenance bytes is used for the signature in order
-     * to interoperate with openssl which expects this format for signature
-     * verification.
-     * The serialized form is captured both to avoid ambiguity in how the
-     * provenance is marshalled to json as well to prevent incompatibilities with
-     * future changes.
-     * 
- * - * string provenance_bytes = 2; - */ - public com.google.protobuf.ByteString getProvenanceBytesBytes() { - java.lang.Object ref = provenanceBytes_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - provenanceBytes_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Serialized JSON representation of the provenance, used in generating the
-     * `BuildSignature` in the corresponding Result. After verifying the
-     * signature, `provenance_bytes` can be unmarshalled and compared to the
-     * provenance to confirm that it is unchanged. A base64-encoded string
-     * representation of the provenance bytes is used for the signature in order
-     * to interoperate with openssl which expects this format for signature
-     * verification.
-     * The serialized form is captured both to avoid ambiguity in how the
-     * provenance is marshalled to json as well to prevent incompatibilities with
-     * future changes.
-     * 
- * - * string provenance_bytes = 2; - */ - public Builder setProvenanceBytes(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - provenanceBytes_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Serialized JSON representation of the provenance, used in generating the
-     * `BuildSignature` in the corresponding Result. After verifying the
-     * signature, `provenance_bytes` can be unmarshalled and compared to the
-     * provenance to confirm that it is unchanged. A base64-encoded string
-     * representation of the provenance bytes is used for the signature in order
-     * to interoperate with openssl which expects this format for signature
-     * verification.
-     * The serialized form is captured both to avoid ambiguity in how the
-     * provenance is marshalled to json as well to prevent incompatibilities with
-     * future changes.
-     * 
- * - * string provenance_bytes = 2; - */ - public Builder clearProvenanceBytes() { - - provenanceBytes_ = getDefaultInstance().getProvenanceBytes(); - onChanged(); - return this; - } - /** - * - * - *
-     * Serialized JSON representation of the provenance, used in generating the
-     * `BuildSignature` in the corresponding Result. After verifying the
-     * signature, `provenance_bytes` can be unmarshalled and compared to the
-     * provenance to confirm that it is unchanged. A base64-encoded string
-     * representation of the provenance bytes is used for the signature in order
-     * to interoperate with openssl which expects this format for signature
-     * verification.
-     * The serialized form is captured both to avoid ambiguity in how the
-     * provenance is marshalled to json as well to prevent incompatibilities with
-     * future changes.
-     * 
- * - * string provenance_bytes = 2; - */ - public Builder setProvenanceBytesBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - provenanceBytes_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.build.Details) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.build.Details) - private static final io.grafeas.v1beta1.build.Details DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.build.Details(); - } - - public static io.grafeas.v1beta1.build.Details getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser
PARSER = - new com.google.protobuf.AbstractParser
() { - @java.lang.Override - public Details parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Details(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser
parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser
getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.build.Details getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/DetailsOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/DetailsOrBuilder.java deleted file mode 100644 index 36e933a1..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/DetailsOrBuilder.java +++ /dev/null @@ -1,80 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/build/build.proto - -package io.grafeas.v1beta1.build; - -public interface DetailsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.build.Details) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The actual provenance for the build.
-   * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - boolean hasProvenance(); - /** - * - * - *
-   * The actual provenance for the build.
-   * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - io.grafeas.v1beta1.provenance.BuildProvenance getProvenance(); - /** - * - * - *
-   * The actual provenance for the build.
-   * 
- * - * .grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - */ - io.grafeas.v1beta1.provenance.BuildProvenanceOrBuilder getProvenanceOrBuilder(); - - /** - * - * - *
-   * Serialized JSON representation of the provenance, used in generating the
-   * `BuildSignature` in the corresponding Result. After verifying the
-   * signature, `provenance_bytes` can be unmarshalled and compared to the
-   * provenance to confirm that it is unchanged. A base64-encoded string
-   * representation of the provenance bytes is used for the signature in order
-   * to interoperate with openssl which expects this format for signature
-   * verification.
-   * The serialized form is captured both to avoid ambiguity in how the
-   * provenance is marshalled to json as well to prevent incompatibilities with
-   * future changes.
-   * 
- * - * string provenance_bytes = 2; - */ - java.lang.String getProvenanceBytes(); - /** - * - * - *
-   * Serialized JSON representation of the provenance, used in generating the
-   * `BuildSignature` in the corresponding Result. After verifying the
-   * signature, `provenance_bytes` can be unmarshalled and compared to the
-   * provenance to confirm that it is unchanged. A base64-encoded string
-   * representation of the provenance bytes is used for the signature in order
-   * to interoperate with openssl which expects this format for signature
-   * verification.
-   * The serialized form is captured both to avoid ambiguity in how the
-   * provenance is marshalled to json as well to prevent incompatibilities with
-   * future changes.
-   * 
- * - * string provenance_bytes = 2; - */ - com.google.protobuf.ByteString getProvenanceBytesBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/IamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/IamResourceName.java deleted file mode 100644 index 91a46c38..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/IamResourceName.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.build; - -import com.google.api.resourcenames.ResourceName; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public abstract class IamResourceName implements ResourceName { - protected IamResourceName() {} -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/IamResourceNames.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/IamResourceNames.java deleted file mode 100644 index 9e14a3dd..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/IamResourceNames.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.build; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class IamResourceNames { - private IamResourceNames() {} - - public static IamResourceName parse(String resourceNameString) { - if (NoteName.isParsableFrom(resourceNameString)) { - return NoteName.parse(resourceNameString); - } - if (OccurrenceName.isParsableFrom(resourceNameString)) { - return OccurrenceName.parse(resourceNameString); - } - return UntypedIamResourceName.parse(resourceNameString); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/NoteName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/NoteName.java deleted file mode 100644 index 5f988dd0..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/NoteName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.build; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class NoteName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/notes/{note}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/OccurrenceName.java deleted file mode 100644 index 72db9e03..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.build; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/ProjectName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/ProjectName.java deleted file mode 100644 index 925e34e3..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.build; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/ScanConfigName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/ScanConfigName.java deleted file mode 100644 index 2a576d48..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/ScanConfigName.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.build; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ScanConfigName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ScanConfigName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - scanConfig = Preconditions.checkNotNull(builder.getScanConfig()); - } - - public static ScanConfigName of(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build(); - } - - public static String format(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build().toString(); - } - - public static ScanConfigName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ScanConfigName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("scan_config")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ScanConfigName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("scanConfig", scanConfig); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "scan_config", scanConfig); - } - - /** Builder for ScanConfigName. */ - public static class Builder { - - private String project; - private String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setScanConfig(String scanConfig) { - this.scanConfig = scanConfig; - return this; - } - - private Builder() {} - - private Builder(ScanConfigName scanConfigName) { - project = scanConfigName.project; - scanConfig = scanConfigName.scanConfig; - } - - public ScanConfigName build() { - return new ScanConfigName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ScanConfigName) { - ScanConfigName that = (ScanConfigName) o; - return (this.project.equals(that.project)) && (this.scanConfig.equals(that.scanConfig)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= scanConfig.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/UntypedIamResourceName.java deleted file mode 100644 index e53e25cc..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/build/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.build; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/Common.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/Common.java deleted file mode 100644 index 412b065b..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/Common.java +++ /dev/null @@ -1,60 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/common/common.proto - -package io.grafeas.v1beta1.common; - -public final class Common { - private Common() {} - - 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_grafeas_v1beta1_RelatedUrl_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_RelatedUrl_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/devtools/containeranalysis/v1be" - + "ta1/common/common.proto\022\017grafeas.v1beta1" - + "\"(\n\nRelatedUrl\022\013\n\003url\030\001 \001(\t\022\r\n\005label\030\002 \001" - + "(\t*\213\001\n\010NoteKind\022\031\n\025NOTE_KIND_UNSPECIFIED" - + "\020\000\022\021\n\rVULNERABILITY\020\001\022\t\n\005BUILD\020\002\022\t\n\005IMAG" - + "E\020\003\022\013\n\007PACKAGE\020\004\022\016\n\nDEPLOYMENT\020\005\022\r\n\tDISC" - + "OVERY\020\006\022\017\n\013ATTESTATION\020\007B{\n\031io.grafeas.v" - + "1beta1.commonP\001ZVgoogle.golang.org/genpr" - + "oto/googleapis/devtools/containeranalysi" - + "s/v1beta1/common;common\242\002\003GRAb\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[] {}, assigner); - internal_static_grafeas_v1beta1_RelatedUrl_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_grafeas_v1beta1_RelatedUrl_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_RelatedUrl_descriptor, - new java.lang.String[] { - "Url", "Label", - }); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/IamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/IamResourceName.java deleted file mode 100644 index 264ca3cb..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/IamResourceName.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.common; - -import com.google.api.resourcenames.ResourceName; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public abstract class IamResourceName implements ResourceName { - protected IamResourceName() {} -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/IamResourceNames.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/IamResourceNames.java deleted file mode 100644 index 53b328cc..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/IamResourceNames.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.common; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class IamResourceNames { - private IamResourceNames() {} - - public static IamResourceName parse(String resourceNameString) { - if (NoteName.isParsableFrom(resourceNameString)) { - return NoteName.parse(resourceNameString); - } - if (OccurrenceName.isParsableFrom(resourceNameString)) { - return OccurrenceName.parse(resourceNameString); - } - return UntypedIamResourceName.parse(resourceNameString); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/NoteKind.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/NoteKind.java deleted file mode 100644 index 843e9430..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/NoteKind.java +++ /dev/null @@ -1,259 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/common/common.proto - -package io.grafeas.v1beta1.common; - -/** - * - * - *
- * Kind represents the kinds of notes supported.
- * 
- * - * Protobuf enum {@code grafeas.v1beta1.NoteKind} - */ -public enum NoteKind implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-   * Unknown.
-   * 
- * - * NOTE_KIND_UNSPECIFIED = 0; - */ - NOTE_KIND_UNSPECIFIED(0), - /** - * - * - *
-   * The note and occurrence represent a package vulnerability.
-   * 
- * - * VULNERABILITY = 1; - */ - VULNERABILITY(1), - /** - * - * - *
-   * The note and occurrence assert build provenance.
-   * 
- * - * BUILD = 2; - */ - BUILD(2), - /** - * - * - *
-   * This represents an image basis relationship.
-   * 
- * - * IMAGE = 3; - */ - IMAGE(3), - /** - * - * - *
-   * This represents a package installed via a package manager.
-   * 
- * - * PACKAGE = 4; - */ - PACKAGE(4), - /** - * - * - *
-   * The note and occurrence track deployment events.
-   * 
- * - * DEPLOYMENT = 5; - */ - DEPLOYMENT(5), - /** - * - * - *
-   * The note and occurrence track the initial discovery status of a resource.
-   * 
- * - * DISCOVERY = 6; - */ - DISCOVERY(6), - /** - * - * - *
-   * This represents a logical "role" that can attest to artifacts.
-   * 
- * - * ATTESTATION = 7; - */ - ATTESTATION(7), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-   * Unknown.
-   * 
- * - * NOTE_KIND_UNSPECIFIED = 0; - */ - public static final int NOTE_KIND_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-   * The note and occurrence represent a package vulnerability.
-   * 
- * - * VULNERABILITY = 1; - */ - public static final int VULNERABILITY_VALUE = 1; - /** - * - * - *
-   * The note and occurrence assert build provenance.
-   * 
- * - * BUILD = 2; - */ - public static final int BUILD_VALUE = 2; - /** - * - * - *
-   * This represents an image basis relationship.
-   * 
- * - * IMAGE = 3; - */ - public static final int IMAGE_VALUE = 3; - /** - * - * - *
-   * This represents a package installed via a package manager.
-   * 
- * - * PACKAGE = 4; - */ - public static final int PACKAGE_VALUE = 4; - /** - * - * - *
-   * The note and occurrence track deployment events.
-   * 
- * - * DEPLOYMENT = 5; - */ - public static final int DEPLOYMENT_VALUE = 5; - /** - * - * - *
-   * The note and occurrence track the initial discovery status of a resource.
-   * 
- * - * DISCOVERY = 6; - */ - public static final int DISCOVERY_VALUE = 6; - /** - * - * - *
-   * This represents a logical "role" that can attest to artifacts.
-   * 
- * - * ATTESTATION = 7; - */ - public static final int ATTESTATION_VALUE = 7; - - 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 NoteKind valueOf(int value) { - return forNumber(value); - } - - public static NoteKind forNumber(int value) { - switch (value) { - case 0: - return NOTE_KIND_UNSPECIFIED; - case 1: - return VULNERABILITY; - case 2: - return BUILD; - case 3: - return IMAGE; - case 4: - return PACKAGE; - case 5: - return DEPLOYMENT; - case 6: - return DISCOVERY; - case 7: - return ATTESTATION; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public NoteKind findValueByNumber(int number) { - return NoteKind.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return io.grafeas.v1beta1.common.Common.getDescriptor().getEnumTypes().get(0); - } - - private static final NoteKind[] VALUES = values(); - - public static NoteKind valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private NoteKind(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:grafeas.v1beta1.NoteKind) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/NoteName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/NoteName.java deleted file mode 100644 index ba0046d8..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/NoteName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.common; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class NoteName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/notes/{note}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/OccurrenceName.java deleted file mode 100644 index ace07bb9..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.common; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/ProjectName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/ProjectName.java deleted file mode 100644 index 01f56aad..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.common; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/RelatedUrl.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/RelatedUrl.java deleted file mode 100644 index 5e1f4b96..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/RelatedUrl.java +++ /dev/null @@ -1,751 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/common/common.proto - -package io.grafeas.v1beta1.common; - -/** - * - * - *
- * Metadata for any related URL information.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.RelatedUrl} - */ -public final class RelatedUrl extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.RelatedUrl) - RelatedUrlOrBuilder { - private static final long serialVersionUID = 0L; - // Use RelatedUrl.newBuilder() to construct. - private RelatedUrl(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private RelatedUrl() { - url_ = ""; - label_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private RelatedUrl( - 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(); - - url_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - label_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.common.Common.internal_static_grafeas_v1beta1_RelatedUrl_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.common.Common - .internal_static_grafeas_v1beta1_RelatedUrl_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.common.RelatedUrl.class, - io.grafeas.v1beta1.common.RelatedUrl.Builder.class); - } - - public static final int URL_FIELD_NUMBER = 1; - private volatile java.lang.Object url_; - /** - * - * - *
-   * Specific URL associated with the resource.
-   * 
- * - * string url = 1; - */ - public java.lang.String getUrl() { - java.lang.Object ref = url_; - 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(); - url_ = s; - return s; - } - } - /** - * - * - *
-   * Specific URL associated with the resource.
-   * 
- * - * string url = 1; - */ - public com.google.protobuf.ByteString getUrlBytes() { - java.lang.Object ref = url_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - url_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int LABEL_FIELD_NUMBER = 2; - private volatile java.lang.Object label_; - /** - * - * - *
-   * Label to describe usage of the URL.
-   * 
- * - * string label = 2; - */ - public java.lang.String getLabel() { - java.lang.Object ref = label_; - 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(); - label_ = s; - return s; - } - } - /** - * - * - *
-   * Label to describe usage of the URL.
-   * 
- * - * string label = 2; - */ - public com.google.protobuf.ByteString getLabelBytes() { - java.lang.Object ref = label_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - label_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getUrlBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, url_); - } - if (!getLabelBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, label_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getUrlBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, url_); - } - if (!getLabelBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, label_); - } - 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 io.grafeas.v1beta1.common.RelatedUrl)) { - return super.equals(obj); - } - io.grafeas.v1beta1.common.RelatedUrl other = (io.grafeas.v1beta1.common.RelatedUrl) obj; - - if (!getUrl().equals(other.getUrl())) return false; - if (!getLabel().equals(other.getLabel())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + URL_FIELD_NUMBER; - hash = (53 * hash) + getUrl().hashCode(); - hash = (37 * hash) + LABEL_FIELD_NUMBER; - hash = (53 * hash) + getLabel().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.common.RelatedUrl parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.common.RelatedUrl parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.common.RelatedUrl parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.common.RelatedUrl parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.common.RelatedUrl parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.common.RelatedUrl parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.common.RelatedUrl parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.common.RelatedUrl 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 io.grafeas.v1beta1.common.RelatedUrl parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.common.RelatedUrl 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 io.grafeas.v1beta1.common.RelatedUrl parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.common.RelatedUrl 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(io.grafeas.v1beta1.common.RelatedUrl 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; - } - /** - * - * - *
-   * Metadata for any related URL information.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.RelatedUrl} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.RelatedUrl) - io.grafeas.v1beta1.common.RelatedUrlOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.common.Common.internal_static_grafeas_v1beta1_RelatedUrl_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.common.Common - .internal_static_grafeas_v1beta1_RelatedUrl_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.common.RelatedUrl.class, - io.grafeas.v1beta1.common.RelatedUrl.Builder.class); - } - - // Construct using io.grafeas.v1beta1.common.RelatedUrl.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - url_ = ""; - - label_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.common.Common.internal_static_grafeas_v1beta1_RelatedUrl_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.common.RelatedUrl getDefaultInstanceForType() { - return io.grafeas.v1beta1.common.RelatedUrl.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.common.RelatedUrl build() { - io.grafeas.v1beta1.common.RelatedUrl result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.common.RelatedUrl buildPartial() { - io.grafeas.v1beta1.common.RelatedUrl result = new io.grafeas.v1beta1.common.RelatedUrl(this); - result.url_ = url_; - result.label_ = label_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.common.RelatedUrl) { - return mergeFrom((io.grafeas.v1beta1.common.RelatedUrl) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.common.RelatedUrl other) { - if (other == io.grafeas.v1beta1.common.RelatedUrl.getDefaultInstance()) return this; - if (!other.getUrl().isEmpty()) { - url_ = other.url_; - onChanged(); - } - if (!other.getLabel().isEmpty()) { - label_ = other.label_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.common.RelatedUrl parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.common.RelatedUrl) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object url_ = ""; - /** - * - * - *
-     * Specific URL associated with the resource.
-     * 
- * - * string url = 1; - */ - public java.lang.String getUrl() { - java.lang.Object ref = url_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - url_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Specific URL associated with the resource.
-     * 
- * - * string url = 1; - */ - public com.google.protobuf.ByteString getUrlBytes() { - java.lang.Object ref = url_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - url_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Specific URL associated with the resource.
-     * 
- * - * string url = 1; - */ - public Builder setUrl(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - url_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Specific URL associated with the resource.
-     * 
- * - * string url = 1; - */ - public Builder clearUrl() { - - url_ = getDefaultInstance().getUrl(); - onChanged(); - return this; - } - /** - * - * - *
-     * Specific URL associated with the resource.
-     * 
- * - * string url = 1; - */ - public Builder setUrlBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - url_ = value; - onChanged(); - return this; - } - - private java.lang.Object label_ = ""; - /** - * - * - *
-     * Label to describe usage of the URL.
-     * 
- * - * string label = 2; - */ - public java.lang.String getLabel() { - java.lang.Object ref = label_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - label_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Label to describe usage of the URL.
-     * 
- * - * string label = 2; - */ - public com.google.protobuf.ByteString getLabelBytes() { - java.lang.Object ref = label_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - label_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Label to describe usage of the URL.
-     * 
- * - * string label = 2; - */ - public Builder setLabel(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - label_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Label to describe usage of the URL.
-     * 
- * - * string label = 2; - */ - public Builder clearLabel() { - - label_ = getDefaultInstance().getLabel(); - onChanged(); - return this; - } - /** - * - * - *
-     * Label to describe usage of the URL.
-     * 
- * - * string label = 2; - */ - public Builder setLabelBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - label_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.RelatedUrl) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.RelatedUrl) - private static final io.grafeas.v1beta1.common.RelatedUrl DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.common.RelatedUrl(); - } - - public static io.grafeas.v1beta1.common.RelatedUrl getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public RelatedUrl parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RelatedUrl(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.common.RelatedUrl getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/RelatedUrlOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/RelatedUrlOrBuilder.java deleted file mode 100644 index c796400b..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/RelatedUrlOrBuilder.java +++ /dev/null @@ -1,52 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/common/common.proto - -package io.grafeas.v1beta1.common; - -public interface RelatedUrlOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.RelatedUrl) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Specific URL associated with the resource.
-   * 
- * - * string url = 1; - */ - java.lang.String getUrl(); - /** - * - * - *
-   * Specific URL associated with the resource.
-   * 
- * - * string url = 1; - */ - com.google.protobuf.ByteString getUrlBytes(); - - /** - * - * - *
-   * Label to describe usage of the URL.
-   * 
- * - * string label = 2; - */ - java.lang.String getLabel(); - /** - * - * - *
-   * Label to describe usage of the URL.
-   * 
- * - * string label = 2; - */ - com.google.protobuf.ByteString getLabelBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/ScanConfigName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/ScanConfigName.java deleted file mode 100644 index f018b59c..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/ScanConfigName.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.common; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ScanConfigName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ScanConfigName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - scanConfig = Preconditions.checkNotNull(builder.getScanConfig()); - } - - public static ScanConfigName of(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build(); - } - - public static String format(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build().toString(); - } - - public static ScanConfigName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ScanConfigName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("scan_config")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ScanConfigName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("scanConfig", scanConfig); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "scan_config", scanConfig); - } - - /** Builder for ScanConfigName. */ - public static class Builder { - - private String project; - private String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setScanConfig(String scanConfig) { - this.scanConfig = scanConfig; - return this; - } - - private Builder() {} - - private Builder(ScanConfigName scanConfigName) { - project = scanConfigName.project; - scanConfig = scanConfigName.scanConfig; - } - - public ScanConfigName build() { - return new ScanConfigName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ScanConfigName) { - ScanConfigName that = (ScanConfigName) o; - return (this.project.equals(that.project)) && (this.scanConfig.equals(that.scanConfig)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= scanConfig.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/UntypedIamResourceName.java deleted file mode 100644 index 7e42c3ce..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/common/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.common; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/Deployable.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/Deployable.java deleted file mode 100644 index 58543ce8..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/Deployable.java +++ /dev/null @@ -1,678 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/deployment/deployment.proto - -package io.grafeas.v1beta1.deployment; - -/** - * - * - *
- * An artifact that can be deployed in some runtime.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.deployment.Deployable} - */ -public final class Deployable extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.deployment.Deployable) - DeployableOrBuilder { - private static final long serialVersionUID = 0L; - // Use Deployable.newBuilder() to construct. - private Deployable(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Deployable() { - resourceUri_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Deployable( - 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(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - resourceUri_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - resourceUri_.add(s); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000001) != 0)) { - resourceUri_ = resourceUri_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Deployable_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Deployable_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.deployment.Deployable.class, - io.grafeas.v1beta1.deployment.Deployable.Builder.class); - } - - public static final int RESOURCE_URI_FIELD_NUMBER = 1; - private com.google.protobuf.LazyStringList resourceUri_; - /** - * - * - *
-   * Resource URI for the artifact being deployed.
-   * 
- * - * repeated string resource_uri = 1; - */ - public com.google.protobuf.ProtocolStringList getResourceUriList() { - return resourceUri_; - } - /** - * - * - *
-   * Resource URI for the artifact being deployed.
-   * 
- * - * repeated string resource_uri = 1; - */ - public int getResourceUriCount() { - return resourceUri_.size(); - } - /** - * - * - *
-   * Resource URI for the artifact being deployed.
-   * 
- * - * repeated string resource_uri = 1; - */ - public java.lang.String getResourceUri(int index) { - return resourceUri_.get(index); - } - /** - * - * - *
-   * Resource URI for the artifact being deployed.
-   * 
- * - * repeated string resource_uri = 1; - */ - public com.google.protobuf.ByteString getResourceUriBytes(int index) { - return resourceUri_.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 { - for (int i = 0; i < resourceUri_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resourceUri_.getRaw(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - for (int i = 0; i < resourceUri_.size(); i++) { - dataSize += computeStringSizeNoTag(resourceUri_.getRaw(i)); - } - size += dataSize; - size += 1 * getResourceUriList().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 io.grafeas.v1beta1.deployment.Deployable)) { - return super.equals(obj); - } - io.grafeas.v1beta1.deployment.Deployable other = (io.grafeas.v1beta1.deployment.Deployable) obj; - - if (!getResourceUriList().equals(other.getResourceUriList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getResourceUriCount() > 0) { - hash = (37 * hash) + RESOURCE_URI_FIELD_NUMBER; - hash = (53 * hash) + getResourceUriList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.deployment.Deployable parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.deployment.Deployable parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.deployment.Deployable parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.deployment.Deployable parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.deployment.Deployable parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.deployment.Deployable parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.deployment.Deployable parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.deployment.Deployable 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 io.grafeas.v1beta1.deployment.Deployable parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.deployment.Deployable 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 io.grafeas.v1beta1.deployment.Deployable parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.deployment.Deployable 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(io.grafeas.v1beta1.deployment.Deployable 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; - } - /** - * - * - *
-   * An artifact that can be deployed in some runtime.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.deployment.Deployable} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.deployment.Deployable) - io.grafeas.v1beta1.deployment.DeployableOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Deployable_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Deployable_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.deployment.Deployable.class, - io.grafeas.v1beta1.deployment.Deployable.Builder.class); - } - - // Construct using io.grafeas.v1beta1.deployment.Deployable.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - resourceUri_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Deployable_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.deployment.Deployable getDefaultInstanceForType() { - return io.grafeas.v1beta1.deployment.Deployable.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.deployment.Deployable build() { - io.grafeas.v1beta1.deployment.Deployable result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.deployment.Deployable buildPartial() { - io.grafeas.v1beta1.deployment.Deployable result = - new io.grafeas.v1beta1.deployment.Deployable(this); - int from_bitField0_ = bitField0_; - if (((bitField0_ & 0x00000001) != 0)) { - resourceUri_ = resourceUri_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.resourceUri_ = resourceUri_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.deployment.Deployable) { - return mergeFrom((io.grafeas.v1beta1.deployment.Deployable) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.deployment.Deployable other) { - if (other == io.grafeas.v1beta1.deployment.Deployable.getDefaultInstance()) return this; - if (!other.resourceUri_.isEmpty()) { - if (resourceUri_.isEmpty()) { - resourceUri_ = other.resourceUri_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureResourceUriIsMutable(); - resourceUri_.addAll(other.resourceUri_); - } - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.deployment.Deployable parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.deployment.Deployable) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private com.google.protobuf.LazyStringList resourceUri_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureResourceUriIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - resourceUri_ = new com.google.protobuf.LazyStringArrayList(resourceUri_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-     * Resource URI for the artifact being deployed.
-     * 
- * - * repeated string resource_uri = 1; - */ - public com.google.protobuf.ProtocolStringList getResourceUriList() { - return resourceUri_.getUnmodifiableView(); - } - /** - * - * - *
-     * Resource URI for the artifact being deployed.
-     * 
- * - * repeated string resource_uri = 1; - */ - public int getResourceUriCount() { - return resourceUri_.size(); - } - /** - * - * - *
-     * Resource URI for the artifact being deployed.
-     * 
- * - * repeated string resource_uri = 1; - */ - public java.lang.String getResourceUri(int index) { - return resourceUri_.get(index); - } - /** - * - * - *
-     * Resource URI for the artifact being deployed.
-     * 
- * - * repeated string resource_uri = 1; - */ - public com.google.protobuf.ByteString getResourceUriBytes(int index) { - return resourceUri_.getByteString(index); - } - /** - * - * - *
-     * Resource URI for the artifact being deployed.
-     * 
- * - * repeated string resource_uri = 1; - */ - public Builder setResourceUri(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureResourceUriIsMutable(); - resourceUri_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * Resource URI for the artifact being deployed.
-     * 
- * - * repeated string resource_uri = 1; - */ - public Builder addResourceUri(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureResourceUriIsMutable(); - resourceUri_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * Resource URI for the artifact being deployed.
-     * 
- * - * repeated string resource_uri = 1; - */ - public Builder addAllResourceUri(java.lang.Iterable values) { - ensureResourceUriIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, resourceUri_); - onChanged(); - return this; - } - /** - * - * - *
-     * Resource URI for the artifact being deployed.
-     * 
- * - * repeated string resource_uri = 1; - */ - public Builder clearResourceUri() { - resourceUri_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-     * Resource URI for the artifact being deployed.
-     * 
- * - * repeated string resource_uri = 1; - */ - public Builder addResourceUriBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureResourceUriIsMutable(); - resourceUri_.add(value); - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.deployment.Deployable) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.deployment.Deployable) - private static final io.grafeas.v1beta1.deployment.Deployable DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.deployment.Deployable(); - } - - public static io.grafeas.v1beta1.deployment.Deployable getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Deployable parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Deployable(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.deployment.Deployable getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DeployableOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DeployableOrBuilder.java deleted file mode 100644 index 8933181d..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DeployableOrBuilder.java +++ /dev/null @@ -1,51 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/deployment/deployment.proto - -package io.grafeas.v1beta1.deployment; - -public interface DeployableOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.deployment.Deployable) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Resource URI for the artifact being deployed.
-   * 
- * - * repeated string resource_uri = 1; - */ - java.util.List getResourceUriList(); - /** - * - * - *
-   * Resource URI for the artifact being deployed.
-   * 
- * - * repeated string resource_uri = 1; - */ - int getResourceUriCount(); - /** - * - * - *
-   * Resource URI for the artifact being deployed.
-   * 
- * - * repeated string resource_uri = 1; - */ - java.lang.String getResourceUri(int index); - /** - * - * - *
-   * Resource URI for the artifact being deployed.
-   * 
- * - * repeated string resource_uri = 1; - */ - com.google.protobuf.ByteString getResourceUriBytes(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/Deployment.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/Deployment.java deleted file mode 100644 index f164a421..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/Deployment.java +++ /dev/null @@ -1,2003 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/deployment/deployment.proto - -package io.grafeas.v1beta1.deployment; - -/** - * - * - *
- * The period during which some deployable was active in a runtime.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.deployment.Deployment} - */ -public final class Deployment extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.deployment.Deployment) - DeploymentOrBuilder { - private static final long serialVersionUID = 0L; - // Use Deployment.newBuilder() to construct. - private Deployment(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Deployment() { - userEmail_ = ""; - config_ = ""; - address_ = ""; - resourceUri_ = com.google.protobuf.LazyStringArrayList.EMPTY; - platform_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Deployment( - 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(); - - userEmail_ = s; - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (deployTime_ != null) { - subBuilder = deployTime_.toBuilder(); - } - deployTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(deployTime_); - deployTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (undeployTime_ != null) { - subBuilder = undeployTime_.toBuilder(); - } - undeployTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(undeployTime_); - undeployTime_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - config_ = s; - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - address_ = s; - break; - } - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000020) != 0)) { - resourceUri_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000020; - } - resourceUri_.add(s); - break; - } - case 56: - { - int rawValue = input.readEnum(); - - platform_ = rawValue; - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000020) != 0)) { - resourceUri_ = resourceUri_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Deployment_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Deployment_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.deployment.Deployment.class, - io.grafeas.v1beta1.deployment.Deployment.Builder.class); - } - - /** - * - * - *
-   * Types of platforms.
-   * 
- * - * Protobuf enum {@code grafeas.v1beta1.deployment.Deployment.Platform} - */ - public enum Platform implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Unknown.
-     * 
- * - * PLATFORM_UNSPECIFIED = 0; - */ - PLATFORM_UNSPECIFIED(0), - /** - * - * - *
-     * Google Container Engine.
-     * 
- * - * GKE = 1; - */ - GKE(1), - /** - * - * - *
-     * Google App Engine: Flexible Environment.
-     * 
- * - * FLEX = 2; - */ - FLEX(2), - /** - * - * - *
-     * Custom user-defined platform.
-     * 
- * - * CUSTOM = 3; - */ - CUSTOM(3), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Unknown.
-     * 
- * - * PLATFORM_UNSPECIFIED = 0; - */ - public static final int PLATFORM_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * Google Container Engine.
-     * 
- * - * GKE = 1; - */ - public static final int GKE_VALUE = 1; - /** - * - * - *
-     * Google App Engine: Flexible Environment.
-     * 
- * - * FLEX = 2; - */ - public static final int FLEX_VALUE = 2; - /** - * - * - *
-     * Custom user-defined platform.
-     * 
- * - * CUSTOM = 3; - */ - public static final int CUSTOM_VALUE = 3; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static Platform valueOf(int value) { - return forNumber(value); - } - - public static Platform forNumber(int value) { - switch (value) { - case 0: - return PLATFORM_UNSPECIFIED; - case 1: - return GKE; - case 2: - return FLEX; - case 3: - return CUSTOM; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Platform findValueByNumber(int number) { - return Platform.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return io.grafeas.v1beta1.deployment.Deployment.getDescriptor().getEnumTypes().get(0); - } - - private static final Platform[] VALUES = values(); - - public static Platform valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Platform(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:grafeas.v1beta1.deployment.Deployment.Platform) - } - - private int bitField0_; - public static final int USER_EMAIL_FIELD_NUMBER = 1; - private volatile java.lang.Object userEmail_; - /** - * - * - *
-   * Identity of the user that triggered this deployment.
-   * 
- * - * string user_email = 1; - */ - public java.lang.String getUserEmail() { - java.lang.Object ref = userEmail_; - 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(); - userEmail_ = s; - return s; - } - } - /** - * - * - *
-   * Identity of the user that triggered this deployment.
-   * 
- * - * string user_email = 1; - */ - public com.google.protobuf.ByteString getUserEmailBytes() { - java.lang.Object ref = userEmail_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - userEmail_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DEPLOY_TIME_FIELD_NUMBER = 2; - private com.google.protobuf.Timestamp deployTime_; - /** - * - * - *
-   * Beginning of the lifetime of this deployment.
-   * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - public boolean hasDeployTime() { - return deployTime_ != null; - } - /** - * - * - *
-   * Beginning of the lifetime of this deployment.
-   * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - public com.google.protobuf.Timestamp getDeployTime() { - return deployTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : deployTime_; - } - /** - * - * - *
-   * Beginning of the lifetime of this deployment.
-   * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - public com.google.protobuf.TimestampOrBuilder getDeployTimeOrBuilder() { - return getDeployTime(); - } - - public static final int UNDEPLOY_TIME_FIELD_NUMBER = 3; - private com.google.protobuf.Timestamp undeployTime_; - /** - * - * - *
-   * End of the lifetime of this deployment.
-   * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - public boolean hasUndeployTime() { - return undeployTime_ != null; - } - /** - * - * - *
-   * End of the lifetime of this deployment.
-   * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - public com.google.protobuf.Timestamp getUndeployTime() { - return undeployTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : undeployTime_; - } - /** - * - * - *
-   * End of the lifetime of this deployment.
-   * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - public com.google.protobuf.TimestampOrBuilder getUndeployTimeOrBuilder() { - return getUndeployTime(); - } - - public static final int CONFIG_FIELD_NUMBER = 4; - private volatile java.lang.Object config_; - /** - * - * - *
-   * Configuration used to create this deployment.
-   * 
- * - * string config = 4; - */ - public java.lang.String getConfig() { - java.lang.Object ref = config_; - 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(); - config_ = s; - return s; - } - } - /** - * - * - *
-   * Configuration used to create this deployment.
-   * 
- * - * string config = 4; - */ - public com.google.protobuf.ByteString getConfigBytes() { - java.lang.Object ref = config_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - config_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ADDRESS_FIELD_NUMBER = 5; - private volatile java.lang.Object address_; - /** - * - * - *
-   * Address of the runtime element hosting this deployment.
-   * 
- * - * string address = 5; - */ - public java.lang.String getAddress() { - java.lang.Object ref = address_; - 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(); - address_ = s; - return s; - } - } - /** - * - * - *
-   * Address of the runtime element hosting this deployment.
-   * 
- * - * string address = 5; - */ - public com.google.protobuf.ByteString getAddressBytes() { - java.lang.Object ref = address_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - address_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int RESOURCE_URI_FIELD_NUMBER = 6; - private com.google.protobuf.LazyStringList resourceUri_; - /** - * - * - *
-   * Output only. Resource URI for the artifact being deployed taken from
-   * the deployable field with the same name.
-   * 
- * - * repeated string resource_uri = 6; - */ - public com.google.protobuf.ProtocolStringList getResourceUriList() { - return resourceUri_; - } - /** - * - * - *
-   * Output only. Resource URI for the artifact being deployed taken from
-   * the deployable field with the same name.
-   * 
- * - * repeated string resource_uri = 6; - */ - public int getResourceUriCount() { - return resourceUri_.size(); - } - /** - * - * - *
-   * Output only. Resource URI for the artifact being deployed taken from
-   * the deployable field with the same name.
-   * 
- * - * repeated string resource_uri = 6; - */ - public java.lang.String getResourceUri(int index) { - return resourceUri_.get(index); - } - /** - * - * - *
-   * Output only. Resource URI for the artifact being deployed taken from
-   * the deployable field with the same name.
-   * 
- * - * repeated string resource_uri = 6; - */ - public com.google.protobuf.ByteString getResourceUriBytes(int index) { - return resourceUri_.getByteString(index); - } - - public static final int PLATFORM_FIELD_NUMBER = 7; - private int platform_; - /** - * - * - *
-   * Platform hosting this deployment.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployment.Platform platform = 7; - */ - public int getPlatformValue() { - return platform_; - } - /** - * - * - *
-   * Platform hosting this deployment.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployment.Platform platform = 7; - */ - public io.grafeas.v1beta1.deployment.Deployment.Platform getPlatform() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.deployment.Deployment.Platform result = - io.grafeas.v1beta1.deployment.Deployment.Platform.valueOf(platform_); - return result == null ? io.grafeas.v1beta1.deployment.Deployment.Platform.UNRECOGNIZED : result; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getUserEmailBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, userEmail_); - } - if (deployTime_ != null) { - output.writeMessage(2, getDeployTime()); - } - if (undeployTime_ != null) { - output.writeMessage(3, getUndeployTime()); - } - if (!getConfigBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, config_); - } - if (!getAddressBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, address_); - } - for (int i = 0; i < resourceUri_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 6, resourceUri_.getRaw(i)); - } - if (platform_ - != io.grafeas.v1beta1.deployment.Deployment.Platform.PLATFORM_UNSPECIFIED.getNumber()) { - output.writeEnum(7, platform_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getUserEmailBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, userEmail_); - } - if (deployTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getDeployTime()); - } - if (undeployTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getUndeployTime()); - } - if (!getConfigBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, config_); - } - if (!getAddressBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, address_); - } - { - int dataSize = 0; - for (int i = 0; i < resourceUri_.size(); i++) { - dataSize += computeStringSizeNoTag(resourceUri_.getRaw(i)); - } - size += dataSize; - size += 1 * getResourceUriList().size(); - } - if (platform_ - != io.grafeas.v1beta1.deployment.Deployment.Platform.PLATFORM_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(7, platform_); - } - 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 io.grafeas.v1beta1.deployment.Deployment)) { - return super.equals(obj); - } - io.grafeas.v1beta1.deployment.Deployment other = (io.grafeas.v1beta1.deployment.Deployment) obj; - - if (!getUserEmail().equals(other.getUserEmail())) return false; - if (hasDeployTime() != other.hasDeployTime()) return false; - if (hasDeployTime()) { - if (!getDeployTime().equals(other.getDeployTime())) return false; - } - if (hasUndeployTime() != other.hasUndeployTime()) return false; - if (hasUndeployTime()) { - if (!getUndeployTime().equals(other.getUndeployTime())) return false; - } - if (!getConfig().equals(other.getConfig())) return false; - if (!getAddress().equals(other.getAddress())) return false; - if (!getResourceUriList().equals(other.getResourceUriList())) return false; - if (platform_ != other.platform_) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + USER_EMAIL_FIELD_NUMBER; - hash = (53 * hash) + getUserEmail().hashCode(); - if (hasDeployTime()) { - hash = (37 * hash) + DEPLOY_TIME_FIELD_NUMBER; - hash = (53 * hash) + getDeployTime().hashCode(); - } - if (hasUndeployTime()) { - hash = (37 * hash) + UNDEPLOY_TIME_FIELD_NUMBER; - hash = (53 * hash) + getUndeployTime().hashCode(); - } - hash = (37 * hash) + CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getConfig().hashCode(); - hash = (37 * hash) + ADDRESS_FIELD_NUMBER; - hash = (53 * hash) + getAddress().hashCode(); - if (getResourceUriCount() > 0) { - hash = (37 * hash) + RESOURCE_URI_FIELD_NUMBER; - hash = (53 * hash) + getResourceUriList().hashCode(); - } - hash = (37 * hash) + PLATFORM_FIELD_NUMBER; - hash = (53 * hash) + platform_; - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.deployment.Deployment parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.deployment.Deployment parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.deployment.Deployment parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.deployment.Deployment parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.deployment.Deployment parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.deployment.Deployment parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.deployment.Deployment parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.deployment.Deployment 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 io.grafeas.v1beta1.deployment.Deployment parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.deployment.Deployment 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 io.grafeas.v1beta1.deployment.Deployment parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.deployment.Deployment 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(io.grafeas.v1beta1.deployment.Deployment 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; - } - /** - * - * - *
-   * The period during which some deployable was active in a runtime.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.deployment.Deployment} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.deployment.Deployment) - io.grafeas.v1beta1.deployment.DeploymentOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Deployment_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Deployment_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.deployment.Deployment.class, - io.grafeas.v1beta1.deployment.Deployment.Builder.class); - } - - // Construct using io.grafeas.v1beta1.deployment.Deployment.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - userEmail_ = ""; - - if (deployTimeBuilder_ == null) { - deployTime_ = null; - } else { - deployTime_ = null; - deployTimeBuilder_ = null; - } - if (undeployTimeBuilder_ == null) { - undeployTime_ = null; - } else { - undeployTime_ = null; - undeployTimeBuilder_ = null; - } - config_ = ""; - - address_ = ""; - - resourceUri_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000020); - platform_ = 0; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Deployment_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.deployment.Deployment getDefaultInstanceForType() { - return io.grafeas.v1beta1.deployment.Deployment.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.deployment.Deployment build() { - io.grafeas.v1beta1.deployment.Deployment result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.deployment.Deployment buildPartial() { - io.grafeas.v1beta1.deployment.Deployment result = - new io.grafeas.v1beta1.deployment.Deployment(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.userEmail_ = userEmail_; - if (deployTimeBuilder_ == null) { - result.deployTime_ = deployTime_; - } else { - result.deployTime_ = deployTimeBuilder_.build(); - } - if (undeployTimeBuilder_ == null) { - result.undeployTime_ = undeployTime_; - } else { - result.undeployTime_ = undeployTimeBuilder_.build(); - } - result.config_ = config_; - result.address_ = address_; - if (((bitField0_ & 0x00000020) != 0)) { - resourceUri_ = resourceUri_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000020); - } - result.resourceUri_ = resourceUri_; - result.platform_ = platform_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.deployment.Deployment) { - return mergeFrom((io.grafeas.v1beta1.deployment.Deployment) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.deployment.Deployment other) { - if (other == io.grafeas.v1beta1.deployment.Deployment.getDefaultInstance()) return this; - if (!other.getUserEmail().isEmpty()) { - userEmail_ = other.userEmail_; - onChanged(); - } - if (other.hasDeployTime()) { - mergeDeployTime(other.getDeployTime()); - } - if (other.hasUndeployTime()) { - mergeUndeployTime(other.getUndeployTime()); - } - if (!other.getConfig().isEmpty()) { - config_ = other.config_; - onChanged(); - } - if (!other.getAddress().isEmpty()) { - address_ = other.address_; - onChanged(); - } - if (!other.resourceUri_.isEmpty()) { - if (resourceUri_.isEmpty()) { - resourceUri_ = other.resourceUri_; - bitField0_ = (bitField0_ & ~0x00000020); - } else { - ensureResourceUriIsMutable(); - resourceUri_.addAll(other.resourceUri_); - } - onChanged(); - } - if (other.platform_ != 0) { - setPlatformValue(other.getPlatformValue()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.deployment.Deployment parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.deployment.Deployment) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object userEmail_ = ""; - /** - * - * - *
-     * Identity of the user that triggered this deployment.
-     * 
- * - * string user_email = 1; - */ - public java.lang.String getUserEmail() { - java.lang.Object ref = userEmail_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - userEmail_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Identity of the user that triggered this deployment.
-     * 
- * - * string user_email = 1; - */ - public com.google.protobuf.ByteString getUserEmailBytes() { - java.lang.Object ref = userEmail_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - userEmail_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Identity of the user that triggered this deployment.
-     * 
- * - * string user_email = 1; - */ - public Builder setUserEmail(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - userEmail_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Identity of the user that triggered this deployment.
-     * 
- * - * string user_email = 1; - */ - public Builder clearUserEmail() { - - userEmail_ = getDefaultInstance().getUserEmail(); - onChanged(); - return this; - } - /** - * - * - *
-     * Identity of the user that triggered this deployment.
-     * 
- * - * string user_email = 1; - */ - public Builder setUserEmailBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - userEmail_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.Timestamp deployTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - deployTimeBuilder_; - /** - * - * - *
-     * Beginning of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - public boolean hasDeployTime() { - return deployTimeBuilder_ != null || deployTime_ != null; - } - /** - * - * - *
-     * Beginning of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - public com.google.protobuf.Timestamp getDeployTime() { - if (deployTimeBuilder_ == null) { - return deployTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : deployTime_; - } else { - return deployTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Beginning of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - public Builder setDeployTime(com.google.protobuf.Timestamp value) { - if (deployTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - deployTime_ = value; - onChanged(); - } else { - deployTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Beginning of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - public Builder setDeployTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (deployTimeBuilder_ == null) { - deployTime_ = builderForValue.build(); - onChanged(); - } else { - deployTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Beginning of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - public Builder mergeDeployTime(com.google.protobuf.Timestamp value) { - if (deployTimeBuilder_ == null) { - if (deployTime_ != null) { - deployTime_ = - com.google.protobuf.Timestamp.newBuilder(deployTime_).mergeFrom(value).buildPartial(); - } else { - deployTime_ = value; - } - onChanged(); - } else { - deployTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Beginning of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - public Builder clearDeployTime() { - if (deployTimeBuilder_ == null) { - deployTime_ = null; - onChanged(); - } else { - deployTime_ = null; - deployTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Beginning of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - public com.google.protobuf.Timestamp.Builder getDeployTimeBuilder() { - - onChanged(); - return getDeployTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Beginning of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - public com.google.protobuf.TimestampOrBuilder getDeployTimeOrBuilder() { - if (deployTimeBuilder_ != null) { - return deployTimeBuilder_.getMessageOrBuilder(); - } else { - return deployTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : deployTime_; - } - } - /** - * - * - *
-     * Beginning of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getDeployTimeFieldBuilder() { - if (deployTimeBuilder_ == null) { - deployTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getDeployTime(), getParentForChildren(), isClean()); - deployTime_ = null; - } - return deployTimeBuilder_; - } - - private com.google.protobuf.Timestamp undeployTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - undeployTimeBuilder_; - /** - * - * - *
-     * End of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - public boolean hasUndeployTime() { - return undeployTimeBuilder_ != null || undeployTime_ != null; - } - /** - * - * - *
-     * End of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - public com.google.protobuf.Timestamp getUndeployTime() { - if (undeployTimeBuilder_ == null) { - return undeployTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : undeployTime_; - } else { - return undeployTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * End of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - public Builder setUndeployTime(com.google.protobuf.Timestamp value) { - if (undeployTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - undeployTime_ = value; - onChanged(); - } else { - undeployTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * End of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - public Builder setUndeployTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (undeployTimeBuilder_ == null) { - undeployTime_ = builderForValue.build(); - onChanged(); - } else { - undeployTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * End of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - public Builder mergeUndeployTime(com.google.protobuf.Timestamp value) { - if (undeployTimeBuilder_ == null) { - if (undeployTime_ != null) { - undeployTime_ = - com.google.protobuf.Timestamp.newBuilder(undeployTime_) - .mergeFrom(value) - .buildPartial(); - } else { - undeployTime_ = value; - } - onChanged(); - } else { - undeployTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * End of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - public Builder clearUndeployTime() { - if (undeployTimeBuilder_ == null) { - undeployTime_ = null; - onChanged(); - } else { - undeployTime_ = null; - undeployTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * End of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - public com.google.protobuf.Timestamp.Builder getUndeployTimeBuilder() { - - onChanged(); - return getUndeployTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * End of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - public com.google.protobuf.TimestampOrBuilder getUndeployTimeOrBuilder() { - if (undeployTimeBuilder_ != null) { - return undeployTimeBuilder_.getMessageOrBuilder(); - } else { - return undeployTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : undeployTime_; - } - } - /** - * - * - *
-     * End of the lifetime of this deployment.
-     * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getUndeployTimeFieldBuilder() { - if (undeployTimeBuilder_ == null) { - undeployTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getUndeployTime(), getParentForChildren(), isClean()); - undeployTime_ = null; - } - return undeployTimeBuilder_; - } - - private java.lang.Object config_ = ""; - /** - * - * - *
-     * Configuration used to create this deployment.
-     * 
- * - * string config = 4; - */ - public java.lang.String getConfig() { - java.lang.Object ref = config_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - config_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Configuration used to create this deployment.
-     * 
- * - * string config = 4; - */ - public com.google.protobuf.ByteString getConfigBytes() { - java.lang.Object ref = config_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - config_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Configuration used to create this deployment.
-     * 
- * - * string config = 4; - */ - public Builder setConfig(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - config_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Configuration used to create this deployment.
-     * 
- * - * string config = 4; - */ - public Builder clearConfig() { - - config_ = getDefaultInstance().getConfig(); - onChanged(); - return this; - } - /** - * - * - *
-     * Configuration used to create this deployment.
-     * 
- * - * string config = 4; - */ - public Builder setConfigBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - config_ = value; - onChanged(); - return this; - } - - private java.lang.Object address_ = ""; - /** - * - * - *
-     * Address of the runtime element hosting this deployment.
-     * 
- * - * string address = 5; - */ - public java.lang.String getAddress() { - java.lang.Object ref = address_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - address_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Address of the runtime element hosting this deployment.
-     * 
- * - * string address = 5; - */ - public com.google.protobuf.ByteString getAddressBytes() { - java.lang.Object ref = address_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - address_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Address of the runtime element hosting this deployment.
-     * 
- * - * string address = 5; - */ - public Builder setAddress(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - address_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Address of the runtime element hosting this deployment.
-     * 
- * - * string address = 5; - */ - public Builder clearAddress() { - - address_ = getDefaultInstance().getAddress(); - onChanged(); - return this; - } - /** - * - * - *
-     * Address of the runtime element hosting this deployment.
-     * 
- * - * string address = 5; - */ - public Builder setAddressBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - address_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList resourceUri_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureResourceUriIsMutable() { - if (!((bitField0_ & 0x00000020) != 0)) { - resourceUri_ = new com.google.protobuf.LazyStringArrayList(resourceUri_); - bitField0_ |= 0x00000020; - } - } - /** - * - * - *
-     * Output only. Resource URI for the artifact being deployed taken from
-     * the deployable field with the same name.
-     * 
- * - * repeated string resource_uri = 6; - */ - public com.google.protobuf.ProtocolStringList getResourceUriList() { - return resourceUri_.getUnmodifiableView(); - } - /** - * - * - *
-     * Output only. Resource URI for the artifact being deployed taken from
-     * the deployable field with the same name.
-     * 
- * - * repeated string resource_uri = 6; - */ - public int getResourceUriCount() { - return resourceUri_.size(); - } - /** - * - * - *
-     * Output only. Resource URI for the artifact being deployed taken from
-     * the deployable field with the same name.
-     * 
- * - * repeated string resource_uri = 6; - */ - public java.lang.String getResourceUri(int index) { - return resourceUri_.get(index); - } - /** - * - * - *
-     * Output only. Resource URI for the artifact being deployed taken from
-     * the deployable field with the same name.
-     * 
- * - * repeated string resource_uri = 6; - */ - public com.google.protobuf.ByteString getResourceUriBytes(int index) { - return resourceUri_.getByteString(index); - } - /** - * - * - *
-     * Output only. Resource URI for the artifact being deployed taken from
-     * the deployable field with the same name.
-     * 
- * - * repeated string resource_uri = 6; - */ - public Builder setResourceUri(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureResourceUriIsMutable(); - resourceUri_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Resource URI for the artifact being deployed taken from
-     * the deployable field with the same name.
-     * 
- * - * repeated string resource_uri = 6; - */ - public Builder addResourceUri(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureResourceUriIsMutable(); - resourceUri_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Resource URI for the artifact being deployed taken from
-     * the deployable field with the same name.
-     * 
- * - * repeated string resource_uri = 6; - */ - public Builder addAllResourceUri(java.lang.Iterable values) { - ensureResourceUriIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, resourceUri_); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Resource URI for the artifact being deployed taken from
-     * the deployable field with the same name.
-     * 
- * - * repeated string resource_uri = 6; - */ - public Builder clearResourceUri() { - resourceUri_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000020); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Resource URI for the artifact being deployed taken from
-     * the deployable field with the same name.
-     * 
- * - * repeated string resource_uri = 6; - */ - public Builder addResourceUriBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureResourceUriIsMutable(); - resourceUri_.add(value); - onChanged(); - return this; - } - - private int platform_ = 0; - /** - * - * - *
-     * Platform hosting this deployment.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment.Platform platform = 7; - */ - public int getPlatformValue() { - return platform_; - } - /** - * - * - *
-     * Platform hosting this deployment.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment.Platform platform = 7; - */ - public Builder setPlatformValue(int value) { - platform_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Platform hosting this deployment.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment.Platform platform = 7; - */ - public io.grafeas.v1beta1.deployment.Deployment.Platform getPlatform() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.deployment.Deployment.Platform result = - io.grafeas.v1beta1.deployment.Deployment.Platform.valueOf(platform_); - return result == null - ? io.grafeas.v1beta1.deployment.Deployment.Platform.UNRECOGNIZED - : result; - } - /** - * - * - *
-     * Platform hosting this deployment.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment.Platform platform = 7; - */ - public Builder setPlatform(io.grafeas.v1beta1.deployment.Deployment.Platform value) { - if (value == null) { - throw new NullPointerException(); - } - - platform_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Platform hosting this deployment.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment.Platform platform = 7; - */ - public Builder clearPlatform() { - - platform_ = 0; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.deployment.Deployment) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.deployment.Deployment) - private static final io.grafeas.v1beta1.deployment.Deployment DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.deployment.Deployment(); - } - - public static io.grafeas.v1beta1.deployment.Deployment getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Deployment parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Deployment(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.deployment.Deployment getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DeploymentOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DeploymentOrBuilder.java deleted file mode 100644 index 2686ecc6..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DeploymentOrBuilder.java +++ /dev/null @@ -1,201 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/deployment/deployment.proto - -package io.grafeas.v1beta1.deployment; - -public interface DeploymentOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.deployment.Deployment) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Identity of the user that triggered this deployment.
-   * 
- * - * string user_email = 1; - */ - java.lang.String getUserEmail(); - /** - * - * - *
-   * Identity of the user that triggered this deployment.
-   * 
- * - * string user_email = 1; - */ - com.google.protobuf.ByteString getUserEmailBytes(); - - /** - * - * - *
-   * Beginning of the lifetime of this deployment.
-   * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - boolean hasDeployTime(); - /** - * - * - *
-   * Beginning of the lifetime of this deployment.
-   * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - com.google.protobuf.Timestamp getDeployTime(); - /** - * - * - *
-   * Beginning of the lifetime of this deployment.
-   * 
- * - * .google.protobuf.Timestamp deploy_time = 2; - */ - com.google.protobuf.TimestampOrBuilder getDeployTimeOrBuilder(); - - /** - * - * - *
-   * End of the lifetime of this deployment.
-   * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - boolean hasUndeployTime(); - /** - * - * - *
-   * End of the lifetime of this deployment.
-   * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - com.google.protobuf.Timestamp getUndeployTime(); - /** - * - * - *
-   * End of the lifetime of this deployment.
-   * 
- * - * .google.protobuf.Timestamp undeploy_time = 3; - */ - com.google.protobuf.TimestampOrBuilder getUndeployTimeOrBuilder(); - - /** - * - * - *
-   * Configuration used to create this deployment.
-   * 
- * - * string config = 4; - */ - java.lang.String getConfig(); - /** - * - * - *
-   * Configuration used to create this deployment.
-   * 
- * - * string config = 4; - */ - com.google.protobuf.ByteString getConfigBytes(); - - /** - * - * - *
-   * Address of the runtime element hosting this deployment.
-   * 
- * - * string address = 5; - */ - java.lang.String getAddress(); - /** - * - * - *
-   * Address of the runtime element hosting this deployment.
-   * 
- * - * string address = 5; - */ - com.google.protobuf.ByteString getAddressBytes(); - - /** - * - * - *
-   * Output only. Resource URI for the artifact being deployed taken from
-   * the deployable field with the same name.
-   * 
- * - * repeated string resource_uri = 6; - */ - java.util.List getResourceUriList(); - /** - * - * - *
-   * Output only. Resource URI for the artifact being deployed taken from
-   * the deployable field with the same name.
-   * 
- * - * repeated string resource_uri = 6; - */ - int getResourceUriCount(); - /** - * - * - *
-   * Output only. Resource URI for the artifact being deployed taken from
-   * the deployable field with the same name.
-   * 
- * - * repeated string resource_uri = 6; - */ - java.lang.String getResourceUri(int index); - /** - * - * - *
-   * Output only. Resource URI for the artifact being deployed taken from
-   * the deployable field with the same name.
-   * 
- * - * repeated string resource_uri = 6; - */ - com.google.protobuf.ByteString getResourceUriBytes(int index); - - /** - * - * - *
-   * Platform hosting this deployment.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployment.Platform platform = 7; - */ - int getPlatformValue(); - /** - * - * - *
-   * Platform hosting this deployment.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployment.Platform platform = 7; - */ - io.grafeas.v1beta1.deployment.Deployment.Platform getPlatform(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DeploymentOuterClass.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DeploymentOuterClass.java deleted file mode 100644 index 27860465..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DeploymentOuterClass.java +++ /dev/null @@ -1,103 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/deployment/deployment.proto - -package io.grafeas.v1beta1.deployment; - -public final class DeploymentOuterClass { - private DeploymentOuterClass() {} - - 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_grafeas_v1beta1_deployment_Deployable_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_deployment_Deployable_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_deployment_Details_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_deployment_Details_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_deployment_Deployment_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_deployment_Deployment_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { - return descriptor; - } - - private static com.google.protobuf.Descriptors.FileDescriptor descriptor; - - static { - java.lang.String[] descriptorData = { - "\nEgoogle/devtools/containeranalysis/v1be" - + "ta1/deployment/deployment.proto\022\032grafeas" - + ".v1beta1.deployment\032\037google/protobuf/tim" - + "estamp.proto\"\"\n\nDeployable\022\024\n\014resource_u" - + "ri\030\001 \003(\t\"E\n\007Details\022:\n\ndeployment\030\001 \001(\0132" - + "&.grafeas.v1beta1.deployment.Deployment\"" - + "\303\002\n\nDeployment\022\022\n\nuser_email\030\001 \001(\t\022/\n\013de" - + "ploy_time\030\002 \001(\0132\032.google.protobuf.Timest" - + "amp\0221\n\rundeploy_time\030\003 \001(\0132\032.google.prot" - + "obuf.Timestamp\022\016\n\006config\030\004 \001(\t\022\017\n\007addres" - + "s\030\005 \001(\t\022\024\n\014resource_uri\030\006 \003(\t\022A\n\010platfor" - + "m\030\007 \001(\0162/.grafeas.v1beta1.deployment.Dep" - + "loyment.Platform\"C\n\010Platform\022\030\n\024PLATFORM" - + "_UNSPECIFIED\020\000\022\007\n\003GKE\020\001\022\010\n\004FLEX\020\002\022\n\n\006CUS" - + "TOM\020\003B\207\001\n\035io.grafeas.v1beta1.deploymentP" - + "\001Z^google.golang.org/genproto/googleapis" - + "/devtools/containeranalysis/v1beta1/depl" - + "oyment;deployment\242\002\003GRAb\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.protobuf.TimestampProto.getDescriptor(), - }, - assigner); - internal_static_grafeas_v1beta1_deployment_Deployable_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_grafeas_v1beta1_deployment_Deployable_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_deployment_Deployable_descriptor, - new java.lang.String[] { - "ResourceUri", - }); - internal_static_grafeas_v1beta1_deployment_Details_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_grafeas_v1beta1_deployment_Details_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_deployment_Details_descriptor, - new java.lang.String[] { - "Deployment", - }); - internal_static_grafeas_v1beta1_deployment_Deployment_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_grafeas_v1beta1_deployment_Deployment_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_deployment_Deployment_descriptor, - new java.lang.String[] { - "UserEmail", - "DeployTime", - "UndeployTime", - "Config", - "Address", - "ResourceUri", - "Platform", - }); - com.google.protobuf.TimestampProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/Details.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/Details.java deleted file mode 100644 index 3c293ecf..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/Details.java +++ /dev/null @@ -1,698 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/deployment/deployment.proto - -package io.grafeas.v1beta1.deployment; - -/** - * - * - *
- * Details of a deployment occurrence.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.deployment.Details} - */ -public final class Details extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.deployment.Details) - DetailsOrBuilder { - private static final long serialVersionUID = 0L; - // Use Details.newBuilder() to construct. - private Details(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Details() {} - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Details( - 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: - { - io.grafeas.v1beta1.deployment.Deployment.Builder subBuilder = null; - if (deployment_ != null) { - subBuilder = deployment_.toBuilder(); - } - deployment_ = - input.readMessage( - io.grafeas.v1beta1.deployment.Deployment.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(deployment_); - deployment_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.deployment.Details.class, - io.grafeas.v1beta1.deployment.Details.Builder.class); - } - - public static final int DEPLOYMENT_FIELD_NUMBER = 1; - private io.grafeas.v1beta1.deployment.Deployment deployment_; - /** - * - * - *
-   * Deployment history for the resource.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - public boolean hasDeployment() { - return deployment_ != null; - } - /** - * - * - *
-   * Deployment history for the resource.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - public io.grafeas.v1beta1.deployment.Deployment getDeployment() { - return deployment_ == null - ? io.grafeas.v1beta1.deployment.Deployment.getDefaultInstance() - : deployment_; - } - /** - * - * - *
-   * Deployment history for the resource.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - public io.grafeas.v1beta1.deployment.DeploymentOrBuilder getDeploymentOrBuilder() { - return getDeployment(); - } - - 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 (deployment_ != null) { - output.writeMessage(1, getDeployment()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (deployment_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getDeployment()); - } - 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 io.grafeas.v1beta1.deployment.Details)) { - return super.equals(obj); - } - io.grafeas.v1beta1.deployment.Details other = (io.grafeas.v1beta1.deployment.Details) obj; - - if (hasDeployment() != other.hasDeployment()) return false; - if (hasDeployment()) { - if (!getDeployment().equals(other.getDeployment())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasDeployment()) { - hash = (37 * hash) + DEPLOYMENT_FIELD_NUMBER; - hash = (53 * hash) + getDeployment().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.deployment.Details parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.deployment.Details parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.deployment.Details parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.deployment.Details parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.deployment.Details parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.deployment.Details parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.deployment.Details parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.deployment.Details 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 io.grafeas.v1beta1.deployment.Details parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.deployment.Details 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 io.grafeas.v1beta1.deployment.Details parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.deployment.Details 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(io.grafeas.v1beta1.deployment.Details 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; - } - /** - * - * - *
-   * Details of a deployment occurrence.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.deployment.Details} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.deployment.Details) - io.grafeas.v1beta1.deployment.DetailsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.deployment.Details.class, - io.grafeas.v1beta1.deployment.Details.Builder.class); - } - - // Construct using io.grafeas.v1beta1.deployment.Details.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (deploymentBuilder_ == null) { - deployment_ = null; - } else { - deployment_ = null; - deploymentBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.deployment.DeploymentOuterClass - .internal_static_grafeas_v1beta1_deployment_Details_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.deployment.Details getDefaultInstanceForType() { - return io.grafeas.v1beta1.deployment.Details.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.deployment.Details build() { - io.grafeas.v1beta1.deployment.Details result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.deployment.Details buildPartial() { - io.grafeas.v1beta1.deployment.Details result = - new io.grafeas.v1beta1.deployment.Details(this); - if (deploymentBuilder_ == null) { - result.deployment_ = deployment_; - } else { - result.deployment_ = deploymentBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.deployment.Details) { - return mergeFrom((io.grafeas.v1beta1.deployment.Details) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.deployment.Details other) { - if (other == io.grafeas.v1beta1.deployment.Details.getDefaultInstance()) return this; - if (other.hasDeployment()) { - mergeDeployment(other.getDeployment()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.deployment.Details parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.deployment.Details) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private io.grafeas.v1beta1.deployment.Deployment deployment_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.deployment.Deployment, - io.grafeas.v1beta1.deployment.Deployment.Builder, - io.grafeas.v1beta1.deployment.DeploymentOrBuilder> - deploymentBuilder_; - /** - * - * - *
-     * Deployment history for the resource.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - public boolean hasDeployment() { - return deploymentBuilder_ != null || deployment_ != null; - } - /** - * - * - *
-     * Deployment history for the resource.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - public io.grafeas.v1beta1.deployment.Deployment getDeployment() { - if (deploymentBuilder_ == null) { - return deployment_ == null - ? io.grafeas.v1beta1.deployment.Deployment.getDefaultInstance() - : deployment_; - } else { - return deploymentBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Deployment history for the resource.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - public Builder setDeployment(io.grafeas.v1beta1.deployment.Deployment value) { - if (deploymentBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - deployment_ = value; - onChanged(); - } else { - deploymentBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Deployment history for the resource.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - public Builder setDeployment(io.grafeas.v1beta1.deployment.Deployment.Builder builderForValue) { - if (deploymentBuilder_ == null) { - deployment_ = builderForValue.build(); - onChanged(); - } else { - deploymentBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Deployment history for the resource.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - public Builder mergeDeployment(io.grafeas.v1beta1.deployment.Deployment value) { - if (deploymentBuilder_ == null) { - if (deployment_ != null) { - deployment_ = - io.grafeas.v1beta1.deployment.Deployment.newBuilder(deployment_) - .mergeFrom(value) - .buildPartial(); - } else { - deployment_ = value; - } - onChanged(); - } else { - deploymentBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Deployment history for the resource.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - public Builder clearDeployment() { - if (deploymentBuilder_ == null) { - deployment_ = null; - onChanged(); - } else { - deployment_ = null; - deploymentBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Deployment history for the resource.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - public io.grafeas.v1beta1.deployment.Deployment.Builder getDeploymentBuilder() { - - onChanged(); - return getDeploymentFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Deployment history for the resource.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - public io.grafeas.v1beta1.deployment.DeploymentOrBuilder getDeploymentOrBuilder() { - if (deploymentBuilder_ != null) { - return deploymentBuilder_.getMessageOrBuilder(); - } else { - return deployment_ == null - ? io.grafeas.v1beta1.deployment.Deployment.getDefaultInstance() - : deployment_; - } - } - /** - * - * - *
-     * Deployment history for the resource.
-     * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.deployment.Deployment, - io.grafeas.v1beta1.deployment.Deployment.Builder, - io.grafeas.v1beta1.deployment.DeploymentOrBuilder> - getDeploymentFieldBuilder() { - if (deploymentBuilder_ == null) { - deploymentBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.deployment.Deployment, - io.grafeas.v1beta1.deployment.Deployment.Builder, - io.grafeas.v1beta1.deployment.DeploymentOrBuilder>( - getDeployment(), getParentForChildren(), isClean()); - deployment_ = null; - } - return deploymentBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.deployment.Details) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.deployment.Details) - private static final io.grafeas.v1beta1.deployment.Details DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.deployment.Details(); - } - - public static io.grafeas.v1beta1.deployment.Details getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser
PARSER = - new com.google.protobuf.AbstractParser
() { - @java.lang.Override - public Details parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Details(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser
parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser
getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.deployment.Details getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DetailsOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DetailsOrBuilder.java deleted file mode 100644 index 6fca14bd..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/DetailsOrBuilder.java +++ /dev/null @@ -1,41 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/deployment/deployment.proto - -package io.grafeas.v1beta1.deployment; - -public interface DetailsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.deployment.Details) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Deployment history for the resource.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - boolean hasDeployment(); - /** - * - * - *
-   * Deployment history for the resource.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - io.grafeas.v1beta1.deployment.Deployment getDeployment(); - /** - * - * - *
-   * Deployment history for the resource.
-   * 
- * - * .grafeas.v1beta1.deployment.Deployment deployment = 1; - */ - io.grafeas.v1beta1.deployment.DeploymentOrBuilder getDeploymentOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/IamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/IamResourceName.java deleted file mode 100644 index 962637d3..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/IamResourceName.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.deployment; - -import com.google.api.resourcenames.ResourceName; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public abstract class IamResourceName implements ResourceName { - protected IamResourceName() {} -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/IamResourceNames.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/IamResourceNames.java deleted file mode 100644 index 46c998f8..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/IamResourceNames.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.deployment; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class IamResourceNames { - private IamResourceNames() {} - - public static IamResourceName parse(String resourceNameString) { - if (NoteName.isParsableFrom(resourceNameString)) { - return NoteName.parse(resourceNameString); - } - if (OccurrenceName.isParsableFrom(resourceNameString)) { - return OccurrenceName.parse(resourceNameString); - } - return UntypedIamResourceName.parse(resourceNameString); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/NoteName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/NoteName.java deleted file mode 100644 index c505e278..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/NoteName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.deployment; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class NoteName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/notes/{note}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/OccurrenceName.java deleted file mode 100644 index e34b8ce9..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.deployment; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/ProjectName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/ProjectName.java deleted file mode 100644 index 5908faed..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.deployment; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/ScanConfigName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/ScanConfigName.java deleted file mode 100644 index 216d5bde..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/ScanConfigName.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.deployment; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ScanConfigName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ScanConfigName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - scanConfig = Preconditions.checkNotNull(builder.getScanConfig()); - } - - public static ScanConfigName of(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build(); - } - - public static String format(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build().toString(); - } - - public static ScanConfigName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ScanConfigName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("scan_config")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ScanConfigName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("scanConfig", scanConfig); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "scan_config", scanConfig); - } - - /** Builder for ScanConfigName. */ - public static class Builder { - - private String project; - private String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setScanConfig(String scanConfig) { - this.scanConfig = scanConfig; - return this; - } - - private Builder() {} - - private Builder(ScanConfigName scanConfigName) { - project = scanConfigName.project; - scanConfig = scanConfigName.scanConfig; - } - - public ScanConfigName build() { - return new ScanConfigName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ScanConfigName) { - ScanConfigName that = (ScanConfigName) o; - return (this.project.equals(that.project)) && (this.scanConfig.equals(that.scanConfig)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= scanConfig.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/UntypedIamResourceName.java deleted file mode 100644 index d31cf1bb..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/deployment/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.deployment; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/Details.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/Details.java deleted file mode 100644 index 4eaf0da8..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/Details.java +++ /dev/null @@ -1,697 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/discovery/discovery.proto - -package io.grafeas.v1beta1.discovery; - -/** - * - * - *
- * Details of a discovery occurrence.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.discovery.Details} - */ -public final class Details extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.discovery.Details) - DetailsOrBuilder { - private static final long serialVersionUID = 0L; - // Use Details.newBuilder() to construct. - private Details(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Details() {} - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Details( - 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: - { - io.grafeas.v1beta1.discovery.Discovered.Builder subBuilder = null; - if (discovered_ != null) { - subBuilder = discovered_.toBuilder(); - } - discovered_ = - input.readMessage( - io.grafeas.v1beta1.discovery.Discovered.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(discovered_); - discovered_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.discovery.Details.class, - io.grafeas.v1beta1.discovery.Details.Builder.class); - } - - public static final int DISCOVERED_FIELD_NUMBER = 1; - private io.grafeas.v1beta1.discovery.Discovered discovered_; - /** - * - * - *
-   * Analysis status for the discovered resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - public boolean hasDiscovered() { - return discovered_ != null; - } - /** - * - * - *
-   * Analysis status for the discovered resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - public io.grafeas.v1beta1.discovery.Discovered getDiscovered() { - return discovered_ == null - ? io.grafeas.v1beta1.discovery.Discovered.getDefaultInstance() - : discovered_; - } - /** - * - * - *
-   * Analysis status for the discovered resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - public io.grafeas.v1beta1.discovery.DiscoveredOrBuilder getDiscoveredOrBuilder() { - return getDiscovered(); - } - - 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 (discovered_ != null) { - output.writeMessage(1, getDiscovered()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (discovered_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getDiscovered()); - } - 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 io.grafeas.v1beta1.discovery.Details)) { - return super.equals(obj); - } - io.grafeas.v1beta1.discovery.Details other = (io.grafeas.v1beta1.discovery.Details) obj; - - if (hasDiscovered() != other.hasDiscovered()) return false; - if (hasDiscovered()) { - if (!getDiscovered().equals(other.getDiscovered())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasDiscovered()) { - hash = (37 * hash) + DISCOVERED_FIELD_NUMBER; - hash = (53 * hash) + getDiscovered().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.discovery.Details parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.discovery.Details parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.discovery.Details parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.discovery.Details parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.discovery.Details parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.discovery.Details parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.discovery.Details parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.discovery.Details 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 io.grafeas.v1beta1.discovery.Details parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.discovery.Details 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 io.grafeas.v1beta1.discovery.Details parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.discovery.Details 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(io.grafeas.v1beta1.discovery.Details 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; - } - /** - * - * - *
-   * Details of a discovery occurrence.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.discovery.Details} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.discovery.Details) - io.grafeas.v1beta1.discovery.DetailsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.discovery.Details.class, - io.grafeas.v1beta1.discovery.Details.Builder.class); - } - - // Construct using io.grafeas.v1beta1.discovery.Details.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (discoveredBuilder_ == null) { - discovered_ = null; - } else { - discovered_ = null; - discoveredBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Details_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.discovery.Details getDefaultInstanceForType() { - return io.grafeas.v1beta1.discovery.Details.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.discovery.Details build() { - io.grafeas.v1beta1.discovery.Details result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.discovery.Details buildPartial() { - io.grafeas.v1beta1.discovery.Details result = new io.grafeas.v1beta1.discovery.Details(this); - if (discoveredBuilder_ == null) { - result.discovered_ = discovered_; - } else { - result.discovered_ = discoveredBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.discovery.Details) { - return mergeFrom((io.grafeas.v1beta1.discovery.Details) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.discovery.Details other) { - if (other == io.grafeas.v1beta1.discovery.Details.getDefaultInstance()) return this; - if (other.hasDiscovered()) { - mergeDiscovered(other.getDiscovered()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.discovery.Details parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.discovery.Details) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private io.grafeas.v1beta1.discovery.Discovered discovered_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.discovery.Discovered, - io.grafeas.v1beta1.discovery.Discovered.Builder, - io.grafeas.v1beta1.discovery.DiscoveredOrBuilder> - discoveredBuilder_; - /** - * - * - *
-     * Analysis status for the discovered resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - public boolean hasDiscovered() { - return discoveredBuilder_ != null || discovered_ != null; - } - /** - * - * - *
-     * Analysis status for the discovered resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - public io.grafeas.v1beta1.discovery.Discovered getDiscovered() { - if (discoveredBuilder_ == null) { - return discovered_ == null - ? io.grafeas.v1beta1.discovery.Discovered.getDefaultInstance() - : discovered_; - } else { - return discoveredBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Analysis status for the discovered resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - public Builder setDiscovered(io.grafeas.v1beta1.discovery.Discovered value) { - if (discoveredBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - discovered_ = value; - onChanged(); - } else { - discoveredBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Analysis status for the discovered resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - public Builder setDiscovered(io.grafeas.v1beta1.discovery.Discovered.Builder builderForValue) { - if (discoveredBuilder_ == null) { - discovered_ = builderForValue.build(); - onChanged(); - } else { - discoveredBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Analysis status for the discovered resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - public Builder mergeDiscovered(io.grafeas.v1beta1.discovery.Discovered value) { - if (discoveredBuilder_ == null) { - if (discovered_ != null) { - discovered_ = - io.grafeas.v1beta1.discovery.Discovered.newBuilder(discovered_) - .mergeFrom(value) - .buildPartial(); - } else { - discovered_ = value; - } - onChanged(); - } else { - discoveredBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Analysis status for the discovered resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - public Builder clearDiscovered() { - if (discoveredBuilder_ == null) { - discovered_ = null; - onChanged(); - } else { - discovered_ = null; - discoveredBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Analysis status for the discovered resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - public io.grafeas.v1beta1.discovery.Discovered.Builder getDiscoveredBuilder() { - - onChanged(); - return getDiscoveredFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Analysis status for the discovered resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - public io.grafeas.v1beta1.discovery.DiscoveredOrBuilder getDiscoveredOrBuilder() { - if (discoveredBuilder_ != null) { - return discoveredBuilder_.getMessageOrBuilder(); - } else { - return discovered_ == null - ? io.grafeas.v1beta1.discovery.Discovered.getDefaultInstance() - : discovered_; - } - } - /** - * - * - *
-     * Analysis status for the discovered resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.discovery.Discovered, - io.grafeas.v1beta1.discovery.Discovered.Builder, - io.grafeas.v1beta1.discovery.DiscoveredOrBuilder> - getDiscoveredFieldBuilder() { - if (discoveredBuilder_ == null) { - discoveredBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.discovery.Discovered, - io.grafeas.v1beta1.discovery.Discovered.Builder, - io.grafeas.v1beta1.discovery.DiscoveredOrBuilder>( - getDiscovered(), getParentForChildren(), isClean()); - discovered_ = null; - } - return discoveredBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.discovery.Details) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.discovery.Details) - private static final io.grafeas.v1beta1.discovery.Details DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.discovery.Details(); - } - - public static io.grafeas.v1beta1.discovery.Details getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser
PARSER = - new com.google.protobuf.AbstractParser
() { - @java.lang.Override - public Details parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Details(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser
parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser
getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.discovery.Details getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DetailsOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DetailsOrBuilder.java deleted file mode 100644 index 6d6d23b5..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DetailsOrBuilder.java +++ /dev/null @@ -1,41 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/discovery/discovery.proto - -package io.grafeas.v1beta1.discovery; - -public interface DetailsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.discovery.Details) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Analysis status for the discovered resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - boolean hasDiscovered(); - /** - * - * - *
-   * Analysis status for the discovered resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - io.grafeas.v1beta1.discovery.Discovered getDiscovered(); - /** - * - * - *
-   * Analysis status for the discovered resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered discovered = 1; - */ - io.grafeas.v1beta1.discovery.DiscoveredOrBuilder getDiscoveredOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/Discovered.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/Discovered.java deleted file mode 100644 index a6a09b20..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/Discovered.java +++ /dev/null @@ -1,1628 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/discovery/discovery.proto - -package io.grafeas.v1beta1.discovery; - -/** - * - * - *
- * Provides information about the analysis status of a discovered resource.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.discovery.Discovered} - */ -public final class Discovered extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.discovery.Discovered) - DiscoveredOrBuilder { - private static final long serialVersionUID = 0L; - // Use Discovered.newBuilder() to construct. - private Discovered(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Discovered() { - continuousAnalysis_ = 0; - analysisStatus_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Discovered( - 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 8: - { - int rawValue = input.readEnum(); - - continuousAnalysis_ = rawValue; - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (lastAnalysisTime_ != null) { - subBuilder = lastAnalysisTime_.toBuilder(); - } - lastAnalysisTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(lastAnalysisTime_); - lastAnalysisTime_ = subBuilder.buildPartial(); - } - - break; - } - case 24: - { - int rawValue = input.readEnum(); - - analysisStatus_ = rawValue; - break; - } - case 34: - { - com.google.rpc.Status.Builder subBuilder = null; - if (analysisStatusError_ != null) { - subBuilder = analysisStatusError_.toBuilder(); - } - analysisStatusError_ = - input.readMessage(com.google.rpc.Status.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(analysisStatusError_); - analysisStatusError_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Discovered_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Discovered_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.discovery.Discovered.class, - io.grafeas.v1beta1.discovery.Discovered.Builder.class); - } - - /** - * - * - *
-   * Whether the resource is continuously analyzed.
-   * 
- * - * Protobuf enum {@code grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis} - */ - public enum ContinuousAnalysis implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Unknown.
-     * 
- * - * CONTINUOUS_ANALYSIS_UNSPECIFIED = 0; - */ - CONTINUOUS_ANALYSIS_UNSPECIFIED(0), - /** - * - * - *
-     * The resource is continuously analyzed.
-     * 
- * - * ACTIVE = 1; - */ - ACTIVE(1), - /** - * - * - *
-     * The resource is ignored for continuous analysis.
-     * 
- * - * INACTIVE = 2; - */ - INACTIVE(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Unknown.
-     * 
- * - * CONTINUOUS_ANALYSIS_UNSPECIFIED = 0; - */ - public static final int CONTINUOUS_ANALYSIS_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * The resource is continuously analyzed.
-     * 
- * - * ACTIVE = 1; - */ - public static final int ACTIVE_VALUE = 1; - /** - * - * - *
-     * The resource is ignored for continuous analysis.
-     * 
- * - * 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 ContinuousAnalysis valueOf(int value) { - return forNumber(value); - } - - public static ContinuousAnalysis forNumber(int value) { - switch (value) { - case 0: - return CONTINUOUS_ANALYSIS_UNSPECIFIED; - case 1: - return ACTIVE; - case 2: - return INACTIVE; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public ContinuousAnalysis findValueByNumber(int number) { - return ContinuousAnalysis.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return io.grafeas.v1beta1.discovery.Discovered.getDescriptor().getEnumTypes().get(0); - } - - private static final ContinuousAnalysis[] VALUES = values(); - - public static ContinuousAnalysis valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private ContinuousAnalysis(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis) - } - - /** - * - * - *
-   * Analysis status for a resource. Currently for initial analysis only (not
-   * updated in continuous analysis).
-   * 
- * - * Protobuf enum {@code grafeas.v1beta1.discovery.Discovered.AnalysisStatus} - */ - public enum AnalysisStatus implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Unknown.
-     * 
- * - * ANALYSIS_STATUS_UNSPECIFIED = 0; - */ - ANALYSIS_STATUS_UNSPECIFIED(0), - /** - * - * - *
-     * Resource is known but no action has been taken yet.
-     * 
- * - * PENDING = 1; - */ - PENDING(1), - /** - * - * - *
-     * Resource is being analyzed.
-     * 
- * - * SCANNING = 2; - */ - SCANNING(2), - /** - * - * - *
-     * Analysis has finished successfully.
-     * 
- * - * FINISHED_SUCCESS = 3; - */ - FINISHED_SUCCESS(3), - /** - * - * - *
-     * Analysis has finished unsuccessfully, the analysis itself is in a bad
-     * state.
-     * 
- * - * FINISHED_FAILED = 4; - */ - FINISHED_FAILED(4), - /** - * - * - *
-     * The resource is known not to be supported
-     * 
- * - * FINISHED_UNSUPPORTED = 5; - */ - FINISHED_UNSUPPORTED(5), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Unknown.
-     * 
- * - * ANALYSIS_STATUS_UNSPECIFIED = 0; - */ - public static final int ANALYSIS_STATUS_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * Resource is known but no action has been taken yet.
-     * 
- * - * PENDING = 1; - */ - public static final int PENDING_VALUE = 1; - /** - * - * - *
-     * Resource is being analyzed.
-     * 
- * - * SCANNING = 2; - */ - public static final int SCANNING_VALUE = 2; - /** - * - * - *
-     * Analysis has finished successfully.
-     * 
- * - * FINISHED_SUCCESS = 3; - */ - public static final int FINISHED_SUCCESS_VALUE = 3; - /** - * - * - *
-     * Analysis has finished unsuccessfully, the analysis itself is in a bad
-     * state.
-     * 
- * - * FINISHED_FAILED = 4; - */ - public static final int FINISHED_FAILED_VALUE = 4; - /** - * - * - *
-     * The resource is known not to be supported
-     * 
- * - * FINISHED_UNSUPPORTED = 5; - */ - public static final int FINISHED_UNSUPPORTED_VALUE = 5; - - 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 AnalysisStatus valueOf(int value) { - return forNumber(value); - } - - public static AnalysisStatus forNumber(int value) { - switch (value) { - case 0: - return ANALYSIS_STATUS_UNSPECIFIED; - case 1: - return PENDING; - case 2: - return SCANNING; - case 3: - return FINISHED_SUCCESS; - case 4: - return FINISHED_FAILED; - case 5: - return FINISHED_UNSUPPORTED; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public AnalysisStatus findValueByNumber(int number) { - return AnalysisStatus.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return io.grafeas.v1beta1.discovery.Discovered.getDescriptor().getEnumTypes().get(1); - } - - private static final AnalysisStatus[] VALUES = values(); - - public static AnalysisStatus valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private AnalysisStatus(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:grafeas.v1beta1.discovery.Discovered.AnalysisStatus) - } - - public static final int CONTINUOUS_ANALYSIS_FIELD_NUMBER = 1; - private int continuousAnalysis_; - /** - * - * - *
-   * Whether the resource is continuously analyzed.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis continuous_analysis = 1; - */ - public int getContinuousAnalysisValue() { - return continuousAnalysis_; - } - /** - * - * - *
-   * Whether the resource is continuously analyzed.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis continuous_analysis = 1; - */ - public io.grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis getContinuousAnalysis() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis result = - io.grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis.valueOf(continuousAnalysis_); - return result == null - ? io.grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis.UNRECOGNIZED - : result; - } - - public static final int LAST_ANALYSIS_TIME_FIELD_NUMBER = 2; - private com.google.protobuf.Timestamp lastAnalysisTime_; - /** - * - * - *
-   * The last time continuous analysis was done for this resource.
-   * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - public boolean hasLastAnalysisTime() { - return lastAnalysisTime_ != null; - } - /** - * - * - *
-   * The last time continuous analysis was done for this resource.
-   * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - public com.google.protobuf.Timestamp getLastAnalysisTime() { - return lastAnalysisTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : lastAnalysisTime_; - } - /** - * - * - *
-   * The last time continuous analysis was done for this resource.
-   * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - public com.google.protobuf.TimestampOrBuilder getLastAnalysisTimeOrBuilder() { - return getLastAnalysisTime(); - } - - public static final int ANALYSIS_STATUS_FIELD_NUMBER = 3; - private int analysisStatus_; - /** - * - * - *
-   * The status of discovery for the resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered.AnalysisStatus analysis_status = 3; - */ - public int getAnalysisStatusValue() { - return analysisStatus_; - } - /** - * - * - *
-   * The status of discovery for the resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered.AnalysisStatus analysis_status = 3; - */ - public io.grafeas.v1beta1.discovery.Discovered.AnalysisStatus getAnalysisStatus() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.discovery.Discovered.AnalysisStatus result = - io.grafeas.v1beta1.discovery.Discovered.AnalysisStatus.valueOf(analysisStatus_); - return result == null - ? io.grafeas.v1beta1.discovery.Discovered.AnalysisStatus.UNRECOGNIZED - : result; - } - - public static final int ANALYSIS_STATUS_ERROR_FIELD_NUMBER = 4; - private com.google.rpc.Status analysisStatusError_; - /** - * - * - *
-   * When an error is encountered this will contain a LocalizedMessage under
-   * details to show to the user. The LocalizedMessage is output only and
-   * populated by the API.
-   * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - public boolean hasAnalysisStatusError() { - return analysisStatusError_ != null; - } - /** - * - * - *
-   * When an error is encountered this will contain a LocalizedMessage under
-   * details to show to the user. The LocalizedMessage is output only and
-   * populated by the API.
-   * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - public com.google.rpc.Status getAnalysisStatusError() { - return analysisStatusError_ == null - ? com.google.rpc.Status.getDefaultInstance() - : analysisStatusError_; - } - /** - * - * - *
-   * When an error is encountered this will contain a LocalizedMessage under
-   * details to show to the user. The LocalizedMessage is output only and
-   * populated by the API.
-   * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - public com.google.rpc.StatusOrBuilder getAnalysisStatusErrorOrBuilder() { - return getAnalysisStatusError(); - } - - 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 (continuousAnalysis_ - != io.grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis - .CONTINUOUS_ANALYSIS_UNSPECIFIED - .getNumber()) { - output.writeEnum(1, continuousAnalysis_); - } - if (lastAnalysisTime_ != null) { - output.writeMessage(2, getLastAnalysisTime()); - } - if (analysisStatus_ - != io.grafeas.v1beta1.discovery.Discovered.AnalysisStatus.ANALYSIS_STATUS_UNSPECIFIED - .getNumber()) { - output.writeEnum(3, analysisStatus_); - } - if (analysisStatusError_ != null) { - output.writeMessage(4, getAnalysisStatusError()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (continuousAnalysis_ - != io.grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis - .CONTINUOUS_ANALYSIS_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, continuousAnalysis_); - } - if (lastAnalysisTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getLastAnalysisTime()); - } - if (analysisStatus_ - != io.grafeas.v1beta1.discovery.Discovered.AnalysisStatus.ANALYSIS_STATUS_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, analysisStatus_); - } - if (analysisStatusError_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getAnalysisStatusError()); - } - 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 io.grafeas.v1beta1.discovery.Discovered)) { - return super.equals(obj); - } - io.grafeas.v1beta1.discovery.Discovered other = (io.grafeas.v1beta1.discovery.Discovered) obj; - - if (continuousAnalysis_ != other.continuousAnalysis_) return false; - if (hasLastAnalysisTime() != other.hasLastAnalysisTime()) return false; - if (hasLastAnalysisTime()) { - if (!getLastAnalysisTime().equals(other.getLastAnalysisTime())) return false; - } - if (analysisStatus_ != other.analysisStatus_) return false; - if (hasAnalysisStatusError() != other.hasAnalysisStatusError()) return false; - if (hasAnalysisStatusError()) { - if (!getAnalysisStatusError().equals(other.getAnalysisStatusError())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + CONTINUOUS_ANALYSIS_FIELD_NUMBER; - hash = (53 * hash) + continuousAnalysis_; - if (hasLastAnalysisTime()) { - hash = (37 * hash) + LAST_ANALYSIS_TIME_FIELD_NUMBER; - hash = (53 * hash) + getLastAnalysisTime().hashCode(); - } - hash = (37 * hash) + ANALYSIS_STATUS_FIELD_NUMBER; - hash = (53 * hash) + analysisStatus_; - if (hasAnalysisStatusError()) { - hash = (37 * hash) + ANALYSIS_STATUS_ERROR_FIELD_NUMBER; - hash = (53 * hash) + getAnalysisStatusError().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.discovery.Discovered parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.discovery.Discovered parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.discovery.Discovered parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.discovery.Discovered parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.discovery.Discovered parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.discovery.Discovered parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.discovery.Discovered parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.discovery.Discovered 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 io.grafeas.v1beta1.discovery.Discovered parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.discovery.Discovered 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 io.grafeas.v1beta1.discovery.Discovered parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.discovery.Discovered 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(io.grafeas.v1beta1.discovery.Discovered 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; - } - /** - * - * - *
-   * Provides information about the analysis status of a discovered resource.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.discovery.Discovered} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.discovery.Discovered) - io.grafeas.v1beta1.discovery.DiscoveredOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Discovered_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Discovered_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.discovery.Discovered.class, - io.grafeas.v1beta1.discovery.Discovered.Builder.class); - } - - // Construct using io.grafeas.v1beta1.discovery.Discovered.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - continuousAnalysis_ = 0; - - if (lastAnalysisTimeBuilder_ == null) { - lastAnalysisTime_ = null; - } else { - lastAnalysisTime_ = null; - lastAnalysisTimeBuilder_ = null; - } - analysisStatus_ = 0; - - if (analysisStatusErrorBuilder_ == null) { - analysisStatusError_ = null; - } else { - analysisStatusError_ = null; - analysisStatusErrorBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Discovered_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.discovery.Discovered getDefaultInstanceForType() { - return io.grafeas.v1beta1.discovery.Discovered.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.discovery.Discovered build() { - io.grafeas.v1beta1.discovery.Discovered result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.discovery.Discovered buildPartial() { - io.grafeas.v1beta1.discovery.Discovered result = - new io.grafeas.v1beta1.discovery.Discovered(this); - result.continuousAnalysis_ = continuousAnalysis_; - if (lastAnalysisTimeBuilder_ == null) { - result.lastAnalysisTime_ = lastAnalysisTime_; - } else { - result.lastAnalysisTime_ = lastAnalysisTimeBuilder_.build(); - } - result.analysisStatus_ = analysisStatus_; - if (analysisStatusErrorBuilder_ == null) { - result.analysisStatusError_ = analysisStatusError_; - } else { - result.analysisStatusError_ = analysisStatusErrorBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.discovery.Discovered) { - return mergeFrom((io.grafeas.v1beta1.discovery.Discovered) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.discovery.Discovered other) { - if (other == io.grafeas.v1beta1.discovery.Discovered.getDefaultInstance()) return this; - if (other.continuousAnalysis_ != 0) { - setContinuousAnalysisValue(other.getContinuousAnalysisValue()); - } - if (other.hasLastAnalysisTime()) { - mergeLastAnalysisTime(other.getLastAnalysisTime()); - } - if (other.analysisStatus_ != 0) { - setAnalysisStatusValue(other.getAnalysisStatusValue()); - } - if (other.hasAnalysisStatusError()) { - mergeAnalysisStatusError(other.getAnalysisStatusError()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.discovery.Discovered parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.discovery.Discovered) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int continuousAnalysis_ = 0; - /** - * - * - *
-     * Whether the resource is continuously analyzed.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis continuous_analysis = 1; - * - */ - public int getContinuousAnalysisValue() { - return continuousAnalysis_; - } - /** - * - * - *
-     * Whether the resource is continuously analyzed.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis continuous_analysis = 1; - * - */ - public Builder setContinuousAnalysisValue(int value) { - continuousAnalysis_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Whether the resource is continuously analyzed.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis continuous_analysis = 1; - * - */ - public io.grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis getContinuousAnalysis() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis result = - io.grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis.valueOf(continuousAnalysis_); - return result == null - ? io.grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis.UNRECOGNIZED - : result; - } - /** - * - * - *
-     * Whether the resource is continuously analyzed.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis continuous_analysis = 1; - * - */ - public Builder setContinuousAnalysis( - io.grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis value) { - if (value == null) { - throw new NullPointerException(); - } - - continuousAnalysis_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Whether the resource is continuously analyzed.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis continuous_analysis = 1; - * - */ - public Builder clearContinuousAnalysis() { - - continuousAnalysis_ = 0; - onChanged(); - return this; - } - - private com.google.protobuf.Timestamp lastAnalysisTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - lastAnalysisTimeBuilder_; - /** - * - * - *
-     * The last time continuous analysis was done for this resource.
-     * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - public boolean hasLastAnalysisTime() { - return lastAnalysisTimeBuilder_ != null || lastAnalysisTime_ != null; - } - /** - * - * - *
-     * The last time continuous analysis was done for this resource.
-     * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - public com.google.protobuf.Timestamp getLastAnalysisTime() { - if (lastAnalysisTimeBuilder_ == null) { - return lastAnalysisTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : lastAnalysisTime_; - } else { - return lastAnalysisTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The last time continuous analysis was done for this resource.
-     * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - public Builder setLastAnalysisTime(com.google.protobuf.Timestamp value) { - if (lastAnalysisTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - lastAnalysisTime_ = value; - onChanged(); - } else { - lastAnalysisTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The last time continuous analysis was done for this resource.
-     * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - public Builder setLastAnalysisTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (lastAnalysisTimeBuilder_ == null) { - lastAnalysisTime_ = builderForValue.build(); - onChanged(); - } else { - lastAnalysisTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The last time continuous analysis was done for this resource.
-     * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - public Builder mergeLastAnalysisTime(com.google.protobuf.Timestamp value) { - if (lastAnalysisTimeBuilder_ == null) { - if (lastAnalysisTime_ != null) { - lastAnalysisTime_ = - com.google.protobuf.Timestamp.newBuilder(lastAnalysisTime_) - .mergeFrom(value) - .buildPartial(); - } else { - lastAnalysisTime_ = value; - } - onChanged(); - } else { - lastAnalysisTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The last time continuous analysis was done for this resource.
-     * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - public Builder clearLastAnalysisTime() { - if (lastAnalysisTimeBuilder_ == null) { - lastAnalysisTime_ = null; - onChanged(); - } else { - lastAnalysisTime_ = null; - lastAnalysisTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The last time continuous analysis was done for this resource.
-     * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - public com.google.protobuf.Timestamp.Builder getLastAnalysisTimeBuilder() { - - onChanged(); - return getLastAnalysisTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The last time continuous analysis was done for this resource.
-     * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - public com.google.protobuf.TimestampOrBuilder getLastAnalysisTimeOrBuilder() { - if (lastAnalysisTimeBuilder_ != null) { - return lastAnalysisTimeBuilder_.getMessageOrBuilder(); - } else { - return lastAnalysisTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : lastAnalysisTime_; - } - } - /** - * - * - *
-     * The last time continuous analysis was done for this resource.
-     * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getLastAnalysisTimeFieldBuilder() { - if (lastAnalysisTimeBuilder_ == null) { - lastAnalysisTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getLastAnalysisTime(), getParentForChildren(), isClean()); - lastAnalysisTime_ = null; - } - return lastAnalysisTimeBuilder_; - } - - private int analysisStatus_ = 0; - /** - * - * - *
-     * The status of discovery for the resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered.AnalysisStatus analysis_status = 3; - */ - public int getAnalysisStatusValue() { - return analysisStatus_; - } - /** - * - * - *
-     * The status of discovery for the resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered.AnalysisStatus analysis_status = 3; - */ - public Builder setAnalysisStatusValue(int value) { - analysisStatus_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The status of discovery for the resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered.AnalysisStatus analysis_status = 3; - */ - public io.grafeas.v1beta1.discovery.Discovered.AnalysisStatus getAnalysisStatus() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.discovery.Discovered.AnalysisStatus result = - io.grafeas.v1beta1.discovery.Discovered.AnalysisStatus.valueOf(analysisStatus_); - return result == null - ? io.grafeas.v1beta1.discovery.Discovered.AnalysisStatus.UNRECOGNIZED - : result; - } - /** - * - * - *
-     * The status of discovery for the resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered.AnalysisStatus analysis_status = 3; - */ - public Builder setAnalysisStatus(io.grafeas.v1beta1.discovery.Discovered.AnalysisStatus value) { - if (value == null) { - throw new NullPointerException(); - } - - analysisStatus_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * The status of discovery for the resource.
-     * 
- * - * .grafeas.v1beta1.discovery.Discovered.AnalysisStatus analysis_status = 3; - */ - public Builder clearAnalysisStatus() { - - analysisStatus_ = 0; - onChanged(); - return this; - } - - private com.google.rpc.Status analysisStatusError_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> - analysisStatusErrorBuilder_; - /** - * - * - *
-     * When an error is encountered this will contain a LocalizedMessage under
-     * details to show to the user. The LocalizedMessage is output only and
-     * populated by the API.
-     * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - public boolean hasAnalysisStatusError() { - return analysisStatusErrorBuilder_ != null || analysisStatusError_ != null; - } - /** - * - * - *
-     * When an error is encountered this will contain a LocalizedMessage under
-     * details to show to the user. The LocalizedMessage is output only and
-     * populated by the API.
-     * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - public com.google.rpc.Status getAnalysisStatusError() { - if (analysisStatusErrorBuilder_ == null) { - return analysisStatusError_ == null - ? com.google.rpc.Status.getDefaultInstance() - : analysisStatusError_; - } else { - return analysisStatusErrorBuilder_.getMessage(); - } - } - /** - * - * - *
-     * When an error is encountered this will contain a LocalizedMessage under
-     * details to show to the user. The LocalizedMessage is output only and
-     * populated by the API.
-     * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - public Builder setAnalysisStatusError(com.google.rpc.Status value) { - if (analysisStatusErrorBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - analysisStatusError_ = value; - onChanged(); - } else { - analysisStatusErrorBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * When an error is encountered this will contain a LocalizedMessage under
-     * details to show to the user. The LocalizedMessage is output only and
-     * populated by the API.
-     * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - public Builder setAnalysisStatusError(com.google.rpc.Status.Builder builderForValue) { - if (analysisStatusErrorBuilder_ == null) { - analysisStatusError_ = builderForValue.build(); - onChanged(); - } else { - analysisStatusErrorBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * When an error is encountered this will contain a LocalizedMessage under
-     * details to show to the user. The LocalizedMessage is output only and
-     * populated by the API.
-     * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - public Builder mergeAnalysisStatusError(com.google.rpc.Status value) { - if (analysisStatusErrorBuilder_ == null) { - if (analysisStatusError_ != null) { - analysisStatusError_ = - com.google.rpc.Status.newBuilder(analysisStatusError_) - .mergeFrom(value) - .buildPartial(); - } else { - analysisStatusError_ = value; - } - onChanged(); - } else { - analysisStatusErrorBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * When an error is encountered this will contain a LocalizedMessage under
-     * details to show to the user. The LocalizedMessage is output only and
-     * populated by the API.
-     * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - public Builder clearAnalysisStatusError() { - if (analysisStatusErrorBuilder_ == null) { - analysisStatusError_ = null; - onChanged(); - } else { - analysisStatusError_ = null; - analysisStatusErrorBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * When an error is encountered this will contain a LocalizedMessage under
-     * details to show to the user. The LocalizedMessage is output only and
-     * populated by the API.
-     * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - public com.google.rpc.Status.Builder getAnalysisStatusErrorBuilder() { - - onChanged(); - return getAnalysisStatusErrorFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * When an error is encountered this will contain a LocalizedMessage under
-     * details to show to the user. The LocalizedMessage is output only and
-     * populated by the API.
-     * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - public com.google.rpc.StatusOrBuilder getAnalysisStatusErrorOrBuilder() { - if (analysisStatusErrorBuilder_ != null) { - return analysisStatusErrorBuilder_.getMessageOrBuilder(); - } else { - return analysisStatusError_ == null - ? com.google.rpc.Status.getDefaultInstance() - : analysisStatusError_; - } - } - /** - * - * - *
-     * When an error is encountered this will contain a LocalizedMessage under
-     * details to show to the user. The LocalizedMessage is output only and
-     * populated by the API.
-     * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> - getAnalysisStatusErrorFieldBuilder() { - if (analysisStatusErrorBuilder_ == null) { - analysisStatusErrorBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.rpc.Status, - com.google.rpc.Status.Builder, - com.google.rpc.StatusOrBuilder>( - getAnalysisStatusError(), getParentForChildren(), isClean()); - analysisStatusError_ = null; - } - return analysisStatusErrorBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.discovery.Discovered) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.discovery.Discovered) - private static final io.grafeas.v1beta1.discovery.Discovered DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.discovery.Discovered(); - } - - public static io.grafeas.v1beta1.discovery.Discovered getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Discovered parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Discovered(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.discovery.Discovered getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DiscoveredOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DiscoveredOrBuilder.java deleted file mode 100644 index aa22eceb..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DiscoveredOrBuilder.java +++ /dev/null @@ -1,120 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/discovery/discovery.proto - -package io.grafeas.v1beta1.discovery; - -public interface DiscoveredOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.discovery.Discovered) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Whether the resource is continuously analyzed.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis continuous_analysis = 1; - */ - int getContinuousAnalysisValue(); - /** - * - * - *
-   * Whether the resource is continuously analyzed.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis continuous_analysis = 1; - */ - io.grafeas.v1beta1.discovery.Discovered.ContinuousAnalysis getContinuousAnalysis(); - - /** - * - * - *
-   * The last time continuous analysis was done for this resource.
-   * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - boolean hasLastAnalysisTime(); - /** - * - * - *
-   * The last time continuous analysis was done for this resource.
-   * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - com.google.protobuf.Timestamp getLastAnalysisTime(); - /** - * - * - *
-   * The last time continuous analysis was done for this resource.
-   * 
- * - * .google.protobuf.Timestamp last_analysis_time = 2; - */ - com.google.protobuf.TimestampOrBuilder getLastAnalysisTimeOrBuilder(); - - /** - * - * - *
-   * The status of discovery for the resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered.AnalysisStatus analysis_status = 3; - */ - int getAnalysisStatusValue(); - /** - * - * - *
-   * The status of discovery for the resource.
-   * 
- * - * .grafeas.v1beta1.discovery.Discovered.AnalysisStatus analysis_status = 3; - */ - io.grafeas.v1beta1.discovery.Discovered.AnalysisStatus getAnalysisStatus(); - - /** - * - * - *
-   * When an error is encountered this will contain a LocalizedMessage under
-   * details to show to the user. The LocalizedMessage is output only and
-   * populated by the API.
-   * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - boolean hasAnalysisStatusError(); - /** - * - * - *
-   * When an error is encountered this will contain a LocalizedMessage under
-   * details to show to the user. The LocalizedMessage is output only and
-   * populated by the API.
-   * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - com.google.rpc.Status getAnalysisStatusError(); - /** - * - * - *
-   * When an error is encountered this will contain a LocalizedMessage under
-   * details to show to the user. The LocalizedMessage is output only and
-   * populated by the API.
-   * 
- * - * .google.rpc.Status analysis_status_error = 4; - */ - com.google.rpc.StatusOrBuilder getAnalysisStatusErrorOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/Discovery.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/Discovery.java deleted file mode 100644 index 446bfe34..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/Discovery.java +++ /dev/null @@ -1,567 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/discovery/discovery.proto - -package io.grafeas.v1beta1.discovery; - -/** - * - * - *
- * A note that indicates a type of analysis a provider would perform. This note
- * exists in a provider's project. A `Discovery` occurrence is created in a
- * consumer's project at the start of analysis.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.discovery.Discovery} - */ -public final class Discovery extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.discovery.Discovery) - DiscoveryOrBuilder { - private static final long serialVersionUID = 0L; - // Use Discovery.newBuilder() to construct. - private Discovery(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Discovery() { - analysisKind_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Discovery( - 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 8: - { - int rawValue = input.readEnum(); - - analysisKind_ = rawValue; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Discovery_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Discovery_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.discovery.Discovery.class, - io.grafeas.v1beta1.discovery.Discovery.Builder.class); - } - - public static final int ANALYSIS_KIND_FIELD_NUMBER = 1; - private int analysisKind_; - /** - * - * - *
-   * The kind of analysis that is handled by this discovery.
-   * 
- * - * .grafeas.v1beta1.NoteKind analysis_kind = 1; - */ - public int getAnalysisKindValue() { - return analysisKind_; - } - /** - * - * - *
-   * The kind of analysis that is handled by this discovery.
-   * 
- * - * .grafeas.v1beta1.NoteKind analysis_kind = 1; - */ - public io.grafeas.v1beta1.common.NoteKind getAnalysisKind() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.common.NoteKind result = - io.grafeas.v1beta1.common.NoteKind.valueOf(analysisKind_); - return result == null ? io.grafeas.v1beta1.common.NoteKind.UNRECOGNIZED : result; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (analysisKind_ != io.grafeas.v1beta1.common.NoteKind.NOTE_KIND_UNSPECIFIED.getNumber()) { - output.writeEnum(1, analysisKind_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (analysisKind_ != io.grafeas.v1beta1.common.NoteKind.NOTE_KIND_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, analysisKind_); - } - 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 io.grafeas.v1beta1.discovery.Discovery)) { - return super.equals(obj); - } - io.grafeas.v1beta1.discovery.Discovery other = (io.grafeas.v1beta1.discovery.Discovery) obj; - - if (analysisKind_ != other.analysisKind_) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + ANALYSIS_KIND_FIELD_NUMBER; - hash = (53 * hash) + analysisKind_; - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.discovery.Discovery parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.discovery.Discovery parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.discovery.Discovery parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.discovery.Discovery parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.discovery.Discovery parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.discovery.Discovery parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.discovery.Discovery parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.discovery.Discovery 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 io.grafeas.v1beta1.discovery.Discovery parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.discovery.Discovery 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 io.grafeas.v1beta1.discovery.Discovery parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.discovery.Discovery 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(io.grafeas.v1beta1.discovery.Discovery prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A note that indicates a type of analysis a provider would perform. This note
-   * exists in a provider's project. A `Discovery` occurrence is created in a
-   * consumer's project at the start of analysis.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.discovery.Discovery} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.discovery.Discovery) - io.grafeas.v1beta1.discovery.DiscoveryOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Discovery_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Discovery_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.discovery.Discovery.class, - io.grafeas.v1beta1.discovery.Discovery.Builder.class); - } - - // Construct using io.grafeas.v1beta1.discovery.Discovery.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - analysisKind_ = 0; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.discovery.DiscoveryOuterClass - .internal_static_grafeas_v1beta1_discovery_Discovery_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.discovery.Discovery getDefaultInstanceForType() { - return io.grafeas.v1beta1.discovery.Discovery.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.discovery.Discovery build() { - io.grafeas.v1beta1.discovery.Discovery result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.discovery.Discovery buildPartial() { - io.grafeas.v1beta1.discovery.Discovery result = - new io.grafeas.v1beta1.discovery.Discovery(this); - result.analysisKind_ = analysisKind_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.discovery.Discovery) { - return mergeFrom((io.grafeas.v1beta1.discovery.Discovery) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.discovery.Discovery other) { - if (other == io.grafeas.v1beta1.discovery.Discovery.getDefaultInstance()) return this; - if (other.analysisKind_ != 0) { - setAnalysisKindValue(other.getAnalysisKindValue()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.discovery.Discovery parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.discovery.Discovery) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int analysisKind_ = 0; - /** - * - * - *
-     * The kind of analysis that is handled by this discovery.
-     * 
- * - * .grafeas.v1beta1.NoteKind analysis_kind = 1; - */ - public int getAnalysisKindValue() { - return analysisKind_; - } - /** - * - * - *
-     * The kind of analysis that is handled by this discovery.
-     * 
- * - * .grafeas.v1beta1.NoteKind analysis_kind = 1; - */ - public Builder setAnalysisKindValue(int value) { - analysisKind_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The kind of analysis that is handled by this discovery.
-     * 
- * - * .grafeas.v1beta1.NoteKind analysis_kind = 1; - */ - public io.grafeas.v1beta1.common.NoteKind getAnalysisKind() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.common.NoteKind result = - io.grafeas.v1beta1.common.NoteKind.valueOf(analysisKind_); - return result == null ? io.grafeas.v1beta1.common.NoteKind.UNRECOGNIZED : result; - } - /** - * - * - *
-     * The kind of analysis that is handled by this discovery.
-     * 
- * - * .grafeas.v1beta1.NoteKind analysis_kind = 1; - */ - public Builder setAnalysisKind(io.grafeas.v1beta1.common.NoteKind value) { - if (value == null) { - throw new NullPointerException(); - } - - analysisKind_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * The kind of analysis that is handled by this discovery.
-     * 
- * - * .grafeas.v1beta1.NoteKind analysis_kind = 1; - */ - public Builder clearAnalysisKind() { - - analysisKind_ = 0; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.discovery.Discovery) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.discovery.Discovery) - private static final io.grafeas.v1beta1.discovery.Discovery DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.discovery.Discovery(); - } - - public static io.grafeas.v1beta1.discovery.Discovery getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Discovery parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Discovery(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.discovery.Discovery getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DiscoveryOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DiscoveryOrBuilder.java deleted file mode 100644 index fee2e850..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DiscoveryOrBuilder.java +++ /dev/null @@ -1,31 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/discovery/discovery.proto - -package io.grafeas.v1beta1.discovery; - -public interface DiscoveryOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.discovery.Discovery) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The kind of analysis that is handled by this discovery.
-   * 
- * - * .grafeas.v1beta1.NoteKind analysis_kind = 1; - */ - int getAnalysisKindValue(); - /** - * - * - *
-   * The kind of analysis that is handled by this discovery.
-   * 
- * - * .grafeas.v1beta1.NoteKind analysis_kind = 1; - */ - io.grafeas.v1beta1.common.NoteKind getAnalysisKind(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DiscoveryOuterClass.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DiscoveryOuterClass.java deleted file mode 100644 index 7b33ccd4..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/DiscoveryOuterClass.java +++ /dev/null @@ -1,109 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/discovery/discovery.proto - -package io.grafeas.v1beta1.discovery; - -public final class DiscoveryOuterClass { - private DiscoveryOuterClass() {} - - 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_grafeas_v1beta1_discovery_Discovery_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_discovery_Discovery_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_discovery_Details_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_discovery_Details_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_discovery_Discovered_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_discovery_Discovered_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { - return descriptor; - } - - private static com.google.protobuf.Descriptors.FileDescriptor descriptor; - - static { - java.lang.String[] descriptorData = { - "\nCgoogle/devtools/containeranalysis/v1be" - + "ta1/discovery/discovery.proto\022\031grafeas.v" - + "1beta1.discovery\032=google/devtools/contai" - + "neranalysis/v1beta1/common/common.proto\032" - + "\037google/protobuf/timestamp.proto\032\027google" - + "/rpc/status.proto\"=\n\tDiscovery\0220\n\ranalys" - + "is_kind\030\001 \001(\0162\031.grafeas.v1beta1.NoteKind" - + "\"D\n\007Details\0229\n\ndiscovered\030\001 \001(\0132%.grafea" - + "s.v1beta1.discovery.Discovered\"\206\004\n\nDisco" - + "vered\022U\n\023continuous_analysis\030\001 \001(\01628.gra" - + "feas.v1beta1.discovery.Discovered.Contin" - + "uousAnalysis\0226\n\022last_analysis_time\030\002 \001(\013" - + "2\032.google.protobuf.Timestamp\022M\n\017analysis" - + "_status\030\003 \001(\01624.grafeas.v1beta1.discover" - + "y.Discovered.AnalysisStatus\0221\n\025analysis_" - + "status_error\030\004 \001(\0132\022.google.rpc.Status\"S" - + "\n\022ContinuousAnalysis\022#\n\037CONTINUOUS_ANALY" - + "SIS_UNSPECIFIED\020\000\022\n\n\006ACTIVE\020\001\022\014\n\010INACTIV" - + "E\020\002\"\221\001\n\016AnalysisStatus\022\037\n\033ANALYSIS_STATU" - + "S_UNSPECIFIED\020\000\022\013\n\007PENDING\020\001\022\014\n\010SCANNING" - + "\020\002\022\024\n\020FINISHED_SUCCESS\020\003\022\023\n\017FINISHED_FAI" - + "LED\020\004\022\030\n\024FINISHED_UNSUPPORTED\020\005B\204\001\n\034io.g" - + "rafeas.v1beta1.discoveryP\001Z\\google.golan" - + "g.org/genproto/googleapis/devtools/conta" - + "ineranalysis/v1beta1/discovery;discovery" - + "\242\002\003GRAb\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[] { - io.grafeas.v1beta1.common.Common.getDescriptor(), - com.google.protobuf.TimestampProto.getDescriptor(), - com.google.rpc.StatusProto.getDescriptor(), - }, - assigner); - internal_static_grafeas_v1beta1_discovery_Discovery_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_grafeas_v1beta1_discovery_Discovery_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_discovery_Discovery_descriptor, - new java.lang.String[] { - "AnalysisKind", - }); - internal_static_grafeas_v1beta1_discovery_Details_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_grafeas_v1beta1_discovery_Details_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_discovery_Details_descriptor, - new java.lang.String[] { - "Discovered", - }); - internal_static_grafeas_v1beta1_discovery_Discovered_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_grafeas_v1beta1_discovery_Discovered_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_discovery_Discovered_descriptor, - new java.lang.String[] { - "ContinuousAnalysis", "LastAnalysisTime", "AnalysisStatus", "AnalysisStatusError", - }); - io.grafeas.v1beta1.common.Common.getDescriptor(); - com.google.protobuf.TimestampProto.getDescriptor(); - com.google.rpc.StatusProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/IamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/IamResourceName.java deleted file mode 100644 index 464a7be9..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/IamResourceName.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.discovery; - -import com.google.api.resourcenames.ResourceName; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public abstract class IamResourceName implements ResourceName { - protected IamResourceName() {} -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/IamResourceNames.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/IamResourceNames.java deleted file mode 100644 index d667dc18..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/IamResourceNames.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.discovery; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class IamResourceNames { - private IamResourceNames() {} - - public static IamResourceName parse(String resourceNameString) { - if (NoteName.isParsableFrom(resourceNameString)) { - return NoteName.parse(resourceNameString); - } - if (OccurrenceName.isParsableFrom(resourceNameString)) { - return OccurrenceName.parse(resourceNameString); - } - return UntypedIamResourceName.parse(resourceNameString); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/NoteName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/NoteName.java deleted file mode 100644 index efbfe1fd..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/NoteName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.discovery; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class NoteName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/notes/{note}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/OccurrenceName.java deleted file mode 100644 index aac5821d..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.discovery; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/ProjectName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/ProjectName.java deleted file mode 100644 index 400d1f69..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.discovery; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/ScanConfigName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/ScanConfigName.java deleted file mode 100644 index d9d5649e..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/ScanConfigName.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.discovery; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ScanConfigName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ScanConfigName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - scanConfig = Preconditions.checkNotNull(builder.getScanConfig()); - } - - public static ScanConfigName of(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build(); - } - - public static String format(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build().toString(); - } - - public static ScanConfigName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ScanConfigName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("scan_config")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ScanConfigName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("scanConfig", scanConfig); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "scan_config", scanConfig); - } - - /** Builder for ScanConfigName. */ - public static class Builder { - - private String project; - private String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setScanConfig(String scanConfig) { - this.scanConfig = scanConfig; - return this; - } - - private Builder() {} - - private Builder(ScanConfigName scanConfigName) { - project = scanConfigName.project; - scanConfig = scanConfigName.scanConfig; - } - - public ScanConfigName build() { - return new ScanConfigName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ScanConfigName) { - ScanConfigName that = (ScanConfigName) o; - return (this.project.equals(that.project)) && (this.scanConfig.equals(that.scanConfig)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= scanConfig.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/UntypedIamResourceName.java deleted file mode 100644 index 3a47d958..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/discovery/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.discovery; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Basis.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Basis.java deleted file mode 100644 index 08f90b2a..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Basis.java +++ /dev/null @@ -1,869 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/image/image.proto - -package io.grafeas.v1beta1.image; - -/** - * - * - *
- * Basis describes the base image portion (Note) of the DockerImage
- * relationship. Linked occurrences are derived from this or an
- * equivalent image via:
- *   FROM <Basis.resource_url>
- * Or an equivalent reference, e.g. a tag of the resource_url.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.image.Basis} - */ -public final class Basis extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.image.Basis) - BasisOrBuilder { - private static final long serialVersionUID = 0L; - // Use Basis.newBuilder() to construct. - private Basis(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Basis() { - resourceUrl_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Basis( - 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(); - - resourceUrl_ = s; - break; - } - case 18: - { - io.grafeas.v1beta1.image.Fingerprint.Builder subBuilder = null; - if (fingerprint_ != null) { - subBuilder = fingerprint_.toBuilder(); - } - fingerprint_ = - input.readMessage( - io.grafeas.v1beta1.image.Fingerprint.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(fingerprint_); - fingerprint_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.image.Image.internal_static_grafeas_v1beta1_image_Basis_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Basis_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.image.Basis.class, io.grafeas.v1beta1.image.Basis.Builder.class); - } - - public static final int RESOURCE_URL_FIELD_NUMBER = 1; - private volatile java.lang.Object resourceUrl_; - /** - * - * - *
-   * The resource_url for the resource representing the basis of
-   * associated occurrence images.
-   * 
- * - * string resource_url = 1; - */ - public java.lang.String getResourceUrl() { - java.lang.Object ref = resourceUrl_; - 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(); - resourceUrl_ = s; - return s; - } - } - /** - * - * - *
-   * The resource_url for the resource representing the basis of
-   * associated occurrence images.
-   * 
- * - * string resource_url = 1; - */ - public com.google.protobuf.ByteString getResourceUrlBytes() { - java.lang.Object ref = resourceUrl_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - resourceUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int FINGERPRINT_FIELD_NUMBER = 2; - private io.grafeas.v1beta1.image.Fingerprint fingerprint_; - /** - * - * - *
-   * The fingerprint of the base image.
-   * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - public boolean hasFingerprint() { - return fingerprint_ != null; - } - /** - * - * - *
-   * The fingerprint of the base image.
-   * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - public io.grafeas.v1beta1.image.Fingerprint getFingerprint() { - return fingerprint_ == null - ? io.grafeas.v1beta1.image.Fingerprint.getDefaultInstance() - : fingerprint_; - } - /** - * - * - *
-   * The fingerprint of the base image.
-   * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - public io.grafeas.v1beta1.image.FingerprintOrBuilder getFingerprintOrBuilder() { - return getFingerprint(); - } - - 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 (!getResourceUrlBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resourceUrl_); - } - if (fingerprint_ != null) { - output.writeMessage(2, getFingerprint()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getResourceUrlBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, resourceUrl_); - } - if (fingerprint_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getFingerprint()); - } - 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 io.grafeas.v1beta1.image.Basis)) { - return super.equals(obj); - } - io.grafeas.v1beta1.image.Basis other = (io.grafeas.v1beta1.image.Basis) obj; - - if (!getResourceUrl().equals(other.getResourceUrl())) return false; - if (hasFingerprint() != other.hasFingerprint()) return false; - if (hasFingerprint()) { - if (!getFingerprint().equals(other.getFingerprint())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + RESOURCE_URL_FIELD_NUMBER; - hash = (53 * hash) + getResourceUrl().hashCode(); - if (hasFingerprint()) { - hash = (37 * hash) + FINGERPRINT_FIELD_NUMBER; - hash = (53 * hash) + getFingerprint().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.image.Basis parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Basis parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Basis parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Basis parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Basis parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Basis parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Basis parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Basis 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 io.grafeas.v1beta1.image.Basis parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Basis 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 io.grafeas.v1beta1.image.Basis parseFrom(com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Basis 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(io.grafeas.v1beta1.image.Basis 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; - } - /** - * - * - *
-   * Basis describes the base image portion (Note) of the DockerImage
-   * relationship. Linked occurrences are derived from this or an
-   * equivalent image via:
-   *   FROM <Basis.resource_url>
-   * Or an equivalent reference, e.g. a tag of the resource_url.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.image.Basis} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.image.Basis) - io.grafeas.v1beta1.image.BasisOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.image.Image.internal_static_grafeas_v1beta1_image_Basis_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Basis_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.image.Basis.class, io.grafeas.v1beta1.image.Basis.Builder.class); - } - - // Construct using io.grafeas.v1beta1.image.Basis.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - resourceUrl_ = ""; - - if (fingerprintBuilder_ == null) { - fingerprint_ = null; - } else { - fingerprint_ = null; - fingerprintBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.image.Image.internal_static_grafeas_v1beta1_image_Basis_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Basis getDefaultInstanceForType() { - return io.grafeas.v1beta1.image.Basis.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Basis build() { - io.grafeas.v1beta1.image.Basis result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Basis buildPartial() { - io.grafeas.v1beta1.image.Basis result = new io.grafeas.v1beta1.image.Basis(this); - result.resourceUrl_ = resourceUrl_; - if (fingerprintBuilder_ == null) { - result.fingerprint_ = fingerprint_; - } else { - result.fingerprint_ = fingerprintBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.image.Basis) { - return mergeFrom((io.grafeas.v1beta1.image.Basis) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.image.Basis other) { - if (other == io.grafeas.v1beta1.image.Basis.getDefaultInstance()) return this; - if (!other.getResourceUrl().isEmpty()) { - resourceUrl_ = other.resourceUrl_; - onChanged(); - } - if (other.hasFingerprint()) { - mergeFingerprint(other.getFingerprint()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.image.Basis parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.image.Basis) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object resourceUrl_ = ""; - /** - * - * - *
-     * The resource_url for the resource representing the basis of
-     * associated occurrence images.
-     * 
- * - * string resource_url = 1; - */ - public java.lang.String getResourceUrl() { - java.lang.Object ref = resourceUrl_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - resourceUrl_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The resource_url for the resource representing the basis of
-     * associated occurrence images.
-     * 
- * - * string resource_url = 1; - */ - public com.google.protobuf.ByteString getResourceUrlBytes() { - java.lang.Object ref = resourceUrl_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - resourceUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The resource_url for the resource representing the basis of
-     * associated occurrence images.
-     * 
- * - * string resource_url = 1; - */ - public Builder setResourceUrl(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - resourceUrl_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The resource_url for the resource representing the basis of
-     * associated occurrence images.
-     * 
- * - * string resource_url = 1; - */ - public Builder clearResourceUrl() { - - resourceUrl_ = getDefaultInstance().getResourceUrl(); - onChanged(); - return this; - } - /** - * - * - *
-     * The resource_url for the resource representing the basis of
-     * associated occurrence images.
-     * 
- * - * string resource_url = 1; - */ - public Builder setResourceUrlBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - resourceUrl_ = value; - onChanged(); - return this; - } - - private io.grafeas.v1beta1.image.Fingerprint fingerprint_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Fingerprint, - io.grafeas.v1beta1.image.Fingerprint.Builder, - io.grafeas.v1beta1.image.FingerprintOrBuilder> - fingerprintBuilder_; - /** - * - * - *
-     * The fingerprint of the base image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - public boolean hasFingerprint() { - return fingerprintBuilder_ != null || fingerprint_ != null; - } - /** - * - * - *
-     * The fingerprint of the base image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - public io.grafeas.v1beta1.image.Fingerprint getFingerprint() { - if (fingerprintBuilder_ == null) { - return fingerprint_ == null - ? io.grafeas.v1beta1.image.Fingerprint.getDefaultInstance() - : fingerprint_; - } else { - return fingerprintBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The fingerprint of the base image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - public Builder setFingerprint(io.grafeas.v1beta1.image.Fingerprint value) { - if (fingerprintBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - fingerprint_ = value; - onChanged(); - } else { - fingerprintBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The fingerprint of the base image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - public Builder setFingerprint(io.grafeas.v1beta1.image.Fingerprint.Builder builderForValue) { - if (fingerprintBuilder_ == null) { - fingerprint_ = builderForValue.build(); - onChanged(); - } else { - fingerprintBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The fingerprint of the base image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - public Builder mergeFingerprint(io.grafeas.v1beta1.image.Fingerprint value) { - if (fingerprintBuilder_ == null) { - if (fingerprint_ != null) { - fingerprint_ = - io.grafeas.v1beta1.image.Fingerprint.newBuilder(fingerprint_) - .mergeFrom(value) - .buildPartial(); - } else { - fingerprint_ = value; - } - onChanged(); - } else { - fingerprintBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The fingerprint of the base image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - public Builder clearFingerprint() { - if (fingerprintBuilder_ == null) { - fingerprint_ = null; - onChanged(); - } else { - fingerprint_ = null; - fingerprintBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The fingerprint of the base image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - public io.grafeas.v1beta1.image.Fingerprint.Builder getFingerprintBuilder() { - - onChanged(); - return getFingerprintFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The fingerprint of the base image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - public io.grafeas.v1beta1.image.FingerprintOrBuilder getFingerprintOrBuilder() { - if (fingerprintBuilder_ != null) { - return fingerprintBuilder_.getMessageOrBuilder(); - } else { - return fingerprint_ == null - ? io.grafeas.v1beta1.image.Fingerprint.getDefaultInstance() - : fingerprint_; - } - } - /** - * - * - *
-     * The fingerprint of the base image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Fingerprint, - io.grafeas.v1beta1.image.Fingerprint.Builder, - io.grafeas.v1beta1.image.FingerprintOrBuilder> - getFingerprintFieldBuilder() { - if (fingerprintBuilder_ == null) { - fingerprintBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Fingerprint, - io.grafeas.v1beta1.image.Fingerprint.Builder, - io.grafeas.v1beta1.image.FingerprintOrBuilder>( - getFingerprint(), getParentForChildren(), isClean()); - fingerprint_ = null; - } - return fingerprintBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.image.Basis) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.image.Basis) - private static final io.grafeas.v1beta1.image.Basis DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.image.Basis(); - } - - public static io.grafeas.v1beta1.image.Basis getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Basis parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Basis(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Basis getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/BasisOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/BasisOrBuilder.java deleted file mode 100644 index 7beae545..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/BasisOrBuilder.java +++ /dev/null @@ -1,64 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/image/image.proto - -package io.grafeas.v1beta1.image; - -public interface BasisOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.image.Basis) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The resource_url for the resource representing the basis of
-   * associated occurrence images.
-   * 
- * - * string resource_url = 1; - */ - java.lang.String getResourceUrl(); - /** - * - * - *
-   * The resource_url for the resource representing the basis of
-   * associated occurrence images.
-   * 
- * - * string resource_url = 1; - */ - com.google.protobuf.ByteString getResourceUrlBytes(); - - /** - * - * - *
-   * The fingerprint of the base image.
-   * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - boolean hasFingerprint(); - /** - * - * - *
-   * The fingerprint of the base image.
-   * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - io.grafeas.v1beta1.image.Fingerprint getFingerprint(); - /** - * - * - *
-   * The fingerprint of the base image.
-   * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 2; - */ - io.grafeas.v1beta1.image.FingerprintOrBuilder getFingerprintOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Derived.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Derived.java deleted file mode 100644 index 1d1eb583..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Derived.java +++ /dev/null @@ -1,1482 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/image/image.proto - -package io.grafeas.v1beta1.image; - -/** - * - * - *
- * Derived describes the derived image portion (Occurrence) of the DockerImage
- * relationship. This image would be produced from a Dockerfile with FROM
- * <DockerImage.Basis in attached Note>.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.image.Derived} - */ -public final class Derived extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.image.Derived) - DerivedOrBuilder { - private static final long serialVersionUID = 0L; - // Use Derived.newBuilder() to construct. - private Derived(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Derived() { - layerInfo_ = java.util.Collections.emptyList(); - baseResourceUrl_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Derived( - 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: - { - io.grafeas.v1beta1.image.Fingerprint.Builder subBuilder = null; - if (fingerprint_ != null) { - subBuilder = fingerprint_.toBuilder(); - } - fingerprint_ = - input.readMessage( - io.grafeas.v1beta1.image.Fingerprint.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(fingerprint_); - fingerprint_ = subBuilder.buildPartial(); - } - - break; - } - case 16: - { - distance_ = input.readInt32(); - break; - } - case 26: - { - if (!((mutable_bitField0_ & 0x00000004) != 0)) { - layerInfo_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000004; - } - layerInfo_.add( - input.readMessage(io.grafeas.v1beta1.image.Layer.parser(), extensionRegistry)); - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - baseResourceUrl_ = s; - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000004) != 0)) { - layerInfo_ = java.util.Collections.unmodifiableList(layerInfo_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.image.Image.internal_static_grafeas_v1beta1_image_Derived_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Derived_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.image.Derived.class, io.grafeas.v1beta1.image.Derived.Builder.class); - } - - private int bitField0_; - public static final int FINGERPRINT_FIELD_NUMBER = 1; - private io.grafeas.v1beta1.image.Fingerprint fingerprint_; - /** - * - * - *
-   * The fingerprint of the derived image.
-   * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - public boolean hasFingerprint() { - return fingerprint_ != null; - } - /** - * - * - *
-   * The fingerprint of the derived image.
-   * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - public io.grafeas.v1beta1.image.Fingerprint getFingerprint() { - return fingerprint_ == null - ? io.grafeas.v1beta1.image.Fingerprint.getDefaultInstance() - : fingerprint_; - } - /** - * - * - *
-   * The fingerprint of the derived image.
-   * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - public io.grafeas.v1beta1.image.FingerprintOrBuilder getFingerprintOrBuilder() { - return getFingerprint(); - } - - public static final int DISTANCE_FIELD_NUMBER = 2; - private int distance_; - /** - * - * - *
-   * Output only. The number of layers by which this image differs from the
-   * associated image basis.
-   * 
- * - * int32 distance = 2; - */ - public int getDistance() { - return distance_; - } - - public static final int LAYER_INFO_FIELD_NUMBER = 3; - private java.util.List layerInfo_; - /** - * - * - *
-   * This contains layer-specific metadata, if populated it has length
-   * "distance" and is ordered with [distance] being the layer immediately
-   * following the base image and [1] being the final layer.
-   * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public java.util.List getLayerInfoList() { - return layerInfo_; - } - /** - * - * - *
-   * This contains layer-specific metadata, if populated it has length
-   * "distance" and is ordered with [distance] being the layer immediately
-   * following the base image and [1] being the final layer.
-   * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public java.util.List - getLayerInfoOrBuilderList() { - return layerInfo_; - } - /** - * - * - *
-   * This contains layer-specific metadata, if populated it has length
-   * "distance" and is ordered with [distance] being the layer immediately
-   * following the base image and [1] being the final layer.
-   * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public int getLayerInfoCount() { - return layerInfo_.size(); - } - /** - * - * - *
-   * This contains layer-specific metadata, if populated it has length
-   * "distance" and is ordered with [distance] being the layer immediately
-   * following the base image and [1] being the final layer.
-   * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public io.grafeas.v1beta1.image.Layer getLayerInfo(int index) { - return layerInfo_.get(index); - } - /** - * - * - *
-   * This contains layer-specific metadata, if populated it has length
-   * "distance" and is ordered with [distance] being the layer immediately
-   * following the base image and [1] being the final layer.
-   * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public io.grafeas.v1beta1.image.LayerOrBuilder getLayerInfoOrBuilder(int index) { - return layerInfo_.get(index); - } - - public static final int BASE_RESOURCE_URL_FIELD_NUMBER = 4; - private volatile java.lang.Object baseResourceUrl_; - /** - * - * - *
-   * Output only. This contains the base image URL for the derived image
-   * occurrence.
-   * 
- * - * string base_resource_url = 4; - */ - public java.lang.String getBaseResourceUrl() { - java.lang.Object ref = baseResourceUrl_; - 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(); - baseResourceUrl_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. This contains the base image URL for the derived image
-   * occurrence.
-   * 
- * - * string base_resource_url = 4; - */ - public com.google.protobuf.ByteString getBaseResourceUrlBytes() { - java.lang.Object ref = baseResourceUrl_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - baseResourceUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (fingerprint_ != null) { - output.writeMessage(1, getFingerprint()); - } - if (distance_ != 0) { - output.writeInt32(2, distance_); - } - for (int i = 0; i < layerInfo_.size(); i++) { - output.writeMessage(3, layerInfo_.get(i)); - } - if (!getBaseResourceUrlBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, baseResourceUrl_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (fingerprint_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getFingerprint()); - } - if (distance_ != 0) { - size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, distance_); - } - for (int i = 0; i < layerInfo_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, layerInfo_.get(i)); - } - if (!getBaseResourceUrlBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, baseResourceUrl_); - } - 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 io.grafeas.v1beta1.image.Derived)) { - return super.equals(obj); - } - io.grafeas.v1beta1.image.Derived other = (io.grafeas.v1beta1.image.Derived) obj; - - if (hasFingerprint() != other.hasFingerprint()) return false; - if (hasFingerprint()) { - if (!getFingerprint().equals(other.getFingerprint())) return false; - } - if (getDistance() != other.getDistance()) return false; - if (!getLayerInfoList().equals(other.getLayerInfoList())) return false; - if (!getBaseResourceUrl().equals(other.getBaseResourceUrl())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasFingerprint()) { - hash = (37 * hash) + FINGERPRINT_FIELD_NUMBER; - hash = (53 * hash) + getFingerprint().hashCode(); - } - hash = (37 * hash) + DISTANCE_FIELD_NUMBER; - hash = (53 * hash) + getDistance(); - if (getLayerInfoCount() > 0) { - hash = (37 * hash) + LAYER_INFO_FIELD_NUMBER; - hash = (53 * hash) + getLayerInfoList().hashCode(); - } - hash = (37 * hash) + BASE_RESOURCE_URL_FIELD_NUMBER; - hash = (53 * hash) + getBaseResourceUrl().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.image.Derived parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Derived parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Derived parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Derived parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Derived parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Derived parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Derived parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Derived 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 io.grafeas.v1beta1.image.Derived parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Derived 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 io.grafeas.v1beta1.image.Derived parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Derived 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(io.grafeas.v1beta1.image.Derived 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; - } - /** - * - * - *
-   * Derived describes the derived image portion (Occurrence) of the DockerImage
-   * relationship. This image would be produced from a Dockerfile with FROM
-   * <DockerImage.Basis in attached Note>.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.image.Derived} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.image.Derived) - io.grafeas.v1beta1.image.DerivedOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Derived_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Derived_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.image.Derived.class, - io.grafeas.v1beta1.image.Derived.Builder.class); - } - - // Construct using io.grafeas.v1beta1.image.Derived.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getLayerInfoFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (fingerprintBuilder_ == null) { - fingerprint_ = null; - } else { - fingerprint_ = null; - fingerprintBuilder_ = null; - } - distance_ = 0; - - if (layerInfoBuilder_ == null) { - layerInfo_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - } else { - layerInfoBuilder_.clear(); - } - baseResourceUrl_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Derived_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Derived getDefaultInstanceForType() { - return io.grafeas.v1beta1.image.Derived.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Derived build() { - io.grafeas.v1beta1.image.Derived result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Derived buildPartial() { - io.grafeas.v1beta1.image.Derived result = new io.grafeas.v1beta1.image.Derived(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (fingerprintBuilder_ == null) { - result.fingerprint_ = fingerprint_; - } else { - result.fingerprint_ = fingerprintBuilder_.build(); - } - result.distance_ = distance_; - if (layerInfoBuilder_ == null) { - if (((bitField0_ & 0x00000004) != 0)) { - layerInfo_ = java.util.Collections.unmodifiableList(layerInfo_); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.layerInfo_ = layerInfo_; - } else { - result.layerInfo_ = layerInfoBuilder_.build(); - } - result.baseResourceUrl_ = baseResourceUrl_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.image.Derived) { - return mergeFrom((io.grafeas.v1beta1.image.Derived) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.image.Derived other) { - if (other == io.grafeas.v1beta1.image.Derived.getDefaultInstance()) return this; - if (other.hasFingerprint()) { - mergeFingerprint(other.getFingerprint()); - } - if (other.getDistance() != 0) { - setDistance(other.getDistance()); - } - if (layerInfoBuilder_ == null) { - if (!other.layerInfo_.isEmpty()) { - if (layerInfo_.isEmpty()) { - layerInfo_ = other.layerInfo_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureLayerInfoIsMutable(); - layerInfo_.addAll(other.layerInfo_); - } - onChanged(); - } - } else { - if (!other.layerInfo_.isEmpty()) { - if (layerInfoBuilder_.isEmpty()) { - layerInfoBuilder_.dispose(); - layerInfoBuilder_ = null; - layerInfo_ = other.layerInfo_; - bitField0_ = (bitField0_ & ~0x00000004); - layerInfoBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getLayerInfoFieldBuilder() - : null; - } else { - layerInfoBuilder_.addAllMessages(other.layerInfo_); - } - } - } - if (!other.getBaseResourceUrl().isEmpty()) { - baseResourceUrl_ = other.baseResourceUrl_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.image.Derived parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.image.Derived) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private io.grafeas.v1beta1.image.Fingerprint fingerprint_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Fingerprint, - io.grafeas.v1beta1.image.Fingerprint.Builder, - io.grafeas.v1beta1.image.FingerprintOrBuilder> - fingerprintBuilder_; - /** - * - * - *
-     * The fingerprint of the derived image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - public boolean hasFingerprint() { - return fingerprintBuilder_ != null || fingerprint_ != null; - } - /** - * - * - *
-     * The fingerprint of the derived image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - public io.grafeas.v1beta1.image.Fingerprint getFingerprint() { - if (fingerprintBuilder_ == null) { - return fingerprint_ == null - ? io.grafeas.v1beta1.image.Fingerprint.getDefaultInstance() - : fingerprint_; - } else { - return fingerprintBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The fingerprint of the derived image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - public Builder setFingerprint(io.grafeas.v1beta1.image.Fingerprint value) { - if (fingerprintBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - fingerprint_ = value; - onChanged(); - } else { - fingerprintBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The fingerprint of the derived image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - public Builder setFingerprint(io.grafeas.v1beta1.image.Fingerprint.Builder builderForValue) { - if (fingerprintBuilder_ == null) { - fingerprint_ = builderForValue.build(); - onChanged(); - } else { - fingerprintBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The fingerprint of the derived image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - public Builder mergeFingerprint(io.grafeas.v1beta1.image.Fingerprint value) { - if (fingerprintBuilder_ == null) { - if (fingerprint_ != null) { - fingerprint_ = - io.grafeas.v1beta1.image.Fingerprint.newBuilder(fingerprint_) - .mergeFrom(value) - .buildPartial(); - } else { - fingerprint_ = value; - } - onChanged(); - } else { - fingerprintBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The fingerprint of the derived image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - public Builder clearFingerprint() { - if (fingerprintBuilder_ == null) { - fingerprint_ = null; - onChanged(); - } else { - fingerprint_ = null; - fingerprintBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The fingerprint of the derived image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - public io.grafeas.v1beta1.image.Fingerprint.Builder getFingerprintBuilder() { - - onChanged(); - return getFingerprintFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The fingerprint of the derived image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - public io.grafeas.v1beta1.image.FingerprintOrBuilder getFingerprintOrBuilder() { - if (fingerprintBuilder_ != null) { - return fingerprintBuilder_.getMessageOrBuilder(); - } else { - return fingerprint_ == null - ? io.grafeas.v1beta1.image.Fingerprint.getDefaultInstance() - : fingerprint_; - } - } - /** - * - * - *
-     * The fingerprint of the derived image.
-     * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Fingerprint, - io.grafeas.v1beta1.image.Fingerprint.Builder, - io.grafeas.v1beta1.image.FingerprintOrBuilder> - getFingerprintFieldBuilder() { - if (fingerprintBuilder_ == null) { - fingerprintBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Fingerprint, - io.grafeas.v1beta1.image.Fingerprint.Builder, - io.grafeas.v1beta1.image.FingerprintOrBuilder>( - getFingerprint(), getParentForChildren(), isClean()); - fingerprint_ = null; - } - return fingerprintBuilder_; - } - - private int distance_; - /** - * - * - *
-     * Output only. The number of layers by which this image differs from the
-     * associated image basis.
-     * 
- * - * int32 distance = 2; - */ - public int getDistance() { - return distance_; - } - /** - * - * - *
-     * Output only. The number of layers by which this image differs from the
-     * associated image basis.
-     * 
- * - * int32 distance = 2; - */ - public Builder setDistance(int value) { - - distance_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The number of layers by which this image differs from the
-     * associated image basis.
-     * 
- * - * int32 distance = 2; - */ - public Builder clearDistance() { - - distance_ = 0; - onChanged(); - return this; - } - - private java.util.List layerInfo_ = - java.util.Collections.emptyList(); - - private void ensureLayerInfoIsMutable() { - if (!((bitField0_ & 0x00000004) != 0)) { - layerInfo_ = new java.util.ArrayList(layerInfo_); - bitField0_ |= 0x00000004; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.image.Layer, - io.grafeas.v1beta1.image.Layer.Builder, - io.grafeas.v1beta1.image.LayerOrBuilder> - layerInfoBuilder_; - - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public java.util.List getLayerInfoList() { - if (layerInfoBuilder_ == null) { - return java.util.Collections.unmodifiableList(layerInfo_); - } else { - return layerInfoBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public int getLayerInfoCount() { - if (layerInfoBuilder_ == null) { - return layerInfo_.size(); - } else { - return layerInfoBuilder_.getCount(); - } - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public io.grafeas.v1beta1.image.Layer getLayerInfo(int index) { - if (layerInfoBuilder_ == null) { - return layerInfo_.get(index); - } else { - return layerInfoBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public Builder setLayerInfo(int index, io.grafeas.v1beta1.image.Layer value) { - if (layerInfoBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureLayerInfoIsMutable(); - layerInfo_.set(index, value); - onChanged(); - } else { - layerInfoBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public Builder setLayerInfo(int index, io.grafeas.v1beta1.image.Layer.Builder builderForValue) { - if (layerInfoBuilder_ == null) { - ensureLayerInfoIsMutable(); - layerInfo_.set(index, builderForValue.build()); - onChanged(); - } else { - layerInfoBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public Builder addLayerInfo(io.grafeas.v1beta1.image.Layer value) { - if (layerInfoBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureLayerInfoIsMutable(); - layerInfo_.add(value); - onChanged(); - } else { - layerInfoBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public Builder addLayerInfo(int index, io.grafeas.v1beta1.image.Layer value) { - if (layerInfoBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureLayerInfoIsMutable(); - layerInfo_.add(index, value); - onChanged(); - } else { - layerInfoBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public Builder addLayerInfo(io.grafeas.v1beta1.image.Layer.Builder builderForValue) { - if (layerInfoBuilder_ == null) { - ensureLayerInfoIsMutable(); - layerInfo_.add(builderForValue.build()); - onChanged(); - } else { - layerInfoBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public Builder addLayerInfo(int index, io.grafeas.v1beta1.image.Layer.Builder builderForValue) { - if (layerInfoBuilder_ == null) { - ensureLayerInfoIsMutable(); - layerInfo_.add(index, builderForValue.build()); - onChanged(); - } else { - layerInfoBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public Builder addAllLayerInfo( - java.lang.Iterable values) { - if (layerInfoBuilder_ == null) { - ensureLayerInfoIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, layerInfo_); - onChanged(); - } else { - layerInfoBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public Builder clearLayerInfo() { - if (layerInfoBuilder_ == null) { - layerInfo_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - } else { - layerInfoBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public Builder removeLayerInfo(int index) { - if (layerInfoBuilder_ == null) { - ensureLayerInfoIsMutable(); - layerInfo_.remove(index); - onChanged(); - } else { - layerInfoBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public io.grafeas.v1beta1.image.Layer.Builder getLayerInfoBuilder(int index) { - return getLayerInfoFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public io.grafeas.v1beta1.image.LayerOrBuilder getLayerInfoOrBuilder(int index) { - if (layerInfoBuilder_ == null) { - return layerInfo_.get(index); - } else { - return layerInfoBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public java.util.List - getLayerInfoOrBuilderList() { - if (layerInfoBuilder_ != null) { - return layerInfoBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(layerInfo_); - } - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public io.grafeas.v1beta1.image.Layer.Builder addLayerInfoBuilder() { - return getLayerInfoFieldBuilder() - .addBuilder(io.grafeas.v1beta1.image.Layer.getDefaultInstance()); - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public io.grafeas.v1beta1.image.Layer.Builder addLayerInfoBuilder(int index) { - return getLayerInfoFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.image.Layer.getDefaultInstance()); - } - /** - * - * - *
-     * This contains layer-specific metadata, if populated it has length
-     * "distance" and is ordered with [distance] being the layer immediately
-     * following the base image and [1] being the final layer.
-     * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - public java.util.List getLayerInfoBuilderList() { - return getLayerInfoFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.image.Layer, - io.grafeas.v1beta1.image.Layer.Builder, - io.grafeas.v1beta1.image.LayerOrBuilder> - getLayerInfoFieldBuilder() { - if (layerInfoBuilder_ == null) { - layerInfoBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.image.Layer, - io.grafeas.v1beta1.image.Layer.Builder, - io.grafeas.v1beta1.image.LayerOrBuilder>( - layerInfo_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); - layerInfo_ = null; - } - return layerInfoBuilder_; - } - - private java.lang.Object baseResourceUrl_ = ""; - /** - * - * - *
-     * Output only. This contains the base image URL for the derived image
-     * occurrence.
-     * 
- * - * string base_resource_url = 4; - */ - public java.lang.String getBaseResourceUrl() { - java.lang.Object ref = baseResourceUrl_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - baseResourceUrl_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. This contains the base image URL for the derived image
-     * occurrence.
-     * 
- * - * string base_resource_url = 4; - */ - public com.google.protobuf.ByteString getBaseResourceUrlBytes() { - java.lang.Object ref = baseResourceUrl_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - baseResourceUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. This contains the base image URL for the derived image
-     * occurrence.
-     * 
- * - * string base_resource_url = 4; - */ - public Builder setBaseResourceUrl(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - baseResourceUrl_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. This contains the base image URL for the derived image
-     * occurrence.
-     * 
- * - * string base_resource_url = 4; - */ - public Builder clearBaseResourceUrl() { - - baseResourceUrl_ = getDefaultInstance().getBaseResourceUrl(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. This contains the base image URL for the derived image
-     * occurrence.
-     * 
- * - * string base_resource_url = 4; - */ - public Builder setBaseResourceUrlBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - baseResourceUrl_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.image.Derived) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.image.Derived) - private static final io.grafeas.v1beta1.image.Derived DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.image.Derived(); - } - - public static io.grafeas.v1beta1.image.Derived getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Derived parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Derived(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Derived getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/DerivedOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/DerivedOrBuilder.java deleted file mode 100644 index 34ce64e5..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/DerivedOrBuilder.java +++ /dev/null @@ -1,137 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/image/image.proto - -package io.grafeas.v1beta1.image; - -public interface DerivedOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.image.Derived) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The fingerprint of the derived image.
-   * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - boolean hasFingerprint(); - /** - * - * - *
-   * The fingerprint of the derived image.
-   * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - io.grafeas.v1beta1.image.Fingerprint getFingerprint(); - /** - * - * - *
-   * The fingerprint of the derived image.
-   * 
- * - * .grafeas.v1beta1.image.Fingerprint fingerprint = 1; - */ - io.grafeas.v1beta1.image.FingerprintOrBuilder getFingerprintOrBuilder(); - - /** - * - * - *
-   * Output only. The number of layers by which this image differs from the
-   * associated image basis.
-   * 
- * - * int32 distance = 2; - */ - int getDistance(); - - /** - * - * - *
-   * This contains layer-specific metadata, if populated it has length
-   * "distance" and is ordered with [distance] being the layer immediately
-   * following the base image and [1] being the final layer.
-   * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - java.util.List getLayerInfoList(); - /** - * - * - *
-   * This contains layer-specific metadata, if populated it has length
-   * "distance" and is ordered with [distance] being the layer immediately
-   * following the base image and [1] being the final layer.
-   * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - io.grafeas.v1beta1.image.Layer getLayerInfo(int index); - /** - * - * - *
-   * This contains layer-specific metadata, if populated it has length
-   * "distance" and is ordered with [distance] being the layer immediately
-   * following the base image and [1] being the final layer.
-   * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - int getLayerInfoCount(); - /** - * - * - *
-   * This contains layer-specific metadata, if populated it has length
-   * "distance" and is ordered with [distance] being the layer immediately
-   * following the base image and [1] being the final layer.
-   * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - java.util.List getLayerInfoOrBuilderList(); - /** - * - * - *
-   * This contains layer-specific metadata, if populated it has length
-   * "distance" and is ordered with [distance] being the layer immediately
-   * following the base image and [1] being the final layer.
-   * 
- * - * repeated .grafeas.v1beta1.image.Layer layer_info = 3; - */ - io.grafeas.v1beta1.image.LayerOrBuilder getLayerInfoOrBuilder(int index); - - /** - * - * - *
-   * Output only. This contains the base image URL for the derived image
-   * occurrence.
-   * 
- * - * string base_resource_url = 4; - */ - java.lang.String getBaseResourceUrl(); - /** - * - * - *
-   * Output only. This contains the base image URL for the derived image
-   * occurrence.
-   * 
- * - * string base_resource_url = 4; - */ - com.google.protobuf.ByteString getBaseResourceUrlBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Details.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Details.java deleted file mode 100644 index eeeb5ff6..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Details.java +++ /dev/null @@ -1,694 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/image/image.proto - -package io.grafeas.v1beta1.image; - -/** - * - * - *
- * Details of an image occurrence.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.image.Details} - */ -public final class Details extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.image.Details) - DetailsOrBuilder { - private static final long serialVersionUID = 0L; - // Use Details.newBuilder() to construct. - private Details(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Details() {} - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Details( - 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: - { - io.grafeas.v1beta1.image.Derived.Builder subBuilder = null; - if (derivedImage_ != null) { - subBuilder = derivedImage_.toBuilder(); - } - derivedImage_ = - input.readMessage(io.grafeas.v1beta1.image.Derived.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(derivedImage_); - derivedImage_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.image.Image.internal_static_grafeas_v1beta1_image_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.image.Details.class, io.grafeas.v1beta1.image.Details.Builder.class); - } - - public static final int DERIVED_IMAGE_FIELD_NUMBER = 1; - private io.grafeas.v1beta1.image.Derived derivedImage_; - /** - * - * - *
-   * The child image derived from the base image.
-   * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - public boolean hasDerivedImage() { - return derivedImage_ != null; - } - /** - * - * - *
-   * The child image derived from the base image.
-   * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - public io.grafeas.v1beta1.image.Derived getDerivedImage() { - return derivedImage_ == null - ? io.grafeas.v1beta1.image.Derived.getDefaultInstance() - : derivedImage_; - } - /** - * - * - *
-   * The child image derived from the base image.
-   * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - public io.grafeas.v1beta1.image.DerivedOrBuilder getDerivedImageOrBuilder() { - return getDerivedImage(); - } - - 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 (derivedImage_ != null) { - output.writeMessage(1, getDerivedImage()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (derivedImage_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getDerivedImage()); - } - 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 io.grafeas.v1beta1.image.Details)) { - return super.equals(obj); - } - io.grafeas.v1beta1.image.Details other = (io.grafeas.v1beta1.image.Details) obj; - - if (hasDerivedImage() != other.hasDerivedImage()) return false; - if (hasDerivedImage()) { - if (!getDerivedImage().equals(other.getDerivedImage())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasDerivedImage()) { - hash = (37 * hash) + DERIVED_IMAGE_FIELD_NUMBER; - hash = (53 * hash) + getDerivedImage().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.image.Details parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Details parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Details parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Details parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Details parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Details parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Details parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Details 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 io.grafeas.v1beta1.image.Details parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Details 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 io.grafeas.v1beta1.image.Details parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Details 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(io.grafeas.v1beta1.image.Details 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; - } - /** - * - * - *
-   * Details of an image occurrence.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.image.Details} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.image.Details) - io.grafeas.v1beta1.image.DetailsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.image.Details.class, - io.grafeas.v1beta1.image.Details.Builder.class); - } - - // Construct using io.grafeas.v1beta1.image.Details.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (derivedImageBuilder_ == null) { - derivedImage_ = null; - } else { - derivedImage_ = null; - derivedImageBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Details_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Details getDefaultInstanceForType() { - return io.grafeas.v1beta1.image.Details.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Details build() { - io.grafeas.v1beta1.image.Details result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Details buildPartial() { - io.grafeas.v1beta1.image.Details result = new io.grafeas.v1beta1.image.Details(this); - if (derivedImageBuilder_ == null) { - result.derivedImage_ = derivedImage_; - } else { - result.derivedImage_ = derivedImageBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.image.Details) { - return mergeFrom((io.grafeas.v1beta1.image.Details) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.image.Details other) { - if (other == io.grafeas.v1beta1.image.Details.getDefaultInstance()) return this; - if (other.hasDerivedImage()) { - mergeDerivedImage(other.getDerivedImage()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.image.Details parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.image.Details) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private io.grafeas.v1beta1.image.Derived derivedImage_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Derived, - io.grafeas.v1beta1.image.Derived.Builder, - io.grafeas.v1beta1.image.DerivedOrBuilder> - derivedImageBuilder_; - /** - * - * - *
-     * The child image derived from the base image.
-     * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - public boolean hasDerivedImage() { - return derivedImageBuilder_ != null || derivedImage_ != null; - } - /** - * - * - *
-     * The child image derived from the base image.
-     * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - public io.grafeas.v1beta1.image.Derived getDerivedImage() { - if (derivedImageBuilder_ == null) { - return derivedImage_ == null - ? io.grafeas.v1beta1.image.Derived.getDefaultInstance() - : derivedImage_; - } else { - return derivedImageBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The child image derived from the base image.
-     * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - public Builder setDerivedImage(io.grafeas.v1beta1.image.Derived value) { - if (derivedImageBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - derivedImage_ = value; - onChanged(); - } else { - derivedImageBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The child image derived from the base image.
-     * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - public Builder setDerivedImage(io.grafeas.v1beta1.image.Derived.Builder builderForValue) { - if (derivedImageBuilder_ == null) { - derivedImage_ = builderForValue.build(); - onChanged(); - } else { - derivedImageBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The child image derived from the base image.
-     * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - public Builder mergeDerivedImage(io.grafeas.v1beta1.image.Derived value) { - if (derivedImageBuilder_ == null) { - if (derivedImage_ != null) { - derivedImage_ = - io.grafeas.v1beta1.image.Derived.newBuilder(derivedImage_) - .mergeFrom(value) - .buildPartial(); - } else { - derivedImage_ = value; - } - onChanged(); - } else { - derivedImageBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The child image derived from the base image.
-     * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - public Builder clearDerivedImage() { - if (derivedImageBuilder_ == null) { - derivedImage_ = null; - onChanged(); - } else { - derivedImage_ = null; - derivedImageBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The child image derived from the base image.
-     * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - public io.grafeas.v1beta1.image.Derived.Builder getDerivedImageBuilder() { - - onChanged(); - return getDerivedImageFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The child image derived from the base image.
-     * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - public io.grafeas.v1beta1.image.DerivedOrBuilder getDerivedImageOrBuilder() { - if (derivedImageBuilder_ != null) { - return derivedImageBuilder_.getMessageOrBuilder(); - } else { - return derivedImage_ == null - ? io.grafeas.v1beta1.image.Derived.getDefaultInstance() - : derivedImage_; - } - } - /** - * - * - *
-     * The child image derived from the base image.
-     * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Derived, - io.grafeas.v1beta1.image.Derived.Builder, - io.grafeas.v1beta1.image.DerivedOrBuilder> - getDerivedImageFieldBuilder() { - if (derivedImageBuilder_ == null) { - derivedImageBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.image.Derived, - io.grafeas.v1beta1.image.Derived.Builder, - io.grafeas.v1beta1.image.DerivedOrBuilder>( - getDerivedImage(), getParentForChildren(), isClean()); - derivedImage_ = null; - } - return derivedImageBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.image.Details) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.image.Details) - private static final io.grafeas.v1beta1.image.Details DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.image.Details(); - } - - public static io.grafeas.v1beta1.image.Details getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser
PARSER = - new com.google.protobuf.AbstractParser
() { - @java.lang.Override - public Details parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Details(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser
parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser
getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Details getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/DetailsOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/DetailsOrBuilder.java deleted file mode 100644 index a7d47a61..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/DetailsOrBuilder.java +++ /dev/null @@ -1,41 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/image/image.proto - -package io.grafeas.v1beta1.image; - -public interface DetailsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.image.Details) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The child image derived from the base image.
-   * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - boolean hasDerivedImage(); - /** - * - * - *
-   * The child image derived from the base image.
-   * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - io.grafeas.v1beta1.image.Derived getDerivedImage(); - /** - * - * - *
-   * The child image derived from the base image.
-   * 
- * - * .grafeas.v1beta1.image.Derived derived_image = 1; - */ - io.grafeas.v1beta1.image.DerivedOrBuilder getDerivedImageOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Fingerprint.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Fingerprint.java deleted file mode 100644 index 530c3e2b..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Fingerprint.java +++ /dev/null @@ -1,1022 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/image/image.proto - -package io.grafeas.v1beta1.image; - -/** - * - * - *
- * A set of properties that uniquely identify a given Docker image.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.image.Fingerprint} - */ -public final class Fingerprint extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.image.Fingerprint) - FingerprintOrBuilder { - private static final long serialVersionUID = 0L; - // Use Fingerprint.newBuilder() to construct. - private Fingerprint(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Fingerprint() { - v1Name_ = ""; - v2Blob_ = com.google.protobuf.LazyStringArrayList.EMPTY; - v2Name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Fingerprint( - 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(); - - v1Name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - v2Blob_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; - } - v2Blob_.add(s); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - v2Name_ = s; - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000002) != 0)) { - v2Blob_ = v2Blob_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Fingerprint_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Fingerprint_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.image.Fingerprint.class, - io.grafeas.v1beta1.image.Fingerprint.Builder.class); - } - - private int bitField0_; - public static final int V1_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object v1Name_; - /** - * - * - *
-   * The layer-id of the final layer in the Docker image's v1 representation.
-   * 
- * - * string v1_name = 1; - */ - public java.lang.String getV1Name() { - java.lang.Object ref = v1Name_; - 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(); - v1Name_ = s; - return s; - } - } - /** - * - * - *
-   * The layer-id of the final layer in the Docker image's v1 representation.
-   * 
- * - * string v1_name = 1; - */ - public com.google.protobuf.ByteString getV1NameBytes() { - java.lang.Object ref = v1Name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - v1Name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int V2_BLOB_FIELD_NUMBER = 2; - private com.google.protobuf.LazyStringList v2Blob_; - /** - * - * - *
-   * The ordered list of v2 blobs that represent a given image.
-   * 
- * - * repeated string v2_blob = 2; - */ - public com.google.protobuf.ProtocolStringList getV2BlobList() { - return v2Blob_; - } - /** - * - * - *
-   * The ordered list of v2 blobs that represent a given image.
-   * 
- * - * repeated string v2_blob = 2; - */ - public int getV2BlobCount() { - return v2Blob_.size(); - } - /** - * - * - *
-   * The ordered list of v2 blobs that represent a given image.
-   * 
- * - * repeated string v2_blob = 2; - */ - public java.lang.String getV2Blob(int index) { - return v2Blob_.get(index); - } - /** - * - * - *
-   * The ordered list of v2 blobs that represent a given image.
-   * 
- * - * repeated string v2_blob = 2; - */ - public com.google.protobuf.ByteString getV2BlobBytes(int index) { - return v2Blob_.getByteString(index); - } - - public static final int V2_NAME_FIELD_NUMBER = 3; - private volatile java.lang.Object v2Name_; - /** - * - * - *
-   * Output only. The name of the image's v2 blobs computed via:
-   *   [bottom] := v2_blob[bottom]
-   *   [N] := sha256(v2_blob[N] + " " + v2_name[N+1])
-   * Only the name of the final blob is kept.
-   * 
- * - * string v2_name = 3; - */ - public java.lang.String getV2Name() { - java.lang.Object ref = v2Name_; - 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(); - v2Name_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. The name of the image's v2 blobs computed via:
-   *   [bottom] := v2_blob[bottom]
-   *   [N] := sha256(v2_blob[N] + " " + v2_name[N+1])
-   * Only the name of the final blob is kept.
-   * 
- * - * string v2_name = 3; - */ - public com.google.protobuf.ByteString getV2NameBytes() { - java.lang.Object ref = v2Name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - v2Name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getV1NameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, v1Name_); - } - for (int i = 0; i < v2Blob_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, v2Blob_.getRaw(i)); - } - if (!getV2NameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, v2Name_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getV1NameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, v1Name_); - } - { - int dataSize = 0; - for (int i = 0; i < v2Blob_.size(); i++) { - dataSize += computeStringSizeNoTag(v2Blob_.getRaw(i)); - } - size += dataSize; - size += 1 * getV2BlobList().size(); - } - if (!getV2NameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, v2Name_); - } - 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 io.grafeas.v1beta1.image.Fingerprint)) { - return super.equals(obj); - } - io.grafeas.v1beta1.image.Fingerprint other = (io.grafeas.v1beta1.image.Fingerprint) obj; - - if (!getV1Name().equals(other.getV1Name())) return false; - if (!getV2BlobList().equals(other.getV2BlobList())) return false; - if (!getV2Name().equals(other.getV2Name())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + V1_NAME_FIELD_NUMBER; - hash = (53 * hash) + getV1Name().hashCode(); - if (getV2BlobCount() > 0) { - hash = (37 * hash) + V2_BLOB_FIELD_NUMBER; - hash = (53 * hash) + getV2BlobList().hashCode(); - } - hash = (37 * hash) + V2_NAME_FIELD_NUMBER; - hash = (53 * hash) + getV2Name().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.image.Fingerprint parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Fingerprint parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Fingerprint parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Fingerprint parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Fingerprint parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Fingerprint parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Fingerprint parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Fingerprint 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 io.grafeas.v1beta1.image.Fingerprint parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Fingerprint 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 io.grafeas.v1beta1.image.Fingerprint parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Fingerprint 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(io.grafeas.v1beta1.image.Fingerprint prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A set of properties that uniquely identify a given Docker image.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.image.Fingerprint} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.image.Fingerprint) - io.grafeas.v1beta1.image.FingerprintOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Fingerprint_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Fingerprint_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.image.Fingerprint.class, - io.grafeas.v1beta1.image.Fingerprint.Builder.class); - } - - // Construct using io.grafeas.v1beta1.image.Fingerprint.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - v1Name_ = ""; - - v2Blob_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - v2Name_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Fingerprint_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Fingerprint getDefaultInstanceForType() { - return io.grafeas.v1beta1.image.Fingerprint.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Fingerprint build() { - io.grafeas.v1beta1.image.Fingerprint result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Fingerprint buildPartial() { - io.grafeas.v1beta1.image.Fingerprint result = new io.grafeas.v1beta1.image.Fingerprint(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.v1Name_ = v1Name_; - if (((bitField0_ & 0x00000002) != 0)) { - v2Blob_ = v2Blob_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.v2Blob_ = v2Blob_; - result.v2Name_ = v2Name_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.image.Fingerprint) { - return mergeFrom((io.grafeas.v1beta1.image.Fingerprint) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.image.Fingerprint other) { - if (other == io.grafeas.v1beta1.image.Fingerprint.getDefaultInstance()) return this; - if (!other.getV1Name().isEmpty()) { - v1Name_ = other.v1Name_; - onChanged(); - } - if (!other.v2Blob_.isEmpty()) { - if (v2Blob_.isEmpty()) { - v2Blob_ = other.v2Blob_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureV2BlobIsMutable(); - v2Blob_.addAll(other.v2Blob_); - } - onChanged(); - } - if (!other.getV2Name().isEmpty()) { - v2Name_ = other.v2Name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.image.Fingerprint parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.image.Fingerprint) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object v1Name_ = ""; - /** - * - * - *
-     * The layer-id of the final layer in the Docker image's v1 representation.
-     * 
- * - * string v1_name = 1; - */ - public java.lang.String getV1Name() { - java.lang.Object ref = v1Name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - v1Name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The layer-id of the final layer in the Docker image's v1 representation.
-     * 
- * - * string v1_name = 1; - */ - public com.google.protobuf.ByteString getV1NameBytes() { - java.lang.Object ref = v1Name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - v1Name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The layer-id of the final layer in the Docker image's v1 representation.
-     * 
- * - * string v1_name = 1; - */ - public Builder setV1Name(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - v1Name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The layer-id of the final layer in the Docker image's v1 representation.
-     * 
- * - * string v1_name = 1; - */ - public Builder clearV1Name() { - - v1Name_ = getDefaultInstance().getV1Name(); - onChanged(); - return this; - } - /** - * - * - *
-     * The layer-id of the final layer in the Docker image's v1 representation.
-     * 
- * - * string v1_name = 1; - */ - public Builder setV1NameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - v1Name_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList v2Blob_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureV2BlobIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { - v2Blob_ = new com.google.protobuf.LazyStringArrayList(v2Blob_); - bitField0_ |= 0x00000002; - } - } - /** - * - * - *
-     * The ordered list of v2 blobs that represent a given image.
-     * 
- * - * repeated string v2_blob = 2; - */ - public com.google.protobuf.ProtocolStringList getV2BlobList() { - return v2Blob_.getUnmodifiableView(); - } - /** - * - * - *
-     * The ordered list of v2 blobs that represent a given image.
-     * 
- * - * repeated string v2_blob = 2; - */ - public int getV2BlobCount() { - return v2Blob_.size(); - } - /** - * - * - *
-     * The ordered list of v2 blobs that represent a given image.
-     * 
- * - * repeated string v2_blob = 2; - */ - public java.lang.String getV2Blob(int index) { - return v2Blob_.get(index); - } - /** - * - * - *
-     * The ordered list of v2 blobs that represent a given image.
-     * 
- * - * repeated string v2_blob = 2; - */ - public com.google.protobuf.ByteString getV2BlobBytes(int index) { - return v2Blob_.getByteString(index); - } - /** - * - * - *
-     * The ordered list of v2 blobs that represent a given image.
-     * 
- * - * repeated string v2_blob = 2; - */ - public Builder setV2Blob(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureV2BlobIsMutable(); - v2Blob_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * The ordered list of v2 blobs that represent a given image.
-     * 
- * - * repeated string v2_blob = 2; - */ - public Builder addV2Blob(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureV2BlobIsMutable(); - v2Blob_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * The ordered list of v2 blobs that represent a given image.
-     * 
- * - * repeated string v2_blob = 2; - */ - public Builder addAllV2Blob(java.lang.Iterable values) { - ensureV2BlobIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, v2Blob_); - onChanged(); - return this; - } - /** - * - * - *
-     * The ordered list of v2 blobs that represent a given image.
-     * 
- * - * repeated string v2_blob = 2; - */ - public Builder clearV2Blob() { - v2Blob_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - return this; - } - /** - * - * - *
-     * The ordered list of v2 blobs that represent a given image.
-     * 
- * - * repeated string v2_blob = 2; - */ - public Builder addV2BlobBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureV2BlobIsMutable(); - v2Blob_.add(value); - onChanged(); - return this; - } - - private java.lang.Object v2Name_ = ""; - /** - * - * - *
-     * Output only. The name of the image's v2 blobs computed via:
-     *   [bottom] := v2_blob[bottom]
-     *   [N] := sha256(v2_blob[N] + " " + v2_name[N+1])
-     * Only the name of the final blob is kept.
-     * 
- * - * string v2_name = 3; - */ - public java.lang.String getV2Name() { - java.lang.Object ref = v2Name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - v2Name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. The name of the image's v2 blobs computed via:
-     *   [bottom] := v2_blob[bottom]
-     *   [N] := sha256(v2_blob[N] + " " + v2_name[N+1])
-     * Only the name of the final blob is kept.
-     * 
- * - * string v2_name = 3; - */ - public com.google.protobuf.ByteString getV2NameBytes() { - java.lang.Object ref = v2Name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - v2Name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. The name of the image's v2 blobs computed via:
-     *   [bottom] := v2_blob[bottom]
-     *   [N] := sha256(v2_blob[N] + " " + v2_name[N+1])
-     * Only the name of the final blob is kept.
-     * 
- * - * string v2_name = 3; - */ - public Builder setV2Name(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - v2Name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The name of the image's v2 blobs computed via:
-     *   [bottom] := v2_blob[bottom]
-     *   [N] := sha256(v2_blob[N] + " " + v2_name[N+1])
-     * Only the name of the final blob is kept.
-     * 
- * - * string v2_name = 3; - */ - public Builder clearV2Name() { - - v2Name_ = getDefaultInstance().getV2Name(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The name of the image's v2 blobs computed via:
-     *   [bottom] := v2_blob[bottom]
-     *   [N] := sha256(v2_blob[N] + " " + v2_name[N+1])
-     * Only the name of the final blob is kept.
-     * 
- * - * string v2_name = 3; - */ - public Builder setV2NameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - v2Name_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.image.Fingerprint) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.image.Fingerprint) - private static final io.grafeas.v1beta1.image.Fingerprint DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.image.Fingerprint(); - } - - public static io.grafeas.v1beta1.image.Fingerprint getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Fingerprint parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Fingerprint(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Fingerprint getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/FingerprintOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/FingerprintOrBuilder.java deleted file mode 100644 index 62e1bea5..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/FingerprintOrBuilder.java +++ /dev/null @@ -1,99 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/image/image.proto - -package io.grafeas.v1beta1.image; - -public interface FingerprintOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.image.Fingerprint) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The layer-id of the final layer in the Docker image's v1 representation.
-   * 
- * - * string v1_name = 1; - */ - java.lang.String getV1Name(); - /** - * - * - *
-   * The layer-id of the final layer in the Docker image's v1 representation.
-   * 
- * - * string v1_name = 1; - */ - com.google.protobuf.ByteString getV1NameBytes(); - - /** - * - * - *
-   * The ordered list of v2 blobs that represent a given image.
-   * 
- * - * repeated string v2_blob = 2; - */ - java.util.List getV2BlobList(); - /** - * - * - *
-   * The ordered list of v2 blobs that represent a given image.
-   * 
- * - * repeated string v2_blob = 2; - */ - int getV2BlobCount(); - /** - * - * - *
-   * The ordered list of v2 blobs that represent a given image.
-   * 
- * - * repeated string v2_blob = 2; - */ - java.lang.String getV2Blob(int index); - /** - * - * - *
-   * The ordered list of v2 blobs that represent a given image.
-   * 
- * - * repeated string v2_blob = 2; - */ - com.google.protobuf.ByteString getV2BlobBytes(int index); - - /** - * - * - *
-   * Output only. The name of the image's v2 blobs computed via:
-   *   [bottom] := v2_blob[bottom]
-   *   [N] := sha256(v2_blob[N] + " " + v2_name[N+1])
-   * Only the name of the final blob is kept.
-   * 
- * - * string v2_name = 3; - */ - java.lang.String getV2Name(); - /** - * - * - *
-   * Output only. The name of the image's v2 blobs computed via:
-   *   [bottom] := v2_blob[bottom]
-   *   [N] := sha256(v2_blob[N] + " " + v2_name[N+1])
-   * Only the name of the final blob is kept.
-   * 
- * - * string v2_name = 3; - */ - com.google.protobuf.ByteString getV2NameBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/IamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/IamResourceName.java deleted file mode 100644 index 4c6decbf..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/IamResourceName.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.image; - -import com.google.api.resourcenames.ResourceName; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public abstract class IamResourceName implements ResourceName { - protected IamResourceName() {} -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/IamResourceNames.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/IamResourceNames.java deleted file mode 100644 index a2cba658..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/IamResourceNames.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.image; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class IamResourceNames { - private IamResourceNames() {} - - public static IamResourceName parse(String resourceNameString) { - if (NoteName.isParsableFrom(resourceNameString)) { - return NoteName.parse(resourceNameString); - } - if (OccurrenceName.isParsableFrom(resourceNameString)) { - return OccurrenceName.parse(resourceNameString); - } - return UntypedIamResourceName.parse(resourceNameString); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Image.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Image.java deleted file mode 100644 index 07c426ea..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Image.java +++ /dev/null @@ -1,122 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/image/image.proto - -package io.grafeas.v1beta1.image; - -public final class Image { - private Image() {} - - 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_grafeas_v1beta1_image_Layer_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_image_Layer_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_image_Fingerprint_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_image_Fingerprint_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_image_Basis_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_image_Basis_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_image_Details_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_image_Details_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_image_Derived_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_image_Derived_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/devtools/containeranalysis/v1be" - + "ta1/image/image.proto\022\025grafeas.v1beta1.i" - + "mage\"\310\002\n\005Layer\0229\n\tdirective\030\001 \001(\0162&.graf" - + "eas.v1beta1.image.Layer.Directive\022\021\n\targ" - + "uments\030\002 \001(\t\"\360\001\n\tDirective\022\031\n\025DIRECTIVE_" - + "UNSPECIFIED\020\000\022\016\n\nMAINTAINER\020\001\022\007\n\003RUN\020\002\022\007" - + "\n\003CMD\020\003\022\t\n\005LABEL\020\004\022\n\n\006EXPOSE\020\005\022\007\n\003ENV\020\006\022" - + "\007\n\003ADD\020\007\022\010\n\004COPY\020\010\022\016\n\nENTRYPOINT\020\t\022\n\n\006VO" - + "LUME\020\n\022\010\n\004USER\020\013\022\013\n\007WORKDIR\020\014\022\007\n\003ARG\020\r\022\013" - + "\n\007ONBUILD\020\016\022\016\n\nSTOPSIGNAL\020\017\022\017\n\013HEALTHCHE" - + "CK\020\020\022\t\n\005SHELL\020\021\"@\n\013Fingerprint\022\017\n\007v1_nam" - + "e\030\001 \001(\t\022\017\n\007v2_blob\030\002 \003(\t\022\017\n\007v2_name\030\003 \001(" - + "\t\"V\n\005Basis\022\024\n\014resource_url\030\001 \001(\t\0227\n\013fing" - + "erprint\030\002 \001(\0132\".grafeas.v1beta1.image.Fi" - + "ngerprint\"@\n\007Details\0225\n\rderived_image\030\001 " - + "\001(\0132\036.grafeas.v1beta1.image.Derived\"\241\001\n\007" - + "Derived\0227\n\013fingerprint\030\001 \001(\0132\".grafeas.v" - + "1beta1.image.Fingerprint\022\020\n\010distance\030\002 \001" - + "(\005\0220\n\nlayer_info\030\003 \003(\0132\034.grafeas.v1beta1" - + ".image.Layer\022\031\n\021base_resource_url\030\004 \001(\tB" - + "x\n\030io.grafeas.v1beta1.imageP\001ZTgoogle.go" - + "lang.org/genproto/googleapis/devtools/co" - + "ntaineranalysis/v1beta1/image;image\242\002\003GR" - + "Ab\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[] {}, assigner); - internal_static_grafeas_v1beta1_image_Layer_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_grafeas_v1beta1_image_Layer_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_image_Layer_descriptor, - new java.lang.String[] { - "Directive", "Arguments", - }); - internal_static_grafeas_v1beta1_image_Fingerprint_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_grafeas_v1beta1_image_Fingerprint_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_image_Fingerprint_descriptor, - new java.lang.String[] { - "V1Name", "V2Blob", "V2Name", - }); - internal_static_grafeas_v1beta1_image_Basis_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_grafeas_v1beta1_image_Basis_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_image_Basis_descriptor, - new java.lang.String[] { - "ResourceUrl", "Fingerprint", - }); - internal_static_grafeas_v1beta1_image_Details_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_grafeas_v1beta1_image_Details_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_image_Details_descriptor, - new java.lang.String[] { - "DerivedImage", - }); - internal_static_grafeas_v1beta1_image_Derived_descriptor = - getDescriptor().getMessageTypes().get(4); - internal_static_grafeas_v1beta1_image_Derived_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_image_Derived_descriptor, - new java.lang.String[] { - "Fingerprint", "Distance", "LayerInfo", "BaseResourceUrl", - }); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Layer.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Layer.java deleted file mode 100644 index 785a9b08..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/Layer.java +++ /dev/null @@ -1,1192 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/image/image.proto - -package io.grafeas.v1beta1.image; - -/** - * - * - *
- * Layer holds metadata specific to a layer of a Docker image.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.image.Layer} - */ -public final class Layer extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.image.Layer) - LayerOrBuilder { - private static final long serialVersionUID = 0L; - // Use Layer.newBuilder() to construct. - private Layer(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Layer() { - directive_ = 0; - arguments_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Layer( - 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 8: - { - int rawValue = input.readEnum(); - - directive_ = rawValue; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - arguments_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.image.Image.internal_static_grafeas_v1beta1_image_Layer_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Layer_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.image.Layer.class, io.grafeas.v1beta1.image.Layer.Builder.class); - } - - /** - * - * - *
-   * Instructions from Dockerfile.
-   * 
- * - * Protobuf enum {@code grafeas.v1beta1.image.Layer.Directive} - */ - public enum Directive implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Default value for unsupported/missing directive.
-     * 
- * - * DIRECTIVE_UNSPECIFIED = 0; - */ - DIRECTIVE_UNSPECIFIED(0), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#maintainer
-     * 
- * - * MAINTAINER = 1; - */ - MAINTAINER(1), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#run
-     * 
- * - * RUN = 2; - */ - RUN(2), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#cmd
-     * 
- * - * CMD = 3; - */ - CMD(3), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#label
-     * 
- * - * LABEL = 4; - */ - LABEL(4), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#expose
-     * 
- * - * EXPOSE = 5; - */ - EXPOSE(5), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#env
-     * 
- * - * ENV = 6; - */ - ENV(6), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#add
-     * 
- * - * ADD = 7; - */ - ADD(7), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#copy
-     * 
- * - * COPY = 8; - */ - COPY(8), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#entrypoint
-     * 
- * - * ENTRYPOINT = 9; - */ - ENTRYPOINT(9), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#volume
-     * 
- * - * VOLUME = 10; - */ - VOLUME(10), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#user
-     * 
- * - * USER = 11; - */ - USER(11), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#workdir
-     * 
- * - * WORKDIR = 12; - */ - WORKDIR(12), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#arg
-     * 
- * - * ARG = 13; - */ - ARG(13), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#onbuild
-     * 
- * - * ONBUILD = 14; - */ - ONBUILD(14), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#stopsignal
-     * 
- * - * STOPSIGNAL = 15; - */ - STOPSIGNAL(15), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#healthcheck
-     * 
- * - * HEALTHCHECK = 16; - */ - HEALTHCHECK(16), - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#shell
-     * 
- * - * SHELL = 17; - */ - SHELL(17), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Default value for unsupported/missing directive.
-     * 
- * - * DIRECTIVE_UNSPECIFIED = 0; - */ - public static final int DIRECTIVE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#maintainer
-     * 
- * - * MAINTAINER = 1; - */ - public static final int MAINTAINER_VALUE = 1; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#run
-     * 
- * - * RUN = 2; - */ - public static final int RUN_VALUE = 2; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#cmd
-     * 
- * - * CMD = 3; - */ - public static final int CMD_VALUE = 3; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#label
-     * 
- * - * LABEL = 4; - */ - public static final int LABEL_VALUE = 4; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#expose
-     * 
- * - * EXPOSE = 5; - */ - public static final int EXPOSE_VALUE = 5; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#env
-     * 
- * - * ENV = 6; - */ - public static final int ENV_VALUE = 6; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#add
-     * 
- * - * ADD = 7; - */ - public static final int ADD_VALUE = 7; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#copy
-     * 
- * - * COPY = 8; - */ - public static final int COPY_VALUE = 8; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#entrypoint
-     * 
- * - * ENTRYPOINT = 9; - */ - public static final int ENTRYPOINT_VALUE = 9; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#volume
-     * 
- * - * VOLUME = 10; - */ - public static final int VOLUME_VALUE = 10; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#user
-     * 
- * - * USER = 11; - */ - public static final int USER_VALUE = 11; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#workdir
-     * 
- * - * WORKDIR = 12; - */ - public static final int WORKDIR_VALUE = 12; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#arg
-     * 
- * - * ARG = 13; - */ - public static final int ARG_VALUE = 13; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#onbuild
-     * 
- * - * ONBUILD = 14; - */ - public static final int ONBUILD_VALUE = 14; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#stopsignal
-     * 
- * - * STOPSIGNAL = 15; - */ - public static final int STOPSIGNAL_VALUE = 15; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#healthcheck
-     * 
- * - * HEALTHCHECK = 16; - */ - public static final int HEALTHCHECK_VALUE = 16; - /** - * - * - *
-     * https://docs.docker.com/reference/builder/#shell
-     * 
- * - * SHELL = 17; - */ - public static final int SHELL_VALUE = 17; - - 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 Directive valueOf(int value) { - return forNumber(value); - } - - public static Directive forNumber(int value) { - switch (value) { - case 0: - return DIRECTIVE_UNSPECIFIED; - case 1: - return MAINTAINER; - case 2: - return RUN; - case 3: - return CMD; - case 4: - return LABEL; - case 5: - return EXPOSE; - case 6: - return ENV; - case 7: - return ADD; - case 8: - return COPY; - case 9: - return ENTRYPOINT; - case 10: - return VOLUME; - case 11: - return USER; - case 12: - return WORKDIR; - case 13: - return ARG; - case 14: - return ONBUILD; - case 15: - return STOPSIGNAL; - case 16: - return HEALTHCHECK; - case 17: - return SHELL; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Directive findValueByNumber(int number) { - return Directive.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return io.grafeas.v1beta1.image.Layer.getDescriptor().getEnumTypes().get(0); - } - - private static final Directive[] VALUES = values(); - - public static Directive valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Directive(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:grafeas.v1beta1.image.Layer.Directive) - } - - public static final int DIRECTIVE_FIELD_NUMBER = 1; - private int directive_; - /** - * - * - *
-   * The recovered Dockerfile directive used to construct this layer.
-   * 
- * - * .grafeas.v1beta1.image.Layer.Directive directive = 1; - */ - public int getDirectiveValue() { - return directive_; - } - /** - * - * - *
-   * The recovered Dockerfile directive used to construct this layer.
-   * 
- * - * .grafeas.v1beta1.image.Layer.Directive directive = 1; - */ - public io.grafeas.v1beta1.image.Layer.Directive getDirective() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.image.Layer.Directive result = - io.grafeas.v1beta1.image.Layer.Directive.valueOf(directive_); - return result == null ? io.grafeas.v1beta1.image.Layer.Directive.UNRECOGNIZED : result; - } - - public static final int ARGUMENTS_FIELD_NUMBER = 2; - private volatile java.lang.Object arguments_; - /** - * - * - *
-   * The recovered arguments to the Dockerfile directive.
-   * 
- * - * string arguments = 2; - */ - public java.lang.String getArguments() { - java.lang.Object ref = arguments_; - 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(); - arguments_ = s; - return s; - } - } - /** - * - * - *
-   * The recovered arguments to the Dockerfile directive.
-   * 
- * - * string arguments = 2; - */ - public com.google.protobuf.ByteString getArgumentsBytes() { - java.lang.Object ref = arguments_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - arguments_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (directive_ != io.grafeas.v1beta1.image.Layer.Directive.DIRECTIVE_UNSPECIFIED.getNumber()) { - output.writeEnum(1, directive_); - } - if (!getArgumentsBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, arguments_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (directive_ != io.grafeas.v1beta1.image.Layer.Directive.DIRECTIVE_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, directive_); - } - if (!getArgumentsBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, arguments_); - } - 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 io.grafeas.v1beta1.image.Layer)) { - return super.equals(obj); - } - io.grafeas.v1beta1.image.Layer other = (io.grafeas.v1beta1.image.Layer) obj; - - if (directive_ != other.directive_) return false; - if (!getArguments().equals(other.getArguments())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + DIRECTIVE_FIELD_NUMBER; - hash = (53 * hash) + directive_; - hash = (37 * hash) + ARGUMENTS_FIELD_NUMBER; - hash = (53 * hash) + getArguments().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.image.Layer parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Layer parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Layer parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Layer parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Layer parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.image.Layer parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.image.Layer parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Layer 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 io.grafeas.v1beta1.image.Layer parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Layer 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 io.grafeas.v1beta1.image.Layer parseFrom(com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.image.Layer 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(io.grafeas.v1beta1.image.Layer 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; - } - /** - * - * - *
-   * Layer holds metadata specific to a layer of a Docker image.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.image.Layer} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.image.Layer) - io.grafeas.v1beta1.image.LayerOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.image.Image.internal_static_grafeas_v1beta1_image_Layer_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.image.Image - .internal_static_grafeas_v1beta1_image_Layer_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.image.Layer.class, io.grafeas.v1beta1.image.Layer.Builder.class); - } - - // Construct using io.grafeas.v1beta1.image.Layer.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - directive_ = 0; - - arguments_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.image.Image.internal_static_grafeas_v1beta1_image_Layer_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Layer getDefaultInstanceForType() { - return io.grafeas.v1beta1.image.Layer.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Layer build() { - io.grafeas.v1beta1.image.Layer result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Layer buildPartial() { - io.grafeas.v1beta1.image.Layer result = new io.grafeas.v1beta1.image.Layer(this); - result.directive_ = directive_; - result.arguments_ = arguments_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.image.Layer) { - return mergeFrom((io.grafeas.v1beta1.image.Layer) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.image.Layer other) { - if (other == io.grafeas.v1beta1.image.Layer.getDefaultInstance()) return this; - if (other.directive_ != 0) { - setDirectiveValue(other.getDirectiveValue()); - } - if (!other.getArguments().isEmpty()) { - arguments_ = other.arguments_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.image.Layer parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.image.Layer) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int directive_ = 0; - /** - * - * - *
-     * The recovered Dockerfile directive used to construct this layer.
-     * 
- * - * .grafeas.v1beta1.image.Layer.Directive directive = 1; - */ - public int getDirectiveValue() { - return directive_; - } - /** - * - * - *
-     * The recovered Dockerfile directive used to construct this layer.
-     * 
- * - * .grafeas.v1beta1.image.Layer.Directive directive = 1; - */ - public Builder setDirectiveValue(int value) { - directive_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The recovered Dockerfile directive used to construct this layer.
-     * 
- * - * .grafeas.v1beta1.image.Layer.Directive directive = 1; - */ - public io.grafeas.v1beta1.image.Layer.Directive getDirective() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.image.Layer.Directive result = - io.grafeas.v1beta1.image.Layer.Directive.valueOf(directive_); - return result == null ? io.grafeas.v1beta1.image.Layer.Directive.UNRECOGNIZED : result; - } - /** - * - * - *
-     * The recovered Dockerfile directive used to construct this layer.
-     * 
- * - * .grafeas.v1beta1.image.Layer.Directive directive = 1; - */ - public Builder setDirective(io.grafeas.v1beta1.image.Layer.Directive value) { - if (value == null) { - throw new NullPointerException(); - } - - directive_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * The recovered Dockerfile directive used to construct this layer.
-     * 
- * - * .grafeas.v1beta1.image.Layer.Directive directive = 1; - */ - public Builder clearDirective() { - - directive_ = 0; - onChanged(); - return this; - } - - private java.lang.Object arguments_ = ""; - /** - * - * - *
-     * The recovered arguments to the Dockerfile directive.
-     * 
- * - * string arguments = 2; - */ - public java.lang.String getArguments() { - java.lang.Object ref = arguments_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - arguments_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The recovered arguments to the Dockerfile directive.
-     * 
- * - * string arguments = 2; - */ - public com.google.protobuf.ByteString getArgumentsBytes() { - java.lang.Object ref = arguments_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - arguments_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The recovered arguments to the Dockerfile directive.
-     * 
- * - * string arguments = 2; - */ - public Builder setArguments(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - arguments_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The recovered arguments to the Dockerfile directive.
-     * 
- * - * string arguments = 2; - */ - public Builder clearArguments() { - - arguments_ = getDefaultInstance().getArguments(); - onChanged(); - return this; - } - /** - * - * - *
-     * The recovered arguments to the Dockerfile directive.
-     * 
- * - * string arguments = 2; - */ - public Builder setArgumentsBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - arguments_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.image.Layer) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.image.Layer) - private static final io.grafeas.v1beta1.image.Layer DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.image.Layer(); - } - - public static io.grafeas.v1beta1.image.Layer getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Layer parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Layer(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.image.Layer getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/LayerOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/LayerOrBuilder.java deleted file mode 100644 index 4a954513..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/LayerOrBuilder.java +++ /dev/null @@ -1,52 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/image/image.proto - -package io.grafeas.v1beta1.image; - -public interface LayerOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.image.Layer) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The recovered Dockerfile directive used to construct this layer.
-   * 
- * - * .grafeas.v1beta1.image.Layer.Directive directive = 1; - */ - int getDirectiveValue(); - /** - * - * - *
-   * The recovered Dockerfile directive used to construct this layer.
-   * 
- * - * .grafeas.v1beta1.image.Layer.Directive directive = 1; - */ - io.grafeas.v1beta1.image.Layer.Directive getDirective(); - - /** - * - * - *
-   * The recovered arguments to the Dockerfile directive.
-   * 
- * - * string arguments = 2; - */ - java.lang.String getArguments(); - /** - * - * - *
-   * The recovered arguments to the Dockerfile directive.
-   * 
- * - * string arguments = 2; - */ - com.google.protobuf.ByteString getArgumentsBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/NoteName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/NoteName.java deleted file mode 100644 index f9c909ae..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/NoteName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.image; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class NoteName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/notes/{note}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/OccurrenceName.java deleted file mode 100644 index 69149f2b..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.image; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/ProjectName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/ProjectName.java deleted file mode 100644 index 93e60f7c..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.image; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/ScanConfigName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/ScanConfigName.java deleted file mode 100644 index 02fef4d3..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/ScanConfigName.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.image; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ScanConfigName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ScanConfigName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - scanConfig = Preconditions.checkNotNull(builder.getScanConfig()); - } - - public static ScanConfigName of(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build(); - } - - public static String format(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build().toString(); - } - - public static ScanConfigName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ScanConfigName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("scan_config")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ScanConfigName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("scanConfig", scanConfig); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "scan_config", scanConfig); - } - - /** Builder for ScanConfigName. */ - public static class Builder { - - private String project; - private String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setScanConfig(String scanConfig) { - this.scanConfig = scanConfig; - return this; - } - - private Builder() {} - - private Builder(ScanConfigName scanConfigName) { - project = scanConfigName.project; - scanConfig = scanConfigName.scanConfig; - } - - public ScanConfigName build() { - return new ScanConfigName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ScanConfigName) { - ScanConfigName that = (ScanConfigName) o; - return (this.project.equals(that.project)) && (this.scanConfig.equals(that.scanConfig)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= scanConfig.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/UntypedIamResourceName.java deleted file mode 100644 index ffde782d..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/image/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.image; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Architecture.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Architecture.java deleted file mode 100644 index 0d47353c..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Architecture.java +++ /dev/null @@ -1,149 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -/** - * - * - *
- * Instruction set architectures supported by various package managers.
- * 
- * - * Protobuf enum {@code grafeas.v1beta1.package.Architecture} - */ -public enum Architecture implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-   * Unknown architecture.
-   * 
- * - * ARCHITECTURE_UNSPECIFIED = 0; - */ - ARCHITECTURE_UNSPECIFIED(0), - /** - * - * - *
-   * X86 architecture.
-   * 
- * - * X86 = 1; - */ - X86(1), - /** - * - * - *
-   * X64 architecture.
-   * 
- * - * X64 = 2; - */ - X64(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-   * Unknown architecture.
-   * 
- * - * ARCHITECTURE_UNSPECIFIED = 0; - */ - public static final int ARCHITECTURE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-   * X86 architecture.
-   * 
- * - * X86 = 1; - */ - public static final int X86_VALUE = 1; - /** - * - * - *
-   * X64 architecture.
-   * 
- * - * X64 = 2; - */ - public static final int X64_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 Architecture valueOf(int value) { - return forNumber(value); - } - - public static Architecture forNumber(int value) { - switch (value) { - case 0: - return ARCHITECTURE_UNSPECIFIED; - case 1: - return X86; - case 2: - return X64; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Architecture findValueByNumber(int number) { - return Architecture.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return io.grafeas.v1beta1.pkg.PackageOuterClass.getDescriptor().getEnumTypes().get(0); - } - - private static final Architecture[] VALUES = values(); - - public static Architecture valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Architecture(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:grafeas.v1beta1.package.Architecture) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Details.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Details.java deleted file mode 100644 index 0d02a5b2..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Details.java +++ /dev/null @@ -1,695 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -/** - * - * - *
- * Details of a package occurrence.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.package.Details} - */ -public final class Details extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.package.Details) - DetailsOrBuilder { - private static final long serialVersionUID = 0L; - // Use Details.newBuilder() to construct. - private Details(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Details() {} - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Details( - 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: - { - io.grafeas.v1beta1.pkg.Installation.Builder subBuilder = null; - if (installation_ != null) { - subBuilder = installation_.toBuilder(); - } - installation_ = - input.readMessage( - io.grafeas.v1beta1.pkg.Installation.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(installation_); - installation_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.pkg.Details.class, io.grafeas.v1beta1.pkg.Details.Builder.class); - } - - public static final int INSTALLATION_FIELD_NUMBER = 1; - private io.grafeas.v1beta1.pkg.Installation installation_; - /** - * - * - *
-   * Where the package was installed.
-   * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - public boolean hasInstallation() { - return installation_ != null; - } - /** - * - * - *
-   * Where the package was installed.
-   * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - public io.grafeas.v1beta1.pkg.Installation getInstallation() { - return installation_ == null - ? io.grafeas.v1beta1.pkg.Installation.getDefaultInstance() - : installation_; - } - /** - * - * - *
-   * Where the package was installed.
-   * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - public io.grafeas.v1beta1.pkg.InstallationOrBuilder getInstallationOrBuilder() { - return getInstallation(); - } - - 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 (installation_ != null) { - output.writeMessage(1, getInstallation()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (installation_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getInstallation()); - } - 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 io.grafeas.v1beta1.pkg.Details)) { - return super.equals(obj); - } - io.grafeas.v1beta1.pkg.Details other = (io.grafeas.v1beta1.pkg.Details) obj; - - if (hasInstallation() != other.hasInstallation()) return false; - if (hasInstallation()) { - if (!getInstallation().equals(other.getInstallation())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasInstallation()) { - hash = (37 * hash) + INSTALLATION_FIELD_NUMBER; - hash = (53 * hash) + getInstallation().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.pkg.Details parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Details parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Details parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Details parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Details parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Details parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Details parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Details 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 io.grafeas.v1beta1.pkg.Details parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Details 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 io.grafeas.v1beta1.pkg.Details parseFrom(com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Details 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(io.grafeas.v1beta1.pkg.Details 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; - } - /** - * - * - *
-   * Details of a package occurrence.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.package.Details} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.package.Details) - io.grafeas.v1beta1.pkg.DetailsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.pkg.Details.class, io.grafeas.v1beta1.pkg.Details.Builder.class); - } - - // Construct using io.grafeas.v1beta1.pkg.Details.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (installationBuilder_ == null) { - installation_ = null; - } else { - installation_ = null; - installationBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Details_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Details getDefaultInstanceForType() { - return io.grafeas.v1beta1.pkg.Details.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Details build() { - io.grafeas.v1beta1.pkg.Details result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Details buildPartial() { - io.grafeas.v1beta1.pkg.Details result = new io.grafeas.v1beta1.pkg.Details(this); - if (installationBuilder_ == null) { - result.installation_ = installation_; - } else { - result.installation_ = installationBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.pkg.Details) { - return mergeFrom((io.grafeas.v1beta1.pkg.Details) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.pkg.Details other) { - if (other == io.grafeas.v1beta1.pkg.Details.getDefaultInstance()) return this; - if (other.hasInstallation()) { - mergeInstallation(other.getInstallation()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.pkg.Details parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.pkg.Details) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private io.grafeas.v1beta1.pkg.Installation installation_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Installation, - io.grafeas.v1beta1.pkg.Installation.Builder, - io.grafeas.v1beta1.pkg.InstallationOrBuilder> - installationBuilder_; - /** - * - * - *
-     * Where the package was installed.
-     * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - public boolean hasInstallation() { - return installationBuilder_ != null || installation_ != null; - } - /** - * - * - *
-     * Where the package was installed.
-     * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - public io.grafeas.v1beta1.pkg.Installation getInstallation() { - if (installationBuilder_ == null) { - return installation_ == null - ? io.grafeas.v1beta1.pkg.Installation.getDefaultInstance() - : installation_; - } else { - return installationBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Where the package was installed.
-     * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - public Builder setInstallation(io.grafeas.v1beta1.pkg.Installation value) { - if (installationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - installation_ = value; - onChanged(); - } else { - installationBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Where the package was installed.
-     * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - public Builder setInstallation(io.grafeas.v1beta1.pkg.Installation.Builder builderForValue) { - if (installationBuilder_ == null) { - installation_ = builderForValue.build(); - onChanged(); - } else { - installationBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Where the package was installed.
-     * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - public Builder mergeInstallation(io.grafeas.v1beta1.pkg.Installation value) { - if (installationBuilder_ == null) { - if (installation_ != null) { - installation_ = - io.grafeas.v1beta1.pkg.Installation.newBuilder(installation_) - .mergeFrom(value) - .buildPartial(); - } else { - installation_ = value; - } - onChanged(); - } else { - installationBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Where the package was installed.
-     * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - public Builder clearInstallation() { - if (installationBuilder_ == null) { - installation_ = null; - onChanged(); - } else { - installation_ = null; - installationBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Where the package was installed.
-     * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - public io.grafeas.v1beta1.pkg.Installation.Builder getInstallationBuilder() { - - onChanged(); - return getInstallationFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Where the package was installed.
-     * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - public io.grafeas.v1beta1.pkg.InstallationOrBuilder getInstallationOrBuilder() { - if (installationBuilder_ != null) { - return installationBuilder_.getMessageOrBuilder(); - } else { - return installation_ == null - ? io.grafeas.v1beta1.pkg.Installation.getDefaultInstance() - : installation_; - } - } - /** - * - * - *
-     * Where the package was installed.
-     * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Installation, - io.grafeas.v1beta1.pkg.Installation.Builder, - io.grafeas.v1beta1.pkg.InstallationOrBuilder> - getInstallationFieldBuilder() { - if (installationBuilder_ == null) { - installationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Installation, - io.grafeas.v1beta1.pkg.Installation.Builder, - io.grafeas.v1beta1.pkg.InstallationOrBuilder>( - getInstallation(), getParentForChildren(), isClean()); - installation_ = null; - } - return installationBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.package.Details) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.package.Details) - private static final io.grafeas.v1beta1.pkg.Details DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.pkg.Details(); - } - - public static io.grafeas.v1beta1.pkg.Details getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser
PARSER = - new com.google.protobuf.AbstractParser
() { - @java.lang.Override - public Details parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Details(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser
parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser
getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Details getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/DetailsOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/DetailsOrBuilder.java deleted file mode 100644 index 4a22b305..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/DetailsOrBuilder.java +++ /dev/null @@ -1,41 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -public interface DetailsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.package.Details) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Where the package was installed.
-   * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - boolean hasInstallation(); - /** - * - * - *
-   * Where the package was installed.
-   * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - io.grafeas.v1beta1.pkg.Installation getInstallation(); - /** - * - * - *
-   * Where the package was installed.
-   * 
- * - * .grafeas.v1beta1.package.Installation installation = 1; - */ - io.grafeas.v1beta1.pkg.InstallationOrBuilder getInstallationOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Distribution.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Distribution.java deleted file mode 100644 index 15b5c35c..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Distribution.java +++ /dev/null @@ -1,1498 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -/** - * - * - *
- * This represents a particular channel of distribution for a given package.
- * E.g., Debian's jessie-backports dpkg mirror.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.package.Distribution} - */ -public final class Distribution extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.package.Distribution) - DistributionOrBuilder { - private static final long serialVersionUID = 0L; - // Use Distribution.newBuilder() to construct. - private Distribution(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Distribution() { - cpeUri_ = ""; - architecture_ = 0; - maintainer_ = ""; - url_ = ""; - description_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Distribution( - 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(); - - cpeUri_ = s; - break; - } - case 16: - { - int rawValue = input.readEnum(); - - architecture_ = rawValue; - break; - } - case 26: - { - io.grafeas.v1beta1.pkg.Version.Builder subBuilder = null; - if (latestVersion_ != null) { - subBuilder = latestVersion_.toBuilder(); - } - latestVersion_ = - input.readMessage(io.grafeas.v1beta1.pkg.Version.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(latestVersion_); - latestVersion_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - maintainer_ = s; - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - url_ = s; - break; - } - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - - description_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Distribution_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Distribution_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.pkg.Distribution.class, - io.grafeas.v1beta1.pkg.Distribution.Builder.class); - } - - public static final int CPE_URI_FIELD_NUMBER = 1; - private volatile java.lang.Object cpeUri_; - /** - * - * - *
-   * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-   * denoting the package manager version distributing a package.
-   * 
- * - * string cpe_uri = 1; - */ - public java.lang.String getCpeUri() { - java.lang.Object ref = cpeUri_; - 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(); - cpeUri_ = s; - return s; - } - } - /** - * - * - *
-   * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-   * denoting the package manager version distributing a package.
-   * 
- * - * string cpe_uri = 1; - */ - public com.google.protobuf.ByteString getCpeUriBytes() { - java.lang.Object ref = cpeUri_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - cpeUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ARCHITECTURE_FIELD_NUMBER = 2; - private int architecture_; - /** - * - * - *
-   * The CPU architecture for which packages in this distribution channel were
-   * built.
-   * 
- * - * .grafeas.v1beta1.package.Architecture architecture = 2; - */ - public int getArchitectureValue() { - return architecture_; - } - /** - * - * - *
-   * The CPU architecture for which packages in this distribution channel were
-   * built.
-   * 
- * - * .grafeas.v1beta1.package.Architecture architecture = 2; - */ - public io.grafeas.v1beta1.pkg.Architecture getArchitecture() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.pkg.Architecture result = - io.grafeas.v1beta1.pkg.Architecture.valueOf(architecture_); - return result == null ? io.grafeas.v1beta1.pkg.Architecture.UNRECOGNIZED : result; - } - - public static final int LATEST_VERSION_FIELD_NUMBER = 3; - private io.grafeas.v1beta1.pkg.Version latestVersion_; - /** - * - * - *
-   * The latest available version of this package in this distribution
-   * channel.
-   * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - public boolean hasLatestVersion() { - return latestVersion_ != null; - } - /** - * - * - *
-   * The latest available version of this package in this distribution
-   * channel.
-   * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - public io.grafeas.v1beta1.pkg.Version getLatestVersion() { - return latestVersion_ == null - ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() - : latestVersion_; - } - /** - * - * - *
-   * The latest available version of this package in this distribution
-   * channel.
-   * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - public io.grafeas.v1beta1.pkg.VersionOrBuilder getLatestVersionOrBuilder() { - return getLatestVersion(); - } - - public static final int MAINTAINER_FIELD_NUMBER = 4; - private volatile java.lang.Object maintainer_; - /** - * - * - *
-   * A freeform string denoting the maintainer of this package.
-   * 
- * - * string maintainer = 4; - */ - public java.lang.String getMaintainer() { - java.lang.Object ref = maintainer_; - 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(); - maintainer_ = s; - return s; - } - } - /** - * - * - *
-   * A freeform string denoting the maintainer of this package.
-   * 
- * - * string maintainer = 4; - */ - public com.google.protobuf.ByteString getMaintainerBytes() { - java.lang.Object ref = maintainer_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - maintainer_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int URL_FIELD_NUMBER = 5; - private volatile java.lang.Object url_; - /** - * - * - *
-   * The distribution channel-specific homepage for this package.
-   * 
- * - * string url = 5; - */ - public java.lang.String getUrl() { - java.lang.Object ref = url_; - 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(); - url_ = s; - return s; - } - } - /** - * - * - *
-   * The distribution channel-specific homepage for this package.
-   * 
- * - * string url = 5; - */ - public com.google.protobuf.ByteString getUrlBytes() { - java.lang.Object ref = url_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - url_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DESCRIPTION_FIELD_NUMBER = 6; - private volatile java.lang.Object description_; - /** - * - * - *
-   * The distribution channel-specific description of this package.
-   * 
- * - * string description = 6; - */ - public java.lang.String getDescription() { - java.lang.Object ref = description_; - 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(); - description_ = s; - return s; - } - } - /** - * - * - *
-   * The distribution channel-specific description of this package.
-   * 
- * - * string description = 6; - */ - public com.google.protobuf.ByteString getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getCpeUriBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, cpeUri_); - } - if (architecture_ != io.grafeas.v1beta1.pkg.Architecture.ARCHITECTURE_UNSPECIFIED.getNumber()) { - output.writeEnum(2, architecture_); - } - if (latestVersion_ != null) { - output.writeMessage(3, getLatestVersion()); - } - if (!getMaintainerBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, maintainer_); - } - if (!getUrlBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, url_); - } - if (!getDescriptionBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 6, description_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getCpeUriBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, cpeUri_); - } - if (architecture_ != io.grafeas.v1beta1.pkg.Architecture.ARCHITECTURE_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, architecture_); - } - if (latestVersion_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getLatestVersion()); - } - if (!getMaintainerBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, maintainer_); - } - if (!getUrlBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, url_); - } - if (!getDescriptionBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, description_); - } - 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 io.grafeas.v1beta1.pkg.Distribution)) { - return super.equals(obj); - } - io.grafeas.v1beta1.pkg.Distribution other = (io.grafeas.v1beta1.pkg.Distribution) obj; - - if (!getCpeUri().equals(other.getCpeUri())) return false; - if (architecture_ != other.architecture_) return false; - if (hasLatestVersion() != other.hasLatestVersion()) return false; - if (hasLatestVersion()) { - if (!getLatestVersion().equals(other.getLatestVersion())) return false; - } - if (!getMaintainer().equals(other.getMaintainer())) return false; - if (!getUrl().equals(other.getUrl())) return false; - if (!getDescription().equals(other.getDescription())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + CPE_URI_FIELD_NUMBER; - hash = (53 * hash) + getCpeUri().hashCode(); - hash = (37 * hash) + ARCHITECTURE_FIELD_NUMBER; - hash = (53 * hash) + architecture_; - if (hasLatestVersion()) { - hash = (37 * hash) + LATEST_VERSION_FIELD_NUMBER; - hash = (53 * hash) + getLatestVersion().hashCode(); - } - hash = (37 * hash) + MAINTAINER_FIELD_NUMBER; - hash = (53 * hash) + getMaintainer().hashCode(); - hash = (37 * hash) + URL_FIELD_NUMBER; - hash = (53 * hash) + getUrl().hashCode(); - hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; - hash = (53 * hash) + getDescription().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.pkg.Distribution parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Distribution parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Distribution parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Distribution parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Distribution parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Distribution parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Distribution parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Distribution 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 io.grafeas.v1beta1.pkg.Distribution parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Distribution 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 io.grafeas.v1beta1.pkg.Distribution parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Distribution 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(io.grafeas.v1beta1.pkg.Distribution 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; - } - /** - * - * - *
-   * This represents a particular channel of distribution for a given package.
-   * E.g., Debian's jessie-backports dpkg mirror.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.package.Distribution} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.package.Distribution) - io.grafeas.v1beta1.pkg.DistributionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Distribution_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Distribution_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.pkg.Distribution.class, - io.grafeas.v1beta1.pkg.Distribution.Builder.class); - } - - // Construct using io.grafeas.v1beta1.pkg.Distribution.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - cpeUri_ = ""; - - architecture_ = 0; - - if (latestVersionBuilder_ == null) { - latestVersion_ = null; - } else { - latestVersion_ = null; - latestVersionBuilder_ = null; - } - maintainer_ = ""; - - url_ = ""; - - description_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Distribution_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Distribution getDefaultInstanceForType() { - return io.grafeas.v1beta1.pkg.Distribution.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Distribution build() { - io.grafeas.v1beta1.pkg.Distribution result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Distribution buildPartial() { - io.grafeas.v1beta1.pkg.Distribution result = new io.grafeas.v1beta1.pkg.Distribution(this); - result.cpeUri_ = cpeUri_; - result.architecture_ = architecture_; - if (latestVersionBuilder_ == null) { - result.latestVersion_ = latestVersion_; - } else { - result.latestVersion_ = latestVersionBuilder_.build(); - } - result.maintainer_ = maintainer_; - result.url_ = url_; - result.description_ = description_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.pkg.Distribution) { - return mergeFrom((io.grafeas.v1beta1.pkg.Distribution) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.pkg.Distribution other) { - if (other == io.grafeas.v1beta1.pkg.Distribution.getDefaultInstance()) return this; - if (!other.getCpeUri().isEmpty()) { - cpeUri_ = other.cpeUri_; - onChanged(); - } - if (other.architecture_ != 0) { - setArchitectureValue(other.getArchitectureValue()); - } - if (other.hasLatestVersion()) { - mergeLatestVersion(other.getLatestVersion()); - } - if (!other.getMaintainer().isEmpty()) { - maintainer_ = other.maintainer_; - onChanged(); - } - if (!other.getUrl().isEmpty()) { - url_ = other.url_; - onChanged(); - } - if (!other.getDescription().isEmpty()) { - description_ = other.description_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.pkg.Distribution parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.pkg.Distribution) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object cpeUri_ = ""; - /** - * - * - *
-     * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-     * denoting the package manager version distributing a package.
-     * 
- * - * string cpe_uri = 1; - */ - public java.lang.String getCpeUri() { - java.lang.Object ref = cpeUri_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - cpeUri_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-     * denoting the package manager version distributing a package.
-     * 
- * - * string cpe_uri = 1; - */ - public com.google.protobuf.ByteString getCpeUriBytes() { - java.lang.Object ref = cpeUri_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - cpeUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-     * denoting the package manager version distributing a package.
-     * 
- * - * string cpe_uri = 1; - */ - public Builder setCpeUri(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - cpeUri_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-     * denoting the package manager version distributing a package.
-     * 
- * - * string cpe_uri = 1; - */ - public Builder clearCpeUri() { - - cpeUri_ = getDefaultInstance().getCpeUri(); - onChanged(); - return this; - } - /** - * - * - *
-     * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-     * denoting the package manager version distributing a package.
-     * 
- * - * string cpe_uri = 1; - */ - public Builder setCpeUriBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - cpeUri_ = value; - onChanged(); - return this; - } - - private int architecture_ = 0; - /** - * - * - *
-     * The CPU architecture for which packages in this distribution channel were
-     * built.
-     * 
- * - * .grafeas.v1beta1.package.Architecture architecture = 2; - */ - public int getArchitectureValue() { - return architecture_; - } - /** - * - * - *
-     * The CPU architecture for which packages in this distribution channel were
-     * built.
-     * 
- * - * .grafeas.v1beta1.package.Architecture architecture = 2; - */ - public Builder setArchitectureValue(int value) { - architecture_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The CPU architecture for which packages in this distribution channel were
-     * built.
-     * 
- * - * .grafeas.v1beta1.package.Architecture architecture = 2; - */ - public io.grafeas.v1beta1.pkg.Architecture getArchitecture() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.pkg.Architecture result = - io.grafeas.v1beta1.pkg.Architecture.valueOf(architecture_); - return result == null ? io.grafeas.v1beta1.pkg.Architecture.UNRECOGNIZED : result; - } - /** - * - * - *
-     * The CPU architecture for which packages in this distribution channel were
-     * built.
-     * 
- * - * .grafeas.v1beta1.package.Architecture architecture = 2; - */ - public Builder setArchitecture(io.grafeas.v1beta1.pkg.Architecture value) { - if (value == null) { - throw new NullPointerException(); - } - - architecture_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * The CPU architecture for which packages in this distribution channel were
-     * built.
-     * 
- * - * .grafeas.v1beta1.package.Architecture architecture = 2; - */ - public Builder clearArchitecture() { - - architecture_ = 0; - onChanged(); - return this; - } - - private io.grafeas.v1beta1.pkg.Version latestVersion_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder> - latestVersionBuilder_; - /** - * - * - *
-     * The latest available version of this package in this distribution
-     * channel.
-     * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - public boolean hasLatestVersion() { - return latestVersionBuilder_ != null || latestVersion_ != null; - } - /** - * - * - *
-     * The latest available version of this package in this distribution
-     * channel.
-     * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - public io.grafeas.v1beta1.pkg.Version getLatestVersion() { - if (latestVersionBuilder_ == null) { - return latestVersion_ == null - ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() - : latestVersion_; - } else { - return latestVersionBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The latest available version of this package in this distribution
-     * channel.
-     * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - public Builder setLatestVersion(io.grafeas.v1beta1.pkg.Version value) { - if (latestVersionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - latestVersion_ = value; - onChanged(); - } else { - latestVersionBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The latest available version of this package in this distribution
-     * channel.
-     * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - public Builder setLatestVersion(io.grafeas.v1beta1.pkg.Version.Builder builderForValue) { - if (latestVersionBuilder_ == null) { - latestVersion_ = builderForValue.build(); - onChanged(); - } else { - latestVersionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The latest available version of this package in this distribution
-     * channel.
-     * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - public Builder mergeLatestVersion(io.grafeas.v1beta1.pkg.Version value) { - if (latestVersionBuilder_ == null) { - if (latestVersion_ != null) { - latestVersion_ = - io.grafeas.v1beta1.pkg.Version.newBuilder(latestVersion_) - .mergeFrom(value) - .buildPartial(); - } else { - latestVersion_ = value; - } - onChanged(); - } else { - latestVersionBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The latest available version of this package in this distribution
-     * channel.
-     * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - public Builder clearLatestVersion() { - if (latestVersionBuilder_ == null) { - latestVersion_ = null; - onChanged(); - } else { - latestVersion_ = null; - latestVersionBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The latest available version of this package in this distribution
-     * channel.
-     * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - public io.grafeas.v1beta1.pkg.Version.Builder getLatestVersionBuilder() { - - onChanged(); - return getLatestVersionFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The latest available version of this package in this distribution
-     * channel.
-     * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - public io.grafeas.v1beta1.pkg.VersionOrBuilder getLatestVersionOrBuilder() { - if (latestVersionBuilder_ != null) { - return latestVersionBuilder_.getMessageOrBuilder(); - } else { - return latestVersion_ == null - ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() - : latestVersion_; - } - } - /** - * - * - *
-     * The latest available version of this package in this distribution
-     * channel.
-     * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder> - getLatestVersionFieldBuilder() { - if (latestVersionBuilder_ == null) { - latestVersionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder>( - getLatestVersion(), getParentForChildren(), isClean()); - latestVersion_ = null; - } - return latestVersionBuilder_; - } - - private java.lang.Object maintainer_ = ""; - /** - * - * - *
-     * A freeform string denoting the maintainer of this package.
-     * 
- * - * string maintainer = 4; - */ - public java.lang.String getMaintainer() { - java.lang.Object ref = maintainer_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - maintainer_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * A freeform string denoting the maintainer of this package.
-     * 
- * - * string maintainer = 4; - */ - public com.google.protobuf.ByteString getMaintainerBytes() { - java.lang.Object ref = maintainer_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - maintainer_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * A freeform string denoting the maintainer of this package.
-     * 
- * - * string maintainer = 4; - */ - public Builder setMaintainer(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - maintainer_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * A freeform string denoting the maintainer of this package.
-     * 
- * - * string maintainer = 4; - */ - public Builder clearMaintainer() { - - maintainer_ = getDefaultInstance().getMaintainer(); - onChanged(); - return this; - } - /** - * - * - *
-     * A freeform string denoting the maintainer of this package.
-     * 
- * - * string maintainer = 4; - */ - public Builder setMaintainerBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - maintainer_ = value; - onChanged(); - return this; - } - - private java.lang.Object url_ = ""; - /** - * - * - *
-     * The distribution channel-specific homepage for this package.
-     * 
- * - * string url = 5; - */ - public java.lang.String getUrl() { - java.lang.Object ref = url_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - url_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The distribution channel-specific homepage for this package.
-     * 
- * - * string url = 5; - */ - public com.google.protobuf.ByteString getUrlBytes() { - java.lang.Object ref = url_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - url_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The distribution channel-specific homepage for this package.
-     * 
- * - * string url = 5; - */ - public Builder setUrl(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - url_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The distribution channel-specific homepage for this package.
-     * 
- * - * string url = 5; - */ - public Builder clearUrl() { - - url_ = getDefaultInstance().getUrl(); - onChanged(); - return this; - } - /** - * - * - *
-     * The distribution channel-specific homepage for this package.
-     * 
- * - * string url = 5; - */ - public Builder setUrlBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - url_ = value; - onChanged(); - return this; - } - - private java.lang.Object description_ = ""; - /** - * - * - *
-     * The distribution channel-specific description of this package.
-     * 
- * - * string description = 6; - */ - public java.lang.String getDescription() { - java.lang.Object ref = description_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - description_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The distribution channel-specific description of this package.
-     * 
- * - * string description = 6; - */ - public com.google.protobuf.ByteString getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The distribution channel-specific description of this package.
-     * 
- * - * string description = 6; - */ - public Builder setDescription(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - description_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The distribution channel-specific description of this package.
-     * 
- * - * string description = 6; - */ - public Builder clearDescription() { - - description_ = getDefaultInstance().getDescription(); - onChanged(); - return this; - } - /** - * - * - *
-     * The distribution channel-specific description of this package.
-     * 
- * - * string description = 6; - */ - public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - description_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.package.Distribution) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.package.Distribution) - private static final io.grafeas.v1beta1.pkg.Distribution DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.pkg.Distribution(); - } - - public static io.grafeas.v1beta1.pkg.Distribution getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Distribution parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Distribution(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Distribution getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/DistributionOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/DistributionOrBuilder.java deleted file mode 100644 index 60c5800a..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/DistributionOrBuilder.java +++ /dev/null @@ -1,153 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -public interface DistributionOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.package.Distribution) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-   * denoting the package manager version distributing a package.
-   * 
- * - * string cpe_uri = 1; - */ - java.lang.String getCpeUri(); - /** - * - * - *
-   * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-   * denoting the package manager version distributing a package.
-   * 
- * - * string cpe_uri = 1; - */ - com.google.protobuf.ByteString getCpeUriBytes(); - - /** - * - * - *
-   * The CPU architecture for which packages in this distribution channel were
-   * built.
-   * 
- * - * .grafeas.v1beta1.package.Architecture architecture = 2; - */ - int getArchitectureValue(); - /** - * - * - *
-   * The CPU architecture for which packages in this distribution channel were
-   * built.
-   * 
- * - * .grafeas.v1beta1.package.Architecture architecture = 2; - */ - io.grafeas.v1beta1.pkg.Architecture getArchitecture(); - - /** - * - * - *
-   * The latest available version of this package in this distribution
-   * channel.
-   * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - boolean hasLatestVersion(); - /** - * - * - *
-   * The latest available version of this package in this distribution
-   * channel.
-   * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - io.grafeas.v1beta1.pkg.Version getLatestVersion(); - /** - * - * - *
-   * The latest available version of this package in this distribution
-   * channel.
-   * 
- * - * .grafeas.v1beta1.package.Version latest_version = 3; - */ - io.grafeas.v1beta1.pkg.VersionOrBuilder getLatestVersionOrBuilder(); - - /** - * - * - *
-   * A freeform string denoting the maintainer of this package.
-   * 
- * - * string maintainer = 4; - */ - java.lang.String getMaintainer(); - /** - * - * - *
-   * A freeform string denoting the maintainer of this package.
-   * 
- * - * string maintainer = 4; - */ - com.google.protobuf.ByteString getMaintainerBytes(); - - /** - * - * - *
-   * The distribution channel-specific homepage for this package.
-   * 
- * - * string url = 5; - */ - java.lang.String getUrl(); - /** - * - * - *
-   * The distribution channel-specific homepage for this package.
-   * 
- * - * string url = 5; - */ - com.google.protobuf.ByteString getUrlBytes(); - - /** - * - * - *
-   * The distribution channel-specific description of this package.
-   * 
- * - * string description = 6; - */ - java.lang.String getDescription(); - /** - * - * - *
-   * The distribution channel-specific description of this package.
-   * 
- * - * string description = 6; - */ - com.google.protobuf.ByteString getDescriptionBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/IamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/IamResourceName.java deleted file mode 100644 index 1db5dba0..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/IamResourceName.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.pkg; - -import com.google.api.resourcenames.ResourceName; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public abstract class IamResourceName implements ResourceName { - protected IamResourceName() {} -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/IamResourceNames.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/IamResourceNames.java deleted file mode 100644 index c7ada2f7..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/IamResourceNames.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.pkg; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class IamResourceNames { - private IamResourceNames() {} - - public static IamResourceName parse(String resourceNameString) { - if (NoteName.isParsableFrom(resourceNameString)) { - return NoteName.parse(resourceNameString); - } - if (OccurrenceName.isParsableFrom(resourceNameString)) { - return OccurrenceName.parse(resourceNameString); - } - return UntypedIamResourceName.parse(resourceNameString); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Installation.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Installation.java deleted file mode 100644 index 95528469..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Installation.java +++ /dev/null @@ -1,1103 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -/** - * - * - *
- * This represents how a particular software package may be installed on a
- * system.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.package.Installation} - */ -public final class Installation extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.package.Installation) - InstallationOrBuilder { - private static final long serialVersionUID = 0L; - // Use Installation.newBuilder() to construct. - private Installation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Installation() { - name_ = ""; - location_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Installation( - 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: - { - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - location_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - location_.add( - input.readMessage(io.grafeas.v1beta1.pkg.Location.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000002) != 0)) { - location_ = java.util.Collections.unmodifiableList(location_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Installation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Installation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.pkg.Installation.class, - io.grafeas.v1beta1.pkg.Installation.Builder.class); - } - - private int bitField0_; - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Output only. The name of the installed package.
-   * 
- * - * 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; - } - } - /** - * - * - *
-   * Output only. The name of the installed package.
-   * 
- * - * 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 LOCATION_FIELD_NUMBER = 2; - private java.util.List location_; - /** - * - * - *
-   * All of the places within the filesystem versions of this package
-   * have been found.
-   * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public java.util.List getLocationList() { - return location_; - } - /** - * - * - *
-   * All of the places within the filesystem versions of this package
-   * have been found.
-   * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public java.util.List - getLocationOrBuilderList() { - return location_; - } - /** - * - * - *
-   * All of the places within the filesystem versions of this package
-   * have been found.
-   * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public int getLocationCount() { - return location_.size(); - } - /** - * - * - *
-   * All of the places within the filesystem versions of this package
-   * have been found.
-   * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public io.grafeas.v1beta1.pkg.Location getLocation(int index) { - return location_.get(index); - } - /** - * - * - *
-   * All of the places within the filesystem versions of this package
-   * have been found.
-   * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public io.grafeas.v1beta1.pkg.LocationOrBuilder getLocationOrBuilder(int index) { - return location_.get(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 (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - for (int i = 0; i < location_.size(); i++) { - output.writeMessage(2, location_.get(i)); - } - 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_); - } - for (int i = 0; i < location_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, location_.get(i)); - } - 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 io.grafeas.v1beta1.pkg.Installation)) { - return super.equals(obj); - } - io.grafeas.v1beta1.pkg.Installation other = (io.grafeas.v1beta1.pkg.Installation) obj; - - if (!getName().equals(other.getName())) return false; - if (!getLocationList().equals(other.getLocationList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - if (getLocationCount() > 0) { - hash = (37 * hash) + LOCATION_FIELD_NUMBER; - hash = (53 * hash) + getLocationList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.pkg.Installation parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Installation parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Installation parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Installation parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Installation parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Installation parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Installation parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Installation 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 io.grafeas.v1beta1.pkg.Installation parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Installation 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 io.grafeas.v1beta1.pkg.Installation parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Installation 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(io.grafeas.v1beta1.pkg.Installation 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; - } - /** - * - * - *
-   * This represents how a particular software package may be installed on a
-   * system.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.package.Installation} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.package.Installation) - io.grafeas.v1beta1.pkg.InstallationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Installation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Installation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.pkg.Installation.class, - io.grafeas.v1beta1.pkg.Installation.Builder.class); - } - - // Construct using io.grafeas.v1beta1.pkg.Installation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getLocationFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - if (locationBuilder_ == null) { - location_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - locationBuilder_.clear(); - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Installation_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Installation getDefaultInstanceForType() { - return io.grafeas.v1beta1.pkg.Installation.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Installation build() { - io.grafeas.v1beta1.pkg.Installation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Installation buildPartial() { - io.grafeas.v1beta1.pkg.Installation result = new io.grafeas.v1beta1.pkg.Installation(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.name_ = name_; - if (locationBuilder_ == null) { - if (((bitField0_ & 0x00000002) != 0)) { - location_ = java.util.Collections.unmodifiableList(location_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.location_ = location_; - } else { - result.location_ = locationBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.pkg.Installation) { - return mergeFrom((io.grafeas.v1beta1.pkg.Installation) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.pkg.Installation other) { - if (other == io.grafeas.v1beta1.pkg.Installation.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (locationBuilder_ == null) { - if (!other.location_.isEmpty()) { - if (location_.isEmpty()) { - location_ = other.location_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureLocationIsMutable(); - location_.addAll(other.location_); - } - onChanged(); - } - } else { - if (!other.location_.isEmpty()) { - if (locationBuilder_.isEmpty()) { - locationBuilder_.dispose(); - locationBuilder_ = null; - location_ = other.location_; - bitField0_ = (bitField0_ & ~0x00000002); - locationBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getLocationFieldBuilder() - : null; - } else { - locationBuilder_.addAllMessages(other.location_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.pkg.Installation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.pkg.Installation) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Output only. The name of the installed package.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * Output only. The name of the installed package.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * Output only. The name of the installed package.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The name of the installed package.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The name of the installed package.
-     * 
- * - * 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 java.util.List location_ = - java.util.Collections.emptyList(); - - private void ensureLocationIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { - location_ = new java.util.ArrayList(location_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.pkg.Location, - io.grafeas.v1beta1.pkg.Location.Builder, - io.grafeas.v1beta1.pkg.LocationOrBuilder> - locationBuilder_; - - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public java.util.List getLocationList() { - if (locationBuilder_ == null) { - return java.util.Collections.unmodifiableList(location_); - } else { - return locationBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public int getLocationCount() { - if (locationBuilder_ == null) { - return location_.size(); - } else { - return locationBuilder_.getCount(); - } - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public io.grafeas.v1beta1.pkg.Location getLocation(int index) { - if (locationBuilder_ == null) { - return location_.get(index); - } else { - return locationBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public Builder setLocation(int index, io.grafeas.v1beta1.pkg.Location value) { - if (locationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureLocationIsMutable(); - location_.set(index, value); - onChanged(); - } else { - locationBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public Builder setLocation(int index, io.grafeas.v1beta1.pkg.Location.Builder builderForValue) { - if (locationBuilder_ == null) { - ensureLocationIsMutable(); - location_.set(index, builderForValue.build()); - onChanged(); - } else { - locationBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public Builder addLocation(io.grafeas.v1beta1.pkg.Location value) { - if (locationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureLocationIsMutable(); - location_.add(value); - onChanged(); - } else { - locationBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public Builder addLocation(int index, io.grafeas.v1beta1.pkg.Location value) { - if (locationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureLocationIsMutable(); - location_.add(index, value); - onChanged(); - } else { - locationBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public Builder addLocation(io.grafeas.v1beta1.pkg.Location.Builder builderForValue) { - if (locationBuilder_ == null) { - ensureLocationIsMutable(); - location_.add(builderForValue.build()); - onChanged(); - } else { - locationBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public Builder addLocation(int index, io.grafeas.v1beta1.pkg.Location.Builder builderForValue) { - if (locationBuilder_ == null) { - ensureLocationIsMutable(); - location_.add(index, builderForValue.build()); - onChanged(); - } else { - locationBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public Builder addAllLocation( - java.lang.Iterable values) { - if (locationBuilder_ == null) { - ensureLocationIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, location_); - onChanged(); - } else { - locationBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public Builder clearLocation() { - if (locationBuilder_ == null) { - location_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - locationBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public Builder removeLocation(int index) { - if (locationBuilder_ == null) { - ensureLocationIsMutable(); - location_.remove(index); - onChanged(); - } else { - locationBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public io.grafeas.v1beta1.pkg.Location.Builder getLocationBuilder(int index) { - return getLocationFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public io.grafeas.v1beta1.pkg.LocationOrBuilder getLocationOrBuilder(int index) { - if (locationBuilder_ == null) { - return location_.get(index); - } else { - return locationBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public java.util.List - getLocationOrBuilderList() { - if (locationBuilder_ != null) { - return locationBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(location_); - } - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public io.grafeas.v1beta1.pkg.Location.Builder addLocationBuilder() { - return getLocationFieldBuilder() - .addBuilder(io.grafeas.v1beta1.pkg.Location.getDefaultInstance()); - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public io.grafeas.v1beta1.pkg.Location.Builder addLocationBuilder(int index) { - return getLocationFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.pkg.Location.getDefaultInstance()); - } - /** - * - * - *
-     * All of the places within the filesystem versions of this package
-     * have been found.
-     * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - public java.util.List getLocationBuilderList() { - return getLocationFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.pkg.Location, - io.grafeas.v1beta1.pkg.Location.Builder, - io.grafeas.v1beta1.pkg.LocationOrBuilder> - getLocationFieldBuilder() { - if (locationBuilder_ == null) { - locationBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.pkg.Location, - io.grafeas.v1beta1.pkg.Location.Builder, - io.grafeas.v1beta1.pkg.LocationOrBuilder>( - location_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); - location_ = null; - } - return locationBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.package.Installation) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.package.Installation) - private static final io.grafeas.v1beta1.pkg.Installation DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.pkg.Installation(); - } - - public static io.grafeas.v1beta1.pkg.Installation getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Installation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Installation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Installation getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/InstallationOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/InstallationOrBuilder.java deleted file mode 100644 index 5a59d988..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/InstallationOrBuilder.java +++ /dev/null @@ -1,87 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -public interface InstallationOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.package.Installation) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Output only. The name of the installed package.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * Output only. The name of the installed package.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * All of the places within the filesystem versions of this package
-   * have been found.
-   * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - java.util.List getLocationList(); - /** - * - * - *
-   * All of the places within the filesystem versions of this package
-   * have been found.
-   * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - io.grafeas.v1beta1.pkg.Location getLocation(int index); - /** - * - * - *
-   * All of the places within the filesystem versions of this package
-   * have been found.
-   * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - int getLocationCount(); - /** - * - * - *
-   * All of the places within the filesystem versions of this package
-   * have been found.
-   * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - java.util.List getLocationOrBuilderList(); - /** - * - * - *
-   * All of the places within the filesystem versions of this package
-   * have been found.
-   * 
- * - * repeated .grafeas.v1beta1.package.Location location = 2; - */ - io.grafeas.v1beta1.pkg.LocationOrBuilder getLocationOrBuilder(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Location.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Location.java deleted file mode 100644 index 6286ebfb..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Location.java +++ /dev/null @@ -1,1018 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -/** - * - * - *
- * An occurrence of a particular package installation found within a system's
- * filesystem. E.g., glibc was found in /var/lib/dpkg/status.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.package.Location} - */ -public final class Location extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.package.Location) - LocationOrBuilder { - private static final long serialVersionUID = 0L; - // Use Location.newBuilder() to construct. - private Location(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Location() { - cpeUri_ = ""; - path_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Location( - 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(); - - cpeUri_ = s; - break; - } - case 18: - { - io.grafeas.v1beta1.pkg.Version.Builder subBuilder = null; - if (version_ != null) { - subBuilder = version_.toBuilder(); - } - version_ = - input.readMessage(io.grafeas.v1beta1.pkg.Version.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(version_); - version_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - path_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Location_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Location_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.pkg.Location.class, io.grafeas.v1beta1.pkg.Location.Builder.class); - } - - public static final int CPE_URI_FIELD_NUMBER = 1; - private volatile java.lang.Object cpeUri_; - /** - * - * - *
-   * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-   * denoting the package manager version distributing a package.
-   * 
- * - * string cpe_uri = 1; - */ - public java.lang.String getCpeUri() { - java.lang.Object ref = cpeUri_; - 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(); - cpeUri_ = s; - return s; - } - } - /** - * - * - *
-   * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-   * denoting the package manager version distributing a package.
-   * 
- * - * string cpe_uri = 1; - */ - public com.google.protobuf.ByteString getCpeUriBytes() { - java.lang.Object ref = cpeUri_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - cpeUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int VERSION_FIELD_NUMBER = 2; - private io.grafeas.v1beta1.pkg.Version version_; - /** - * - * - *
-   * The version installed at this location.
-   * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - public boolean hasVersion() { - return version_ != null; - } - /** - * - * - *
-   * The version installed at this location.
-   * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - public io.grafeas.v1beta1.pkg.Version getVersion() { - return version_ == null ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() : version_; - } - /** - * - * - *
-   * The version installed at this location.
-   * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - public io.grafeas.v1beta1.pkg.VersionOrBuilder getVersionOrBuilder() { - return getVersion(); - } - - public static final int PATH_FIELD_NUMBER = 3; - private volatile java.lang.Object path_; - /** - * - * - *
-   * The path from which we gathered that this package/version is installed.
-   * 
- * - * string path = 3; - */ - public java.lang.String getPath() { - java.lang.Object ref = path_; - 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(); - path_ = s; - return s; - } - } - /** - * - * - *
-   * The path from which we gathered that this package/version is installed.
-   * 
- * - * string path = 3; - */ - public com.google.protobuf.ByteString getPathBytes() { - java.lang.Object ref = path_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - path_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getCpeUriBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, cpeUri_); - } - if (version_ != null) { - output.writeMessage(2, getVersion()); - } - if (!getPathBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, path_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getCpeUriBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, cpeUri_); - } - if (version_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getVersion()); - } - if (!getPathBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, path_); - } - 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 io.grafeas.v1beta1.pkg.Location)) { - return super.equals(obj); - } - io.grafeas.v1beta1.pkg.Location other = (io.grafeas.v1beta1.pkg.Location) obj; - - if (!getCpeUri().equals(other.getCpeUri())) return false; - if (hasVersion() != other.hasVersion()) return false; - if (hasVersion()) { - if (!getVersion().equals(other.getVersion())) return false; - } - if (!getPath().equals(other.getPath())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + CPE_URI_FIELD_NUMBER; - hash = (53 * hash) + getCpeUri().hashCode(); - if (hasVersion()) { - hash = (37 * hash) + VERSION_FIELD_NUMBER; - hash = (53 * hash) + getVersion().hashCode(); - } - hash = (37 * hash) + PATH_FIELD_NUMBER; - hash = (53 * hash) + getPath().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.pkg.Location parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Location parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Location parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Location parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Location parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Location parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Location parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Location 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 io.grafeas.v1beta1.pkg.Location parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Location 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 io.grafeas.v1beta1.pkg.Location parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Location 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(io.grafeas.v1beta1.pkg.Location 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; - } - /** - * - * - *
-   * An occurrence of a particular package installation found within a system's
-   * filesystem. E.g., glibc was found in /var/lib/dpkg/status.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.package.Location} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.package.Location) - io.grafeas.v1beta1.pkg.LocationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Location_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Location_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.pkg.Location.class, io.grafeas.v1beta1.pkg.Location.Builder.class); - } - - // Construct using io.grafeas.v1beta1.pkg.Location.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - cpeUri_ = ""; - - if (versionBuilder_ == null) { - version_ = null; - } else { - version_ = null; - versionBuilder_ = null; - } - path_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Location_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Location getDefaultInstanceForType() { - return io.grafeas.v1beta1.pkg.Location.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Location build() { - io.grafeas.v1beta1.pkg.Location result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Location buildPartial() { - io.grafeas.v1beta1.pkg.Location result = new io.grafeas.v1beta1.pkg.Location(this); - result.cpeUri_ = cpeUri_; - if (versionBuilder_ == null) { - result.version_ = version_; - } else { - result.version_ = versionBuilder_.build(); - } - result.path_ = path_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.pkg.Location) { - return mergeFrom((io.grafeas.v1beta1.pkg.Location) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.pkg.Location other) { - if (other == io.grafeas.v1beta1.pkg.Location.getDefaultInstance()) return this; - if (!other.getCpeUri().isEmpty()) { - cpeUri_ = other.cpeUri_; - onChanged(); - } - if (other.hasVersion()) { - mergeVersion(other.getVersion()); - } - if (!other.getPath().isEmpty()) { - path_ = other.path_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.pkg.Location parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.pkg.Location) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object cpeUri_ = ""; - /** - * - * - *
-     * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-     * denoting the package manager version distributing a package.
-     * 
- * - * string cpe_uri = 1; - */ - public java.lang.String getCpeUri() { - java.lang.Object ref = cpeUri_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - cpeUri_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-     * denoting the package manager version distributing a package.
-     * 
- * - * string cpe_uri = 1; - */ - public com.google.protobuf.ByteString getCpeUriBytes() { - java.lang.Object ref = cpeUri_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - cpeUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-     * denoting the package manager version distributing a package.
-     * 
- * - * string cpe_uri = 1; - */ - public Builder setCpeUri(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - cpeUri_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-     * denoting the package manager version distributing a package.
-     * 
- * - * string cpe_uri = 1; - */ - public Builder clearCpeUri() { - - cpeUri_ = getDefaultInstance().getCpeUri(); - onChanged(); - return this; - } - /** - * - * - *
-     * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-     * denoting the package manager version distributing a package.
-     * 
- * - * string cpe_uri = 1; - */ - public Builder setCpeUriBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - cpeUri_ = value; - onChanged(); - return this; - } - - private io.grafeas.v1beta1.pkg.Version version_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder> - versionBuilder_; - /** - * - * - *
-     * The version installed at this location.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - public boolean hasVersion() { - return versionBuilder_ != null || version_ != null; - } - /** - * - * - *
-     * The version installed at this location.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - public io.grafeas.v1beta1.pkg.Version getVersion() { - if (versionBuilder_ == null) { - return version_ == null ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() : version_; - } else { - return versionBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The version installed at this location.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - public Builder setVersion(io.grafeas.v1beta1.pkg.Version value) { - if (versionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - version_ = value; - onChanged(); - } else { - versionBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The version installed at this location.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - public Builder setVersion(io.grafeas.v1beta1.pkg.Version.Builder builderForValue) { - if (versionBuilder_ == null) { - version_ = builderForValue.build(); - onChanged(); - } else { - versionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The version installed at this location.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - public Builder mergeVersion(io.grafeas.v1beta1.pkg.Version value) { - if (versionBuilder_ == null) { - if (version_ != null) { - version_ = - io.grafeas.v1beta1.pkg.Version.newBuilder(version_).mergeFrom(value).buildPartial(); - } else { - version_ = value; - } - onChanged(); - } else { - versionBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The version installed at this location.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - public Builder clearVersion() { - if (versionBuilder_ == null) { - version_ = null; - onChanged(); - } else { - version_ = null; - versionBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The version installed at this location.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - public io.grafeas.v1beta1.pkg.Version.Builder getVersionBuilder() { - - onChanged(); - return getVersionFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The version installed at this location.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - public io.grafeas.v1beta1.pkg.VersionOrBuilder getVersionOrBuilder() { - if (versionBuilder_ != null) { - return versionBuilder_.getMessageOrBuilder(); - } else { - return version_ == null ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() : version_; - } - } - /** - * - * - *
-     * The version installed at this location.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder> - getVersionFieldBuilder() { - if (versionBuilder_ == null) { - versionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder>( - getVersion(), getParentForChildren(), isClean()); - version_ = null; - } - return versionBuilder_; - } - - private java.lang.Object path_ = ""; - /** - * - * - *
-     * The path from which we gathered that this package/version is installed.
-     * 
- * - * string path = 3; - */ - public java.lang.String getPath() { - java.lang.Object ref = path_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - path_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The path from which we gathered that this package/version is installed.
-     * 
- * - * string path = 3; - */ - public com.google.protobuf.ByteString getPathBytes() { - java.lang.Object ref = path_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - path_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The path from which we gathered that this package/version is installed.
-     * 
- * - * string path = 3; - */ - public Builder setPath(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - path_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The path from which we gathered that this package/version is installed.
-     * 
- * - * string path = 3; - */ - public Builder clearPath() { - - path_ = getDefaultInstance().getPath(); - onChanged(); - return this; - } - /** - * - * - *
-     * The path from which we gathered that this package/version is installed.
-     * 
- * - * string path = 3; - */ - public Builder setPathBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - path_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.package.Location) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.package.Location) - private static final io.grafeas.v1beta1.pkg.Location DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.pkg.Location(); - } - - public static io.grafeas.v1beta1.pkg.Location getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Location parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Location(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Location getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/LocationOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/LocationOrBuilder.java deleted file mode 100644 index d770fab7..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/LocationOrBuilder.java +++ /dev/null @@ -1,85 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -public interface LocationOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.package.Location) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-   * denoting the package manager version distributing a package.
-   * 
- * - * string cpe_uri = 1; - */ - java.lang.String getCpeUri(); - /** - * - * - *
-   * The cpe_uri in [cpe format](https://cpe.mitre.org/specification/)
-   * denoting the package manager version distributing a package.
-   * 
- * - * string cpe_uri = 1; - */ - com.google.protobuf.ByteString getCpeUriBytes(); - - /** - * - * - *
-   * The version installed at this location.
-   * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - boolean hasVersion(); - /** - * - * - *
-   * The version installed at this location.
-   * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - io.grafeas.v1beta1.pkg.Version getVersion(); - /** - * - * - *
-   * The version installed at this location.
-   * 
- * - * .grafeas.v1beta1.package.Version version = 2; - */ - io.grafeas.v1beta1.pkg.VersionOrBuilder getVersionOrBuilder(); - - /** - * - * - *
-   * The path from which we gathered that this package/version is installed.
-   * 
- * - * string path = 3; - */ - java.lang.String getPath(); - /** - * - * - *
-   * The path from which we gathered that this package/version is installed.
-   * 
- * - * string path = 3; - */ - com.google.protobuf.ByteString getPathBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/NoteName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/NoteName.java deleted file mode 100644 index e927fd7b..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/NoteName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.pkg; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class NoteName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/notes/{note}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/OccurrenceName.java deleted file mode 100644 index cde57a07..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.pkg; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Package.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Package.java deleted file mode 100644 index bf4d0914..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Package.java +++ /dev/null @@ -1,1084 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -/** - * - * - *
- * This represents a particular package that is distributed over various
- * channels. E.g., glibc (aka libc6) is distributed by many, at various
- * versions.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.package.Package} - */ -public final class Package extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.package.Package) - PackageOrBuilder { - private static final long serialVersionUID = 0L; - // Use Package.newBuilder() to construct. - private Package(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Package() { - name_ = ""; - distribution_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Package( - 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 82: - { - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - distribution_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - distribution_.add( - input.readMessage( - io.grafeas.v1beta1.pkg.Distribution.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000002) != 0)) { - distribution_ = java.util.Collections.unmodifiableList(distribution_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Package_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Package_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.pkg.Package.class, io.grafeas.v1beta1.pkg.Package.Builder.class); - } - - private int bitField0_; - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the package.
-   * 
- * - * 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 name of the package.
-   * 
- * - * 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 DISTRIBUTION_FIELD_NUMBER = 10; - private java.util.List distribution_; - /** - * - * - *
-   * The various channels by which a package is distributed.
-   * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public java.util.List getDistributionList() { - return distribution_; - } - /** - * - * - *
-   * The various channels by which a package is distributed.
-   * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public java.util.List - getDistributionOrBuilderList() { - return distribution_; - } - /** - * - * - *
-   * The various channels by which a package is distributed.
-   * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public int getDistributionCount() { - return distribution_.size(); - } - /** - * - * - *
-   * The various channels by which a package is distributed.
-   * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public io.grafeas.v1beta1.pkg.Distribution getDistribution(int index) { - return distribution_.get(index); - } - /** - * - * - *
-   * The various channels by which a package is distributed.
-   * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public io.grafeas.v1beta1.pkg.DistributionOrBuilder getDistributionOrBuilder(int index) { - return distribution_.get(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 (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - for (int i = 0; i < distribution_.size(); i++) { - output.writeMessage(10, distribution_.get(i)); - } - 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_); - } - for (int i = 0; i < distribution_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, distribution_.get(i)); - } - 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 io.grafeas.v1beta1.pkg.Package)) { - return super.equals(obj); - } - io.grafeas.v1beta1.pkg.Package other = (io.grafeas.v1beta1.pkg.Package) obj; - - if (!getName().equals(other.getName())) return false; - if (!getDistributionList().equals(other.getDistributionList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - if (getDistributionCount() > 0) { - hash = (37 * hash) + DISTRIBUTION_FIELD_NUMBER; - hash = (53 * hash) + getDistributionList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.pkg.Package parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Package parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Package parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Package parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Package parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Package parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Package parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Package 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 io.grafeas.v1beta1.pkg.Package parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Package 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 io.grafeas.v1beta1.pkg.Package parseFrom(com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Package 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(io.grafeas.v1beta1.pkg.Package 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; - } - /** - * - * - *
-   * This represents a particular package that is distributed over various
-   * channels. E.g., glibc (aka libc6) is distributed by many, at various
-   * versions.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.package.Package} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.package.Package) - io.grafeas.v1beta1.pkg.PackageOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Package_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Package_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.pkg.Package.class, io.grafeas.v1beta1.pkg.Package.Builder.class); - } - - // Construct using io.grafeas.v1beta1.pkg.Package.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getDistributionFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - if (distributionBuilder_ == null) { - distribution_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - distributionBuilder_.clear(); - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Package_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Package getDefaultInstanceForType() { - return io.grafeas.v1beta1.pkg.Package.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Package build() { - io.grafeas.v1beta1.pkg.Package result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Package buildPartial() { - io.grafeas.v1beta1.pkg.Package result = new io.grafeas.v1beta1.pkg.Package(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.name_ = name_; - if (distributionBuilder_ == null) { - if (((bitField0_ & 0x00000002) != 0)) { - distribution_ = java.util.Collections.unmodifiableList(distribution_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.distribution_ = distribution_; - } else { - result.distribution_ = distributionBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.pkg.Package) { - return mergeFrom((io.grafeas.v1beta1.pkg.Package) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.pkg.Package other) { - if (other == io.grafeas.v1beta1.pkg.Package.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (distributionBuilder_ == null) { - if (!other.distribution_.isEmpty()) { - if (distribution_.isEmpty()) { - distribution_ = other.distribution_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureDistributionIsMutable(); - distribution_.addAll(other.distribution_); - } - onChanged(); - } - } else { - if (!other.distribution_.isEmpty()) { - if (distributionBuilder_.isEmpty()) { - distributionBuilder_.dispose(); - distributionBuilder_ = null; - distribution_ = other.distribution_; - bitField0_ = (bitField0_ & ~0x00000002); - distributionBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getDistributionFieldBuilder() - : null; - } else { - distributionBuilder_.addAllMessages(other.distribution_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.pkg.Package parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.pkg.Package) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the package.
-     * 
- * - * 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 name of the package.
-     * 
- * - * 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 name of the package.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the package.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the package.
-     * 
- * - * 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 java.util.List distribution_ = - java.util.Collections.emptyList(); - - private void ensureDistributionIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { - distribution_ = new java.util.ArrayList(distribution_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.pkg.Distribution, - io.grafeas.v1beta1.pkg.Distribution.Builder, - io.grafeas.v1beta1.pkg.DistributionOrBuilder> - distributionBuilder_; - - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public java.util.List getDistributionList() { - if (distributionBuilder_ == null) { - return java.util.Collections.unmodifiableList(distribution_); - } else { - return distributionBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public int getDistributionCount() { - if (distributionBuilder_ == null) { - return distribution_.size(); - } else { - return distributionBuilder_.getCount(); - } - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public io.grafeas.v1beta1.pkg.Distribution getDistribution(int index) { - if (distributionBuilder_ == null) { - return distribution_.get(index); - } else { - return distributionBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public Builder setDistribution(int index, io.grafeas.v1beta1.pkg.Distribution value) { - if (distributionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureDistributionIsMutable(); - distribution_.set(index, value); - onChanged(); - } else { - distributionBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public Builder setDistribution( - int index, io.grafeas.v1beta1.pkg.Distribution.Builder builderForValue) { - if (distributionBuilder_ == null) { - ensureDistributionIsMutable(); - distribution_.set(index, builderForValue.build()); - onChanged(); - } else { - distributionBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public Builder addDistribution(io.grafeas.v1beta1.pkg.Distribution value) { - if (distributionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureDistributionIsMutable(); - distribution_.add(value); - onChanged(); - } else { - distributionBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public Builder addDistribution(int index, io.grafeas.v1beta1.pkg.Distribution value) { - if (distributionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureDistributionIsMutable(); - distribution_.add(index, value); - onChanged(); - } else { - distributionBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public Builder addDistribution(io.grafeas.v1beta1.pkg.Distribution.Builder builderForValue) { - if (distributionBuilder_ == null) { - ensureDistributionIsMutable(); - distribution_.add(builderForValue.build()); - onChanged(); - } else { - distributionBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public Builder addDistribution( - int index, io.grafeas.v1beta1.pkg.Distribution.Builder builderForValue) { - if (distributionBuilder_ == null) { - ensureDistributionIsMutable(); - distribution_.add(index, builderForValue.build()); - onChanged(); - } else { - distributionBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public Builder addAllDistribution( - java.lang.Iterable values) { - if (distributionBuilder_ == null) { - ensureDistributionIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, distribution_); - onChanged(); - } else { - distributionBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public Builder clearDistribution() { - if (distributionBuilder_ == null) { - distribution_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - distributionBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public Builder removeDistribution(int index) { - if (distributionBuilder_ == null) { - ensureDistributionIsMutable(); - distribution_.remove(index); - onChanged(); - } else { - distributionBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public io.grafeas.v1beta1.pkg.Distribution.Builder getDistributionBuilder(int index) { - return getDistributionFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public io.grafeas.v1beta1.pkg.DistributionOrBuilder getDistributionOrBuilder(int index) { - if (distributionBuilder_ == null) { - return distribution_.get(index); - } else { - return distributionBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public java.util.List - getDistributionOrBuilderList() { - if (distributionBuilder_ != null) { - return distributionBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(distribution_); - } - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public io.grafeas.v1beta1.pkg.Distribution.Builder addDistributionBuilder() { - return getDistributionFieldBuilder() - .addBuilder(io.grafeas.v1beta1.pkg.Distribution.getDefaultInstance()); - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public io.grafeas.v1beta1.pkg.Distribution.Builder addDistributionBuilder(int index) { - return getDistributionFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.pkg.Distribution.getDefaultInstance()); - } - /** - * - * - *
-     * The various channels by which a package is distributed.
-     * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - public java.util.List - getDistributionBuilderList() { - return getDistributionFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.pkg.Distribution, - io.grafeas.v1beta1.pkg.Distribution.Builder, - io.grafeas.v1beta1.pkg.DistributionOrBuilder> - getDistributionFieldBuilder() { - if (distributionBuilder_ == null) { - distributionBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.pkg.Distribution, - io.grafeas.v1beta1.pkg.Distribution.Builder, - io.grafeas.v1beta1.pkg.DistributionOrBuilder>( - distribution_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); - distribution_ = null; - } - return distributionBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.package.Package) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.package.Package) - private static final io.grafeas.v1beta1.pkg.Package DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.pkg.Package(); - } - - public static io.grafeas.v1beta1.pkg.Package getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Package parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Package(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Package getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/PackageOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/PackageOrBuilder.java deleted file mode 100644 index 47549b6a..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/PackageOrBuilder.java +++ /dev/null @@ -1,83 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -public interface PackageOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.package.Package) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the package.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the package.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * The various channels by which a package is distributed.
-   * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - java.util.List getDistributionList(); - /** - * - * - *
-   * The various channels by which a package is distributed.
-   * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - io.grafeas.v1beta1.pkg.Distribution getDistribution(int index); - /** - * - * - *
-   * The various channels by which a package is distributed.
-   * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - int getDistributionCount(); - /** - * - * - *
-   * The various channels by which a package is distributed.
-   * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - java.util.List - getDistributionOrBuilderList(); - /** - * - * - *
-   * The various channels by which a package is distributed.
-   * 
- * - * repeated .grafeas.v1beta1.package.Distribution distribution = 10; - */ - io.grafeas.v1beta1.pkg.DistributionOrBuilder getDistributionOrBuilder(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/PackageOuterClass.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/PackageOuterClass.java deleted file mode 100644 index e86b405e..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/PackageOuterClass.java +++ /dev/null @@ -1,136 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -public final class PackageOuterClass { - private PackageOuterClass() {} - - 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_grafeas_v1beta1_package_Distribution_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_package_Distribution_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_package_Location_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_package_Location_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_package_Package_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_package_Package_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_package_Details_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_package_Details_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_package_Installation_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_package_Installation_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_package_Version_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_package_Version_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/devtools/containeranalysis/v1be" - + "ta1/package/package.proto\022\027grafeas.v1bet" - + "a1.package\"\314\001\n\014Distribution\022\017\n\007cpe_uri\030\001" - + " \001(\t\022;\n\014architecture\030\002 \001(\0162%.grafeas.v1b" - + "eta1.package.Architecture\0228\n\016latest_vers" - + "ion\030\003 \001(\0132 .grafeas.v1beta1.package.Vers" - + "ion\022\022\n\nmaintainer\030\004 \001(\t\022\013\n\003url\030\005 \001(\t\022\023\n\013" - + "description\030\006 \001(\t\"\\\n\010Location\022\017\n\007cpe_uri" - + "\030\001 \001(\t\0221\n\007version\030\002 \001(\0132 .grafeas.v1beta" - + "1.package.Version\022\014\n\004path\030\003 \001(\t\"T\n\007Packa" - + "ge\022\014\n\004name\030\001 \001(\t\022;\n\014distribution\030\n \003(\0132%" - + ".grafeas.v1beta1.package.Distribution\"F\n" - + "\007Details\022;\n\014installation\030\001 \001(\0132%.grafeas" - + ".v1beta1.package.Installation\"Q\n\014Install" - + "ation\022\014\n\004name\030\001 \001(\t\0223\n\010location\030\002 \003(\0132!." - + "grafeas.v1beta1.package.Location\"\307\001\n\007Ver" - + "sion\022\r\n\005epoch\030\001 \001(\005\022\014\n\004name\030\002 \001(\t\022\020\n\010rev" - + "ision\030\003 \001(\t\022:\n\004kind\030\004 \001(\0162,.grafeas.v1be" - + "ta1.package.Version.VersionKind\"Q\n\013Versi" - + "onKind\022\034\n\030VERSION_KIND_UNSPECIFIED\020\000\022\n\n\006" - + "NORMAL\020\001\022\013\n\007MINIMUM\020\002\022\013\n\007MAXIMUM\020\003*>\n\014Ar" - + "chitecture\022\034\n\030ARCHITECTURE_UNSPECIFIED\020\000" - + "\022\007\n\003X86\020\001\022\007\n\003X64\020\002Bz\n\026io.grafeas.v1beta1" - + ".pkgP\001ZXgoogle.golang.org/genproto/googl" - + "eapis/devtools/containeranalysis/v1beta1" - + "/package;package\242\002\003GRAb\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[] {}, assigner); - internal_static_grafeas_v1beta1_package_Distribution_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_grafeas_v1beta1_package_Distribution_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_package_Distribution_descriptor, - new java.lang.String[] { - "CpeUri", "Architecture", "LatestVersion", "Maintainer", "Url", "Description", - }); - internal_static_grafeas_v1beta1_package_Location_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_grafeas_v1beta1_package_Location_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_package_Location_descriptor, - new java.lang.String[] { - "CpeUri", "Version", "Path", - }); - internal_static_grafeas_v1beta1_package_Package_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_grafeas_v1beta1_package_Package_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_package_Package_descriptor, - new java.lang.String[] { - "Name", "Distribution", - }); - internal_static_grafeas_v1beta1_package_Details_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_grafeas_v1beta1_package_Details_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_package_Details_descriptor, - new java.lang.String[] { - "Installation", - }); - internal_static_grafeas_v1beta1_package_Installation_descriptor = - getDescriptor().getMessageTypes().get(4); - internal_static_grafeas_v1beta1_package_Installation_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_package_Installation_descriptor, - new java.lang.String[] { - "Name", "Location", - }); - internal_static_grafeas_v1beta1_package_Version_descriptor = - getDescriptor().getMessageTypes().get(5); - internal_static_grafeas_v1beta1_package_Version_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_package_Version_descriptor, - new java.lang.String[] { - "Epoch", "Name", "Revision", "Kind", - }); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/ProjectName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/ProjectName.java deleted file mode 100644 index c750bbb7..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.pkg; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/ScanConfigName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/ScanConfigName.java deleted file mode 100644 index f3426df3..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/ScanConfigName.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.pkg; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ScanConfigName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ScanConfigName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - scanConfig = Preconditions.checkNotNull(builder.getScanConfig()); - } - - public static ScanConfigName of(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build(); - } - - public static String format(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build().toString(); - } - - public static ScanConfigName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ScanConfigName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("scan_config")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ScanConfigName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("scanConfig", scanConfig); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "scan_config", scanConfig); - } - - /** Builder for ScanConfigName. */ - public static class Builder { - - private String project; - private String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setScanConfig(String scanConfig) { - this.scanConfig = scanConfig; - return this; - } - - private Builder() {} - - private Builder(ScanConfigName scanConfigName) { - project = scanConfigName.project; - scanConfig = scanConfigName.scanConfig; - } - - public ScanConfigName build() { - return new ScanConfigName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ScanConfigName) { - ScanConfigName that = (ScanConfigName) o; - return (this.project.equals(that.project)) && (this.scanConfig.equals(that.scanConfig)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= scanConfig.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/UntypedIamResourceName.java deleted file mode 100644 index 6b942008..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.pkg; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Version.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Version.java deleted file mode 100644 index 263ee21c..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/Version.java +++ /dev/null @@ -1,1138 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -/** - * - * - *
- * Version contains structured information about the version of a package.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.package.Version} - */ -public final class Version extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.package.Version) - VersionOrBuilder { - private static final long serialVersionUID = 0L; - // Use Version.newBuilder() to construct. - private Version(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Version() { - name_ = ""; - revision_ = ""; - kind_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Version( - 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 8: - { - epoch_ = input.readInt32(); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - revision_ = s; - break; - } - case 32: - { - int rawValue = input.readEnum(); - - kind_ = rawValue; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Version_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Version_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.pkg.Version.class, io.grafeas.v1beta1.pkg.Version.Builder.class); - } - - /** - * - * - *
-   * Whether this is an ordinary package version or a sentinel MIN/MAX version.
-   * 
- * - * Protobuf enum {@code grafeas.v1beta1.package.Version.VersionKind} - */ - public enum VersionKind implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Unknown.
-     * 
- * - * VERSION_KIND_UNSPECIFIED = 0; - */ - VERSION_KIND_UNSPECIFIED(0), - /** - * - * - *
-     * A standard package version, defined by the other fields.
-     * 
- * - * NORMAL = 1; - */ - NORMAL(1), - /** - * - * - *
-     * A special version representing negative infinity, other fields are
-     * ignored.
-     * 
- * - * MINIMUM = 2; - */ - MINIMUM(2), - /** - * - * - *
-     * A special version representing positive infinity, other fields are
-     * ignored.
-     * 
- * - * MAXIMUM = 3; - */ - MAXIMUM(3), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Unknown.
-     * 
- * - * VERSION_KIND_UNSPECIFIED = 0; - */ - public static final int VERSION_KIND_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * A standard package version, defined by the other fields.
-     * 
- * - * NORMAL = 1; - */ - public static final int NORMAL_VALUE = 1; - /** - * - * - *
-     * A special version representing negative infinity, other fields are
-     * ignored.
-     * 
- * - * MINIMUM = 2; - */ - public static final int MINIMUM_VALUE = 2; - /** - * - * - *
-     * A special version representing positive infinity, other fields are
-     * ignored.
-     * 
- * - * MAXIMUM = 3; - */ - public static final int MAXIMUM_VALUE = 3; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static VersionKind valueOf(int value) { - return forNumber(value); - } - - public static VersionKind forNumber(int value) { - switch (value) { - case 0: - return VERSION_KIND_UNSPECIFIED; - case 1: - return NORMAL; - case 2: - return MINIMUM; - case 3: - return MAXIMUM; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public VersionKind findValueByNumber(int number) { - return VersionKind.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return io.grafeas.v1beta1.pkg.Version.getDescriptor().getEnumTypes().get(0); - } - - private static final VersionKind[] VALUES = values(); - - public static VersionKind valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private VersionKind(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:grafeas.v1beta1.package.Version.VersionKind) - } - - public static final int EPOCH_FIELD_NUMBER = 1; - private int epoch_; - /** - * - * - *
-   * Used to correct mistakes in the version numbering scheme.
-   * 
- * - * int32 epoch = 1; - */ - public int getEpoch() { - return epoch_; - } - - public static final int NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The main part of the version name.
-   * 
- * - * string name = 2; - */ - 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 main part of the version name.
-   * 
- * - * string name = 2; - */ - 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 REVISION_FIELD_NUMBER = 3; - private volatile java.lang.Object revision_; - /** - * - * - *
-   * The iteration of the package build from the above version.
-   * 
- * - * string revision = 3; - */ - public java.lang.String getRevision() { - java.lang.Object ref = revision_; - 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(); - revision_ = s; - return s; - } - } - /** - * - * - *
-   * The iteration of the package build from the above version.
-   * 
- * - * string revision = 3; - */ - public com.google.protobuf.ByteString getRevisionBytes() { - java.lang.Object ref = revision_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - revision_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int KIND_FIELD_NUMBER = 4; - private int kind_; - /** - * - * - *
-   * Distinguish between sentinel MIN/MAX versions and normal versions. If
-   * kind is not NORMAL, then the other fields are ignored.
-   * 
- * - * .grafeas.v1beta1.package.Version.VersionKind kind = 4; - */ - public int getKindValue() { - return kind_; - } - /** - * - * - *
-   * Distinguish between sentinel MIN/MAX versions and normal versions. If
-   * kind is not NORMAL, then the other fields are ignored.
-   * 
- * - * .grafeas.v1beta1.package.Version.VersionKind kind = 4; - */ - public io.grafeas.v1beta1.pkg.Version.VersionKind getKind() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.pkg.Version.VersionKind result = - io.grafeas.v1beta1.pkg.Version.VersionKind.valueOf(kind_); - return result == null ? io.grafeas.v1beta1.pkg.Version.VersionKind.UNRECOGNIZED : result; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (epoch_ != 0) { - output.writeInt32(1, epoch_); - } - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, name_); - } - if (!getRevisionBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, revision_); - } - if (kind_ != io.grafeas.v1beta1.pkg.Version.VersionKind.VERSION_KIND_UNSPECIFIED.getNumber()) { - output.writeEnum(4, kind_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (epoch_ != 0) { - size += com.google.protobuf.CodedOutputStream.computeInt32Size(1, epoch_); - } - if (!getNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, name_); - } - if (!getRevisionBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, revision_); - } - if (kind_ != io.grafeas.v1beta1.pkg.Version.VersionKind.VERSION_KIND_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, kind_); - } - 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 io.grafeas.v1beta1.pkg.Version)) { - return super.equals(obj); - } - io.grafeas.v1beta1.pkg.Version other = (io.grafeas.v1beta1.pkg.Version) obj; - - if (getEpoch() != other.getEpoch()) return false; - if (!getName().equals(other.getName())) return false; - if (!getRevision().equals(other.getRevision())) return false; - if (kind_ != other.kind_) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + EPOCH_FIELD_NUMBER; - hash = (53 * hash) + getEpoch(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + REVISION_FIELD_NUMBER; - hash = (53 * hash) + getRevision().hashCode(); - hash = (37 * hash) + KIND_FIELD_NUMBER; - hash = (53 * hash) + kind_; - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.pkg.Version parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Version parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Version parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Version parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Version parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.pkg.Version parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.pkg.Version parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Version 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 io.grafeas.v1beta1.pkg.Version parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Version 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 io.grafeas.v1beta1.pkg.Version parseFrom(com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.pkg.Version 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(io.grafeas.v1beta1.pkg.Version 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; - } - /** - * - * - *
-   * Version contains structured information about the version of a package.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.package.Version} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.package.Version) - io.grafeas.v1beta1.pkg.VersionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Version_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Version_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.pkg.Version.class, io.grafeas.v1beta1.pkg.Version.Builder.class); - } - - // Construct using io.grafeas.v1beta1.pkg.Version.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - epoch_ = 0; - - name_ = ""; - - revision_ = ""; - - kind_ = 0; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.pkg.PackageOuterClass - .internal_static_grafeas_v1beta1_package_Version_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Version getDefaultInstanceForType() { - return io.grafeas.v1beta1.pkg.Version.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Version build() { - io.grafeas.v1beta1.pkg.Version result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Version buildPartial() { - io.grafeas.v1beta1.pkg.Version result = new io.grafeas.v1beta1.pkg.Version(this); - result.epoch_ = epoch_; - result.name_ = name_; - result.revision_ = revision_; - result.kind_ = kind_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.pkg.Version) { - return mergeFrom((io.grafeas.v1beta1.pkg.Version) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.pkg.Version other) { - if (other == io.grafeas.v1beta1.pkg.Version.getDefaultInstance()) return this; - if (other.getEpoch() != 0) { - setEpoch(other.getEpoch()); - } - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getRevision().isEmpty()) { - revision_ = other.revision_; - onChanged(); - } - if (other.kind_ != 0) { - setKindValue(other.getKindValue()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.pkg.Version parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.pkg.Version) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int epoch_; - /** - * - * - *
-     * Used to correct mistakes in the version numbering scheme.
-     * 
- * - * int32 epoch = 1; - */ - public int getEpoch() { - return epoch_; - } - /** - * - * - *
-     * Used to correct mistakes in the version numbering scheme.
-     * 
- * - * int32 epoch = 1; - */ - public Builder setEpoch(int value) { - - epoch_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Used to correct mistakes in the version numbering scheme.
-     * 
- * - * int32 epoch = 1; - */ - public Builder clearEpoch() { - - epoch_ = 0; - onChanged(); - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The main part of the version name.
-     * 
- * - * string name = 2; - */ - 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 main part of the version name.
-     * 
- * - * string name = 2; - */ - 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 main part of the version name.
-     * 
- * - * string name = 2; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The main part of the version name.
-     * 
- * - * string name = 2; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The main part of the version name.
-     * 
- * - * string name = 2; - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object revision_ = ""; - /** - * - * - *
-     * The iteration of the package build from the above version.
-     * 
- * - * string revision = 3; - */ - public java.lang.String getRevision() { - java.lang.Object ref = revision_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - revision_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The iteration of the package build from the above version.
-     * 
- * - * string revision = 3; - */ - public com.google.protobuf.ByteString getRevisionBytes() { - java.lang.Object ref = revision_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - revision_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The iteration of the package build from the above version.
-     * 
- * - * string revision = 3; - */ - public Builder setRevision(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - revision_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The iteration of the package build from the above version.
-     * 
- * - * string revision = 3; - */ - public Builder clearRevision() { - - revision_ = getDefaultInstance().getRevision(); - onChanged(); - return this; - } - /** - * - * - *
-     * The iteration of the package build from the above version.
-     * 
- * - * string revision = 3; - */ - public Builder setRevisionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - revision_ = value; - onChanged(); - return this; - } - - private int kind_ = 0; - /** - * - * - *
-     * Distinguish between sentinel MIN/MAX versions and normal versions. If
-     * kind is not NORMAL, then the other fields are ignored.
-     * 
- * - * .grafeas.v1beta1.package.Version.VersionKind kind = 4; - */ - public int getKindValue() { - return kind_; - } - /** - * - * - *
-     * Distinguish between sentinel MIN/MAX versions and normal versions. If
-     * kind is not NORMAL, then the other fields are ignored.
-     * 
- * - * .grafeas.v1beta1.package.Version.VersionKind kind = 4; - */ - public Builder setKindValue(int value) { - kind_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Distinguish between sentinel MIN/MAX versions and normal versions. If
-     * kind is not NORMAL, then the other fields are ignored.
-     * 
- * - * .grafeas.v1beta1.package.Version.VersionKind kind = 4; - */ - public io.grafeas.v1beta1.pkg.Version.VersionKind getKind() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.pkg.Version.VersionKind result = - io.grafeas.v1beta1.pkg.Version.VersionKind.valueOf(kind_); - return result == null ? io.grafeas.v1beta1.pkg.Version.VersionKind.UNRECOGNIZED : result; - } - /** - * - * - *
-     * Distinguish between sentinel MIN/MAX versions and normal versions. If
-     * kind is not NORMAL, then the other fields are ignored.
-     * 
- * - * .grafeas.v1beta1.package.Version.VersionKind kind = 4; - */ - public Builder setKind(io.grafeas.v1beta1.pkg.Version.VersionKind value) { - if (value == null) { - throw new NullPointerException(); - } - - kind_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Distinguish between sentinel MIN/MAX versions and normal versions. If
-     * kind is not NORMAL, then the other fields are ignored.
-     * 
- * - * .grafeas.v1beta1.package.Version.VersionKind kind = 4; - */ - public Builder clearKind() { - - kind_ = 0; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.package.Version) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.package.Version) - private static final io.grafeas.v1beta1.pkg.Version DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.pkg.Version(); - } - - public static io.grafeas.v1beta1.pkg.Version getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Version parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Version(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.pkg.Version getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/VersionOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/VersionOrBuilder.java deleted file mode 100644 index 74018867..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/pkg/VersionOrBuilder.java +++ /dev/null @@ -1,86 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/package/package.proto - -package io.grafeas.v1beta1.pkg; - -public interface VersionOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.package.Version) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Used to correct mistakes in the version numbering scheme.
-   * 
- * - * int32 epoch = 1; - */ - int getEpoch(); - - /** - * - * - *
-   * The main part of the version name.
-   * 
- * - * string name = 2; - */ - java.lang.String getName(); - /** - * - * - *
-   * The main part of the version name.
-   * 
- * - * string name = 2; - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * The iteration of the package build from the above version.
-   * 
- * - * string revision = 3; - */ - java.lang.String getRevision(); - /** - * - * - *
-   * The iteration of the package build from the above version.
-   * 
- * - * string revision = 3; - */ - com.google.protobuf.ByteString getRevisionBytes(); - - /** - * - * - *
-   * Distinguish between sentinel MIN/MAX versions and normal versions. If
-   * kind is not NORMAL, then the other fields are ignored.
-   * 
- * - * .grafeas.v1beta1.package.Version.VersionKind kind = 4; - */ - int getKindValue(); - /** - * - * - *
-   * Distinguish between sentinel MIN/MAX versions and normal versions. If
-   * kind is not NORMAL, then the other fields are ignored.
-   * 
- * - * .grafeas.v1beta1.package.Version.VersionKind kind = 4; - */ - io.grafeas.v1beta1.pkg.Version.VersionKind getKind(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Artifact.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Artifact.java deleted file mode 100644 index 1d40b2c5..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Artifact.java +++ /dev/null @@ -1,1069 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -/** - * - * - *
- * Artifact describes a build product.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.provenance.Artifact} - */ -public final class Artifact extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.provenance.Artifact) - ArtifactOrBuilder { - private static final long serialVersionUID = 0L; - // Use Artifact.newBuilder() to construct. - private Artifact(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Artifact() { - checksum_ = ""; - id_ = ""; - names_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Artifact( - 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(); - - checksum_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - id_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000004) != 0)) { - names_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000004; - } - names_.add(s); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000004) != 0)) { - names_ = names_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Artifact_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Artifact_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.provenance.Artifact.class, - io.grafeas.v1beta1.provenance.Artifact.Builder.class); - } - - private int bitField0_; - public static final int CHECKSUM_FIELD_NUMBER = 1; - private volatile java.lang.Object checksum_; - /** - * - * - *
-   * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a
-   * container.
-   * 
- * - * string checksum = 1; - */ - public java.lang.String getChecksum() { - java.lang.Object ref = checksum_; - 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(); - checksum_ = s; - return s; - } - } - /** - * - * - *
-   * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a
-   * container.
-   * 
- * - * string checksum = 1; - */ - public com.google.protobuf.ByteString getChecksumBytes() { - java.lang.Object ref = checksum_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - checksum_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ID_FIELD_NUMBER = 2; - private volatile java.lang.Object id_; - /** - * - * - *
-   * Artifact ID, if any; for container images, this will be a URL by digest
-   * like `gcr.io/projectID/imagename@sha256:123456`.
-   * 
- * - * string id = 2; - */ - public java.lang.String getId() { - java.lang.Object ref = id_; - 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(); - id_ = s; - return s; - } - } - /** - * - * - *
-   * Artifact ID, if any; for container images, this will be a URL by digest
-   * like `gcr.io/projectID/imagename@sha256:123456`.
-   * 
- * - * string id = 2; - */ - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int NAMES_FIELD_NUMBER = 3; - private com.google.protobuf.LazyStringList names_; - /** - * - * - *
-   * Related artifact names. This may be the path to a binary or jar file, or in
-   * the case of a container build, the name used to push the container image to
-   * Google Container Registry, as presented to `docker push`. Note that a
-   * single Artifact ID can have multiple names, for example if two tags are
-   * applied to one image.
-   * 
- * - * repeated string names = 3; - */ - public com.google.protobuf.ProtocolStringList getNamesList() { - return names_; - } - /** - * - * - *
-   * Related artifact names. This may be the path to a binary or jar file, or in
-   * the case of a container build, the name used to push the container image to
-   * Google Container Registry, as presented to `docker push`. Note that a
-   * single Artifact ID can have multiple names, for example if two tags are
-   * applied to one image.
-   * 
- * - * repeated string names = 3; - */ - public int getNamesCount() { - return names_.size(); - } - /** - * - * - *
-   * Related artifact names. This may be the path to a binary or jar file, or in
-   * the case of a container build, the name used to push the container image to
-   * Google Container Registry, as presented to `docker push`. Note that a
-   * single Artifact ID can have multiple names, for example if two tags are
-   * applied to one image.
-   * 
- * - * repeated string names = 3; - */ - public java.lang.String getNames(int index) { - return names_.get(index); - } - /** - * - * - *
-   * Related artifact names. This may be the path to a binary or jar file, or in
-   * the case of a container build, the name used to push the container image to
-   * Google Container Registry, as presented to `docker push`. Note that a
-   * single Artifact ID can have multiple names, for example if two tags are
-   * applied to one image.
-   * 
- * - * repeated string names = 3; - */ - public com.google.protobuf.ByteString getNamesBytes(int index) { - return names_.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 (!getChecksumBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, checksum_); - } - if (!getIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, id_); - } - for (int i = 0; i < names_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, names_.getRaw(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getChecksumBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, checksum_); - } - if (!getIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, id_); - } - { - int dataSize = 0; - for (int i = 0; i < names_.size(); i++) { - dataSize += computeStringSizeNoTag(names_.getRaw(i)); - } - size += dataSize; - size += 1 * getNamesList().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 io.grafeas.v1beta1.provenance.Artifact)) { - return super.equals(obj); - } - io.grafeas.v1beta1.provenance.Artifact other = (io.grafeas.v1beta1.provenance.Artifact) obj; - - if (!getChecksum().equals(other.getChecksum())) return false; - if (!getId().equals(other.getId())) return false; - if (!getNamesList().equals(other.getNamesList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + CHECKSUM_FIELD_NUMBER; - hash = (53 * hash) + getChecksum().hashCode(); - hash = (37 * hash) + ID_FIELD_NUMBER; - hash = (53 * hash) + getId().hashCode(); - if (getNamesCount() > 0) { - hash = (37 * hash) + NAMES_FIELD_NUMBER; - hash = (53 * hash) + getNamesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.provenance.Artifact parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.Artifact parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.Artifact parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.Artifact parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.Artifact parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.Artifact parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.Artifact parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.Artifact 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 io.grafeas.v1beta1.provenance.Artifact parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.Artifact 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 io.grafeas.v1beta1.provenance.Artifact parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.Artifact 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(io.grafeas.v1beta1.provenance.Artifact 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; - } - /** - * - * - *
-   * Artifact describes a build product.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.provenance.Artifact} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.provenance.Artifact) - io.grafeas.v1beta1.provenance.ArtifactOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Artifact_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Artifact_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.provenance.Artifact.class, - io.grafeas.v1beta1.provenance.Artifact.Builder.class); - } - - // Construct using io.grafeas.v1beta1.provenance.Artifact.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - checksum_ = ""; - - id_ = ""; - - names_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000004); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Artifact_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Artifact getDefaultInstanceForType() { - return io.grafeas.v1beta1.provenance.Artifact.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Artifact build() { - io.grafeas.v1beta1.provenance.Artifact result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Artifact buildPartial() { - io.grafeas.v1beta1.provenance.Artifact result = - new io.grafeas.v1beta1.provenance.Artifact(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.checksum_ = checksum_; - result.id_ = id_; - if (((bitField0_ & 0x00000004) != 0)) { - names_ = names_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.names_ = names_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.provenance.Artifact) { - return mergeFrom((io.grafeas.v1beta1.provenance.Artifact) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.provenance.Artifact other) { - if (other == io.grafeas.v1beta1.provenance.Artifact.getDefaultInstance()) return this; - if (!other.getChecksum().isEmpty()) { - checksum_ = other.checksum_; - onChanged(); - } - if (!other.getId().isEmpty()) { - id_ = other.id_; - onChanged(); - } - if (!other.names_.isEmpty()) { - if (names_.isEmpty()) { - names_ = other.names_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureNamesIsMutable(); - names_.addAll(other.names_); - } - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.provenance.Artifact parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.provenance.Artifact) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object checksum_ = ""; - /** - * - * - *
-     * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a
-     * container.
-     * 
- * - * string checksum = 1; - */ - public java.lang.String getChecksum() { - java.lang.Object ref = checksum_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - checksum_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a
-     * container.
-     * 
- * - * string checksum = 1; - */ - public com.google.protobuf.ByteString getChecksumBytes() { - java.lang.Object ref = checksum_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - checksum_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a
-     * container.
-     * 
- * - * string checksum = 1; - */ - public Builder setChecksum(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - checksum_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a
-     * container.
-     * 
- * - * string checksum = 1; - */ - public Builder clearChecksum() { - - checksum_ = getDefaultInstance().getChecksum(); - onChanged(); - return this; - } - /** - * - * - *
-     * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a
-     * container.
-     * 
- * - * string checksum = 1; - */ - public Builder setChecksumBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - checksum_ = value; - onChanged(); - return this; - } - - private java.lang.Object id_ = ""; - /** - * - * - *
-     * Artifact ID, if any; for container images, this will be a URL by digest
-     * like `gcr.io/projectID/imagename@sha256:123456`.
-     * 
- * - * string id = 2; - */ - public java.lang.String getId() { - java.lang.Object ref = id_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Artifact ID, if any; for container images, this will be a URL by digest
-     * like `gcr.io/projectID/imagename@sha256:123456`.
-     * 
- * - * string id = 2; - */ - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Artifact ID, if any; for container images, this will be a URL by digest
-     * like `gcr.io/projectID/imagename@sha256:123456`.
-     * 
- * - * string id = 2; - */ - public Builder setId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - id_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Artifact ID, if any; for container images, this will be a URL by digest
-     * like `gcr.io/projectID/imagename@sha256:123456`.
-     * 
- * - * string id = 2; - */ - public Builder clearId() { - - id_ = getDefaultInstance().getId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Artifact ID, if any; for container images, this will be a URL by digest
-     * like `gcr.io/projectID/imagename@sha256:123456`.
-     * 
- * - * string id = 2; - */ - public Builder setIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - id_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList names_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureNamesIsMutable() { - if (!((bitField0_ & 0x00000004) != 0)) { - names_ = new com.google.protobuf.LazyStringArrayList(names_); - bitField0_ |= 0x00000004; - } - } - /** - * - * - *
-     * Related artifact names. This may be the path to a binary or jar file, or in
-     * the case of a container build, the name used to push the container image to
-     * Google Container Registry, as presented to `docker push`. Note that a
-     * single Artifact ID can have multiple names, for example if two tags are
-     * applied to one image.
-     * 
- * - * repeated string names = 3; - */ - public com.google.protobuf.ProtocolStringList getNamesList() { - return names_.getUnmodifiableView(); - } - /** - * - * - *
-     * Related artifact names. This may be the path to a binary or jar file, or in
-     * the case of a container build, the name used to push the container image to
-     * Google Container Registry, as presented to `docker push`. Note that a
-     * single Artifact ID can have multiple names, for example if two tags are
-     * applied to one image.
-     * 
- * - * repeated string names = 3; - */ - public int getNamesCount() { - return names_.size(); - } - /** - * - * - *
-     * Related artifact names. This may be the path to a binary or jar file, or in
-     * the case of a container build, the name used to push the container image to
-     * Google Container Registry, as presented to `docker push`. Note that a
-     * single Artifact ID can have multiple names, for example if two tags are
-     * applied to one image.
-     * 
- * - * repeated string names = 3; - */ - public java.lang.String getNames(int index) { - return names_.get(index); - } - /** - * - * - *
-     * Related artifact names. This may be the path to a binary or jar file, or in
-     * the case of a container build, the name used to push the container image to
-     * Google Container Registry, as presented to `docker push`. Note that a
-     * single Artifact ID can have multiple names, for example if two tags are
-     * applied to one image.
-     * 
- * - * repeated string names = 3; - */ - public com.google.protobuf.ByteString getNamesBytes(int index) { - return names_.getByteString(index); - } - /** - * - * - *
-     * Related artifact names. This may be the path to a binary or jar file, or in
-     * the case of a container build, the name used to push the container image to
-     * Google Container Registry, as presented to `docker push`. Note that a
-     * single Artifact ID can have multiple names, for example if two tags are
-     * applied to one image.
-     * 
- * - * repeated string names = 3; - */ - public Builder setNames(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureNamesIsMutable(); - names_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * Related artifact names. This may be the path to a binary or jar file, or in
-     * the case of a container build, the name used to push the container image to
-     * Google Container Registry, as presented to `docker push`. Note that a
-     * single Artifact ID can have multiple names, for example if two tags are
-     * applied to one image.
-     * 
- * - * repeated string names = 3; - */ - public Builder addNames(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureNamesIsMutable(); - names_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * Related artifact names. This may be the path to a binary or jar file, or in
-     * the case of a container build, the name used to push the container image to
-     * Google Container Registry, as presented to `docker push`. Note that a
-     * single Artifact ID can have multiple names, for example if two tags are
-     * applied to one image.
-     * 
- * - * repeated string names = 3; - */ - public Builder addAllNames(java.lang.Iterable values) { - ensureNamesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, names_); - onChanged(); - return this; - } - /** - * - * - *
-     * Related artifact names. This may be the path to a binary or jar file, or in
-     * the case of a container build, the name used to push the container image to
-     * Google Container Registry, as presented to `docker push`. Note that a
-     * single Artifact ID can have multiple names, for example if two tags are
-     * applied to one image.
-     * 
- * - * repeated string names = 3; - */ - public Builder clearNames() { - names_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - return this; - } - /** - * - * - *
-     * Related artifact names. This may be the path to a binary or jar file, or in
-     * the case of a container build, the name used to push the container image to
-     * Google Container Registry, as presented to `docker push`. Note that a
-     * single Artifact ID can have multiple names, for example if two tags are
-     * applied to one image.
-     * 
- * - * repeated string names = 3; - */ - public Builder addNamesBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureNamesIsMutable(); - names_.add(value); - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.provenance.Artifact) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.provenance.Artifact) - private static final io.grafeas.v1beta1.provenance.Artifact DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.provenance.Artifact(); - } - - public static io.grafeas.v1beta1.provenance.Artifact getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Artifact parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Artifact(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Artifact getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/ArtifactOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/ArtifactOrBuilder.java deleted file mode 100644 index a5a1ebac..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/ArtifactOrBuilder.java +++ /dev/null @@ -1,113 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -public interface ArtifactOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.provenance.Artifact) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a
-   * container.
-   * 
- * - * string checksum = 1; - */ - java.lang.String getChecksum(); - /** - * - * - *
-   * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a
-   * container.
-   * 
- * - * string checksum = 1; - */ - com.google.protobuf.ByteString getChecksumBytes(); - - /** - * - * - *
-   * Artifact ID, if any; for container images, this will be a URL by digest
-   * like `gcr.io/projectID/imagename@sha256:123456`.
-   * 
- * - * string id = 2; - */ - java.lang.String getId(); - /** - * - * - *
-   * Artifact ID, if any; for container images, this will be a URL by digest
-   * like `gcr.io/projectID/imagename@sha256:123456`.
-   * 
- * - * string id = 2; - */ - com.google.protobuf.ByteString getIdBytes(); - - /** - * - * - *
-   * Related artifact names. This may be the path to a binary or jar file, or in
-   * the case of a container build, the name used to push the container image to
-   * Google Container Registry, as presented to `docker push`. Note that a
-   * single Artifact ID can have multiple names, for example if two tags are
-   * applied to one image.
-   * 
- * - * repeated string names = 3; - */ - java.util.List getNamesList(); - /** - * - * - *
-   * Related artifact names. This may be the path to a binary or jar file, or in
-   * the case of a container build, the name used to push the container image to
-   * Google Container Registry, as presented to `docker push`. Note that a
-   * single Artifact ID can have multiple names, for example if two tags are
-   * applied to one image.
-   * 
- * - * repeated string names = 3; - */ - int getNamesCount(); - /** - * - * - *
-   * Related artifact names. This may be the path to a binary or jar file, or in
-   * the case of a container build, the name used to push the container image to
-   * Google Container Registry, as presented to `docker push`. Note that a
-   * single Artifact ID can have multiple names, for example if two tags are
-   * applied to one image.
-   * 
- * - * repeated string names = 3; - */ - java.lang.String getNames(int index); - /** - * - * - *
-   * Related artifact names. This may be the path to a binary or jar file, or in
-   * the case of a container build, the name used to push the container image to
-   * Google Container Registry, as presented to `docker push`. Note that a
-   * single Artifact ID can have multiple names, for example if two tags are
-   * applied to one image.
-   * 
- * - * repeated string names = 3; - */ - com.google.protobuf.ByteString getNamesBytes(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/BuildProvenance.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/BuildProvenance.java deleted file mode 100644 index 18a1eaeb..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/BuildProvenance.java +++ /dev/null @@ -1,3763 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -/** - * - * - *
- * Provenance of a build. Contains all information needed to verify the full
- * details about the build from source to completion.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.provenance.BuildProvenance} - */ -public final class BuildProvenance extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.provenance.BuildProvenance) - BuildProvenanceOrBuilder { - private static final long serialVersionUID = 0L; - // Use BuildProvenance.newBuilder() to construct. - private BuildProvenance(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BuildProvenance() { - id_ = ""; - projectId_ = ""; - commands_ = java.util.Collections.emptyList(); - builtArtifacts_ = java.util.Collections.emptyList(); - creator_ = ""; - logsUri_ = ""; - triggerId_ = ""; - builderVersion_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private BuildProvenance( - 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(); - - id_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 26: - { - if (!((mutable_bitField0_ & 0x00000004) != 0)) { - commands_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000004; - } - commands_.add( - input.readMessage( - io.grafeas.v1beta1.provenance.Command.parser(), extensionRegistry)); - break; - } - case 34: - { - if (!((mutable_bitField0_ & 0x00000008) != 0)) { - builtArtifacts_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000008; - } - builtArtifacts_.add( - input.readMessage( - io.grafeas.v1beta1.provenance.Artifact.parser(), extensionRegistry)); - break; - } - case 42: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 50: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (startTime_ != null) { - subBuilder = startTime_.toBuilder(); - } - startTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(startTime_); - startTime_ = subBuilder.buildPartial(); - } - - break; - } - case 58: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (endTime_ != null) { - subBuilder = endTime_.toBuilder(); - } - endTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(endTime_); - endTime_ = subBuilder.buildPartial(); - } - - break; - } - case 66: - { - java.lang.String s = input.readStringRequireUtf8(); - - creator_ = s; - break; - } - case 74: - { - java.lang.String s = input.readStringRequireUtf8(); - - logsUri_ = s; - break; - } - case 82: - { - io.grafeas.v1beta1.provenance.Source.Builder subBuilder = null; - if (sourceProvenance_ != null) { - subBuilder = sourceProvenance_.toBuilder(); - } - sourceProvenance_ = - input.readMessage( - io.grafeas.v1beta1.provenance.Source.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(sourceProvenance_); - sourceProvenance_ = subBuilder.buildPartial(); - } - - break; - } - case 90: - { - java.lang.String s = input.readStringRequireUtf8(); - - triggerId_ = s; - break; - } - case 98: - { - if (!((mutable_bitField0_ & 0x00000800) != 0)) { - buildOptions_ = - com.google.protobuf.MapField.newMapField( - BuildOptionsDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000800; - } - com.google.protobuf.MapEntry buildOptions__ = - input.readMessage( - BuildOptionsDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - buildOptions_.getMutableMap().put(buildOptions__.getKey(), buildOptions__.getValue()); - break; - } - case 106: - { - java.lang.String s = input.readStringRequireUtf8(); - - builderVersion_ = s; - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000004) != 0)) { - commands_ = java.util.Collections.unmodifiableList(commands_); - } - if (((mutable_bitField0_ & 0x00000008) != 0)) { - builtArtifacts_ = java.util.Collections.unmodifiableList(builtArtifacts_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_BuildProvenance_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 12: - return internalGetBuildOptions(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_BuildProvenance_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.provenance.BuildProvenance.class, - io.grafeas.v1beta1.provenance.BuildProvenance.Builder.class); - } - - private int bitField0_; - public static final int ID_FIELD_NUMBER = 1; - private volatile java.lang.Object id_; - /** - * - * - *
-   * Unique identifier of the build.
-   * 
- * - * string id = 1; - */ - public java.lang.String getId() { - java.lang.Object ref = id_; - 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(); - id_ = s; - return s; - } - } - /** - * - * - *
-   * Unique identifier of the build.
-   * 
- * - * string id = 1; - */ - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PROJECT_ID_FIELD_NUMBER = 2; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * ID of the project.
-   * 
- * - * string project_id = 2; - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - 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(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * ID of the project.
-   * 
- * - * string project_id = 2; - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int COMMANDS_FIELD_NUMBER = 3; - private java.util.List commands_; - /** - * - * - *
-   * Commands requested by the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public java.util.List getCommandsList() { - return commands_; - } - /** - * - * - *
-   * Commands requested by the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public java.util.List - getCommandsOrBuilderList() { - return commands_; - } - /** - * - * - *
-   * Commands requested by the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public int getCommandsCount() { - return commands_.size(); - } - /** - * - * - *
-   * Commands requested by the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public io.grafeas.v1beta1.provenance.Command getCommands(int index) { - return commands_.get(index); - } - /** - * - * - *
-   * Commands requested by the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public io.grafeas.v1beta1.provenance.CommandOrBuilder getCommandsOrBuilder(int index) { - return commands_.get(index); - } - - public static final int BUILT_ARTIFACTS_FIELD_NUMBER = 4; - private java.util.List builtArtifacts_; - /** - * - * - *
-   * Output of the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public java.util.List getBuiltArtifactsList() { - return builtArtifacts_; - } - /** - * - * - *
-   * Output of the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public java.util.List - getBuiltArtifactsOrBuilderList() { - return builtArtifacts_; - } - /** - * - * - *
-   * Output of the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public int getBuiltArtifactsCount() { - return builtArtifacts_.size(); - } - /** - * - * - *
-   * Output of the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public io.grafeas.v1beta1.provenance.Artifact getBuiltArtifacts(int index) { - return builtArtifacts_.get(index); - } - /** - * - * - *
-   * Output of the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public io.grafeas.v1beta1.provenance.ArtifactOrBuilder getBuiltArtifactsOrBuilder(int index) { - return builtArtifacts_.get(index); - } - - public static final int CREATE_TIME_FIELD_NUMBER = 5; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-   * Time at which the build was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-   * Time at which the build was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-   * Time at which the build was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int START_TIME_FIELD_NUMBER = 6; - private com.google.protobuf.Timestamp startTime_; - /** - * - * - *
-   * Time at which execution of the build was started.
-   * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - public boolean hasStartTime() { - return startTime_ != null; - } - /** - * - * - *
-   * Time at which execution of the build was started.
-   * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - public com.google.protobuf.Timestamp getStartTime() { - return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; - } - /** - * - * - *
-   * Time at which execution of the build was started.
-   * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { - return getStartTime(); - } - - public static final int END_TIME_FIELD_NUMBER = 7; - private com.google.protobuf.Timestamp endTime_; - /** - * - * - *
-   * Time at which execution of the build was finished.
-   * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - public boolean hasEndTime() { - return endTime_ != null; - } - /** - * - * - *
-   * Time at which execution of the build was finished.
-   * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - public com.google.protobuf.Timestamp getEndTime() { - return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; - } - /** - * - * - *
-   * Time at which execution of the build was finished.
-   * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { - return getEndTime(); - } - - public static final int CREATOR_FIELD_NUMBER = 8; - private volatile java.lang.Object creator_; - /** - * - * - *
-   * E-mail address of the user who initiated this build. Note that this was the
-   * user's e-mail address at the time the build was initiated; this address may
-   * not represent the same end-user for all time.
-   * 
- * - * string creator = 8; - */ - public java.lang.String getCreator() { - java.lang.Object ref = creator_; - 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(); - creator_ = s; - return s; - } - } - /** - * - * - *
-   * E-mail address of the user who initiated this build. Note that this was the
-   * user's e-mail address at the time the build was initiated; this address may
-   * not represent the same end-user for all time.
-   * 
- * - * string creator = 8; - */ - public com.google.protobuf.ByteString getCreatorBytes() { - java.lang.Object ref = creator_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - creator_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int LOGS_URI_FIELD_NUMBER = 9; - private volatile java.lang.Object logsUri_; - /** - * - * - *
-   * URI where any logs for this provenance were written.
-   * 
- * - * string logs_uri = 9; - */ - public java.lang.String getLogsUri() { - java.lang.Object ref = logsUri_; - 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(); - logsUri_ = s; - return s; - } - } - /** - * - * - *
-   * URI where any logs for this provenance were written.
-   * 
- * - * string logs_uri = 9; - */ - public com.google.protobuf.ByteString getLogsUriBytes() { - java.lang.Object ref = logsUri_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - logsUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SOURCE_PROVENANCE_FIELD_NUMBER = 10; - private io.grafeas.v1beta1.provenance.Source sourceProvenance_; - /** - * - * - *
-   * Details of the Source input to the build.
-   * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - public boolean hasSourceProvenance() { - return sourceProvenance_ != null; - } - /** - * - * - *
-   * Details of the Source input to the build.
-   * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - public io.grafeas.v1beta1.provenance.Source getSourceProvenance() { - return sourceProvenance_ == null - ? io.grafeas.v1beta1.provenance.Source.getDefaultInstance() - : sourceProvenance_; - } - /** - * - * - *
-   * Details of the Source input to the build.
-   * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - public io.grafeas.v1beta1.provenance.SourceOrBuilder getSourceProvenanceOrBuilder() { - return getSourceProvenance(); - } - - public static final int TRIGGER_ID_FIELD_NUMBER = 11; - private volatile java.lang.Object triggerId_; - /** - * - * - *
-   * Trigger identifier if the build was triggered automatically; empty if not.
-   * 
- * - * string trigger_id = 11; - */ - public java.lang.String getTriggerId() { - java.lang.Object ref = triggerId_; - 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(); - triggerId_ = s; - return s; - } - } - /** - * - * - *
-   * Trigger identifier if the build was triggered automatically; empty if not.
-   * 
- * - * string trigger_id = 11; - */ - public com.google.protobuf.ByteString getTriggerIdBytes() { - java.lang.Object ref = triggerId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - triggerId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int BUILD_OPTIONS_FIELD_NUMBER = 12; - - private static final class BuildOptionsDefaultEntryHolder { - static final com.google.protobuf.MapEntry defaultEntry = - com.google.protobuf.MapEntry.newDefaultInstance( - io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_BuildProvenance_BuildOptionsEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.STRING, - ""); - } - - private com.google.protobuf.MapField buildOptions_; - - private com.google.protobuf.MapField - internalGetBuildOptions() { - if (buildOptions_ == null) { - return com.google.protobuf.MapField.emptyMapField( - BuildOptionsDefaultEntryHolder.defaultEntry); - } - return buildOptions_; - } - - public int getBuildOptionsCount() { - return internalGetBuildOptions().getMap().size(); - } - /** - * - * - *
-   * Special options applied to this build. This is a catch-all field where
-   * build providers can enter any desired additional details.
-   * 
- * - * map<string, string> build_options = 12; - */ - public boolean containsBuildOptions(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - return internalGetBuildOptions().getMap().containsKey(key); - } - /** Use {@link #getBuildOptionsMap()} instead. */ - @java.lang.Deprecated - public java.util.Map getBuildOptions() { - return getBuildOptionsMap(); - } - /** - * - * - *
-   * Special options applied to this build. This is a catch-all field where
-   * build providers can enter any desired additional details.
-   * 
- * - * map<string, string> build_options = 12; - */ - public java.util.Map getBuildOptionsMap() { - return internalGetBuildOptions().getMap(); - } - /** - * - * - *
-   * Special options applied to this build. This is a catch-all field where
-   * build providers can enter any desired additional details.
-   * 
- * - * map<string, string> build_options = 12; - */ - public java.lang.String getBuildOptionsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetBuildOptions().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-   * Special options applied to this build. This is a catch-all field where
-   * build providers can enter any desired additional details.
-   * 
- * - * map<string, string> build_options = 12; - */ - public java.lang.String getBuildOptionsOrThrow(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetBuildOptions().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public static final int BUILDER_VERSION_FIELD_NUMBER = 13; - private volatile java.lang.Object builderVersion_; - /** - * - * - *
-   * Version string of the builder at the time this build was executed.
-   * 
- * - * string builder_version = 13; - */ - public java.lang.String getBuilderVersion() { - java.lang.Object ref = builderVersion_; - 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(); - builderVersion_ = s; - return s; - } - } - /** - * - * - *
-   * Version string of the builder at the time this build was executed.
-   * 
- * - * string builder_version = 13; - */ - public com.google.protobuf.ByteString getBuilderVersionBytes() { - java.lang.Object ref = builderVersion_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - builderVersion_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, id_); - } - if (!getProjectIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, projectId_); - } - for (int i = 0; i < commands_.size(); i++) { - output.writeMessage(3, commands_.get(i)); - } - for (int i = 0; i < builtArtifacts_.size(); i++) { - output.writeMessage(4, builtArtifacts_.get(i)); - } - if (createTime_ != null) { - output.writeMessage(5, getCreateTime()); - } - if (startTime_ != null) { - output.writeMessage(6, getStartTime()); - } - if (endTime_ != null) { - output.writeMessage(7, getEndTime()); - } - if (!getCreatorBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 8, creator_); - } - if (!getLogsUriBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 9, logsUri_); - } - if (sourceProvenance_ != null) { - output.writeMessage(10, getSourceProvenance()); - } - if (!getTriggerIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 11, triggerId_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetBuildOptions(), BuildOptionsDefaultEntryHolder.defaultEntry, 12); - if (!getBuilderVersionBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 13, builderVersion_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, id_); - } - if (!getProjectIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, projectId_); - } - for (int i = 0; i < commands_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, commands_.get(i)); - } - for (int i = 0; i < builtArtifacts_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, builtArtifacts_.get(i)); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); - } - if (startTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getStartTime()); - } - if (endTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getEndTime()); - } - if (!getCreatorBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, creator_); - } - if (!getLogsUriBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(9, logsUri_); - } - if (sourceProvenance_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getSourceProvenance()); - } - if (!getTriggerIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(11, triggerId_); - } - for (java.util.Map.Entry entry : - internalGetBuildOptions().getMap().entrySet()) { - com.google.protobuf.MapEntry buildOptions__ = - BuildOptionsDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(12, buildOptions__); - } - if (!getBuilderVersionBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(13, builderVersion_); - } - 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 io.grafeas.v1beta1.provenance.BuildProvenance)) { - return super.equals(obj); - } - io.grafeas.v1beta1.provenance.BuildProvenance other = - (io.grafeas.v1beta1.provenance.BuildProvenance) obj; - - if (!getId().equals(other.getId())) return false; - if (!getProjectId().equals(other.getProjectId())) return false; - if (!getCommandsList().equals(other.getCommandsList())) return false; - if (!getBuiltArtifactsList().equals(other.getBuiltArtifactsList())) return false; - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasStartTime() != other.hasStartTime()) return false; - if (hasStartTime()) { - if (!getStartTime().equals(other.getStartTime())) return false; - } - if (hasEndTime() != other.hasEndTime()) return false; - if (hasEndTime()) { - if (!getEndTime().equals(other.getEndTime())) return false; - } - if (!getCreator().equals(other.getCreator())) return false; - if (!getLogsUri().equals(other.getLogsUri())) return false; - if (hasSourceProvenance() != other.hasSourceProvenance()) return false; - if (hasSourceProvenance()) { - if (!getSourceProvenance().equals(other.getSourceProvenance())) return false; - } - if (!getTriggerId().equals(other.getTriggerId())) return false; - if (!internalGetBuildOptions().equals(other.internalGetBuildOptions())) return false; - if (!getBuilderVersion().equals(other.getBuilderVersion())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + ID_FIELD_NUMBER; - hash = (53 * hash) + getId().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - if (getCommandsCount() > 0) { - hash = (37 * hash) + COMMANDS_FIELD_NUMBER; - hash = (53 * hash) + getCommandsList().hashCode(); - } - if (getBuiltArtifactsCount() > 0) { - hash = (37 * hash) + BUILT_ARTIFACTS_FIELD_NUMBER; - hash = (53 * hash) + getBuiltArtifactsList().hashCode(); - } - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasStartTime()) { - hash = (37 * hash) + START_TIME_FIELD_NUMBER; - hash = (53 * hash) + getStartTime().hashCode(); - } - if (hasEndTime()) { - hash = (37 * hash) + END_TIME_FIELD_NUMBER; - hash = (53 * hash) + getEndTime().hashCode(); - } - hash = (37 * hash) + CREATOR_FIELD_NUMBER; - hash = (53 * hash) + getCreator().hashCode(); - hash = (37 * hash) + LOGS_URI_FIELD_NUMBER; - hash = (53 * hash) + getLogsUri().hashCode(); - if (hasSourceProvenance()) { - hash = (37 * hash) + SOURCE_PROVENANCE_FIELD_NUMBER; - hash = (53 * hash) + getSourceProvenance().hashCode(); - } - hash = (37 * hash) + TRIGGER_ID_FIELD_NUMBER; - hash = (53 * hash) + getTriggerId().hashCode(); - if (!internalGetBuildOptions().getMap().isEmpty()) { - hash = (37 * hash) + BUILD_OPTIONS_FIELD_NUMBER; - hash = (53 * hash) + internalGetBuildOptions().hashCode(); - } - hash = (37 * hash) + BUILDER_VERSION_FIELD_NUMBER; - hash = (53 * hash) + getBuilderVersion().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.provenance.BuildProvenance parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.BuildProvenance parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.BuildProvenance parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.BuildProvenance parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.BuildProvenance parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.BuildProvenance parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.BuildProvenance parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.BuildProvenance 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 io.grafeas.v1beta1.provenance.BuildProvenance parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.BuildProvenance 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 io.grafeas.v1beta1.provenance.BuildProvenance parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.BuildProvenance 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(io.grafeas.v1beta1.provenance.BuildProvenance 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; - } - /** - * - * - *
-   * Provenance of a build. Contains all information needed to verify the full
-   * details about the build from source to completion.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.provenance.BuildProvenance} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.provenance.BuildProvenance) - io.grafeas.v1beta1.provenance.BuildProvenanceOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_BuildProvenance_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 12: - return internalGetBuildOptions(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 12: - return internalGetMutableBuildOptions(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_BuildProvenance_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.provenance.BuildProvenance.class, - io.grafeas.v1beta1.provenance.BuildProvenance.Builder.class); - } - - // Construct using io.grafeas.v1beta1.provenance.BuildProvenance.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getCommandsFieldBuilder(); - getBuiltArtifactsFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - id_ = ""; - - projectId_ = ""; - - if (commandsBuilder_ == null) { - commands_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - } else { - commandsBuilder_.clear(); - } - if (builtArtifactsBuilder_ == null) { - builtArtifacts_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - } else { - builtArtifactsBuilder_.clear(); - } - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (startTimeBuilder_ == null) { - startTime_ = null; - } else { - startTime_ = null; - startTimeBuilder_ = null; - } - if (endTimeBuilder_ == null) { - endTime_ = null; - } else { - endTime_ = null; - endTimeBuilder_ = null; - } - creator_ = ""; - - logsUri_ = ""; - - if (sourceProvenanceBuilder_ == null) { - sourceProvenance_ = null; - } else { - sourceProvenance_ = null; - sourceProvenanceBuilder_ = null; - } - triggerId_ = ""; - - internalGetMutableBuildOptions().clear(); - builderVersion_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_BuildProvenance_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.BuildProvenance getDefaultInstanceForType() { - return io.grafeas.v1beta1.provenance.BuildProvenance.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.BuildProvenance build() { - io.grafeas.v1beta1.provenance.BuildProvenance result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.BuildProvenance buildPartial() { - io.grafeas.v1beta1.provenance.BuildProvenance result = - new io.grafeas.v1beta1.provenance.BuildProvenance(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.id_ = id_; - result.projectId_ = projectId_; - if (commandsBuilder_ == null) { - if (((bitField0_ & 0x00000004) != 0)) { - commands_ = java.util.Collections.unmodifiableList(commands_); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.commands_ = commands_; - } else { - result.commands_ = commandsBuilder_.build(); - } - if (builtArtifactsBuilder_ == null) { - if (((bitField0_ & 0x00000008) != 0)) { - builtArtifacts_ = java.util.Collections.unmodifiableList(builtArtifacts_); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.builtArtifacts_ = builtArtifacts_; - } else { - result.builtArtifacts_ = builtArtifactsBuilder_.build(); - } - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (startTimeBuilder_ == null) { - result.startTime_ = startTime_; - } else { - result.startTime_ = startTimeBuilder_.build(); - } - if (endTimeBuilder_ == null) { - result.endTime_ = endTime_; - } else { - result.endTime_ = endTimeBuilder_.build(); - } - result.creator_ = creator_; - result.logsUri_ = logsUri_; - if (sourceProvenanceBuilder_ == null) { - result.sourceProvenance_ = sourceProvenance_; - } else { - result.sourceProvenance_ = sourceProvenanceBuilder_.build(); - } - result.triggerId_ = triggerId_; - result.buildOptions_ = internalGetBuildOptions(); - result.buildOptions_.makeImmutable(); - result.builderVersion_ = builderVersion_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.provenance.BuildProvenance) { - return mergeFrom((io.grafeas.v1beta1.provenance.BuildProvenance) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.provenance.BuildProvenance other) { - if (other == io.grafeas.v1beta1.provenance.BuildProvenance.getDefaultInstance()) return this; - if (!other.getId().isEmpty()) { - id_ = other.id_; - onChanged(); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (commandsBuilder_ == null) { - if (!other.commands_.isEmpty()) { - if (commands_.isEmpty()) { - commands_ = other.commands_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureCommandsIsMutable(); - commands_.addAll(other.commands_); - } - onChanged(); - } - } else { - if (!other.commands_.isEmpty()) { - if (commandsBuilder_.isEmpty()) { - commandsBuilder_.dispose(); - commandsBuilder_ = null; - commands_ = other.commands_; - bitField0_ = (bitField0_ & ~0x00000004); - commandsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getCommandsFieldBuilder() - : null; - } else { - commandsBuilder_.addAllMessages(other.commands_); - } - } - } - if (builtArtifactsBuilder_ == null) { - if (!other.builtArtifacts_.isEmpty()) { - if (builtArtifacts_.isEmpty()) { - builtArtifacts_ = other.builtArtifacts_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureBuiltArtifactsIsMutable(); - builtArtifacts_.addAll(other.builtArtifacts_); - } - onChanged(); - } - } else { - if (!other.builtArtifacts_.isEmpty()) { - if (builtArtifactsBuilder_.isEmpty()) { - builtArtifactsBuilder_.dispose(); - builtArtifactsBuilder_ = null; - builtArtifacts_ = other.builtArtifacts_; - bitField0_ = (bitField0_ & ~0x00000008); - builtArtifactsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getBuiltArtifactsFieldBuilder() - : null; - } else { - builtArtifactsBuilder_.addAllMessages(other.builtArtifacts_); - } - } - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasStartTime()) { - mergeStartTime(other.getStartTime()); - } - if (other.hasEndTime()) { - mergeEndTime(other.getEndTime()); - } - if (!other.getCreator().isEmpty()) { - creator_ = other.creator_; - onChanged(); - } - if (!other.getLogsUri().isEmpty()) { - logsUri_ = other.logsUri_; - onChanged(); - } - if (other.hasSourceProvenance()) { - mergeSourceProvenance(other.getSourceProvenance()); - } - if (!other.getTriggerId().isEmpty()) { - triggerId_ = other.triggerId_; - onChanged(); - } - internalGetMutableBuildOptions().mergeFrom(other.internalGetBuildOptions()); - if (!other.getBuilderVersion().isEmpty()) { - builderVersion_ = other.builderVersion_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.provenance.BuildProvenance parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.provenance.BuildProvenance) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object id_ = ""; - /** - * - * - *
-     * Unique identifier of the build.
-     * 
- * - * string id = 1; - */ - public java.lang.String getId() { - java.lang.Object ref = id_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Unique identifier of the build.
-     * 
- * - * string id = 1; - */ - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Unique identifier of the build.
-     * 
- * - * string id = 1; - */ - public Builder setId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - id_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Unique identifier of the build.
-     * 
- * - * string id = 1; - */ - public Builder clearId() { - - id_ = getDefaultInstance().getId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Unique identifier of the build.
-     * 
- * - * string id = 1; - */ - public Builder setIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - id_ = value; - onChanged(); - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * ID of the project.
-     * 
- * - * string project_id = 2; - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * ID of the project.
-     * 
- * - * string project_id = 2; - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * ID of the project.
-     * 
- * - * string project_id = 2; - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * ID of the project.
-     * 
- * - * string project_id = 2; - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * ID of the project.
-     * 
- * - * string project_id = 2; - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.util.List commands_ = - java.util.Collections.emptyList(); - - private void ensureCommandsIsMutable() { - if (!((bitField0_ & 0x00000004) != 0)) { - commands_ = new java.util.ArrayList(commands_); - bitField0_ |= 0x00000004; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.provenance.Command, - io.grafeas.v1beta1.provenance.Command.Builder, - io.grafeas.v1beta1.provenance.CommandOrBuilder> - commandsBuilder_; - - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public java.util.List getCommandsList() { - if (commandsBuilder_ == null) { - return java.util.Collections.unmodifiableList(commands_); - } else { - return commandsBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public int getCommandsCount() { - if (commandsBuilder_ == null) { - return commands_.size(); - } else { - return commandsBuilder_.getCount(); - } - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public io.grafeas.v1beta1.provenance.Command getCommands(int index) { - if (commandsBuilder_ == null) { - return commands_.get(index); - } else { - return commandsBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public Builder setCommands(int index, io.grafeas.v1beta1.provenance.Command value) { - if (commandsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCommandsIsMutable(); - commands_.set(index, value); - onChanged(); - } else { - commandsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public Builder setCommands( - int index, io.grafeas.v1beta1.provenance.Command.Builder builderForValue) { - if (commandsBuilder_ == null) { - ensureCommandsIsMutable(); - commands_.set(index, builderForValue.build()); - onChanged(); - } else { - commandsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public Builder addCommands(io.grafeas.v1beta1.provenance.Command value) { - if (commandsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCommandsIsMutable(); - commands_.add(value); - onChanged(); - } else { - commandsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public Builder addCommands(int index, io.grafeas.v1beta1.provenance.Command value) { - if (commandsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCommandsIsMutable(); - commands_.add(index, value); - onChanged(); - } else { - commandsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public Builder addCommands(io.grafeas.v1beta1.provenance.Command.Builder builderForValue) { - if (commandsBuilder_ == null) { - ensureCommandsIsMutable(); - commands_.add(builderForValue.build()); - onChanged(); - } else { - commandsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public Builder addCommands( - int index, io.grafeas.v1beta1.provenance.Command.Builder builderForValue) { - if (commandsBuilder_ == null) { - ensureCommandsIsMutable(); - commands_.add(index, builderForValue.build()); - onChanged(); - } else { - commandsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public Builder addAllCommands( - java.lang.Iterable values) { - if (commandsBuilder_ == null) { - ensureCommandsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, commands_); - onChanged(); - } else { - commandsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public Builder clearCommands() { - if (commandsBuilder_ == null) { - commands_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - } else { - commandsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public Builder removeCommands(int index) { - if (commandsBuilder_ == null) { - ensureCommandsIsMutable(); - commands_.remove(index); - onChanged(); - } else { - commandsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public io.grafeas.v1beta1.provenance.Command.Builder getCommandsBuilder(int index) { - return getCommandsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public io.grafeas.v1beta1.provenance.CommandOrBuilder getCommandsOrBuilder(int index) { - if (commandsBuilder_ == null) { - return commands_.get(index); - } else { - return commandsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public java.util.List - getCommandsOrBuilderList() { - if (commandsBuilder_ != null) { - return commandsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(commands_); - } - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public io.grafeas.v1beta1.provenance.Command.Builder addCommandsBuilder() { - return getCommandsFieldBuilder() - .addBuilder(io.grafeas.v1beta1.provenance.Command.getDefaultInstance()); - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public io.grafeas.v1beta1.provenance.Command.Builder addCommandsBuilder(int index) { - return getCommandsFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.provenance.Command.getDefaultInstance()); - } - /** - * - * - *
-     * Commands requested by the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - public java.util.List getCommandsBuilderList() { - return getCommandsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.provenance.Command, - io.grafeas.v1beta1.provenance.Command.Builder, - io.grafeas.v1beta1.provenance.CommandOrBuilder> - getCommandsFieldBuilder() { - if (commandsBuilder_ == null) { - commandsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.provenance.Command, - io.grafeas.v1beta1.provenance.Command.Builder, - io.grafeas.v1beta1.provenance.CommandOrBuilder>( - commands_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); - commands_ = null; - } - return commandsBuilder_; - } - - private java.util.List builtArtifacts_ = - java.util.Collections.emptyList(); - - private void ensureBuiltArtifactsIsMutable() { - if (!((bitField0_ & 0x00000008) != 0)) { - builtArtifacts_ = - new java.util.ArrayList(builtArtifacts_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.provenance.Artifact, - io.grafeas.v1beta1.provenance.Artifact.Builder, - io.grafeas.v1beta1.provenance.ArtifactOrBuilder> - builtArtifactsBuilder_; - - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public java.util.List getBuiltArtifactsList() { - if (builtArtifactsBuilder_ == null) { - return java.util.Collections.unmodifiableList(builtArtifacts_); - } else { - return builtArtifactsBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public int getBuiltArtifactsCount() { - if (builtArtifactsBuilder_ == null) { - return builtArtifacts_.size(); - } else { - return builtArtifactsBuilder_.getCount(); - } - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public io.grafeas.v1beta1.provenance.Artifact getBuiltArtifacts(int index) { - if (builtArtifactsBuilder_ == null) { - return builtArtifacts_.get(index); - } else { - return builtArtifactsBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public Builder setBuiltArtifacts(int index, io.grafeas.v1beta1.provenance.Artifact value) { - if (builtArtifactsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBuiltArtifactsIsMutable(); - builtArtifacts_.set(index, value); - onChanged(); - } else { - builtArtifactsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public Builder setBuiltArtifacts( - int index, io.grafeas.v1beta1.provenance.Artifact.Builder builderForValue) { - if (builtArtifactsBuilder_ == null) { - ensureBuiltArtifactsIsMutable(); - builtArtifacts_.set(index, builderForValue.build()); - onChanged(); - } else { - builtArtifactsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public Builder addBuiltArtifacts(io.grafeas.v1beta1.provenance.Artifact value) { - if (builtArtifactsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBuiltArtifactsIsMutable(); - builtArtifacts_.add(value); - onChanged(); - } else { - builtArtifactsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public Builder addBuiltArtifacts(int index, io.grafeas.v1beta1.provenance.Artifact value) { - if (builtArtifactsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBuiltArtifactsIsMutable(); - builtArtifacts_.add(index, value); - onChanged(); - } else { - builtArtifactsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public Builder addBuiltArtifacts( - io.grafeas.v1beta1.provenance.Artifact.Builder builderForValue) { - if (builtArtifactsBuilder_ == null) { - ensureBuiltArtifactsIsMutable(); - builtArtifacts_.add(builderForValue.build()); - onChanged(); - } else { - builtArtifactsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public Builder addBuiltArtifacts( - int index, io.grafeas.v1beta1.provenance.Artifact.Builder builderForValue) { - if (builtArtifactsBuilder_ == null) { - ensureBuiltArtifactsIsMutable(); - builtArtifacts_.add(index, builderForValue.build()); - onChanged(); - } else { - builtArtifactsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public Builder addAllBuiltArtifacts( - java.lang.Iterable values) { - if (builtArtifactsBuilder_ == null) { - ensureBuiltArtifactsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, builtArtifacts_); - onChanged(); - } else { - builtArtifactsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public Builder clearBuiltArtifacts() { - if (builtArtifactsBuilder_ == null) { - builtArtifacts_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - builtArtifactsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public Builder removeBuiltArtifacts(int index) { - if (builtArtifactsBuilder_ == null) { - ensureBuiltArtifactsIsMutable(); - builtArtifacts_.remove(index); - onChanged(); - } else { - builtArtifactsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public io.grafeas.v1beta1.provenance.Artifact.Builder getBuiltArtifactsBuilder(int index) { - return getBuiltArtifactsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public io.grafeas.v1beta1.provenance.ArtifactOrBuilder getBuiltArtifactsOrBuilder(int index) { - if (builtArtifactsBuilder_ == null) { - return builtArtifacts_.get(index); - } else { - return builtArtifactsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public java.util.List - getBuiltArtifactsOrBuilderList() { - if (builtArtifactsBuilder_ != null) { - return builtArtifactsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(builtArtifacts_); - } - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public io.grafeas.v1beta1.provenance.Artifact.Builder addBuiltArtifactsBuilder() { - return getBuiltArtifactsFieldBuilder() - .addBuilder(io.grafeas.v1beta1.provenance.Artifact.getDefaultInstance()); - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public io.grafeas.v1beta1.provenance.Artifact.Builder addBuiltArtifactsBuilder(int index) { - return getBuiltArtifactsFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.provenance.Artifact.getDefaultInstance()); - } - /** - * - * - *
-     * Output of the build.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - public java.util.List - getBuiltArtifactsBuilderList() { - return getBuiltArtifactsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.provenance.Artifact, - io.grafeas.v1beta1.provenance.Artifact.Builder, - io.grafeas.v1beta1.provenance.ArtifactOrBuilder> - getBuiltArtifactsFieldBuilder() { - if (builtArtifactsBuilder_ == null) { - builtArtifactsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.provenance.Artifact, - io.grafeas.v1beta1.provenance.Artifact.Builder, - io.grafeas.v1beta1.provenance.ArtifactOrBuilder>( - builtArtifacts_, - ((bitField0_ & 0x00000008) != 0), - getParentForChildren(), - isClean()); - builtArtifacts_ = null; - } - return builtArtifactsBuilder_; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-     * Time at which the build was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-     * Time at which the build was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Time at which the build was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - 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; - } - /** - * - * - *
-     * Time at which the build was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Time at which the build was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - 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; - } - /** - * - * - *
-     * Time at which the build was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Time at which the build was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Time at which the build was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-     * Time at which the build was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - 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 startTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - startTimeBuilder_; - /** - * - * - *
-     * Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - public boolean hasStartTime() { - return startTimeBuilder_ != null || startTime_ != null; - } - /** - * - * - *
-     * Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - public com.google.protobuf.Timestamp getStartTime() { - if (startTimeBuilder_ == null) { - return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; - } else { - return startTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - public Builder setStartTime(com.google.protobuf.Timestamp value) { - if (startTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - startTime_ = value; - onChanged(); - } else { - startTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - public Builder setStartTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (startTimeBuilder_ == null) { - startTime_ = builderForValue.build(); - onChanged(); - } else { - startTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - public Builder mergeStartTime(com.google.protobuf.Timestamp value) { - if (startTimeBuilder_ == null) { - if (startTime_ != null) { - startTime_ = - com.google.protobuf.Timestamp.newBuilder(startTime_).mergeFrom(value).buildPartial(); - } else { - startTime_ = value; - } - onChanged(); - } else { - startTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - public Builder clearStartTime() { - if (startTimeBuilder_ == null) { - startTime_ = null; - onChanged(); - } else { - startTime_ = null; - startTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - public com.google.protobuf.Timestamp.Builder getStartTimeBuilder() { - - onChanged(); - return getStartTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { - if (startTimeBuilder_ != null) { - return startTimeBuilder_.getMessageOrBuilder(); - } else { - return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; - } - } - /** - * - * - *
-     * Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getStartTimeFieldBuilder() { - if (startTimeBuilder_ == null) { - startTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getStartTime(), getParentForChildren(), isClean()); - startTime_ = null; - } - return startTimeBuilder_; - } - - private com.google.protobuf.Timestamp endTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - endTimeBuilder_; - /** - * - * - *
-     * Time at which execution of the build was finished.
-     * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - public boolean hasEndTime() { - return endTimeBuilder_ != null || endTime_ != null; - } - /** - * - * - *
-     * Time at which execution of the build was finished.
-     * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - public com.google.protobuf.Timestamp getEndTime() { - if (endTimeBuilder_ == null) { - return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; - } else { - return endTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Time at which execution of the build was finished.
-     * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - public Builder setEndTime(com.google.protobuf.Timestamp value) { - if (endTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - endTime_ = value; - onChanged(); - } else { - endTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Time at which execution of the build was finished.
-     * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - public Builder setEndTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (endTimeBuilder_ == null) { - endTime_ = builderForValue.build(); - onChanged(); - } else { - endTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Time at which execution of the build was finished.
-     * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - public Builder mergeEndTime(com.google.protobuf.Timestamp value) { - if (endTimeBuilder_ == null) { - if (endTime_ != null) { - endTime_ = - com.google.protobuf.Timestamp.newBuilder(endTime_).mergeFrom(value).buildPartial(); - } else { - endTime_ = value; - } - onChanged(); - } else { - endTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Time at which execution of the build was finished.
-     * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - public Builder clearEndTime() { - if (endTimeBuilder_ == null) { - endTime_ = null; - onChanged(); - } else { - endTime_ = null; - endTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Time at which execution of the build was finished.
-     * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - public com.google.protobuf.Timestamp.Builder getEndTimeBuilder() { - - onChanged(); - return getEndTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Time at which execution of the build was finished.
-     * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { - if (endTimeBuilder_ != null) { - return endTimeBuilder_.getMessageOrBuilder(); - } else { - return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; - } - } - /** - * - * - *
-     * Time at which execution of the build was finished.
-     * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getEndTimeFieldBuilder() { - if (endTimeBuilder_ == null) { - endTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getEndTime(), getParentForChildren(), isClean()); - endTime_ = null; - } - return endTimeBuilder_; - } - - private java.lang.Object creator_ = ""; - /** - * - * - *
-     * E-mail address of the user who initiated this build. Note that this was the
-     * user's e-mail address at the time the build was initiated; this address may
-     * not represent the same end-user for all time.
-     * 
- * - * string creator = 8; - */ - public java.lang.String getCreator() { - java.lang.Object ref = creator_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - creator_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * E-mail address of the user who initiated this build. Note that this was the
-     * user's e-mail address at the time the build was initiated; this address may
-     * not represent the same end-user for all time.
-     * 
- * - * string creator = 8; - */ - public com.google.protobuf.ByteString getCreatorBytes() { - java.lang.Object ref = creator_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - creator_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * E-mail address of the user who initiated this build. Note that this was the
-     * user's e-mail address at the time the build was initiated; this address may
-     * not represent the same end-user for all time.
-     * 
- * - * string creator = 8; - */ - public Builder setCreator(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - creator_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * E-mail address of the user who initiated this build. Note that this was the
-     * user's e-mail address at the time the build was initiated; this address may
-     * not represent the same end-user for all time.
-     * 
- * - * string creator = 8; - */ - public Builder clearCreator() { - - creator_ = getDefaultInstance().getCreator(); - onChanged(); - return this; - } - /** - * - * - *
-     * E-mail address of the user who initiated this build. Note that this was the
-     * user's e-mail address at the time the build was initiated; this address may
-     * not represent the same end-user for all time.
-     * 
- * - * string creator = 8; - */ - public Builder setCreatorBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - creator_ = value; - onChanged(); - return this; - } - - private java.lang.Object logsUri_ = ""; - /** - * - * - *
-     * URI where any logs for this provenance were written.
-     * 
- * - * string logs_uri = 9; - */ - public java.lang.String getLogsUri() { - java.lang.Object ref = logsUri_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - logsUri_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * URI where any logs for this provenance were written.
-     * 
- * - * string logs_uri = 9; - */ - public com.google.protobuf.ByteString getLogsUriBytes() { - java.lang.Object ref = logsUri_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - logsUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * URI where any logs for this provenance were written.
-     * 
- * - * string logs_uri = 9; - */ - public Builder setLogsUri(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - logsUri_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * URI where any logs for this provenance were written.
-     * 
- * - * string logs_uri = 9; - */ - public Builder clearLogsUri() { - - logsUri_ = getDefaultInstance().getLogsUri(); - onChanged(); - return this; - } - /** - * - * - *
-     * URI where any logs for this provenance were written.
-     * 
- * - * string logs_uri = 9; - */ - public Builder setLogsUriBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - logsUri_ = value; - onChanged(); - return this; - } - - private io.grafeas.v1beta1.provenance.Source sourceProvenance_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.provenance.Source, - io.grafeas.v1beta1.provenance.Source.Builder, - io.grafeas.v1beta1.provenance.SourceOrBuilder> - sourceProvenanceBuilder_; - /** - * - * - *
-     * Details of the Source input to the build.
-     * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - public boolean hasSourceProvenance() { - return sourceProvenanceBuilder_ != null || sourceProvenance_ != null; - } - /** - * - * - *
-     * Details of the Source input to the build.
-     * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - public io.grafeas.v1beta1.provenance.Source getSourceProvenance() { - if (sourceProvenanceBuilder_ == null) { - return sourceProvenance_ == null - ? io.grafeas.v1beta1.provenance.Source.getDefaultInstance() - : sourceProvenance_; - } else { - return sourceProvenanceBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Details of the Source input to the build.
-     * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - public Builder setSourceProvenance(io.grafeas.v1beta1.provenance.Source value) { - if (sourceProvenanceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - sourceProvenance_ = value; - onChanged(); - } else { - sourceProvenanceBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Details of the Source input to the build.
-     * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - public Builder setSourceProvenance( - io.grafeas.v1beta1.provenance.Source.Builder builderForValue) { - if (sourceProvenanceBuilder_ == null) { - sourceProvenance_ = builderForValue.build(); - onChanged(); - } else { - sourceProvenanceBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Details of the Source input to the build.
-     * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - public Builder mergeSourceProvenance(io.grafeas.v1beta1.provenance.Source value) { - if (sourceProvenanceBuilder_ == null) { - if (sourceProvenance_ != null) { - sourceProvenance_ = - io.grafeas.v1beta1.provenance.Source.newBuilder(sourceProvenance_) - .mergeFrom(value) - .buildPartial(); - } else { - sourceProvenance_ = value; - } - onChanged(); - } else { - sourceProvenanceBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Details of the Source input to the build.
-     * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - public Builder clearSourceProvenance() { - if (sourceProvenanceBuilder_ == null) { - sourceProvenance_ = null; - onChanged(); - } else { - sourceProvenance_ = null; - sourceProvenanceBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Details of the Source input to the build.
-     * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - public io.grafeas.v1beta1.provenance.Source.Builder getSourceProvenanceBuilder() { - - onChanged(); - return getSourceProvenanceFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Details of the Source input to the build.
-     * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - public io.grafeas.v1beta1.provenance.SourceOrBuilder getSourceProvenanceOrBuilder() { - if (sourceProvenanceBuilder_ != null) { - return sourceProvenanceBuilder_.getMessageOrBuilder(); - } else { - return sourceProvenance_ == null - ? io.grafeas.v1beta1.provenance.Source.getDefaultInstance() - : sourceProvenance_; - } - } - /** - * - * - *
-     * Details of the Source input to the build.
-     * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.provenance.Source, - io.grafeas.v1beta1.provenance.Source.Builder, - io.grafeas.v1beta1.provenance.SourceOrBuilder> - getSourceProvenanceFieldBuilder() { - if (sourceProvenanceBuilder_ == null) { - sourceProvenanceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.provenance.Source, - io.grafeas.v1beta1.provenance.Source.Builder, - io.grafeas.v1beta1.provenance.SourceOrBuilder>( - getSourceProvenance(), getParentForChildren(), isClean()); - sourceProvenance_ = null; - } - return sourceProvenanceBuilder_; - } - - private java.lang.Object triggerId_ = ""; - /** - * - * - *
-     * Trigger identifier if the build was triggered automatically; empty if not.
-     * 
- * - * string trigger_id = 11; - */ - public java.lang.String getTriggerId() { - java.lang.Object ref = triggerId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - triggerId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Trigger identifier if the build was triggered automatically; empty if not.
-     * 
- * - * string trigger_id = 11; - */ - public com.google.protobuf.ByteString getTriggerIdBytes() { - java.lang.Object ref = triggerId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - triggerId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Trigger identifier if the build was triggered automatically; empty if not.
-     * 
- * - * string trigger_id = 11; - */ - public Builder setTriggerId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - triggerId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Trigger identifier if the build was triggered automatically; empty if not.
-     * 
- * - * string trigger_id = 11; - */ - public Builder clearTriggerId() { - - triggerId_ = getDefaultInstance().getTriggerId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Trigger identifier if the build was triggered automatically; empty if not.
-     * 
- * - * string trigger_id = 11; - */ - public Builder setTriggerIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - triggerId_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.MapField buildOptions_; - - private com.google.protobuf.MapField - internalGetBuildOptions() { - if (buildOptions_ == null) { - return com.google.protobuf.MapField.emptyMapField( - BuildOptionsDefaultEntryHolder.defaultEntry); - } - return buildOptions_; - } - - private com.google.protobuf.MapField - internalGetMutableBuildOptions() { - onChanged(); - ; - if (buildOptions_ == null) { - buildOptions_ = - com.google.protobuf.MapField.newMapField(BuildOptionsDefaultEntryHolder.defaultEntry); - } - if (!buildOptions_.isMutable()) { - buildOptions_ = buildOptions_.copy(); - } - return buildOptions_; - } - - public int getBuildOptionsCount() { - return internalGetBuildOptions().getMap().size(); - } - /** - * - * - *
-     * Special options applied to this build. This is a catch-all field where
-     * build providers can enter any desired additional details.
-     * 
- * - * map<string, string> build_options = 12; - */ - public boolean containsBuildOptions(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - return internalGetBuildOptions().getMap().containsKey(key); - } - /** Use {@link #getBuildOptionsMap()} instead. */ - @java.lang.Deprecated - public java.util.Map getBuildOptions() { - return getBuildOptionsMap(); - } - /** - * - * - *
-     * Special options applied to this build. This is a catch-all field where
-     * build providers can enter any desired additional details.
-     * 
- * - * map<string, string> build_options = 12; - */ - public java.util.Map getBuildOptionsMap() { - return internalGetBuildOptions().getMap(); - } - /** - * - * - *
-     * Special options applied to this build. This is a catch-all field where
-     * build providers can enter any desired additional details.
-     * 
- * - * map<string, string> build_options = 12; - */ - public java.lang.String getBuildOptionsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetBuildOptions().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * Special options applied to this build. This is a catch-all field where
-     * build providers can enter any desired additional details.
-     * 
- * - * map<string, string> build_options = 12; - */ - public java.lang.String getBuildOptionsOrThrow(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetBuildOptions().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearBuildOptions() { - internalGetMutableBuildOptions().getMutableMap().clear(); - return this; - } - /** - * - * - *
-     * Special options applied to this build. This is a catch-all field where
-     * build providers can enter any desired additional details.
-     * 
- * - * map<string, string> build_options = 12; - */ - public Builder removeBuildOptions(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - internalGetMutableBuildOptions().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map getMutableBuildOptions() { - return internalGetMutableBuildOptions().getMutableMap(); - } - /** - * - * - *
-     * Special options applied to this build. This is a catch-all field where
-     * build providers can enter any desired additional details.
-     * 
- * - * map<string, string> build_options = 12; - */ - public Builder putBuildOptions(java.lang.String key, java.lang.String value) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - if (value == null) { - throw new java.lang.NullPointerException(); - } - internalGetMutableBuildOptions().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-     * Special options applied to this build. This is a catch-all field where
-     * build providers can enter any desired additional details.
-     * 
- * - * map<string, string> build_options = 12; - */ - public Builder putAllBuildOptions(java.util.Map values) { - internalGetMutableBuildOptions().getMutableMap().putAll(values); - return this; - } - - private java.lang.Object builderVersion_ = ""; - /** - * - * - *
-     * Version string of the builder at the time this build was executed.
-     * 
- * - * string builder_version = 13; - */ - public java.lang.String getBuilderVersion() { - java.lang.Object ref = builderVersion_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - builderVersion_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Version string of the builder at the time this build was executed.
-     * 
- * - * string builder_version = 13; - */ - public com.google.protobuf.ByteString getBuilderVersionBytes() { - java.lang.Object ref = builderVersion_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - builderVersion_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Version string of the builder at the time this build was executed.
-     * 
- * - * string builder_version = 13; - */ - public Builder setBuilderVersion(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - builderVersion_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Version string of the builder at the time this build was executed.
-     * 
- * - * string builder_version = 13; - */ - public Builder clearBuilderVersion() { - - builderVersion_ = getDefaultInstance().getBuilderVersion(); - onChanged(); - return this; - } - /** - * - * - *
-     * Version string of the builder at the time this build was executed.
-     * 
- * - * string builder_version = 13; - */ - public Builder setBuilderVersionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - builderVersion_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.provenance.BuildProvenance) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.provenance.BuildProvenance) - private static final io.grafeas.v1beta1.provenance.BuildProvenance DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.provenance.BuildProvenance(); - } - - public static io.grafeas.v1beta1.provenance.BuildProvenance getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BuildProvenance parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new BuildProvenance(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.BuildProvenance getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/BuildProvenanceOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/BuildProvenanceOrBuilder.java deleted file mode 100644 index 79646c70..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/BuildProvenanceOrBuilder.java +++ /dev/null @@ -1,427 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -public interface BuildProvenanceOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.provenance.BuildProvenance) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Unique identifier of the build.
-   * 
- * - * string id = 1; - */ - java.lang.String getId(); - /** - * - * - *
-   * Unique identifier of the build.
-   * 
- * - * string id = 1; - */ - com.google.protobuf.ByteString getIdBytes(); - - /** - * - * - *
-   * ID of the project.
-   * 
- * - * string project_id = 2; - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * ID of the project.
-   * 
- * - * string project_id = 2; - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Commands requested by the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - java.util.List getCommandsList(); - /** - * - * - *
-   * Commands requested by the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - io.grafeas.v1beta1.provenance.Command getCommands(int index); - /** - * - * - *
-   * Commands requested by the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - int getCommandsCount(); - /** - * - * - *
-   * Commands requested by the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - java.util.List - getCommandsOrBuilderList(); - /** - * - * - *
-   * Commands requested by the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Command commands = 3; - */ - io.grafeas.v1beta1.provenance.CommandOrBuilder getCommandsOrBuilder(int index); - - /** - * - * - *
-   * Output of the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - java.util.List getBuiltArtifactsList(); - /** - * - * - *
-   * Output of the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - io.grafeas.v1beta1.provenance.Artifact getBuiltArtifacts(int index); - /** - * - * - *
-   * Output of the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - int getBuiltArtifactsCount(); - /** - * - * - *
-   * Output of the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - java.util.List - getBuiltArtifactsOrBuilderList(); - /** - * - * - *
-   * Output of the build.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Artifact built_artifacts = 4; - */ - io.grafeas.v1beta1.provenance.ArtifactOrBuilder getBuiltArtifactsOrBuilder(int index); - - /** - * - * - *
-   * Time at which the build was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - boolean hasCreateTime(); - /** - * - * - *
-   * Time at which the build was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-   * Time at which the build was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-   * Time at which execution of the build was started.
-   * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - boolean hasStartTime(); - /** - * - * - *
-   * Time at which execution of the build was started.
-   * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - com.google.protobuf.Timestamp getStartTime(); - /** - * - * - *
-   * Time at which execution of the build was started.
-   * 
- * - * .google.protobuf.Timestamp start_time = 6; - */ - com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder(); - - /** - * - * - *
-   * Time at which execution of the build was finished.
-   * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - boolean hasEndTime(); - /** - * - * - *
-   * Time at which execution of the build was finished.
-   * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - com.google.protobuf.Timestamp getEndTime(); - /** - * - * - *
-   * Time at which execution of the build was finished.
-   * 
- * - * .google.protobuf.Timestamp end_time = 7; - */ - com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder(); - - /** - * - * - *
-   * E-mail address of the user who initiated this build. Note that this was the
-   * user's e-mail address at the time the build was initiated; this address may
-   * not represent the same end-user for all time.
-   * 
- * - * string creator = 8; - */ - java.lang.String getCreator(); - /** - * - * - *
-   * E-mail address of the user who initiated this build. Note that this was the
-   * user's e-mail address at the time the build was initiated; this address may
-   * not represent the same end-user for all time.
-   * 
- * - * string creator = 8; - */ - com.google.protobuf.ByteString getCreatorBytes(); - - /** - * - * - *
-   * URI where any logs for this provenance were written.
-   * 
- * - * string logs_uri = 9; - */ - java.lang.String getLogsUri(); - /** - * - * - *
-   * URI where any logs for this provenance were written.
-   * 
- * - * string logs_uri = 9; - */ - com.google.protobuf.ByteString getLogsUriBytes(); - - /** - * - * - *
-   * Details of the Source input to the build.
-   * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - boolean hasSourceProvenance(); - /** - * - * - *
-   * Details of the Source input to the build.
-   * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - io.grafeas.v1beta1.provenance.Source getSourceProvenance(); - /** - * - * - *
-   * Details of the Source input to the build.
-   * 
- * - * .grafeas.v1beta1.provenance.Source source_provenance = 10; - */ - io.grafeas.v1beta1.provenance.SourceOrBuilder getSourceProvenanceOrBuilder(); - - /** - * - * - *
-   * Trigger identifier if the build was triggered automatically; empty if not.
-   * 
- * - * string trigger_id = 11; - */ - java.lang.String getTriggerId(); - /** - * - * - *
-   * Trigger identifier if the build was triggered automatically; empty if not.
-   * 
- * - * string trigger_id = 11; - */ - com.google.protobuf.ByteString getTriggerIdBytes(); - - /** - * - * - *
-   * Special options applied to this build. This is a catch-all field where
-   * build providers can enter any desired additional details.
-   * 
- * - * map<string, string> build_options = 12; - */ - int getBuildOptionsCount(); - /** - * - * - *
-   * Special options applied to this build. This is a catch-all field where
-   * build providers can enter any desired additional details.
-   * 
- * - * map<string, string> build_options = 12; - */ - boolean containsBuildOptions(java.lang.String key); - /** Use {@link #getBuildOptionsMap()} instead. */ - @java.lang.Deprecated - java.util.Map getBuildOptions(); - /** - * - * - *
-   * Special options applied to this build. This is a catch-all field where
-   * build providers can enter any desired additional details.
-   * 
- * - * map<string, string> build_options = 12; - */ - java.util.Map getBuildOptionsMap(); - /** - * - * - *
-   * Special options applied to this build. This is a catch-all field where
-   * build providers can enter any desired additional details.
-   * 
- * - * map<string, string> build_options = 12; - */ - java.lang.String getBuildOptionsOrDefault(java.lang.String key, java.lang.String defaultValue); - /** - * - * - *
-   * Special options applied to this build. This is a catch-all field where
-   * build providers can enter any desired additional details.
-   * 
- * - * map<string, string> build_options = 12; - */ - java.lang.String getBuildOptionsOrThrow(java.lang.String key); - - /** - * - * - *
-   * Version string of the builder at the time this build was executed.
-   * 
- * - * string builder_version = 13; - */ - java.lang.String getBuilderVersion(); - /** - * - * - *
-   * Version string of the builder at the time this build was executed.
-   * 
- * - * string builder_version = 13; - */ - com.google.protobuf.ByteString getBuilderVersionBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Command.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Command.java deleted file mode 100644 index cc3da421..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Command.java +++ /dev/null @@ -1,1665 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -/** - * - * - *
- * Command describes a step performed as part of the build pipeline.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.provenance.Command} - */ -public final class Command extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.provenance.Command) - CommandOrBuilder { - private static final long serialVersionUID = 0L; - // Use Command.newBuilder() to construct. - private Command(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Command() { - name_ = ""; - env_ = com.google.protobuf.LazyStringArrayList.EMPTY; - args_ = com.google.protobuf.LazyStringArrayList.EMPTY; - dir_ = ""; - id_ = ""; - waitFor_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Command( - 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(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - env_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; - } - env_.add(s); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000004) != 0)) { - args_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000004; - } - args_.add(s); - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - dir_ = s; - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - id_ = s; - break; - } - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000020) != 0)) { - waitFor_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000020; - } - waitFor_.add(s); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000002) != 0)) { - env_ = env_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000004) != 0)) { - args_ = args_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000020) != 0)) { - waitFor_ = waitFor_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Command_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Command_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.provenance.Command.class, - io.grafeas.v1beta1.provenance.Command.Builder.class); - } - - private int bitField0_; - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Name of the command, as presented on the command line, or if the command is
-   * packaged as a Docker container, as presented to `docker pull`.
-   * 
- * - * 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; - } - } - /** - * - * - *
-   * Name of the command, as presented on the command line, or if the command is
-   * packaged as a Docker container, as presented to `docker pull`.
-   * 
- * - * 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 ENV_FIELD_NUMBER = 2; - private com.google.protobuf.LazyStringList env_; - /** - * - * - *
-   * Environment variables set before running this command.
-   * 
- * - * repeated string env = 2; - */ - public com.google.protobuf.ProtocolStringList getEnvList() { - return env_; - } - /** - * - * - *
-   * Environment variables set before running this command.
-   * 
- * - * repeated string env = 2; - */ - public int getEnvCount() { - return env_.size(); - } - /** - * - * - *
-   * Environment variables set before running this command.
-   * 
- * - * repeated string env = 2; - */ - public java.lang.String getEnv(int index) { - return env_.get(index); - } - /** - * - * - *
-   * Environment variables set before running this command.
-   * 
- * - * repeated string env = 2; - */ - public com.google.protobuf.ByteString getEnvBytes(int index) { - return env_.getByteString(index); - } - - public static final int ARGS_FIELD_NUMBER = 3; - private com.google.protobuf.LazyStringList args_; - /** - * - * - *
-   * Command-line arguments used when executing this command.
-   * 
- * - * repeated string args = 3; - */ - public com.google.protobuf.ProtocolStringList getArgsList() { - return args_; - } - /** - * - * - *
-   * Command-line arguments used when executing this command.
-   * 
- * - * repeated string args = 3; - */ - public int getArgsCount() { - return args_.size(); - } - /** - * - * - *
-   * Command-line arguments used when executing this command.
-   * 
- * - * repeated string args = 3; - */ - public java.lang.String getArgs(int index) { - return args_.get(index); - } - /** - * - * - *
-   * Command-line arguments used when executing this command.
-   * 
- * - * repeated string args = 3; - */ - public com.google.protobuf.ByteString getArgsBytes(int index) { - return args_.getByteString(index); - } - - public static final int DIR_FIELD_NUMBER = 4; - private volatile java.lang.Object dir_; - /** - * - * - *
-   * Working directory (relative to project source root) used when running this
-   * command.
-   * 
- * - * string dir = 4; - */ - public java.lang.String getDir() { - java.lang.Object ref = dir_; - 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(); - dir_ = s; - return s; - } - } - /** - * - * - *
-   * Working directory (relative to project source root) used when running this
-   * command.
-   * 
- * - * string dir = 4; - */ - public com.google.protobuf.ByteString getDirBytes() { - java.lang.Object ref = dir_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - dir_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ID_FIELD_NUMBER = 5; - private volatile java.lang.Object id_; - /** - * - * - *
-   * Optional unique identifier for this command, used in wait_for to reference
-   * this command as a dependency.
-   * 
- * - * string id = 5; - */ - public java.lang.String getId() { - java.lang.Object ref = id_; - 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(); - id_ = s; - return s; - } - } - /** - * - * - *
-   * Optional unique identifier for this command, used in wait_for to reference
-   * this command as a dependency.
-   * 
- * - * string id = 5; - */ - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int WAIT_FOR_FIELD_NUMBER = 6; - private com.google.protobuf.LazyStringList waitFor_; - /** - * - * - *
-   * The ID(s) of the command(s) that this command depends on.
-   * 
- * - * repeated string wait_for = 6; - */ - public com.google.protobuf.ProtocolStringList getWaitForList() { - return waitFor_; - } - /** - * - * - *
-   * The ID(s) of the command(s) that this command depends on.
-   * 
- * - * repeated string wait_for = 6; - */ - public int getWaitForCount() { - return waitFor_.size(); - } - /** - * - * - *
-   * The ID(s) of the command(s) that this command depends on.
-   * 
- * - * repeated string wait_for = 6; - */ - public java.lang.String getWaitFor(int index) { - return waitFor_.get(index); - } - /** - * - * - *
-   * The ID(s) of the command(s) that this command depends on.
-   * 
- * - * repeated string wait_for = 6; - */ - public com.google.protobuf.ByteString getWaitForBytes(int index) { - return waitFor_.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 (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - for (int i = 0; i < env_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, env_.getRaw(i)); - } - for (int i = 0; i < args_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, args_.getRaw(i)); - } - if (!getDirBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, dir_); - } - if (!getIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, id_); - } - for (int i = 0; i < waitFor_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 6, waitFor_.getRaw(i)); - } - 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_); - } - { - int dataSize = 0; - for (int i = 0; i < env_.size(); i++) { - dataSize += computeStringSizeNoTag(env_.getRaw(i)); - } - size += dataSize; - size += 1 * getEnvList().size(); - } - { - int dataSize = 0; - for (int i = 0; i < args_.size(); i++) { - dataSize += computeStringSizeNoTag(args_.getRaw(i)); - } - size += dataSize; - size += 1 * getArgsList().size(); - } - if (!getDirBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, dir_); - } - if (!getIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, id_); - } - { - int dataSize = 0; - for (int i = 0; i < waitFor_.size(); i++) { - dataSize += computeStringSizeNoTag(waitFor_.getRaw(i)); - } - size += dataSize; - size += 1 * getWaitForList().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 io.grafeas.v1beta1.provenance.Command)) { - return super.equals(obj); - } - io.grafeas.v1beta1.provenance.Command other = (io.grafeas.v1beta1.provenance.Command) obj; - - if (!getName().equals(other.getName())) return false; - if (!getEnvList().equals(other.getEnvList())) return false; - if (!getArgsList().equals(other.getArgsList())) return false; - if (!getDir().equals(other.getDir())) return false; - if (!getId().equals(other.getId())) return false; - if (!getWaitForList().equals(other.getWaitForList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - if (getEnvCount() > 0) { - hash = (37 * hash) + ENV_FIELD_NUMBER; - hash = (53 * hash) + getEnvList().hashCode(); - } - if (getArgsCount() > 0) { - hash = (37 * hash) + ARGS_FIELD_NUMBER; - hash = (53 * hash) + getArgsList().hashCode(); - } - hash = (37 * hash) + DIR_FIELD_NUMBER; - hash = (53 * hash) + getDir().hashCode(); - hash = (37 * hash) + ID_FIELD_NUMBER; - hash = (53 * hash) + getId().hashCode(); - if (getWaitForCount() > 0) { - hash = (37 * hash) + WAIT_FOR_FIELD_NUMBER; - hash = (53 * hash) + getWaitForList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.provenance.Command parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.Command parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.Command parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.Command parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.Command parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.Command parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.Command parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.Command 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 io.grafeas.v1beta1.provenance.Command parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.Command 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 io.grafeas.v1beta1.provenance.Command parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.Command 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(io.grafeas.v1beta1.provenance.Command 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; - } - /** - * - * - *
-   * Command describes a step performed as part of the build pipeline.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.provenance.Command} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.provenance.Command) - io.grafeas.v1beta1.provenance.CommandOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Command_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Command_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.provenance.Command.class, - io.grafeas.v1beta1.provenance.Command.Builder.class); - } - - // Construct using io.grafeas.v1beta1.provenance.Command.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - env_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - args_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000004); - dir_ = ""; - - id_ = ""; - - waitFor_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000020); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Command_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Command getDefaultInstanceForType() { - return io.grafeas.v1beta1.provenance.Command.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Command build() { - io.grafeas.v1beta1.provenance.Command result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Command buildPartial() { - io.grafeas.v1beta1.provenance.Command result = - new io.grafeas.v1beta1.provenance.Command(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.name_ = name_; - if (((bitField0_ & 0x00000002) != 0)) { - env_ = env_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.env_ = env_; - if (((bitField0_ & 0x00000004) != 0)) { - args_ = args_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.args_ = args_; - result.dir_ = dir_; - result.id_ = id_; - if (((bitField0_ & 0x00000020) != 0)) { - waitFor_ = waitFor_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000020); - } - result.waitFor_ = waitFor_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.provenance.Command) { - return mergeFrom((io.grafeas.v1beta1.provenance.Command) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.provenance.Command other) { - if (other == io.grafeas.v1beta1.provenance.Command.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.env_.isEmpty()) { - if (env_.isEmpty()) { - env_ = other.env_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureEnvIsMutable(); - env_.addAll(other.env_); - } - onChanged(); - } - if (!other.args_.isEmpty()) { - if (args_.isEmpty()) { - args_ = other.args_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureArgsIsMutable(); - args_.addAll(other.args_); - } - onChanged(); - } - if (!other.getDir().isEmpty()) { - dir_ = other.dir_; - onChanged(); - } - if (!other.getId().isEmpty()) { - id_ = other.id_; - onChanged(); - } - if (!other.waitFor_.isEmpty()) { - if (waitFor_.isEmpty()) { - waitFor_ = other.waitFor_; - bitField0_ = (bitField0_ & ~0x00000020); - } else { - ensureWaitForIsMutable(); - waitFor_.addAll(other.waitFor_); - } - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.provenance.Command parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.provenance.Command) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Name of the command, as presented on the command line, or if the command is
-     * packaged as a Docker container, as presented to `docker pull`.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * Name of the command, as presented on the command line, or if the command is
-     * packaged as a Docker container, as presented to `docker pull`.
-     * 
- * - * 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; - } - } - /** - * - * - *
-     * Name of the command, as presented on the command line, or if the command is
-     * packaged as a Docker container, as presented to `docker pull`.
-     * 
- * - * string name = 1; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Name of the command, as presented on the command line, or if the command is
-     * packaged as a Docker container, as presented to `docker pull`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Name of the command, as presented on the command line, or if the command is
-     * packaged as a Docker container, as presented to `docker pull`.
-     * 
- * - * 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.protobuf.LazyStringList env_ = com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureEnvIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { - env_ = new com.google.protobuf.LazyStringArrayList(env_); - bitField0_ |= 0x00000002; - } - } - /** - * - * - *
-     * Environment variables set before running this command.
-     * 
- * - * repeated string env = 2; - */ - public com.google.protobuf.ProtocolStringList getEnvList() { - return env_.getUnmodifiableView(); - } - /** - * - * - *
-     * Environment variables set before running this command.
-     * 
- * - * repeated string env = 2; - */ - public int getEnvCount() { - return env_.size(); - } - /** - * - * - *
-     * Environment variables set before running this command.
-     * 
- * - * repeated string env = 2; - */ - public java.lang.String getEnv(int index) { - return env_.get(index); - } - /** - * - * - *
-     * Environment variables set before running this command.
-     * 
- * - * repeated string env = 2; - */ - public com.google.protobuf.ByteString getEnvBytes(int index) { - return env_.getByteString(index); - } - /** - * - * - *
-     * Environment variables set before running this command.
-     * 
- * - * repeated string env = 2; - */ - public Builder setEnv(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureEnvIsMutable(); - env_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * Environment variables set before running this command.
-     * 
- * - * repeated string env = 2; - */ - public Builder addEnv(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureEnvIsMutable(); - env_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * Environment variables set before running this command.
-     * 
- * - * repeated string env = 2; - */ - public Builder addAllEnv(java.lang.Iterable values) { - ensureEnvIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, env_); - onChanged(); - return this; - } - /** - * - * - *
-     * Environment variables set before running this command.
-     * 
- * - * repeated string env = 2; - */ - public Builder clearEnv() { - env_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - return this; - } - /** - * - * - *
-     * Environment variables set before running this command.
-     * 
- * - * repeated string env = 2; - */ - public Builder addEnvBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureEnvIsMutable(); - env_.add(value); - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList args_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureArgsIsMutable() { - if (!((bitField0_ & 0x00000004) != 0)) { - args_ = new com.google.protobuf.LazyStringArrayList(args_); - bitField0_ |= 0x00000004; - } - } - /** - * - * - *
-     * Command-line arguments used when executing this command.
-     * 
- * - * repeated string args = 3; - */ - public com.google.protobuf.ProtocolStringList getArgsList() { - return args_.getUnmodifiableView(); - } - /** - * - * - *
-     * Command-line arguments used when executing this command.
-     * 
- * - * repeated string args = 3; - */ - public int getArgsCount() { - return args_.size(); - } - /** - * - * - *
-     * Command-line arguments used when executing this command.
-     * 
- * - * repeated string args = 3; - */ - public java.lang.String getArgs(int index) { - return args_.get(index); - } - /** - * - * - *
-     * Command-line arguments used when executing this command.
-     * 
- * - * repeated string args = 3; - */ - public com.google.protobuf.ByteString getArgsBytes(int index) { - return args_.getByteString(index); - } - /** - * - * - *
-     * Command-line arguments used when executing this command.
-     * 
- * - * repeated string args = 3; - */ - public Builder setArgs(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureArgsIsMutable(); - args_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * Command-line arguments used when executing this command.
-     * 
- * - * repeated string args = 3; - */ - public Builder addArgs(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureArgsIsMutable(); - args_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * Command-line arguments used when executing this command.
-     * 
- * - * repeated string args = 3; - */ - public Builder addAllArgs(java.lang.Iterable values) { - ensureArgsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, args_); - onChanged(); - return this; - } - /** - * - * - *
-     * Command-line arguments used when executing this command.
-     * 
- * - * repeated string args = 3; - */ - public Builder clearArgs() { - args_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - return this; - } - /** - * - * - *
-     * Command-line arguments used when executing this command.
-     * 
- * - * repeated string args = 3; - */ - public Builder addArgsBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureArgsIsMutable(); - args_.add(value); - onChanged(); - return this; - } - - private java.lang.Object dir_ = ""; - /** - * - * - *
-     * Working directory (relative to project source root) used when running this
-     * command.
-     * 
- * - * string dir = 4; - */ - public java.lang.String getDir() { - java.lang.Object ref = dir_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - dir_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Working directory (relative to project source root) used when running this
-     * command.
-     * 
- * - * string dir = 4; - */ - public com.google.protobuf.ByteString getDirBytes() { - java.lang.Object ref = dir_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - dir_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Working directory (relative to project source root) used when running this
-     * command.
-     * 
- * - * string dir = 4; - */ - public Builder setDir(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - dir_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Working directory (relative to project source root) used when running this
-     * command.
-     * 
- * - * string dir = 4; - */ - public Builder clearDir() { - - dir_ = getDefaultInstance().getDir(); - onChanged(); - return this; - } - /** - * - * - *
-     * Working directory (relative to project source root) used when running this
-     * command.
-     * 
- * - * string dir = 4; - */ - public Builder setDirBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - dir_ = value; - onChanged(); - return this; - } - - private java.lang.Object id_ = ""; - /** - * - * - *
-     * Optional unique identifier for this command, used in wait_for to reference
-     * this command as a dependency.
-     * 
- * - * string id = 5; - */ - public java.lang.String getId() { - java.lang.Object ref = id_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Optional unique identifier for this command, used in wait_for to reference
-     * this command as a dependency.
-     * 
- * - * string id = 5; - */ - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Optional unique identifier for this command, used in wait_for to reference
-     * this command as a dependency.
-     * 
- * - * string id = 5; - */ - public Builder setId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - id_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Optional unique identifier for this command, used in wait_for to reference
-     * this command as a dependency.
-     * 
- * - * string id = 5; - */ - public Builder clearId() { - - id_ = getDefaultInstance().getId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Optional unique identifier for this command, used in wait_for to reference
-     * this command as a dependency.
-     * 
- * - * string id = 5; - */ - public Builder setIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - id_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList waitFor_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureWaitForIsMutable() { - if (!((bitField0_ & 0x00000020) != 0)) { - waitFor_ = new com.google.protobuf.LazyStringArrayList(waitFor_); - bitField0_ |= 0x00000020; - } - } - /** - * - * - *
-     * The ID(s) of the command(s) that this command depends on.
-     * 
- * - * repeated string wait_for = 6; - */ - public com.google.protobuf.ProtocolStringList getWaitForList() { - return waitFor_.getUnmodifiableView(); - } - /** - * - * - *
-     * The ID(s) of the command(s) that this command depends on.
-     * 
- * - * repeated string wait_for = 6; - */ - public int getWaitForCount() { - return waitFor_.size(); - } - /** - * - * - *
-     * The ID(s) of the command(s) that this command depends on.
-     * 
- * - * repeated string wait_for = 6; - */ - public java.lang.String getWaitFor(int index) { - return waitFor_.get(index); - } - /** - * - * - *
-     * The ID(s) of the command(s) that this command depends on.
-     * 
- * - * repeated string wait_for = 6; - */ - public com.google.protobuf.ByteString getWaitForBytes(int index) { - return waitFor_.getByteString(index); - } - /** - * - * - *
-     * The ID(s) of the command(s) that this command depends on.
-     * 
- * - * repeated string wait_for = 6; - */ - public Builder setWaitFor(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureWaitForIsMutable(); - waitFor_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * The ID(s) of the command(s) that this command depends on.
-     * 
- * - * repeated string wait_for = 6; - */ - public Builder addWaitFor(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureWaitForIsMutable(); - waitFor_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * The ID(s) of the command(s) that this command depends on.
-     * 
- * - * repeated string wait_for = 6; - */ - public Builder addAllWaitFor(java.lang.Iterable values) { - ensureWaitForIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, waitFor_); - onChanged(); - return this; - } - /** - * - * - *
-     * The ID(s) of the command(s) that this command depends on.
-     * 
- * - * repeated string wait_for = 6; - */ - public Builder clearWaitFor() { - waitFor_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000020); - onChanged(); - return this; - } - /** - * - * - *
-     * The ID(s) of the command(s) that this command depends on.
-     * 
- * - * repeated string wait_for = 6; - */ - public Builder addWaitForBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureWaitForIsMutable(); - waitFor_.add(value); - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.provenance.Command) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.provenance.Command) - private static final io.grafeas.v1beta1.provenance.Command DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.provenance.Command(); - } - - public static io.grafeas.v1beta1.provenance.Command getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Command parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Command(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Command getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/CommandOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/CommandOrBuilder.java deleted file mode 100644 index 12907b72..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/CommandOrBuilder.java +++ /dev/null @@ -1,202 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -public interface CommandOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.provenance.Command) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Name of the command, as presented on the command line, or if the command is
-   * packaged as a Docker container, as presented to `docker pull`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - * - * - *
-   * Name of the command, as presented on the command line, or if the command is
-   * packaged as a Docker container, as presented to `docker pull`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Environment variables set before running this command.
-   * 
- * - * repeated string env = 2; - */ - java.util.List getEnvList(); - /** - * - * - *
-   * Environment variables set before running this command.
-   * 
- * - * repeated string env = 2; - */ - int getEnvCount(); - /** - * - * - *
-   * Environment variables set before running this command.
-   * 
- * - * repeated string env = 2; - */ - java.lang.String getEnv(int index); - /** - * - * - *
-   * Environment variables set before running this command.
-   * 
- * - * repeated string env = 2; - */ - com.google.protobuf.ByteString getEnvBytes(int index); - - /** - * - * - *
-   * Command-line arguments used when executing this command.
-   * 
- * - * repeated string args = 3; - */ - java.util.List getArgsList(); - /** - * - * - *
-   * Command-line arguments used when executing this command.
-   * 
- * - * repeated string args = 3; - */ - int getArgsCount(); - /** - * - * - *
-   * Command-line arguments used when executing this command.
-   * 
- * - * repeated string args = 3; - */ - java.lang.String getArgs(int index); - /** - * - * - *
-   * Command-line arguments used when executing this command.
-   * 
- * - * repeated string args = 3; - */ - com.google.protobuf.ByteString getArgsBytes(int index); - - /** - * - * - *
-   * Working directory (relative to project source root) used when running this
-   * command.
-   * 
- * - * string dir = 4; - */ - java.lang.String getDir(); - /** - * - * - *
-   * Working directory (relative to project source root) used when running this
-   * command.
-   * 
- * - * string dir = 4; - */ - com.google.protobuf.ByteString getDirBytes(); - - /** - * - * - *
-   * Optional unique identifier for this command, used in wait_for to reference
-   * this command as a dependency.
-   * 
- * - * string id = 5; - */ - java.lang.String getId(); - /** - * - * - *
-   * Optional unique identifier for this command, used in wait_for to reference
-   * this command as a dependency.
-   * 
- * - * string id = 5; - */ - com.google.protobuf.ByteString getIdBytes(); - - /** - * - * - *
-   * The ID(s) of the command(s) that this command depends on.
-   * 
- * - * repeated string wait_for = 6; - */ - java.util.List getWaitForList(); - /** - * - * - *
-   * The ID(s) of the command(s) that this command depends on.
-   * 
- * - * repeated string wait_for = 6; - */ - int getWaitForCount(); - /** - * - * - *
-   * The ID(s) of the command(s) that this command depends on.
-   * 
- * - * repeated string wait_for = 6; - */ - java.lang.String getWaitFor(int index); - /** - * - * - *
-   * The ID(s) of the command(s) that this command depends on.
-   * 
- * - * repeated string wait_for = 6; - */ - com.google.protobuf.ByteString getWaitForBytes(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/FileHashes.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/FileHashes.java deleted file mode 100644 index daac09ab..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/FileHashes.java +++ /dev/null @@ -1,921 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -/** - * - * - *
- * Container message for hashes of byte content of files, used in Source
- * messages to verify integrity of source input to the build.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.provenance.FileHashes} - */ -public final class FileHashes extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.provenance.FileHashes) - FileHashesOrBuilder { - private static final long serialVersionUID = 0L; - // Use FileHashes.newBuilder() to construct. - private FileHashes(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private FileHashes() { - fileHash_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private FileHashes( - 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: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - fileHash_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - fileHash_.add( - input.readMessage( - io.grafeas.v1beta1.provenance.Hash.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000001) != 0)) { - fileHash_ = java.util.Collections.unmodifiableList(fileHash_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_FileHashes_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_FileHashes_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.provenance.FileHashes.class, - io.grafeas.v1beta1.provenance.FileHashes.Builder.class); - } - - public static final int FILE_HASH_FIELD_NUMBER = 1; - private java.util.List fileHash_; - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public java.util.List getFileHashList() { - return fileHash_; - } - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public java.util.List - getFileHashOrBuilderList() { - return fileHash_; - } - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public int getFileHashCount() { - return fileHash_.size(); - } - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public io.grafeas.v1beta1.provenance.Hash getFileHash(int index) { - return fileHash_.get(index); - } - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public io.grafeas.v1beta1.provenance.HashOrBuilder getFileHashOrBuilder(int index) { - return fileHash_.get(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 { - for (int i = 0; i < fileHash_.size(); i++) { - output.writeMessage(1, fileHash_.get(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < fileHash_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, fileHash_.get(i)); - } - 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 io.grafeas.v1beta1.provenance.FileHashes)) { - return super.equals(obj); - } - io.grafeas.v1beta1.provenance.FileHashes other = (io.grafeas.v1beta1.provenance.FileHashes) obj; - - if (!getFileHashList().equals(other.getFileHashList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getFileHashCount() > 0) { - hash = (37 * hash) + FILE_HASH_FIELD_NUMBER; - hash = (53 * hash) + getFileHashList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.provenance.FileHashes parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.FileHashes parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.FileHashes parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.FileHashes parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.FileHashes parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.FileHashes parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.FileHashes parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.FileHashes 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 io.grafeas.v1beta1.provenance.FileHashes parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.FileHashes 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 io.grafeas.v1beta1.provenance.FileHashes parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.FileHashes 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(io.grafeas.v1beta1.provenance.FileHashes 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; - } - /** - * - * - *
-   * Container message for hashes of byte content of files, used in Source
-   * messages to verify integrity of source input to the build.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.provenance.FileHashes} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.provenance.FileHashes) - io.grafeas.v1beta1.provenance.FileHashesOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_FileHashes_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_FileHashes_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.provenance.FileHashes.class, - io.grafeas.v1beta1.provenance.FileHashes.Builder.class); - } - - // Construct using io.grafeas.v1beta1.provenance.FileHashes.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getFileHashFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (fileHashBuilder_ == null) { - fileHash_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - fileHashBuilder_.clear(); - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_FileHashes_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.FileHashes getDefaultInstanceForType() { - return io.grafeas.v1beta1.provenance.FileHashes.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.FileHashes build() { - io.grafeas.v1beta1.provenance.FileHashes result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.FileHashes buildPartial() { - io.grafeas.v1beta1.provenance.FileHashes result = - new io.grafeas.v1beta1.provenance.FileHashes(this); - int from_bitField0_ = bitField0_; - if (fileHashBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - fileHash_ = java.util.Collections.unmodifiableList(fileHash_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.fileHash_ = fileHash_; - } else { - result.fileHash_ = fileHashBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.provenance.FileHashes) { - return mergeFrom((io.grafeas.v1beta1.provenance.FileHashes) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.provenance.FileHashes other) { - if (other == io.grafeas.v1beta1.provenance.FileHashes.getDefaultInstance()) return this; - if (fileHashBuilder_ == null) { - if (!other.fileHash_.isEmpty()) { - if (fileHash_.isEmpty()) { - fileHash_ = other.fileHash_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureFileHashIsMutable(); - fileHash_.addAll(other.fileHash_); - } - onChanged(); - } - } else { - if (!other.fileHash_.isEmpty()) { - if (fileHashBuilder_.isEmpty()) { - fileHashBuilder_.dispose(); - fileHashBuilder_ = null; - fileHash_ = other.fileHash_; - bitField0_ = (bitField0_ & ~0x00000001); - fileHashBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getFileHashFieldBuilder() - : null; - } else { - fileHashBuilder_.addAllMessages(other.fileHash_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.provenance.FileHashes parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.provenance.FileHashes) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.util.List fileHash_ = - java.util.Collections.emptyList(); - - private void ensureFileHashIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - fileHash_ = new java.util.ArrayList(fileHash_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.provenance.Hash, - io.grafeas.v1beta1.provenance.Hash.Builder, - io.grafeas.v1beta1.provenance.HashOrBuilder> - fileHashBuilder_; - - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public java.util.List getFileHashList() { - if (fileHashBuilder_ == null) { - return java.util.Collections.unmodifiableList(fileHash_); - } else { - return fileHashBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public int getFileHashCount() { - if (fileHashBuilder_ == null) { - return fileHash_.size(); - } else { - return fileHashBuilder_.getCount(); - } - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public io.grafeas.v1beta1.provenance.Hash getFileHash(int index) { - if (fileHashBuilder_ == null) { - return fileHash_.get(index); - } else { - return fileHashBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public Builder setFileHash(int index, io.grafeas.v1beta1.provenance.Hash value) { - if (fileHashBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFileHashIsMutable(); - fileHash_.set(index, value); - onChanged(); - } else { - fileHashBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public Builder setFileHash( - int index, io.grafeas.v1beta1.provenance.Hash.Builder builderForValue) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.set(index, builderForValue.build()); - onChanged(); - } else { - fileHashBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public Builder addFileHash(io.grafeas.v1beta1.provenance.Hash value) { - if (fileHashBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFileHashIsMutable(); - fileHash_.add(value); - onChanged(); - } else { - fileHashBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public Builder addFileHash(int index, io.grafeas.v1beta1.provenance.Hash value) { - if (fileHashBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFileHashIsMutable(); - fileHash_.add(index, value); - onChanged(); - } else { - fileHashBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public Builder addFileHash(io.grafeas.v1beta1.provenance.Hash.Builder builderForValue) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.add(builderForValue.build()); - onChanged(); - } else { - fileHashBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public Builder addFileHash( - int index, io.grafeas.v1beta1.provenance.Hash.Builder builderForValue) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.add(index, builderForValue.build()); - onChanged(); - } else { - fileHashBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public Builder addAllFileHash( - java.lang.Iterable values) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, fileHash_); - onChanged(); - } else { - fileHashBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public Builder clearFileHash() { - if (fileHashBuilder_ == null) { - fileHash_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - fileHashBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public Builder removeFileHash(int index) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.remove(index); - onChanged(); - } else { - fileHashBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public io.grafeas.v1beta1.provenance.Hash.Builder getFileHashBuilder(int index) { - return getFileHashFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public io.grafeas.v1beta1.provenance.HashOrBuilder getFileHashOrBuilder(int index) { - if (fileHashBuilder_ == null) { - return fileHash_.get(index); - } else { - return fileHashBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public java.util.List - getFileHashOrBuilderList() { - if (fileHashBuilder_ != null) { - return fileHashBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(fileHash_); - } - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public io.grafeas.v1beta1.provenance.Hash.Builder addFileHashBuilder() { - return getFileHashFieldBuilder() - .addBuilder(io.grafeas.v1beta1.provenance.Hash.getDefaultInstance()); - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public io.grafeas.v1beta1.provenance.Hash.Builder addFileHashBuilder(int index) { - return getFileHashFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.provenance.Hash.getDefaultInstance()); - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - public java.util.List getFileHashBuilderList() { - return getFileHashFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.provenance.Hash, - io.grafeas.v1beta1.provenance.Hash.Builder, - io.grafeas.v1beta1.provenance.HashOrBuilder> - getFileHashFieldBuilder() { - if (fileHashBuilder_ == null) { - fileHashBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.provenance.Hash, - io.grafeas.v1beta1.provenance.Hash.Builder, - io.grafeas.v1beta1.provenance.HashOrBuilder>( - fileHash_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - fileHash_ = null; - } - return fileHashBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.provenance.FileHashes) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.provenance.FileHashes) - private static final io.grafeas.v1beta1.provenance.FileHashes DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.provenance.FileHashes(); - } - - public static io.grafeas.v1beta1.provenance.FileHashes getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public FileHashes parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new FileHashes(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.FileHashes getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/FileHashesOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/FileHashesOrBuilder.java deleted file mode 100644 index f419f400..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/FileHashesOrBuilder.java +++ /dev/null @@ -1,61 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -public interface FileHashesOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.provenance.FileHashes) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - java.util.List getFileHashList(); - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - io.grafeas.v1beta1.provenance.Hash getFileHash(int index); - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - int getFileHashCount(); - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - java.util.List getFileHashOrBuilderList(); - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .grafeas.v1beta1.provenance.Hash file_hash = 1; - */ - io.grafeas.v1beta1.provenance.HashOrBuilder getFileHashOrBuilder(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Hash.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Hash.java deleted file mode 100644 index 1736b048..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Hash.java +++ /dev/null @@ -1,767 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -/** - * - * - *
- * Container message for hash values.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.provenance.Hash} - */ -public final class Hash extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.provenance.Hash) - HashOrBuilder { - private static final long serialVersionUID = 0L; - // Use Hash.newBuilder() to construct. - private Hash(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Hash() { - type_ = 0; - value_ = com.google.protobuf.ByteString.EMPTY; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Hash( - 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 8: - { - int rawValue = input.readEnum(); - - type_ = rawValue; - break; - } - case 18: - { - value_ = input.readBytes(); - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Hash_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Hash_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.provenance.Hash.class, - io.grafeas.v1beta1.provenance.Hash.Builder.class); - } - - /** - * - * - *
-   * Specifies the hash algorithm, if any.
-   * 
- * - * Protobuf enum {@code grafeas.v1beta1.provenance.Hash.HashType} - */ - public enum HashType implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Unknown.
-     * 
- * - * HASH_TYPE_UNSPECIFIED = 0; - */ - HASH_TYPE_UNSPECIFIED(0), - /** - * - * - *
-     * A SHA-256 hash.
-     * 
- * - * SHA256 = 1; - */ - SHA256(1), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Unknown.
-     * 
- * - * HASH_TYPE_UNSPECIFIED = 0; - */ - public static final int HASH_TYPE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * A SHA-256 hash.
-     * 
- * - * SHA256 = 1; - */ - public static final int SHA256_VALUE = 1; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static HashType valueOf(int value) { - return forNumber(value); - } - - public static HashType forNumber(int value) { - switch (value) { - case 0: - return HASH_TYPE_UNSPECIFIED; - case 1: - return SHA256; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public HashType findValueByNumber(int number) { - return HashType.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return io.grafeas.v1beta1.provenance.Hash.getDescriptor().getEnumTypes().get(0); - } - - private static final HashType[] VALUES = values(); - - public static HashType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private HashType(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:grafeas.v1beta1.provenance.Hash.HashType) - } - - public static final int TYPE_FIELD_NUMBER = 1; - private int type_; - /** - * - * - *
-   * The type of hash that was performed.
-   * 
- * - * .grafeas.v1beta1.provenance.Hash.HashType type = 1; - */ - public int getTypeValue() { - return type_; - } - /** - * - * - *
-   * The type of hash that was performed.
-   * 
- * - * .grafeas.v1beta1.provenance.Hash.HashType type = 1; - */ - public io.grafeas.v1beta1.provenance.Hash.HashType getType() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.provenance.Hash.HashType result = - io.grafeas.v1beta1.provenance.Hash.HashType.valueOf(type_); - return result == null ? io.grafeas.v1beta1.provenance.Hash.HashType.UNRECOGNIZED : result; - } - - public static final int VALUE_FIELD_NUMBER = 2; - private com.google.protobuf.ByteString value_; - /** - * - * - *
-   * The hash value.
-   * 
- * - * bytes value = 2; - */ - public com.google.protobuf.ByteString getValue() { - return value_; - } - - 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 (type_ != io.grafeas.v1beta1.provenance.Hash.HashType.HASH_TYPE_UNSPECIFIED.getNumber()) { - output.writeEnum(1, type_); - } - if (!value_.isEmpty()) { - output.writeBytes(2, value_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (type_ != io.grafeas.v1beta1.provenance.Hash.HashType.HASH_TYPE_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, type_); - } - if (!value_.isEmpty()) { - size += com.google.protobuf.CodedOutputStream.computeBytesSize(2, value_); - } - 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 io.grafeas.v1beta1.provenance.Hash)) { - return super.equals(obj); - } - io.grafeas.v1beta1.provenance.Hash other = (io.grafeas.v1beta1.provenance.Hash) obj; - - if (type_ != other.type_) return false; - if (!getValue().equals(other.getValue())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + TYPE_FIELD_NUMBER; - hash = (53 * hash) + type_; - hash = (37 * hash) + VALUE_FIELD_NUMBER; - hash = (53 * hash) + getValue().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.provenance.Hash parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.Hash parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.Hash parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.Hash parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.Hash parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.Hash parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.Hash parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.Hash 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 io.grafeas.v1beta1.provenance.Hash parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.Hash 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 io.grafeas.v1beta1.provenance.Hash parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.Hash 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(io.grafeas.v1beta1.provenance.Hash 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; - } - /** - * - * - *
-   * Container message for hash values.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.provenance.Hash} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.provenance.Hash) - io.grafeas.v1beta1.provenance.HashOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Hash_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Hash_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.provenance.Hash.class, - io.grafeas.v1beta1.provenance.Hash.Builder.class); - } - - // Construct using io.grafeas.v1beta1.provenance.Hash.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - type_ = 0; - - value_ = com.google.protobuf.ByteString.EMPTY; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Hash_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Hash getDefaultInstanceForType() { - return io.grafeas.v1beta1.provenance.Hash.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Hash build() { - io.grafeas.v1beta1.provenance.Hash result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Hash buildPartial() { - io.grafeas.v1beta1.provenance.Hash result = new io.grafeas.v1beta1.provenance.Hash(this); - result.type_ = type_; - result.value_ = value_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.provenance.Hash) { - return mergeFrom((io.grafeas.v1beta1.provenance.Hash) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.provenance.Hash other) { - if (other == io.grafeas.v1beta1.provenance.Hash.getDefaultInstance()) return this; - if (other.type_ != 0) { - setTypeValue(other.getTypeValue()); - } - if (other.getValue() != com.google.protobuf.ByteString.EMPTY) { - setValue(other.getValue()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.provenance.Hash parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.provenance.Hash) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int type_ = 0; - /** - * - * - *
-     * The type of hash that was performed.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash.HashType type = 1; - */ - public int getTypeValue() { - return type_; - } - /** - * - * - *
-     * The type of hash that was performed.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash.HashType type = 1; - */ - public Builder setTypeValue(int value) { - type_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The type of hash that was performed.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash.HashType type = 1; - */ - public io.grafeas.v1beta1.provenance.Hash.HashType getType() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.provenance.Hash.HashType result = - io.grafeas.v1beta1.provenance.Hash.HashType.valueOf(type_); - return result == null ? io.grafeas.v1beta1.provenance.Hash.HashType.UNRECOGNIZED : result; - } - /** - * - * - *
-     * The type of hash that was performed.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash.HashType type = 1; - */ - public Builder setType(io.grafeas.v1beta1.provenance.Hash.HashType value) { - if (value == null) { - throw new NullPointerException(); - } - - type_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * The type of hash that was performed.
-     * 
- * - * .grafeas.v1beta1.provenance.Hash.HashType type = 1; - */ - public Builder clearType() { - - type_ = 0; - onChanged(); - return this; - } - - private com.google.protobuf.ByteString value_ = com.google.protobuf.ByteString.EMPTY; - /** - * - * - *
-     * The hash value.
-     * 
- * - * bytes value = 2; - */ - public com.google.protobuf.ByteString getValue() { - return value_; - } - /** - * - * - *
-     * The hash value.
-     * 
- * - * bytes value = 2; - */ - public Builder setValue(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - - value_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The hash value.
-     * 
- * - * bytes value = 2; - */ - public Builder clearValue() { - - value_ = getDefaultInstance().getValue(); - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.provenance.Hash) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.provenance.Hash) - private static final io.grafeas.v1beta1.provenance.Hash DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.provenance.Hash(); - } - - public static io.grafeas.v1beta1.provenance.Hash getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Hash parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Hash(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Hash getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/HashOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/HashOrBuilder.java deleted file mode 100644 index ebbec21e..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/HashOrBuilder.java +++ /dev/null @@ -1,42 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -public interface HashOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.provenance.Hash) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The type of hash that was performed.
-   * 
- * - * .grafeas.v1beta1.provenance.Hash.HashType type = 1; - */ - int getTypeValue(); - /** - * - * - *
-   * The type of hash that was performed.
-   * 
- * - * .grafeas.v1beta1.provenance.Hash.HashType type = 1; - */ - io.grafeas.v1beta1.provenance.Hash.HashType getType(); - - /** - * - * - *
-   * The hash value.
-   * 
- * - * bytes value = 2; - */ - com.google.protobuf.ByteString getValue(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/IamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/IamResourceName.java deleted file mode 100644 index d0e52ebf..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/IamResourceName.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.provenance; - -import com.google.api.resourcenames.ResourceName; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public abstract class IamResourceName implements ResourceName { - protected IamResourceName() {} -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/IamResourceNames.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/IamResourceNames.java deleted file mode 100644 index aa736316..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/IamResourceNames.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.provenance; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class IamResourceNames { - private IamResourceNames() {} - - public static IamResourceName parse(String resourceNameString) { - if (NoteName.isParsableFrom(resourceNameString)) { - return NoteName.parse(resourceNameString); - } - if (OccurrenceName.isParsableFrom(resourceNameString)) { - return OccurrenceName.parse(resourceNameString); - } - return UntypedIamResourceName.parse(resourceNameString); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/NoteName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/NoteName.java deleted file mode 100644 index cbf7a780..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/NoteName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.provenance; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class NoteName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/notes/{note}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/OccurrenceName.java deleted file mode 100644 index d8e1f0b1..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.provenance; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/ProjectName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/ProjectName.java deleted file mode 100644 index 341a12da..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.provenance; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Provenance.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Provenance.java deleted file mode 100644 index 6f213136..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Provenance.java +++ /dev/null @@ -1,196 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -public final class Provenance { - private Provenance() {} - - 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_grafeas_v1beta1_provenance_BuildProvenance_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_provenance_BuildProvenance_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_provenance_BuildProvenance_BuildOptionsEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_provenance_BuildProvenance_BuildOptionsEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_provenance_Source_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_provenance_Source_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_provenance_Source_FileHashesEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_provenance_Source_FileHashesEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_provenance_FileHashes_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_provenance_FileHashes_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_provenance_Hash_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_provenance_Hash_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_provenance_Command_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_provenance_Command_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_provenance_Artifact_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_provenance_Artifact_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { - return descriptor; - } - - private static com.google.protobuf.Descriptors.FileDescriptor descriptor; - - static { - java.lang.String[] descriptorData = { - "\nEgoogle/devtools/containeranalysis/v1be" - + "ta1/provenance/provenance.proto\022\032grafeas" - + ".v1beta1.provenance\032=google/devtools/con" - + "taineranalysis/v1beta1/source/source.pro" - + "to\032\037google/protobuf/timestamp.proto\"\320\004\n\017" - + "BuildProvenance\022\n\n\002id\030\001 \001(\t\022\022\n\nproject_i" - + "d\030\002 \001(\t\0225\n\010commands\030\003 \003(\0132#.grafeas.v1be" - + "ta1.provenance.Command\022=\n\017built_artifact" - + "s\030\004 \003(\0132$.grafeas.v1beta1.provenance.Art" - + "ifact\022/\n\013create_time\030\005 \001(\0132\032.google.prot" - + "obuf.Timestamp\022.\n\nstart_time\030\006 \001(\0132\032.goo" - + "gle.protobuf.Timestamp\022,\n\010end_time\030\007 \001(\013" - + "2\032.google.protobuf.Timestamp\022\017\n\007creator\030" - + "\010 \001(\t\022\020\n\010logs_uri\030\t \001(\t\022=\n\021source_proven" - + "ance\030\n \001(\0132\".grafeas.v1beta1.provenance." - + "Source\022\022\n\ntrigger_id\030\013 \001(\t\022T\n\rbuild_opti" - + "ons\030\014 \003(\0132=.grafeas.v1beta1.provenance.B" - + "uildProvenance.BuildOptionsEntry\022\027\n\017buil" - + "der_version\030\r \001(\t\0323\n\021BuildOptionsEntry\022\013" - + "\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"\315\002\n\006Sourc" - + "e\022#\n\033artifact_storage_source_uri\030\001 \001(\t\022G" - + "\n\013file_hashes\030\002 \003(\01322.grafeas.v1beta1.pr" - + "ovenance.Source.FileHashesEntry\0226\n\007conte" - + "xt\030\003 \001(\0132%.grafeas.v1beta1.source.Source" - + "Context\022B\n\023additional_contexts\030\004 \003(\0132%.g" - + "rafeas.v1beta1.source.SourceContext\032Y\n\017F" - + "ileHashesEntry\022\013\n\003key\030\001 \001(\t\0225\n\005value\030\002 \001" - + "(\0132&.grafeas.v1beta1.provenance.FileHash" - + "es:\0028\001\"A\n\nFileHashes\0223\n\tfile_hash\030\001 \003(\0132" - + " .grafeas.v1beta1.provenance.Hash\"\201\001\n\004Ha" - + "sh\0227\n\004type\030\001 \001(\0162).grafeas.v1beta1.prove" - + "nance.Hash.HashType\022\r\n\005value\030\002 \001(\014\"1\n\010Ha" - + "shType\022\031\n\025HASH_TYPE_UNSPECIFIED\020\000\022\n\n\006SHA" - + "256\020\001\"]\n\007Command\022\014\n\004name\030\001 \001(\t\022\013\n\003env\030\002 " - + "\003(\t\022\014\n\004args\030\003 \003(\t\022\013\n\003dir\030\004 \001(\t\022\n\n\002id\030\005 \001" - + "(\t\022\020\n\010wait_for\030\006 \003(\t\"7\n\010Artifact\022\020\n\010chec" - + "ksum\030\001 \001(\t\022\n\n\002id\030\002 \001(\t\022\r\n\005names\030\003 \003(\tB\207\001" - + "\n\035io.grafeas.v1beta1.provenanceP\001Z^googl" - + "e.golang.org/genproto/googleapis/devtool" - + "s/containeranalysis/v1beta1/provenance;p" - + "rovenance\242\002\003GRAb\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[] { - io.grafeas.v1beta1.source.Source.getDescriptor(), - com.google.protobuf.TimestampProto.getDescriptor(), - }, - assigner); - internal_static_grafeas_v1beta1_provenance_BuildProvenance_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_grafeas_v1beta1_provenance_BuildProvenance_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_provenance_BuildProvenance_descriptor, - new java.lang.String[] { - "Id", - "ProjectId", - "Commands", - "BuiltArtifacts", - "CreateTime", - "StartTime", - "EndTime", - "Creator", - "LogsUri", - "SourceProvenance", - "TriggerId", - "BuildOptions", - "BuilderVersion", - }); - internal_static_grafeas_v1beta1_provenance_BuildProvenance_BuildOptionsEntry_descriptor = - internal_static_grafeas_v1beta1_provenance_BuildProvenance_descriptor - .getNestedTypes() - .get(0); - internal_static_grafeas_v1beta1_provenance_BuildProvenance_BuildOptionsEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_provenance_BuildProvenance_BuildOptionsEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_grafeas_v1beta1_provenance_Source_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_grafeas_v1beta1_provenance_Source_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_provenance_Source_descriptor, - new java.lang.String[] { - "ArtifactStorageSourceUri", "FileHashes", "Context", "AdditionalContexts", - }); - internal_static_grafeas_v1beta1_provenance_Source_FileHashesEntry_descriptor = - internal_static_grafeas_v1beta1_provenance_Source_descriptor.getNestedTypes().get(0); - internal_static_grafeas_v1beta1_provenance_Source_FileHashesEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_provenance_Source_FileHashesEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_grafeas_v1beta1_provenance_FileHashes_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_grafeas_v1beta1_provenance_FileHashes_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_provenance_FileHashes_descriptor, - new java.lang.String[] { - "FileHash", - }); - internal_static_grafeas_v1beta1_provenance_Hash_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_grafeas_v1beta1_provenance_Hash_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_provenance_Hash_descriptor, - new java.lang.String[] { - "Type", "Value", - }); - internal_static_grafeas_v1beta1_provenance_Command_descriptor = - getDescriptor().getMessageTypes().get(4); - internal_static_grafeas_v1beta1_provenance_Command_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_provenance_Command_descriptor, - new java.lang.String[] { - "Name", "Env", "Args", "Dir", "Id", "WaitFor", - }); - internal_static_grafeas_v1beta1_provenance_Artifact_descriptor = - getDescriptor().getMessageTypes().get(5); - internal_static_grafeas_v1beta1_provenance_Artifact_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_provenance_Artifact_descriptor, - new java.lang.String[] { - "Checksum", "Id", "Names", - }); - io.grafeas.v1beta1.source.Source.getDescriptor(); - com.google.protobuf.TimestampProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/ScanConfigName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/ScanConfigName.java deleted file mode 100644 index 43572685..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/ScanConfigName.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.provenance; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ScanConfigName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ScanConfigName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - scanConfig = Preconditions.checkNotNull(builder.getScanConfig()); - } - - public static ScanConfigName of(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build(); - } - - public static String format(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build().toString(); - } - - public static ScanConfigName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ScanConfigName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("scan_config")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ScanConfigName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("scanConfig", scanConfig); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "scan_config", scanConfig); - } - - /** Builder for ScanConfigName. */ - public static class Builder { - - private String project; - private String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setScanConfig(String scanConfig) { - this.scanConfig = scanConfig; - return this; - } - - private Builder() {} - - private Builder(ScanConfigName scanConfigName) { - project = scanConfigName.project; - scanConfig = scanConfigName.scanConfig; - } - - public ScanConfigName build() { - return new ScanConfigName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ScanConfigName) { - ScanConfigName that = (ScanConfigName) o; - return (this.project.equals(that.project)) && (this.scanConfig.equals(that.scanConfig)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= scanConfig.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Source.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Source.java deleted file mode 100644 index 6430bb04..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/Source.java +++ /dev/null @@ -1,1824 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -/** - * - * - *
- * Source describes the location of the source used for the build.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.provenance.Source} - */ -public final class Source extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.provenance.Source) - SourceOrBuilder { - private static final long serialVersionUID = 0L; - // Use Source.newBuilder() to construct. - private Source(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Source() { - artifactStorageSourceUri_ = ""; - additionalContexts_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Source( - 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(); - - artifactStorageSourceUri_ = s; - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - fileHashes_ = - com.google.protobuf.MapField.newMapField( - FileHashesDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000002; - } - com.google.protobuf.MapEntry< - java.lang.String, io.grafeas.v1beta1.provenance.FileHashes> - fileHashes__ = - input.readMessage( - FileHashesDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - fileHashes_.getMutableMap().put(fileHashes__.getKey(), fileHashes__.getValue()); - break; - } - case 26: - { - io.grafeas.v1beta1.source.SourceContext.Builder subBuilder = null; - if (context_ != null) { - subBuilder = context_.toBuilder(); - } - context_ = - input.readMessage( - io.grafeas.v1beta1.source.SourceContext.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(context_); - context_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - if (!((mutable_bitField0_ & 0x00000008) != 0)) { - additionalContexts_ = - new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000008; - } - additionalContexts_.add( - input.readMessage( - io.grafeas.v1beta1.source.SourceContext.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000008) != 0)) { - additionalContexts_ = java.util.Collections.unmodifiableList(additionalContexts_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Source_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 2: - return internalGetFileHashes(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Source_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.provenance.Source.class, - io.grafeas.v1beta1.provenance.Source.Builder.class); - } - - private int bitField0_; - public static final int ARTIFACT_STORAGE_SOURCE_URI_FIELD_NUMBER = 1; - private volatile java.lang.Object artifactStorageSourceUri_; - /** - * - * - *
-   * If provided, the input binary artifacts for the build came from this
-   * location.
-   * 
- * - * string artifact_storage_source_uri = 1; - */ - public java.lang.String getArtifactStorageSourceUri() { - java.lang.Object ref = artifactStorageSourceUri_; - 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(); - artifactStorageSourceUri_ = s; - return s; - } - } - /** - * - * - *
-   * If provided, the input binary artifacts for the build came from this
-   * location.
-   * 
- * - * string artifact_storage_source_uri = 1; - */ - public com.google.protobuf.ByteString getArtifactStorageSourceUriBytes() { - java.lang.Object ref = artifactStorageSourceUri_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - artifactStorageSourceUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int FILE_HASHES_FIELD_NUMBER = 2; - - private static final class FileHashesDefaultEntryHolder { - static final com.google.protobuf.MapEntry< - java.lang.String, io.grafeas.v1beta1.provenance.FileHashes> - defaultEntry = - com.google.protobuf.MapEntry - .newDefaultInstance( - io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Source_FileHashesEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.MESSAGE, - io.grafeas.v1beta1.provenance.FileHashes.getDefaultInstance()); - } - - private com.google.protobuf.MapField - fileHashes_; - - private com.google.protobuf.MapField - internalGetFileHashes() { - if (fileHashes_ == null) { - return com.google.protobuf.MapField.emptyMapField(FileHashesDefaultEntryHolder.defaultEntry); - } - return fileHashes_; - } - - public int getFileHashesCount() { - return internalGetFileHashes().getMap().size(); - } - /** - * - * - *
-   * Hash(es) of the build source, which can be used to verify that the original
-   * source integrity was maintained in the build.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (.tar.gz), the FileHash will be for the single path to that file.
-   * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - public boolean containsFileHashes(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - return internalGetFileHashes().getMap().containsKey(key); - } - /** Use {@link #getFileHashesMap()} instead. */ - @java.lang.Deprecated - public java.util.Map getFileHashes() { - return getFileHashesMap(); - } - /** - * - * - *
-   * Hash(es) of the build source, which can be used to verify that the original
-   * source integrity was maintained in the build.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (.tar.gz), the FileHash will be for the single path to that file.
-   * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - public java.util.Map - getFileHashesMap() { - return internalGetFileHashes().getMap(); - } - /** - * - * - *
-   * Hash(es) of the build source, which can be used to verify that the original
-   * source integrity was maintained in the build.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (.tar.gz), the FileHash will be for the single path to that file.
-   * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - public io.grafeas.v1beta1.provenance.FileHashes getFileHashesOrDefault( - java.lang.String key, io.grafeas.v1beta1.provenance.FileHashes defaultValue) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = - internalGetFileHashes().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-   * Hash(es) of the build source, which can be used to verify that the original
-   * source integrity was maintained in the build.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (.tar.gz), the FileHash will be for the single path to that file.
-   * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - public io.grafeas.v1beta1.provenance.FileHashes getFileHashesOrThrow(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = - internalGetFileHashes().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public static final int CONTEXT_FIELD_NUMBER = 3; - private io.grafeas.v1beta1.source.SourceContext context_; - /** - * - * - *
-   * If provided, the source code used for the build came from this location.
-   * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - public boolean hasContext() { - return context_ != null; - } - /** - * - * - *
-   * If provided, the source code used for the build came from this location.
-   * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - public io.grafeas.v1beta1.source.SourceContext getContext() { - return context_ == null - ? io.grafeas.v1beta1.source.SourceContext.getDefaultInstance() - : context_; - } - /** - * - * - *
-   * If provided, the source code used for the build came from this location.
-   * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - public io.grafeas.v1beta1.source.SourceContextOrBuilder getContextOrBuilder() { - return getContext(); - } - - public static final int ADDITIONAL_CONTEXTS_FIELD_NUMBER = 4; - private java.util.List additionalContexts_; - /** - * - * - *
-   * If provided, some of the source code used for the build may be found in
-   * these locations, in the case where the source repository had multiple
-   * remotes or submodules. This list will not include the context specified in
-   * the context field.
-   * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public java.util.List getAdditionalContextsList() { - return additionalContexts_; - } - /** - * - * - *
-   * If provided, some of the source code used for the build may be found in
-   * these locations, in the case where the source repository had multiple
-   * remotes or submodules. This list will not include the context specified in
-   * the context field.
-   * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public java.util.List - getAdditionalContextsOrBuilderList() { - return additionalContexts_; - } - /** - * - * - *
-   * If provided, some of the source code used for the build may be found in
-   * these locations, in the case where the source repository had multiple
-   * remotes or submodules. This list will not include the context specified in
-   * the context field.
-   * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public int getAdditionalContextsCount() { - return additionalContexts_.size(); - } - /** - * - * - *
-   * If provided, some of the source code used for the build may be found in
-   * these locations, in the case where the source repository had multiple
-   * remotes or submodules. This list will not include the context specified in
-   * the context field.
-   * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public io.grafeas.v1beta1.source.SourceContext getAdditionalContexts(int index) { - return additionalContexts_.get(index); - } - /** - * - * - *
-   * If provided, some of the source code used for the build may be found in
-   * these locations, in the case where the source repository had multiple
-   * remotes or submodules. This list will not include the context specified in
-   * the context field.
-   * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public io.grafeas.v1beta1.source.SourceContextOrBuilder getAdditionalContextsOrBuilder( - int index) { - return additionalContexts_.get(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 (!getArtifactStorageSourceUriBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, artifactStorageSourceUri_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetFileHashes(), FileHashesDefaultEntryHolder.defaultEntry, 2); - if (context_ != null) { - output.writeMessage(3, getContext()); - } - for (int i = 0; i < additionalContexts_.size(); i++) { - output.writeMessage(4, additionalContexts_.get(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getArtifactStorageSourceUriBytes().isEmpty()) { - size += - com.google.protobuf.GeneratedMessageV3.computeStringSize(1, artifactStorageSourceUri_); - } - for (java.util.Map.Entry entry : - internalGetFileHashes().getMap().entrySet()) { - com.google.protobuf.MapEntry - fileHashes__ = - FileHashesDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, fileHashes__); - } - if (context_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getContext()); - } - for (int i = 0; i < additionalContexts_.size(); i++) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize(4, additionalContexts_.get(i)); - } - 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 io.grafeas.v1beta1.provenance.Source)) { - return super.equals(obj); - } - io.grafeas.v1beta1.provenance.Source other = (io.grafeas.v1beta1.provenance.Source) obj; - - if (!getArtifactStorageSourceUri().equals(other.getArtifactStorageSourceUri())) return false; - if (!internalGetFileHashes().equals(other.internalGetFileHashes())) return false; - if (hasContext() != other.hasContext()) return false; - if (hasContext()) { - if (!getContext().equals(other.getContext())) return false; - } - if (!getAdditionalContextsList().equals(other.getAdditionalContextsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + ARTIFACT_STORAGE_SOURCE_URI_FIELD_NUMBER; - hash = (53 * hash) + getArtifactStorageSourceUri().hashCode(); - if (!internalGetFileHashes().getMap().isEmpty()) { - hash = (37 * hash) + FILE_HASHES_FIELD_NUMBER; - hash = (53 * hash) + internalGetFileHashes().hashCode(); - } - if (hasContext()) { - hash = (37 * hash) + CONTEXT_FIELD_NUMBER; - hash = (53 * hash) + getContext().hashCode(); - } - if (getAdditionalContextsCount() > 0) { - hash = (37 * hash) + ADDITIONAL_CONTEXTS_FIELD_NUMBER; - hash = (53 * hash) + getAdditionalContextsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.provenance.Source parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.Source parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.Source parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.Source parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.Source parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.provenance.Source parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.provenance.Source parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.Source 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 io.grafeas.v1beta1.provenance.Source parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.Source 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 io.grafeas.v1beta1.provenance.Source parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.provenance.Source 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(io.grafeas.v1beta1.provenance.Source 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; - } - /** - * - * - *
-   * Source describes the location of the source used for the build.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.provenance.Source} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.provenance.Source) - io.grafeas.v1beta1.provenance.SourceOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Source_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 2: - return internalGetFileHashes(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 2: - return internalGetMutableFileHashes(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Source_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.provenance.Source.class, - io.grafeas.v1beta1.provenance.Source.Builder.class); - } - - // Construct using io.grafeas.v1beta1.provenance.Source.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getAdditionalContextsFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - artifactStorageSourceUri_ = ""; - - internalGetMutableFileHashes().clear(); - if (contextBuilder_ == null) { - context_ = null; - } else { - context_ = null; - contextBuilder_ = null; - } - if (additionalContextsBuilder_ == null) { - additionalContexts_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - } else { - additionalContextsBuilder_.clear(); - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.provenance.Provenance - .internal_static_grafeas_v1beta1_provenance_Source_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Source getDefaultInstanceForType() { - return io.grafeas.v1beta1.provenance.Source.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Source build() { - io.grafeas.v1beta1.provenance.Source result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Source buildPartial() { - io.grafeas.v1beta1.provenance.Source result = new io.grafeas.v1beta1.provenance.Source(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.artifactStorageSourceUri_ = artifactStorageSourceUri_; - result.fileHashes_ = internalGetFileHashes(); - result.fileHashes_.makeImmutable(); - if (contextBuilder_ == null) { - result.context_ = context_; - } else { - result.context_ = contextBuilder_.build(); - } - if (additionalContextsBuilder_ == null) { - if (((bitField0_ & 0x00000008) != 0)) { - additionalContexts_ = java.util.Collections.unmodifiableList(additionalContexts_); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.additionalContexts_ = additionalContexts_; - } else { - result.additionalContexts_ = additionalContextsBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.provenance.Source) { - return mergeFrom((io.grafeas.v1beta1.provenance.Source) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.provenance.Source other) { - if (other == io.grafeas.v1beta1.provenance.Source.getDefaultInstance()) return this; - if (!other.getArtifactStorageSourceUri().isEmpty()) { - artifactStorageSourceUri_ = other.artifactStorageSourceUri_; - onChanged(); - } - internalGetMutableFileHashes().mergeFrom(other.internalGetFileHashes()); - if (other.hasContext()) { - mergeContext(other.getContext()); - } - if (additionalContextsBuilder_ == null) { - if (!other.additionalContexts_.isEmpty()) { - if (additionalContexts_.isEmpty()) { - additionalContexts_ = other.additionalContexts_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureAdditionalContextsIsMutable(); - additionalContexts_.addAll(other.additionalContexts_); - } - onChanged(); - } - } else { - if (!other.additionalContexts_.isEmpty()) { - if (additionalContextsBuilder_.isEmpty()) { - additionalContextsBuilder_.dispose(); - additionalContextsBuilder_ = null; - additionalContexts_ = other.additionalContexts_; - bitField0_ = (bitField0_ & ~0x00000008); - additionalContextsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getAdditionalContextsFieldBuilder() - : null; - } else { - additionalContextsBuilder_.addAllMessages(other.additionalContexts_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.provenance.Source parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.provenance.Source) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object artifactStorageSourceUri_ = ""; - /** - * - * - *
-     * If provided, the input binary artifacts for the build came from this
-     * location.
-     * 
- * - * string artifact_storage_source_uri = 1; - */ - public java.lang.String getArtifactStorageSourceUri() { - java.lang.Object ref = artifactStorageSourceUri_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - artifactStorageSourceUri_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * If provided, the input binary artifacts for the build came from this
-     * location.
-     * 
- * - * string artifact_storage_source_uri = 1; - */ - public com.google.protobuf.ByteString getArtifactStorageSourceUriBytes() { - java.lang.Object ref = artifactStorageSourceUri_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - artifactStorageSourceUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * If provided, the input binary artifacts for the build came from this
-     * location.
-     * 
- * - * string artifact_storage_source_uri = 1; - */ - public Builder setArtifactStorageSourceUri(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - artifactStorageSourceUri_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * If provided, the input binary artifacts for the build came from this
-     * location.
-     * 
- * - * string artifact_storage_source_uri = 1; - */ - public Builder clearArtifactStorageSourceUri() { - - artifactStorageSourceUri_ = getDefaultInstance().getArtifactStorageSourceUri(); - onChanged(); - return this; - } - /** - * - * - *
-     * If provided, the input binary artifacts for the build came from this
-     * location.
-     * 
- * - * string artifact_storage_source_uri = 1; - */ - public Builder setArtifactStorageSourceUriBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - artifactStorageSourceUri_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.MapField - fileHashes_; - - private com.google.protobuf.MapField - internalGetFileHashes() { - if (fileHashes_ == null) { - return com.google.protobuf.MapField.emptyMapField( - FileHashesDefaultEntryHolder.defaultEntry); - } - return fileHashes_; - } - - private com.google.protobuf.MapField - internalGetMutableFileHashes() { - onChanged(); - ; - if (fileHashes_ == null) { - fileHashes_ = - com.google.protobuf.MapField.newMapField(FileHashesDefaultEntryHolder.defaultEntry); - } - if (!fileHashes_.isMutable()) { - fileHashes_ = fileHashes_.copy(); - } - return fileHashes_; - } - - public int getFileHashesCount() { - return internalGetFileHashes().getMap().size(); - } - /** - * - * - *
-     * Hash(es) of the build source, which can be used to verify that the original
-     * source integrity was maintained in the build.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (.tar.gz), the FileHash will be for the single path to that file.
-     * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - public boolean containsFileHashes(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - return internalGetFileHashes().getMap().containsKey(key); - } - /** Use {@link #getFileHashesMap()} instead. */ - @java.lang.Deprecated - public java.util.Map - getFileHashes() { - return getFileHashesMap(); - } - /** - * - * - *
-     * Hash(es) of the build source, which can be used to verify that the original
-     * source integrity was maintained in the build.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (.tar.gz), the FileHash will be for the single path to that file.
-     * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - public java.util.Map - getFileHashesMap() { - return internalGetFileHashes().getMap(); - } - /** - * - * - *
-     * Hash(es) of the build source, which can be used to verify that the original
-     * source integrity was maintained in the build.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (.tar.gz), the FileHash will be for the single path to that file.
-     * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - public io.grafeas.v1beta1.provenance.FileHashes getFileHashesOrDefault( - java.lang.String key, io.grafeas.v1beta1.provenance.FileHashes defaultValue) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = - internalGetFileHashes().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * Hash(es) of the build source, which can be used to verify that the original
-     * source integrity was maintained in the build.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (.tar.gz), the FileHash will be for the single path to that file.
-     * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - public io.grafeas.v1beta1.provenance.FileHashes getFileHashesOrThrow(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = - internalGetFileHashes().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearFileHashes() { - internalGetMutableFileHashes().getMutableMap().clear(); - return this; - } - /** - * - * - *
-     * Hash(es) of the build source, which can be used to verify that the original
-     * source integrity was maintained in the build.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (.tar.gz), the FileHash will be for the single path to that file.
-     * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - public Builder removeFileHashes(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - internalGetMutableFileHashes().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map - getMutableFileHashes() { - return internalGetMutableFileHashes().getMutableMap(); - } - /** - * - * - *
-     * Hash(es) of the build source, which can be used to verify that the original
-     * source integrity was maintained in the build.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (.tar.gz), the FileHash will be for the single path to that file.
-     * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - public Builder putFileHashes( - java.lang.String key, io.grafeas.v1beta1.provenance.FileHashes value) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - if (value == null) { - throw new java.lang.NullPointerException(); - } - internalGetMutableFileHashes().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-     * Hash(es) of the build source, which can be used to verify that the original
-     * source integrity was maintained in the build.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (.tar.gz), the FileHash will be for the single path to that file.
-     * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - public Builder putAllFileHashes( - java.util.Map values) { - internalGetMutableFileHashes().getMutableMap().putAll(values); - return this; - } - - private io.grafeas.v1beta1.source.SourceContext context_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.SourceContext, - io.grafeas.v1beta1.source.SourceContext.Builder, - io.grafeas.v1beta1.source.SourceContextOrBuilder> - contextBuilder_; - /** - * - * - *
-     * If provided, the source code used for the build came from this location.
-     * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - public boolean hasContext() { - return contextBuilder_ != null || context_ != null; - } - /** - * - * - *
-     * If provided, the source code used for the build came from this location.
-     * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - public io.grafeas.v1beta1.source.SourceContext getContext() { - if (contextBuilder_ == null) { - return context_ == null - ? io.grafeas.v1beta1.source.SourceContext.getDefaultInstance() - : context_; - } else { - return contextBuilder_.getMessage(); - } - } - /** - * - * - *
-     * If provided, the source code used for the build came from this location.
-     * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - public Builder setContext(io.grafeas.v1beta1.source.SourceContext value) { - if (contextBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - context_ = value; - onChanged(); - } else { - contextBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * If provided, the source code used for the build came from this location.
-     * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - public Builder setContext(io.grafeas.v1beta1.source.SourceContext.Builder builderForValue) { - if (contextBuilder_ == null) { - context_ = builderForValue.build(); - onChanged(); - } else { - contextBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * If provided, the source code used for the build came from this location.
-     * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - public Builder mergeContext(io.grafeas.v1beta1.source.SourceContext value) { - if (contextBuilder_ == null) { - if (context_ != null) { - context_ = - io.grafeas.v1beta1.source.SourceContext.newBuilder(context_) - .mergeFrom(value) - .buildPartial(); - } else { - context_ = value; - } - onChanged(); - } else { - contextBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * If provided, the source code used for the build came from this location.
-     * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - public Builder clearContext() { - if (contextBuilder_ == null) { - context_ = null; - onChanged(); - } else { - context_ = null; - contextBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * If provided, the source code used for the build came from this location.
-     * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - public io.grafeas.v1beta1.source.SourceContext.Builder getContextBuilder() { - - onChanged(); - return getContextFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * If provided, the source code used for the build came from this location.
-     * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - public io.grafeas.v1beta1.source.SourceContextOrBuilder getContextOrBuilder() { - if (contextBuilder_ != null) { - return contextBuilder_.getMessageOrBuilder(); - } else { - return context_ == null - ? io.grafeas.v1beta1.source.SourceContext.getDefaultInstance() - : context_; - } - } - /** - * - * - *
-     * If provided, the source code used for the build came from this location.
-     * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.SourceContext, - io.grafeas.v1beta1.source.SourceContext.Builder, - io.grafeas.v1beta1.source.SourceContextOrBuilder> - getContextFieldBuilder() { - if (contextBuilder_ == null) { - contextBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.SourceContext, - io.grafeas.v1beta1.source.SourceContext.Builder, - io.grafeas.v1beta1.source.SourceContextOrBuilder>( - getContext(), getParentForChildren(), isClean()); - context_ = null; - } - return contextBuilder_; - } - - private java.util.List additionalContexts_ = - java.util.Collections.emptyList(); - - private void ensureAdditionalContextsIsMutable() { - if (!((bitField0_ & 0x00000008) != 0)) { - additionalContexts_ = - new java.util.ArrayList(additionalContexts_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.source.SourceContext, - io.grafeas.v1beta1.source.SourceContext.Builder, - io.grafeas.v1beta1.source.SourceContextOrBuilder> - additionalContextsBuilder_; - - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public java.util.List getAdditionalContextsList() { - if (additionalContextsBuilder_ == null) { - return java.util.Collections.unmodifiableList(additionalContexts_); - } else { - return additionalContextsBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public int getAdditionalContextsCount() { - if (additionalContextsBuilder_ == null) { - return additionalContexts_.size(); - } else { - return additionalContextsBuilder_.getCount(); - } - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public io.grafeas.v1beta1.source.SourceContext getAdditionalContexts(int index) { - if (additionalContextsBuilder_ == null) { - return additionalContexts_.get(index); - } else { - return additionalContextsBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public Builder setAdditionalContexts(int index, io.grafeas.v1beta1.source.SourceContext value) { - if (additionalContextsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureAdditionalContextsIsMutable(); - additionalContexts_.set(index, value); - onChanged(); - } else { - additionalContextsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public Builder setAdditionalContexts( - int index, io.grafeas.v1beta1.source.SourceContext.Builder builderForValue) { - if (additionalContextsBuilder_ == null) { - ensureAdditionalContextsIsMutable(); - additionalContexts_.set(index, builderForValue.build()); - onChanged(); - } else { - additionalContextsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public Builder addAdditionalContexts(io.grafeas.v1beta1.source.SourceContext value) { - if (additionalContextsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureAdditionalContextsIsMutable(); - additionalContexts_.add(value); - onChanged(); - } else { - additionalContextsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public Builder addAdditionalContexts(int index, io.grafeas.v1beta1.source.SourceContext value) { - if (additionalContextsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureAdditionalContextsIsMutable(); - additionalContexts_.add(index, value); - onChanged(); - } else { - additionalContextsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public Builder addAdditionalContexts( - io.grafeas.v1beta1.source.SourceContext.Builder builderForValue) { - if (additionalContextsBuilder_ == null) { - ensureAdditionalContextsIsMutable(); - additionalContexts_.add(builderForValue.build()); - onChanged(); - } else { - additionalContextsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public Builder addAdditionalContexts( - int index, io.grafeas.v1beta1.source.SourceContext.Builder builderForValue) { - if (additionalContextsBuilder_ == null) { - ensureAdditionalContextsIsMutable(); - additionalContexts_.add(index, builderForValue.build()); - onChanged(); - } else { - additionalContextsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public Builder addAllAdditionalContexts( - java.lang.Iterable values) { - if (additionalContextsBuilder_ == null) { - ensureAdditionalContextsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, additionalContexts_); - onChanged(); - } else { - additionalContextsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public Builder clearAdditionalContexts() { - if (additionalContextsBuilder_ == null) { - additionalContexts_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - additionalContextsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public Builder removeAdditionalContexts(int index) { - if (additionalContextsBuilder_ == null) { - ensureAdditionalContextsIsMutable(); - additionalContexts_.remove(index); - onChanged(); - } else { - additionalContextsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public io.grafeas.v1beta1.source.SourceContext.Builder getAdditionalContextsBuilder(int index) { - return getAdditionalContextsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public io.grafeas.v1beta1.source.SourceContextOrBuilder getAdditionalContextsOrBuilder( - int index) { - if (additionalContextsBuilder_ == null) { - return additionalContexts_.get(index); - } else { - return additionalContextsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public java.util.List - getAdditionalContextsOrBuilderList() { - if (additionalContextsBuilder_ != null) { - return additionalContextsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(additionalContexts_); - } - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public io.grafeas.v1beta1.source.SourceContext.Builder addAdditionalContextsBuilder() { - return getAdditionalContextsFieldBuilder() - .addBuilder(io.grafeas.v1beta1.source.SourceContext.getDefaultInstance()); - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public io.grafeas.v1beta1.source.SourceContext.Builder addAdditionalContextsBuilder(int index) { - return getAdditionalContextsFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.source.SourceContext.getDefaultInstance()); - } - /** - * - * - *
-     * If provided, some of the source code used for the build may be found in
-     * these locations, in the case where the source repository had multiple
-     * remotes or submodules. This list will not include the context specified in
-     * the context field.
-     * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - public java.util.List - getAdditionalContextsBuilderList() { - return getAdditionalContextsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.source.SourceContext, - io.grafeas.v1beta1.source.SourceContext.Builder, - io.grafeas.v1beta1.source.SourceContextOrBuilder> - getAdditionalContextsFieldBuilder() { - if (additionalContextsBuilder_ == null) { - additionalContextsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.source.SourceContext, - io.grafeas.v1beta1.source.SourceContext.Builder, - io.grafeas.v1beta1.source.SourceContextOrBuilder>( - additionalContexts_, - ((bitField0_ & 0x00000008) != 0), - getParentForChildren(), - isClean()); - additionalContexts_ = null; - } - return additionalContextsBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.provenance.Source) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.provenance.Source) - private static final io.grafeas.v1beta1.provenance.Source DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.provenance.Source(); - } - - public static io.grafeas.v1beta1.provenance.Source getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Source parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Source(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.provenance.Source getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/SourceOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/SourceOrBuilder.java deleted file mode 100644 index b271984f..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/SourceOrBuilder.java +++ /dev/null @@ -1,211 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/provenance/provenance.proto - -package io.grafeas.v1beta1.provenance; - -public interface SourceOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.provenance.Source) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * If provided, the input binary artifacts for the build came from this
-   * location.
-   * 
- * - * string artifact_storage_source_uri = 1; - */ - java.lang.String getArtifactStorageSourceUri(); - /** - * - * - *
-   * If provided, the input binary artifacts for the build came from this
-   * location.
-   * 
- * - * string artifact_storage_source_uri = 1; - */ - com.google.protobuf.ByteString getArtifactStorageSourceUriBytes(); - - /** - * - * - *
-   * Hash(es) of the build source, which can be used to verify that the original
-   * source integrity was maintained in the build.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (.tar.gz), the FileHash will be for the single path to that file.
-   * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - int getFileHashesCount(); - /** - * - * - *
-   * Hash(es) of the build source, which can be used to verify that the original
-   * source integrity was maintained in the build.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (.tar.gz), the FileHash will be for the single path to that file.
-   * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - boolean containsFileHashes(java.lang.String key); - /** Use {@link #getFileHashesMap()} instead. */ - @java.lang.Deprecated - java.util.Map getFileHashes(); - /** - * - * - *
-   * Hash(es) of the build source, which can be used to verify that the original
-   * source integrity was maintained in the build.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (.tar.gz), the FileHash will be for the single path to that file.
-   * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - java.util.Map getFileHashesMap(); - /** - * - * - *
-   * Hash(es) of the build source, which can be used to verify that the original
-   * source integrity was maintained in the build.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (.tar.gz), the FileHash will be for the single path to that file.
-   * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - io.grafeas.v1beta1.provenance.FileHashes getFileHashesOrDefault( - java.lang.String key, io.grafeas.v1beta1.provenance.FileHashes defaultValue); - /** - * - * - *
-   * Hash(es) of the build source, which can be used to verify that the original
-   * source integrity was maintained in the build.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (.tar.gz), the FileHash will be for the single path to that file.
-   * 
- * - * map<string, .grafeas.v1beta1.provenance.FileHashes> file_hashes = 2; - */ - io.grafeas.v1beta1.provenance.FileHashes getFileHashesOrThrow(java.lang.String key); - - /** - * - * - *
-   * If provided, the source code used for the build came from this location.
-   * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - boolean hasContext(); - /** - * - * - *
-   * If provided, the source code used for the build came from this location.
-   * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - io.grafeas.v1beta1.source.SourceContext getContext(); - /** - * - * - *
-   * If provided, the source code used for the build came from this location.
-   * 
- * - * .grafeas.v1beta1.source.SourceContext context = 3; - */ - io.grafeas.v1beta1.source.SourceContextOrBuilder getContextOrBuilder(); - - /** - * - * - *
-   * If provided, some of the source code used for the build may be found in
-   * these locations, in the case where the source repository had multiple
-   * remotes or submodules. This list will not include the context specified in
-   * the context field.
-   * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - java.util.List getAdditionalContextsList(); - /** - * - * - *
-   * If provided, some of the source code used for the build may be found in
-   * these locations, in the case where the source repository had multiple
-   * remotes or submodules. This list will not include the context specified in
-   * the context field.
-   * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - io.grafeas.v1beta1.source.SourceContext getAdditionalContexts(int index); - /** - * - * - *
-   * If provided, some of the source code used for the build may be found in
-   * these locations, in the case where the source repository had multiple
-   * remotes or submodules. This list will not include the context specified in
-   * the context field.
-   * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - int getAdditionalContextsCount(); - /** - * - * - *
-   * If provided, some of the source code used for the build may be found in
-   * these locations, in the case where the source repository had multiple
-   * remotes or submodules. This list will not include the context specified in
-   * the context field.
-   * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - java.util.List - getAdditionalContextsOrBuilderList(); - /** - * - * - *
-   * If provided, some of the source code used for the build may be found in
-   * these locations, in the case where the source repository had multiple
-   * remotes or submodules. This list will not include the context specified in
-   * the context field.
-   * 
- * - * repeated .grafeas.v1beta1.source.SourceContext additional_contexts = 4; - */ - io.grafeas.v1beta1.source.SourceContextOrBuilder getAdditionalContextsOrBuilder(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/UntypedIamResourceName.java deleted file mode 100644 index 2bc9e10a..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/provenance/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.provenance; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/AliasContext.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/AliasContext.java deleted file mode 100644 index fe42f701..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/AliasContext.java +++ /dev/null @@ -1,893 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -/** - * - * - *
- * An alias to a repo revision.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.source.AliasContext} - */ -public final class AliasContext extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.source.AliasContext) - AliasContextOrBuilder { - private static final long serialVersionUID = 0L; - // Use AliasContext.newBuilder() to construct. - private AliasContext(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private AliasContext() { - kind_ = 0; - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private AliasContext( - 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 8: - { - int rawValue = input.readEnum(); - - kind_ = rawValue; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_AliasContext_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_AliasContext_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.AliasContext.class, - io.grafeas.v1beta1.source.AliasContext.Builder.class); - } - - /** - * - * - *
-   * The type of an alias.
-   * 
- * - * Protobuf enum {@code grafeas.v1beta1.source.AliasContext.Kind} - */ - public enum Kind implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Unknown.
-     * 
- * - * KIND_UNSPECIFIED = 0; - */ - KIND_UNSPECIFIED(0), - /** - * - * - *
-     * Git tag.
-     * 
- * - * FIXED = 1; - */ - FIXED(1), - /** - * - * - *
-     * Git branch.
-     * 
- * - * MOVABLE = 2; - */ - MOVABLE(2), - /** - * - * - *
-     * Used to specify non-standard aliases. For example, if a Git repo has a
-     * ref named "refs/foo/bar".
-     * 
- * - * OTHER = 4; - */ - OTHER(4), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Unknown.
-     * 
- * - * KIND_UNSPECIFIED = 0; - */ - public static final int KIND_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * Git tag.
-     * 
- * - * FIXED = 1; - */ - public static final int FIXED_VALUE = 1; - /** - * - * - *
-     * Git branch.
-     * 
- * - * MOVABLE = 2; - */ - public static final int MOVABLE_VALUE = 2; - /** - * - * - *
-     * Used to specify non-standard aliases. For example, if a Git repo has a
-     * ref named "refs/foo/bar".
-     * 
- * - * OTHER = 4; - */ - public static final int OTHER_VALUE = 4; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static Kind valueOf(int value) { - return forNumber(value); - } - - public static Kind forNumber(int value) { - switch (value) { - case 0: - return KIND_UNSPECIFIED; - case 1: - return FIXED; - case 2: - return MOVABLE; - case 4: - return OTHER; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Kind findValueByNumber(int number) { - return Kind.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return io.grafeas.v1beta1.source.AliasContext.getDescriptor().getEnumTypes().get(0); - } - - private static final Kind[] VALUES = values(); - - public static Kind valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Kind(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:grafeas.v1beta1.source.AliasContext.Kind) - } - - public static final int KIND_FIELD_NUMBER = 1; - private int kind_; - /** - * - * - *
-   * The alias kind.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext.Kind kind = 1; - */ - public int getKindValue() { - return kind_; - } - /** - * - * - *
-   * The alias kind.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext.Kind kind = 1; - */ - public io.grafeas.v1beta1.source.AliasContext.Kind getKind() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.source.AliasContext.Kind result = - io.grafeas.v1beta1.source.AliasContext.Kind.valueOf(kind_); - return result == null ? io.grafeas.v1beta1.source.AliasContext.Kind.UNRECOGNIZED : result; - } - - public static final int NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The alias name.
-   * 
- * - * string name = 2; - */ - 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 alias name.
-   * 
- * - * string name = 2; - */ - 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; - } - } - - 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 (kind_ != io.grafeas.v1beta1.source.AliasContext.Kind.KIND_UNSPECIFIED.getNumber()) { - output.writeEnum(1, kind_); - } - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, name_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (kind_ != io.grafeas.v1beta1.source.AliasContext.Kind.KIND_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, kind_); - } - if (!getNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, name_); - } - 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 io.grafeas.v1beta1.source.AliasContext)) { - return super.equals(obj); - } - io.grafeas.v1beta1.source.AliasContext other = (io.grafeas.v1beta1.source.AliasContext) obj; - - if (kind_ != other.kind_) return false; - if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + KIND_FIELD_NUMBER; - hash = (53 * hash) + kind_; - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.source.AliasContext parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.AliasContext parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.AliasContext parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.AliasContext parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.AliasContext parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.AliasContext parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.AliasContext parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.AliasContext 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 io.grafeas.v1beta1.source.AliasContext parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.AliasContext 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 io.grafeas.v1beta1.source.AliasContext parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.AliasContext 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(io.grafeas.v1beta1.source.AliasContext 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; - } - /** - * - * - *
-   * An alias to a repo revision.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.source.AliasContext} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.source.AliasContext) - io.grafeas.v1beta1.source.AliasContextOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_AliasContext_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_AliasContext_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.AliasContext.class, - io.grafeas.v1beta1.source.AliasContext.Builder.class); - } - - // Construct using io.grafeas.v1beta1.source.AliasContext.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - kind_ = 0; - - name_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_AliasContext_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.AliasContext getDefaultInstanceForType() { - return io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.source.AliasContext build() { - io.grafeas.v1beta1.source.AliasContext result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.AliasContext buildPartial() { - io.grafeas.v1beta1.source.AliasContext result = - new io.grafeas.v1beta1.source.AliasContext(this); - result.kind_ = kind_; - result.name_ = name_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.source.AliasContext) { - return mergeFrom((io.grafeas.v1beta1.source.AliasContext) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.source.AliasContext other) { - if (other == io.grafeas.v1beta1.source.AliasContext.getDefaultInstance()) return this; - if (other.kind_ != 0) { - setKindValue(other.getKindValue()); - } - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.source.AliasContext parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.source.AliasContext) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int kind_ = 0; - /** - * - * - *
-     * The alias kind.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext.Kind kind = 1; - */ - public int getKindValue() { - return kind_; - } - /** - * - * - *
-     * The alias kind.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext.Kind kind = 1; - */ - public Builder setKindValue(int value) { - kind_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The alias kind.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext.Kind kind = 1; - */ - public io.grafeas.v1beta1.source.AliasContext.Kind getKind() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.source.AliasContext.Kind result = - io.grafeas.v1beta1.source.AliasContext.Kind.valueOf(kind_); - return result == null ? io.grafeas.v1beta1.source.AliasContext.Kind.UNRECOGNIZED : result; - } - /** - * - * - *
-     * The alias kind.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext.Kind kind = 1; - */ - public Builder setKind(io.grafeas.v1beta1.source.AliasContext.Kind value) { - if (value == null) { - throw new NullPointerException(); - } - - kind_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * The alias kind.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext.Kind kind = 1; - */ - public Builder clearKind() { - - kind_ = 0; - onChanged(); - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The alias name.
-     * 
- * - * string name = 2; - */ - 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 alias name.
-     * 
- * - * string name = 2; - */ - 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 alias name.
-     * 
- * - * string name = 2; - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The alias name.
-     * 
- * - * string name = 2; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The alias name.
-     * 
- * - * string name = 2; - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.source.AliasContext) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.source.AliasContext) - private static final io.grafeas.v1beta1.source.AliasContext DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.source.AliasContext(); - } - - public static io.grafeas.v1beta1.source.AliasContext getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public AliasContext parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new AliasContext(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.AliasContext getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/AliasContextOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/AliasContextOrBuilder.java deleted file mode 100644 index 6109e796..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/AliasContextOrBuilder.java +++ /dev/null @@ -1,52 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -public interface AliasContextOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.source.AliasContext) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The alias kind.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext.Kind kind = 1; - */ - int getKindValue(); - /** - * - * - *
-   * The alias kind.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext.Kind kind = 1; - */ - io.grafeas.v1beta1.source.AliasContext.Kind getKind(); - - /** - * - * - *
-   * The alias name.
-   * 
- * - * string name = 2; - */ - java.lang.String getName(); - /** - * - * - *
-   * The alias name.
-   * 
- * - * string name = 2; - */ - com.google.protobuf.ByteString getNameBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/CloudRepoSourceContext.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/CloudRepoSourceContext.java deleted file mode 100644 index 9242fc58..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/CloudRepoSourceContext.java +++ /dev/null @@ -1,1241 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -/** - * - * - *
- * A CloudRepoSourceContext denotes a particular revision in a Google Cloud
- * Source Repo.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.source.CloudRepoSourceContext} - */ -public final class CloudRepoSourceContext extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.source.CloudRepoSourceContext) - CloudRepoSourceContextOrBuilder { - private static final long serialVersionUID = 0L; - // Use CloudRepoSourceContext.newBuilder() to construct. - private CloudRepoSourceContext(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private CloudRepoSourceContext() {} - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private CloudRepoSourceContext( - 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: - { - io.grafeas.v1beta1.source.RepoId.Builder subBuilder = null; - if (repoId_ != null) { - subBuilder = repoId_.toBuilder(); - } - repoId_ = - input.readMessage(io.grafeas.v1beta1.source.RepoId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(repoId_); - repoId_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - revisionCase_ = 2; - revision_ = s; - break; - } - case 26: - { - io.grafeas.v1beta1.source.AliasContext.Builder subBuilder = null; - if (revisionCase_ == 3) { - subBuilder = ((io.grafeas.v1beta1.source.AliasContext) revision_).toBuilder(); - } - revision_ = - input.readMessage( - io.grafeas.v1beta1.source.AliasContext.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.source.AliasContext) revision_); - revision_ = subBuilder.buildPartial(); - } - revisionCase_ = 3; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_CloudRepoSourceContext_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_CloudRepoSourceContext_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.CloudRepoSourceContext.class, - io.grafeas.v1beta1.source.CloudRepoSourceContext.Builder.class); - } - - private int revisionCase_ = 0; - private java.lang.Object revision_; - - public enum RevisionCase implements com.google.protobuf.Internal.EnumLite { - REVISION_ID(2), - ALIAS_CONTEXT(3), - REVISION_NOT_SET(0); - private final int value; - - private RevisionCase(int value) { - this.value = value; - } - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static RevisionCase valueOf(int value) { - return forNumber(value); - } - - public static RevisionCase forNumber(int value) { - switch (value) { - case 2: - return REVISION_ID; - case 3: - return ALIAS_CONTEXT; - case 0: - return REVISION_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public RevisionCase getRevisionCase() { - return RevisionCase.forNumber(revisionCase_); - } - - public static final int REPO_ID_FIELD_NUMBER = 1; - private io.grafeas.v1beta1.source.RepoId repoId_; - /** - * - * - *
-   * The ID of the repo.
-   * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - public boolean hasRepoId() { - return repoId_ != null; - } - /** - * - * - *
-   * The ID of the repo.
-   * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - public io.grafeas.v1beta1.source.RepoId getRepoId() { - return repoId_ == null ? io.grafeas.v1beta1.source.RepoId.getDefaultInstance() : repoId_; - } - /** - * - * - *
-   * The ID of the repo.
-   * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - public io.grafeas.v1beta1.source.RepoIdOrBuilder getRepoIdOrBuilder() { - return getRepoId(); - } - - public static final int REVISION_ID_FIELD_NUMBER = 2; - /** - * - * - *
-   * A revision ID.
-   * 
- * - * string revision_id = 2; - */ - public java.lang.String getRevisionId() { - java.lang.Object ref = ""; - if (revisionCase_ == 2) { - ref = revision_; - } - 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(); - if (revisionCase_ == 2) { - revision_ = s; - } - return s; - } - } - /** - * - * - *
-   * A revision ID.
-   * 
- * - * string revision_id = 2; - */ - public com.google.protobuf.ByteString getRevisionIdBytes() { - java.lang.Object ref = ""; - if (revisionCase_ == 2) { - ref = revision_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (revisionCase_ == 2) { - revision_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ALIAS_CONTEXT_FIELD_NUMBER = 3; - /** - * - * - *
-   * An alias, which may be a branch or tag.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - public boolean hasAliasContext() { - return revisionCase_ == 3; - } - /** - * - * - *
-   * An alias, which may be a branch or tag.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - public io.grafeas.v1beta1.source.AliasContext getAliasContext() { - if (revisionCase_ == 3) { - return (io.grafeas.v1beta1.source.AliasContext) revision_; - } - return io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } - /** - * - * - *
-   * An alias, which may be a branch or tag.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - public io.grafeas.v1beta1.source.AliasContextOrBuilder getAliasContextOrBuilder() { - if (revisionCase_ == 3) { - return (io.grafeas.v1beta1.source.AliasContext) revision_; - } - return io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } - - 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 (repoId_ != null) { - output.writeMessage(1, getRepoId()); - } - if (revisionCase_ == 2) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, revision_); - } - if (revisionCase_ == 3) { - output.writeMessage(3, (io.grafeas.v1beta1.source.AliasContext) revision_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (repoId_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getRepoId()); - } - if (revisionCase_ == 2) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, revision_); - } - if (revisionCase_ == 3) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 3, (io.grafeas.v1beta1.source.AliasContext) revision_); - } - 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 io.grafeas.v1beta1.source.CloudRepoSourceContext)) { - return super.equals(obj); - } - io.grafeas.v1beta1.source.CloudRepoSourceContext other = - (io.grafeas.v1beta1.source.CloudRepoSourceContext) obj; - - if (hasRepoId() != other.hasRepoId()) return false; - if (hasRepoId()) { - if (!getRepoId().equals(other.getRepoId())) return false; - } - if (!getRevisionCase().equals(other.getRevisionCase())) return false; - switch (revisionCase_) { - case 2: - if (!getRevisionId().equals(other.getRevisionId())) return false; - break; - case 3: - if (!getAliasContext().equals(other.getAliasContext())) return false; - break; - case 0: - default: - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasRepoId()) { - hash = (37 * hash) + REPO_ID_FIELD_NUMBER; - hash = (53 * hash) + getRepoId().hashCode(); - } - switch (revisionCase_) { - case 2: - hash = (37 * hash) + REVISION_ID_FIELD_NUMBER; - hash = (53 * hash) + getRevisionId().hashCode(); - break; - case 3: - hash = (37 * hash) + ALIAS_CONTEXT_FIELD_NUMBER; - hash = (53 * hash) + getAliasContext().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.source.CloudRepoSourceContext parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.CloudRepoSourceContext parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.CloudRepoSourceContext parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.CloudRepoSourceContext parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.CloudRepoSourceContext parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.CloudRepoSourceContext parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.CloudRepoSourceContext parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.CloudRepoSourceContext 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 io.grafeas.v1beta1.source.CloudRepoSourceContext parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.CloudRepoSourceContext 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 io.grafeas.v1beta1.source.CloudRepoSourceContext parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.CloudRepoSourceContext 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(io.grafeas.v1beta1.source.CloudRepoSourceContext prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A CloudRepoSourceContext denotes a particular revision in a Google Cloud
-   * Source Repo.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.source.CloudRepoSourceContext} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.source.CloudRepoSourceContext) - io.grafeas.v1beta1.source.CloudRepoSourceContextOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_CloudRepoSourceContext_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_CloudRepoSourceContext_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.CloudRepoSourceContext.class, - io.grafeas.v1beta1.source.CloudRepoSourceContext.Builder.class); - } - - // Construct using io.grafeas.v1beta1.source.CloudRepoSourceContext.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (repoIdBuilder_ == null) { - repoId_ = null; - } else { - repoId_ = null; - repoIdBuilder_ = null; - } - revisionCase_ = 0; - revision_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_CloudRepoSourceContext_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.CloudRepoSourceContext getDefaultInstanceForType() { - return io.grafeas.v1beta1.source.CloudRepoSourceContext.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.source.CloudRepoSourceContext build() { - io.grafeas.v1beta1.source.CloudRepoSourceContext result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.CloudRepoSourceContext buildPartial() { - io.grafeas.v1beta1.source.CloudRepoSourceContext result = - new io.grafeas.v1beta1.source.CloudRepoSourceContext(this); - if (repoIdBuilder_ == null) { - result.repoId_ = repoId_; - } else { - result.repoId_ = repoIdBuilder_.build(); - } - if (revisionCase_ == 2) { - result.revision_ = revision_; - } - if (revisionCase_ == 3) { - if (aliasContextBuilder_ == null) { - result.revision_ = revision_; - } else { - result.revision_ = aliasContextBuilder_.build(); - } - } - result.revisionCase_ = revisionCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.source.CloudRepoSourceContext) { - return mergeFrom((io.grafeas.v1beta1.source.CloudRepoSourceContext) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.source.CloudRepoSourceContext other) { - if (other == io.grafeas.v1beta1.source.CloudRepoSourceContext.getDefaultInstance()) - return this; - if (other.hasRepoId()) { - mergeRepoId(other.getRepoId()); - } - switch (other.getRevisionCase()) { - case REVISION_ID: - { - revisionCase_ = 2; - revision_ = other.revision_; - onChanged(); - break; - } - case ALIAS_CONTEXT: - { - mergeAliasContext(other.getAliasContext()); - break; - } - case REVISION_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.source.CloudRepoSourceContext parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.source.CloudRepoSourceContext) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int revisionCase_ = 0; - private java.lang.Object revision_; - - public RevisionCase getRevisionCase() { - return RevisionCase.forNumber(revisionCase_); - } - - public Builder clearRevision() { - revisionCase_ = 0; - revision_ = null; - onChanged(); - return this; - } - - private io.grafeas.v1beta1.source.RepoId repoId_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.RepoId, - io.grafeas.v1beta1.source.RepoId.Builder, - io.grafeas.v1beta1.source.RepoIdOrBuilder> - repoIdBuilder_; - /** - * - * - *
-     * The ID of the repo.
-     * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - public boolean hasRepoId() { - return repoIdBuilder_ != null || repoId_ != null; - } - /** - * - * - *
-     * The ID of the repo.
-     * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - public io.grafeas.v1beta1.source.RepoId getRepoId() { - if (repoIdBuilder_ == null) { - return repoId_ == null ? io.grafeas.v1beta1.source.RepoId.getDefaultInstance() : repoId_; - } else { - return repoIdBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The ID of the repo.
-     * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - public Builder setRepoId(io.grafeas.v1beta1.source.RepoId value) { - if (repoIdBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - repoId_ = value; - onChanged(); - } else { - repoIdBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The ID of the repo.
-     * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - public Builder setRepoId(io.grafeas.v1beta1.source.RepoId.Builder builderForValue) { - if (repoIdBuilder_ == null) { - repoId_ = builderForValue.build(); - onChanged(); - } else { - repoIdBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The ID of the repo.
-     * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - public Builder mergeRepoId(io.grafeas.v1beta1.source.RepoId value) { - if (repoIdBuilder_ == null) { - if (repoId_ != null) { - repoId_ = - io.grafeas.v1beta1.source.RepoId.newBuilder(repoId_).mergeFrom(value).buildPartial(); - } else { - repoId_ = value; - } - onChanged(); - } else { - repoIdBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The ID of the repo.
-     * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - public Builder clearRepoId() { - if (repoIdBuilder_ == null) { - repoId_ = null; - onChanged(); - } else { - repoId_ = null; - repoIdBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The ID of the repo.
-     * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - public io.grafeas.v1beta1.source.RepoId.Builder getRepoIdBuilder() { - - onChanged(); - return getRepoIdFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The ID of the repo.
-     * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - public io.grafeas.v1beta1.source.RepoIdOrBuilder getRepoIdOrBuilder() { - if (repoIdBuilder_ != null) { - return repoIdBuilder_.getMessageOrBuilder(); - } else { - return repoId_ == null ? io.grafeas.v1beta1.source.RepoId.getDefaultInstance() : repoId_; - } - } - /** - * - * - *
-     * The ID of the repo.
-     * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.RepoId, - io.grafeas.v1beta1.source.RepoId.Builder, - io.grafeas.v1beta1.source.RepoIdOrBuilder> - getRepoIdFieldBuilder() { - if (repoIdBuilder_ == null) { - repoIdBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.RepoId, - io.grafeas.v1beta1.source.RepoId.Builder, - io.grafeas.v1beta1.source.RepoIdOrBuilder>( - getRepoId(), getParentForChildren(), isClean()); - repoId_ = null; - } - return repoIdBuilder_; - } - - /** - * - * - *
-     * A revision ID.
-     * 
- * - * string revision_id = 2; - */ - public java.lang.String getRevisionId() { - java.lang.Object ref = ""; - if (revisionCase_ == 2) { - ref = revision_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (revisionCase_ == 2) { - revision_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * A revision ID.
-     * 
- * - * string revision_id = 2; - */ - public com.google.protobuf.ByteString getRevisionIdBytes() { - java.lang.Object ref = ""; - if (revisionCase_ == 2) { - ref = revision_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (revisionCase_ == 2) { - revision_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * A revision ID.
-     * 
- * - * string revision_id = 2; - */ - public Builder setRevisionId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - revisionCase_ = 2; - revision_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * A revision ID.
-     * 
- * - * string revision_id = 2; - */ - public Builder clearRevisionId() { - if (revisionCase_ == 2) { - revisionCase_ = 0; - revision_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-     * A revision ID.
-     * 
- * - * string revision_id = 2; - */ - public Builder setRevisionIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - revisionCase_ = 2; - revision_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.AliasContext, - io.grafeas.v1beta1.source.AliasContext.Builder, - io.grafeas.v1beta1.source.AliasContextOrBuilder> - aliasContextBuilder_; - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - public boolean hasAliasContext() { - return revisionCase_ == 3; - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - public io.grafeas.v1beta1.source.AliasContext getAliasContext() { - if (aliasContextBuilder_ == null) { - if (revisionCase_ == 3) { - return (io.grafeas.v1beta1.source.AliasContext) revision_; - } - return io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } else { - if (revisionCase_ == 3) { - return aliasContextBuilder_.getMessage(); - } - return io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - public Builder setAliasContext(io.grafeas.v1beta1.source.AliasContext value) { - if (aliasContextBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - revision_ = value; - onChanged(); - } else { - aliasContextBuilder_.setMessage(value); - } - revisionCase_ = 3; - return this; - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - public Builder setAliasContext(io.grafeas.v1beta1.source.AliasContext.Builder builderForValue) { - if (aliasContextBuilder_ == null) { - revision_ = builderForValue.build(); - onChanged(); - } else { - aliasContextBuilder_.setMessage(builderForValue.build()); - } - revisionCase_ = 3; - return this; - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - public Builder mergeAliasContext(io.grafeas.v1beta1.source.AliasContext value) { - if (aliasContextBuilder_ == null) { - if (revisionCase_ == 3 - && revision_ != io.grafeas.v1beta1.source.AliasContext.getDefaultInstance()) { - revision_ = - io.grafeas.v1beta1.source.AliasContext.newBuilder( - (io.grafeas.v1beta1.source.AliasContext) revision_) - .mergeFrom(value) - .buildPartial(); - } else { - revision_ = value; - } - onChanged(); - } else { - if (revisionCase_ == 3) { - aliasContextBuilder_.mergeFrom(value); - } - aliasContextBuilder_.setMessage(value); - } - revisionCase_ = 3; - return this; - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - public Builder clearAliasContext() { - if (aliasContextBuilder_ == null) { - if (revisionCase_ == 3) { - revisionCase_ = 0; - revision_ = null; - onChanged(); - } - } else { - if (revisionCase_ == 3) { - revisionCase_ = 0; - revision_ = null; - } - aliasContextBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - public io.grafeas.v1beta1.source.AliasContext.Builder getAliasContextBuilder() { - return getAliasContextFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - public io.grafeas.v1beta1.source.AliasContextOrBuilder getAliasContextOrBuilder() { - if ((revisionCase_ == 3) && (aliasContextBuilder_ != null)) { - return aliasContextBuilder_.getMessageOrBuilder(); - } else { - if (revisionCase_ == 3) { - return (io.grafeas.v1beta1.source.AliasContext) revision_; - } - return io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.AliasContext, - io.grafeas.v1beta1.source.AliasContext.Builder, - io.grafeas.v1beta1.source.AliasContextOrBuilder> - getAliasContextFieldBuilder() { - if (aliasContextBuilder_ == null) { - if (!(revisionCase_ == 3)) { - revision_ = io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } - aliasContextBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.AliasContext, - io.grafeas.v1beta1.source.AliasContext.Builder, - io.grafeas.v1beta1.source.AliasContextOrBuilder>( - (io.grafeas.v1beta1.source.AliasContext) revision_, - getParentForChildren(), - isClean()); - revision_ = null; - } - revisionCase_ = 3; - onChanged(); - ; - return aliasContextBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.source.CloudRepoSourceContext) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.source.CloudRepoSourceContext) - private static final io.grafeas.v1beta1.source.CloudRepoSourceContext DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.source.CloudRepoSourceContext(); - } - - public static io.grafeas.v1beta1.source.CloudRepoSourceContext getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public CloudRepoSourceContext parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CloudRepoSourceContext(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.CloudRepoSourceContext getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/CloudRepoSourceContextOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/CloudRepoSourceContextOrBuilder.java deleted file mode 100644 index d0b51d3f..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/CloudRepoSourceContextOrBuilder.java +++ /dev/null @@ -1,95 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -public interface CloudRepoSourceContextOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.source.CloudRepoSourceContext) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The ID of the repo.
-   * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - boolean hasRepoId(); - /** - * - * - *
-   * The ID of the repo.
-   * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - io.grafeas.v1beta1.source.RepoId getRepoId(); - /** - * - * - *
-   * The ID of the repo.
-   * 
- * - * .grafeas.v1beta1.source.RepoId repo_id = 1; - */ - io.grafeas.v1beta1.source.RepoIdOrBuilder getRepoIdOrBuilder(); - - /** - * - * - *
-   * A revision ID.
-   * 
- * - * string revision_id = 2; - */ - java.lang.String getRevisionId(); - /** - * - * - *
-   * A revision ID.
-   * 
- * - * string revision_id = 2; - */ - com.google.protobuf.ByteString getRevisionIdBytes(); - - /** - * - * - *
-   * An alias, which may be a branch or tag.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - boolean hasAliasContext(); - /** - * - * - *
-   * An alias, which may be a branch or tag.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - io.grafeas.v1beta1.source.AliasContext getAliasContext(); - /** - * - * - *
-   * An alias, which may be a branch or tag.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 3; - */ - io.grafeas.v1beta1.source.AliasContextOrBuilder getAliasContextOrBuilder(); - - public io.grafeas.v1beta1.source.CloudRepoSourceContext.RevisionCase getRevisionCase(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GerritSourceContext.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GerritSourceContext.java deleted file mode 100644 index d9927ca8..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GerritSourceContext.java +++ /dev/null @@ -1,1318 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -/** - * - * - *
- * A SourceContext referring to a Gerrit project.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.source.GerritSourceContext} - */ -public final class GerritSourceContext extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.source.GerritSourceContext) - GerritSourceContextOrBuilder { - private static final long serialVersionUID = 0L; - // Use GerritSourceContext.newBuilder() to construct. - private GerritSourceContext(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private GerritSourceContext() { - hostUri_ = ""; - gerritProject_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private GerritSourceContext( - 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(); - - hostUri_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - gerritProject_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - revisionCase_ = 3; - revision_ = s; - break; - } - case 34: - { - io.grafeas.v1beta1.source.AliasContext.Builder subBuilder = null; - if (revisionCase_ == 4) { - subBuilder = ((io.grafeas.v1beta1.source.AliasContext) revision_).toBuilder(); - } - revision_ = - input.readMessage( - io.grafeas.v1beta1.source.AliasContext.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.source.AliasContext) revision_); - revision_ = subBuilder.buildPartial(); - } - revisionCase_ = 4; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_GerritSourceContext_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_GerritSourceContext_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.GerritSourceContext.class, - io.grafeas.v1beta1.source.GerritSourceContext.Builder.class); - } - - private int revisionCase_ = 0; - private java.lang.Object revision_; - - public enum RevisionCase implements com.google.protobuf.Internal.EnumLite { - REVISION_ID(3), - ALIAS_CONTEXT(4), - REVISION_NOT_SET(0); - private final int value; - - private RevisionCase(int value) { - this.value = value; - } - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static RevisionCase valueOf(int value) { - return forNumber(value); - } - - public static RevisionCase forNumber(int value) { - switch (value) { - case 3: - return REVISION_ID; - case 4: - return ALIAS_CONTEXT; - case 0: - return REVISION_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public RevisionCase getRevisionCase() { - return RevisionCase.forNumber(revisionCase_); - } - - public static final int HOST_URI_FIELD_NUMBER = 1; - private volatile java.lang.Object hostUri_; - /** - * - * - *
-   * The URI of a running Gerrit instance.
-   * 
- * - * string host_uri = 1; - */ - public java.lang.String getHostUri() { - java.lang.Object ref = hostUri_; - 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(); - hostUri_ = s; - return s; - } - } - /** - * - * - *
-   * The URI of a running Gerrit instance.
-   * 
- * - * string host_uri = 1; - */ - public com.google.protobuf.ByteString getHostUriBytes() { - java.lang.Object ref = hostUri_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - hostUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int GERRIT_PROJECT_FIELD_NUMBER = 2; - private volatile java.lang.Object gerritProject_; - /** - * - * - *
-   * The full project name within the host. Projects may be nested, so
-   * "project/subproject" is a valid project name. The "repo name" is the
-   * hostURI/project.
-   * 
- * - * string gerrit_project = 2; - */ - public java.lang.String getGerritProject() { - java.lang.Object ref = gerritProject_; - 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(); - gerritProject_ = s; - return s; - } - } - /** - * - * - *
-   * The full project name within the host. Projects may be nested, so
-   * "project/subproject" is a valid project name. The "repo name" is the
-   * hostURI/project.
-   * 
- * - * string gerrit_project = 2; - */ - public com.google.protobuf.ByteString getGerritProjectBytes() { - java.lang.Object ref = gerritProject_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - gerritProject_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int REVISION_ID_FIELD_NUMBER = 3; - /** - * - * - *
-   * A revision (commit) ID.
-   * 
- * - * string revision_id = 3; - */ - public java.lang.String getRevisionId() { - java.lang.Object ref = ""; - if (revisionCase_ == 3) { - ref = revision_; - } - 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(); - if (revisionCase_ == 3) { - revision_ = s; - } - return s; - } - } - /** - * - * - *
-   * A revision (commit) ID.
-   * 
- * - * string revision_id = 3; - */ - public com.google.protobuf.ByteString getRevisionIdBytes() { - java.lang.Object ref = ""; - if (revisionCase_ == 3) { - ref = revision_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (revisionCase_ == 3) { - revision_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ALIAS_CONTEXT_FIELD_NUMBER = 4; - /** - * - * - *
-   * An alias, which may be a branch or tag.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - public boolean hasAliasContext() { - return revisionCase_ == 4; - } - /** - * - * - *
-   * An alias, which may be a branch or tag.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - public io.grafeas.v1beta1.source.AliasContext getAliasContext() { - if (revisionCase_ == 4) { - return (io.grafeas.v1beta1.source.AliasContext) revision_; - } - return io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } - /** - * - * - *
-   * An alias, which may be a branch or tag.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - public io.grafeas.v1beta1.source.AliasContextOrBuilder getAliasContextOrBuilder() { - if (revisionCase_ == 4) { - return (io.grafeas.v1beta1.source.AliasContext) revision_; - } - return io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } - - 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 (!getHostUriBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, hostUri_); - } - if (!getGerritProjectBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, gerritProject_); - } - if (revisionCase_ == 3) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, revision_); - } - if (revisionCase_ == 4) { - output.writeMessage(4, (io.grafeas.v1beta1.source.AliasContext) revision_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getHostUriBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, hostUri_); - } - if (!getGerritProjectBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, gerritProject_); - } - if (revisionCase_ == 3) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, revision_); - } - if (revisionCase_ == 4) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 4, (io.grafeas.v1beta1.source.AliasContext) revision_); - } - 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 io.grafeas.v1beta1.source.GerritSourceContext)) { - return super.equals(obj); - } - io.grafeas.v1beta1.source.GerritSourceContext other = - (io.grafeas.v1beta1.source.GerritSourceContext) obj; - - if (!getHostUri().equals(other.getHostUri())) return false; - if (!getGerritProject().equals(other.getGerritProject())) return false; - if (!getRevisionCase().equals(other.getRevisionCase())) return false; - switch (revisionCase_) { - case 3: - if (!getRevisionId().equals(other.getRevisionId())) return false; - break; - case 4: - if (!getAliasContext().equals(other.getAliasContext())) return false; - break; - case 0: - default: - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + HOST_URI_FIELD_NUMBER; - hash = (53 * hash) + getHostUri().hashCode(); - hash = (37 * hash) + GERRIT_PROJECT_FIELD_NUMBER; - hash = (53 * hash) + getGerritProject().hashCode(); - switch (revisionCase_) { - case 3: - hash = (37 * hash) + REVISION_ID_FIELD_NUMBER; - hash = (53 * hash) + getRevisionId().hashCode(); - break; - case 4: - hash = (37 * hash) + ALIAS_CONTEXT_FIELD_NUMBER; - hash = (53 * hash) + getAliasContext().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.source.GerritSourceContext parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.GerritSourceContext parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.GerritSourceContext parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.GerritSourceContext parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.GerritSourceContext parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.GerritSourceContext parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.GerritSourceContext parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.GerritSourceContext 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 io.grafeas.v1beta1.source.GerritSourceContext parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.GerritSourceContext 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 io.grafeas.v1beta1.source.GerritSourceContext parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.GerritSourceContext 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(io.grafeas.v1beta1.source.GerritSourceContext prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A SourceContext referring to a Gerrit project.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.source.GerritSourceContext} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.source.GerritSourceContext) - io.grafeas.v1beta1.source.GerritSourceContextOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_GerritSourceContext_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_GerritSourceContext_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.GerritSourceContext.class, - io.grafeas.v1beta1.source.GerritSourceContext.Builder.class); - } - - // Construct using io.grafeas.v1beta1.source.GerritSourceContext.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - hostUri_ = ""; - - gerritProject_ = ""; - - revisionCase_ = 0; - revision_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_GerritSourceContext_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.GerritSourceContext getDefaultInstanceForType() { - return io.grafeas.v1beta1.source.GerritSourceContext.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.source.GerritSourceContext build() { - io.grafeas.v1beta1.source.GerritSourceContext result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.GerritSourceContext buildPartial() { - io.grafeas.v1beta1.source.GerritSourceContext result = - new io.grafeas.v1beta1.source.GerritSourceContext(this); - result.hostUri_ = hostUri_; - result.gerritProject_ = gerritProject_; - if (revisionCase_ == 3) { - result.revision_ = revision_; - } - if (revisionCase_ == 4) { - if (aliasContextBuilder_ == null) { - result.revision_ = revision_; - } else { - result.revision_ = aliasContextBuilder_.build(); - } - } - result.revisionCase_ = revisionCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.source.GerritSourceContext) { - return mergeFrom((io.grafeas.v1beta1.source.GerritSourceContext) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.source.GerritSourceContext other) { - if (other == io.grafeas.v1beta1.source.GerritSourceContext.getDefaultInstance()) return this; - if (!other.getHostUri().isEmpty()) { - hostUri_ = other.hostUri_; - onChanged(); - } - if (!other.getGerritProject().isEmpty()) { - gerritProject_ = other.gerritProject_; - onChanged(); - } - switch (other.getRevisionCase()) { - case REVISION_ID: - { - revisionCase_ = 3; - revision_ = other.revision_; - onChanged(); - break; - } - case ALIAS_CONTEXT: - { - mergeAliasContext(other.getAliasContext()); - break; - } - case REVISION_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.source.GerritSourceContext parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.source.GerritSourceContext) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int revisionCase_ = 0; - private java.lang.Object revision_; - - public RevisionCase getRevisionCase() { - return RevisionCase.forNumber(revisionCase_); - } - - public Builder clearRevision() { - revisionCase_ = 0; - revision_ = null; - onChanged(); - return this; - } - - private java.lang.Object hostUri_ = ""; - /** - * - * - *
-     * The URI of a running Gerrit instance.
-     * 
- * - * string host_uri = 1; - */ - public java.lang.String getHostUri() { - java.lang.Object ref = hostUri_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - hostUri_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The URI of a running Gerrit instance.
-     * 
- * - * string host_uri = 1; - */ - public com.google.protobuf.ByteString getHostUriBytes() { - java.lang.Object ref = hostUri_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - hostUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The URI of a running Gerrit instance.
-     * 
- * - * string host_uri = 1; - */ - public Builder setHostUri(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - hostUri_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The URI of a running Gerrit instance.
-     * 
- * - * string host_uri = 1; - */ - public Builder clearHostUri() { - - hostUri_ = getDefaultInstance().getHostUri(); - onChanged(); - return this; - } - /** - * - * - *
-     * The URI of a running Gerrit instance.
-     * 
- * - * string host_uri = 1; - */ - public Builder setHostUriBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - hostUri_ = value; - onChanged(); - return this; - } - - private java.lang.Object gerritProject_ = ""; - /** - * - * - *
-     * The full project name within the host. Projects may be nested, so
-     * "project/subproject" is a valid project name. The "repo name" is the
-     * hostURI/project.
-     * 
- * - * string gerrit_project = 2; - */ - public java.lang.String getGerritProject() { - java.lang.Object ref = gerritProject_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - gerritProject_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The full project name within the host. Projects may be nested, so
-     * "project/subproject" is a valid project name. The "repo name" is the
-     * hostURI/project.
-     * 
- * - * string gerrit_project = 2; - */ - public com.google.protobuf.ByteString getGerritProjectBytes() { - java.lang.Object ref = gerritProject_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - gerritProject_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The full project name within the host. Projects may be nested, so
-     * "project/subproject" is a valid project name. The "repo name" is the
-     * hostURI/project.
-     * 
- * - * string gerrit_project = 2; - */ - public Builder setGerritProject(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - gerritProject_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The full project name within the host. Projects may be nested, so
-     * "project/subproject" is a valid project name. The "repo name" is the
-     * hostURI/project.
-     * 
- * - * string gerrit_project = 2; - */ - public Builder clearGerritProject() { - - gerritProject_ = getDefaultInstance().getGerritProject(); - onChanged(); - return this; - } - /** - * - * - *
-     * The full project name within the host. Projects may be nested, so
-     * "project/subproject" is a valid project name. The "repo name" is the
-     * hostURI/project.
-     * 
- * - * string gerrit_project = 2; - */ - public Builder setGerritProjectBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - gerritProject_ = value; - onChanged(); - return this; - } - - /** - * - * - *
-     * A revision (commit) ID.
-     * 
- * - * string revision_id = 3; - */ - public java.lang.String getRevisionId() { - java.lang.Object ref = ""; - if (revisionCase_ == 3) { - ref = revision_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (revisionCase_ == 3) { - revision_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * A revision (commit) ID.
-     * 
- * - * string revision_id = 3; - */ - public com.google.protobuf.ByteString getRevisionIdBytes() { - java.lang.Object ref = ""; - if (revisionCase_ == 3) { - ref = revision_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (revisionCase_ == 3) { - revision_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * A revision (commit) ID.
-     * 
- * - * string revision_id = 3; - */ - public Builder setRevisionId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - revisionCase_ = 3; - revision_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * A revision (commit) ID.
-     * 
- * - * string revision_id = 3; - */ - public Builder clearRevisionId() { - if (revisionCase_ == 3) { - revisionCase_ = 0; - revision_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-     * A revision (commit) ID.
-     * 
- * - * string revision_id = 3; - */ - public Builder setRevisionIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - revisionCase_ = 3; - revision_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.AliasContext, - io.grafeas.v1beta1.source.AliasContext.Builder, - io.grafeas.v1beta1.source.AliasContextOrBuilder> - aliasContextBuilder_; - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - public boolean hasAliasContext() { - return revisionCase_ == 4; - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - public io.grafeas.v1beta1.source.AliasContext getAliasContext() { - if (aliasContextBuilder_ == null) { - if (revisionCase_ == 4) { - return (io.grafeas.v1beta1.source.AliasContext) revision_; - } - return io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } else { - if (revisionCase_ == 4) { - return aliasContextBuilder_.getMessage(); - } - return io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - public Builder setAliasContext(io.grafeas.v1beta1.source.AliasContext value) { - if (aliasContextBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - revision_ = value; - onChanged(); - } else { - aliasContextBuilder_.setMessage(value); - } - revisionCase_ = 4; - return this; - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - public Builder setAliasContext(io.grafeas.v1beta1.source.AliasContext.Builder builderForValue) { - if (aliasContextBuilder_ == null) { - revision_ = builderForValue.build(); - onChanged(); - } else { - aliasContextBuilder_.setMessage(builderForValue.build()); - } - revisionCase_ = 4; - return this; - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - public Builder mergeAliasContext(io.grafeas.v1beta1.source.AliasContext value) { - if (aliasContextBuilder_ == null) { - if (revisionCase_ == 4 - && revision_ != io.grafeas.v1beta1.source.AliasContext.getDefaultInstance()) { - revision_ = - io.grafeas.v1beta1.source.AliasContext.newBuilder( - (io.grafeas.v1beta1.source.AliasContext) revision_) - .mergeFrom(value) - .buildPartial(); - } else { - revision_ = value; - } - onChanged(); - } else { - if (revisionCase_ == 4) { - aliasContextBuilder_.mergeFrom(value); - } - aliasContextBuilder_.setMessage(value); - } - revisionCase_ = 4; - return this; - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - public Builder clearAliasContext() { - if (aliasContextBuilder_ == null) { - if (revisionCase_ == 4) { - revisionCase_ = 0; - revision_ = null; - onChanged(); - } - } else { - if (revisionCase_ == 4) { - revisionCase_ = 0; - revision_ = null; - } - aliasContextBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - public io.grafeas.v1beta1.source.AliasContext.Builder getAliasContextBuilder() { - return getAliasContextFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - public io.grafeas.v1beta1.source.AliasContextOrBuilder getAliasContextOrBuilder() { - if ((revisionCase_ == 4) && (aliasContextBuilder_ != null)) { - return aliasContextBuilder_.getMessageOrBuilder(); - } else { - if (revisionCase_ == 4) { - return (io.grafeas.v1beta1.source.AliasContext) revision_; - } - return io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } - } - /** - * - * - *
-     * An alias, which may be a branch or tag.
-     * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.AliasContext, - io.grafeas.v1beta1.source.AliasContext.Builder, - io.grafeas.v1beta1.source.AliasContextOrBuilder> - getAliasContextFieldBuilder() { - if (aliasContextBuilder_ == null) { - if (!(revisionCase_ == 4)) { - revision_ = io.grafeas.v1beta1.source.AliasContext.getDefaultInstance(); - } - aliasContextBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.AliasContext, - io.grafeas.v1beta1.source.AliasContext.Builder, - io.grafeas.v1beta1.source.AliasContextOrBuilder>( - (io.grafeas.v1beta1.source.AliasContext) revision_, - getParentForChildren(), - isClean()); - revision_ = null; - } - revisionCase_ = 4; - onChanged(); - ; - return aliasContextBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.source.GerritSourceContext) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.source.GerritSourceContext) - private static final io.grafeas.v1beta1.source.GerritSourceContext DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.source.GerritSourceContext(); - } - - public static io.grafeas.v1beta1.source.GerritSourceContext getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GerritSourceContext parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new GerritSourceContext(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.GerritSourceContext getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GerritSourceContextOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GerritSourceContextOrBuilder.java deleted file mode 100644 index 156b0d80..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GerritSourceContextOrBuilder.java +++ /dev/null @@ -1,110 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -public interface GerritSourceContextOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.source.GerritSourceContext) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The URI of a running Gerrit instance.
-   * 
- * - * string host_uri = 1; - */ - java.lang.String getHostUri(); - /** - * - * - *
-   * The URI of a running Gerrit instance.
-   * 
- * - * string host_uri = 1; - */ - com.google.protobuf.ByteString getHostUriBytes(); - - /** - * - * - *
-   * The full project name within the host. Projects may be nested, so
-   * "project/subproject" is a valid project name. The "repo name" is the
-   * hostURI/project.
-   * 
- * - * string gerrit_project = 2; - */ - java.lang.String getGerritProject(); - /** - * - * - *
-   * The full project name within the host. Projects may be nested, so
-   * "project/subproject" is a valid project name. The "repo name" is the
-   * hostURI/project.
-   * 
- * - * string gerrit_project = 2; - */ - com.google.protobuf.ByteString getGerritProjectBytes(); - - /** - * - * - *
-   * A revision (commit) ID.
-   * 
- * - * string revision_id = 3; - */ - java.lang.String getRevisionId(); - /** - * - * - *
-   * A revision (commit) ID.
-   * 
- * - * string revision_id = 3; - */ - com.google.protobuf.ByteString getRevisionIdBytes(); - - /** - * - * - *
-   * An alias, which may be a branch or tag.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - boolean hasAliasContext(); - /** - * - * - *
-   * An alias, which may be a branch or tag.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - io.grafeas.v1beta1.source.AliasContext getAliasContext(); - /** - * - * - *
-   * An alias, which may be a branch or tag.
-   * 
- * - * .grafeas.v1beta1.source.AliasContext alias_context = 4; - */ - io.grafeas.v1beta1.source.AliasContextOrBuilder getAliasContextOrBuilder(); - - public io.grafeas.v1beta1.source.GerritSourceContext.RevisionCase getRevisionCase(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GitSourceContext.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GitSourceContext.java deleted file mode 100644 index 8de5fa81..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GitSourceContext.java +++ /dev/null @@ -1,759 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -/** - * - * - *
- * A GitSourceContext denotes a particular revision in a third party Git
- * repository (e.g., GitHub).
- * 
- * - * Protobuf type {@code grafeas.v1beta1.source.GitSourceContext} - */ -public final class GitSourceContext extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.source.GitSourceContext) - GitSourceContextOrBuilder { - private static final long serialVersionUID = 0L; - // Use GitSourceContext.newBuilder() to construct. - private GitSourceContext(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private GitSourceContext() { - url_ = ""; - revisionId_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private GitSourceContext( - 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(); - - url_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - revisionId_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_GitSourceContext_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_GitSourceContext_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.GitSourceContext.class, - io.grafeas.v1beta1.source.GitSourceContext.Builder.class); - } - - public static final int URL_FIELD_NUMBER = 1; - private volatile java.lang.Object url_; - /** - * - * - *
-   * Git repository URL.
-   * 
- * - * string url = 1; - */ - public java.lang.String getUrl() { - java.lang.Object ref = url_; - 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(); - url_ = s; - return s; - } - } - /** - * - * - *
-   * Git repository URL.
-   * 
- * - * string url = 1; - */ - public com.google.protobuf.ByteString getUrlBytes() { - java.lang.Object ref = url_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - url_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int REVISION_ID_FIELD_NUMBER = 2; - private volatile java.lang.Object revisionId_; - /** - * - * - *
-   * Git commit hash.
-   * 
- * - * string revision_id = 2; - */ - public java.lang.String getRevisionId() { - java.lang.Object ref = revisionId_; - 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(); - revisionId_ = s; - return s; - } - } - /** - * - * - *
-   * Git commit hash.
-   * 
- * - * string revision_id = 2; - */ - public com.google.protobuf.ByteString getRevisionIdBytes() { - java.lang.Object ref = revisionId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - revisionId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getUrlBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, url_); - } - if (!getRevisionIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, revisionId_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getUrlBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, url_); - } - if (!getRevisionIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, revisionId_); - } - 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 io.grafeas.v1beta1.source.GitSourceContext)) { - return super.equals(obj); - } - io.grafeas.v1beta1.source.GitSourceContext other = - (io.grafeas.v1beta1.source.GitSourceContext) obj; - - if (!getUrl().equals(other.getUrl())) return false; - if (!getRevisionId().equals(other.getRevisionId())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + URL_FIELD_NUMBER; - hash = (53 * hash) + getUrl().hashCode(); - hash = (37 * hash) + REVISION_ID_FIELD_NUMBER; - hash = (53 * hash) + getRevisionId().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.source.GitSourceContext parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.GitSourceContext parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.GitSourceContext parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.GitSourceContext parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.GitSourceContext parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.GitSourceContext parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.GitSourceContext parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.GitSourceContext 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 io.grafeas.v1beta1.source.GitSourceContext parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.GitSourceContext 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 io.grafeas.v1beta1.source.GitSourceContext parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.GitSourceContext 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(io.grafeas.v1beta1.source.GitSourceContext prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A GitSourceContext denotes a particular revision in a third party Git
-   * repository (e.g., GitHub).
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.source.GitSourceContext} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.source.GitSourceContext) - io.grafeas.v1beta1.source.GitSourceContextOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_GitSourceContext_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_GitSourceContext_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.GitSourceContext.class, - io.grafeas.v1beta1.source.GitSourceContext.Builder.class); - } - - // Construct using io.grafeas.v1beta1.source.GitSourceContext.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - url_ = ""; - - revisionId_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_GitSourceContext_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.GitSourceContext getDefaultInstanceForType() { - return io.grafeas.v1beta1.source.GitSourceContext.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.source.GitSourceContext build() { - io.grafeas.v1beta1.source.GitSourceContext result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.GitSourceContext buildPartial() { - io.grafeas.v1beta1.source.GitSourceContext result = - new io.grafeas.v1beta1.source.GitSourceContext(this); - result.url_ = url_; - result.revisionId_ = revisionId_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.source.GitSourceContext) { - return mergeFrom((io.grafeas.v1beta1.source.GitSourceContext) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.source.GitSourceContext other) { - if (other == io.grafeas.v1beta1.source.GitSourceContext.getDefaultInstance()) return this; - if (!other.getUrl().isEmpty()) { - url_ = other.url_; - onChanged(); - } - if (!other.getRevisionId().isEmpty()) { - revisionId_ = other.revisionId_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.source.GitSourceContext parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.source.GitSourceContext) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object url_ = ""; - /** - * - * - *
-     * Git repository URL.
-     * 
- * - * string url = 1; - */ - public java.lang.String getUrl() { - java.lang.Object ref = url_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - url_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Git repository URL.
-     * 
- * - * string url = 1; - */ - public com.google.protobuf.ByteString getUrlBytes() { - java.lang.Object ref = url_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - url_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Git repository URL.
-     * 
- * - * string url = 1; - */ - public Builder setUrl(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - url_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Git repository URL.
-     * 
- * - * string url = 1; - */ - public Builder clearUrl() { - - url_ = getDefaultInstance().getUrl(); - onChanged(); - return this; - } - /** - * - * - *
-     * Git repository URL.
-     * 
- * - * string url = 1; - */ - public Builder setUrlBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - url_ = value; - onChanged(); - return this; - } - - private java.lang.Object revisionId_ = ""; - /** - * - * - *
-     * Git commit hash.
-     * 
- * - * string revision_id = 2; - */ - public java.lang.String getRevisionId() { - java.lang.Object ref = revisionId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - revisionId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Git commit hash.
-     * 
- * - * string revision_id = 2; - */ - public com.google.protobuf.ByteString getRevisionIdBytes() { - java.lang.Object ref = revisionId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - revisionId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Git commit hash.
-     * 
- * - * string revision_id = 2; - */ - public Builder setRevisionId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - revisionId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Git commit hash.
-     * 
- * - * string revision_id = 2; - */ - public Builder clearRevisionId() { - - revisionId_ = getDefaultInstance().getRevisionId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Git commit hash.
-     * 
- * - * string revision_id = 2; - */ - public Builder setRevisionIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - revisionId_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.source.GitSourceContext) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.source.GitSourceContext) - private static final io.grafeas.v1beta1.source.GitSourceContext DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.source.GitSourceContext(); - } - - public static io.grafeas.v1beta1.source.GitSourceContext getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GitSourceContext parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new GitSourceContext(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.GitSourceContext getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GitSourceContextOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GitSourceContextOrBuilder.java deleted file mode 100644 index dc548d46..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/GitSourceContextOrBuilder.java +++ /dev/null @@ -1,52 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -public interface GitSourceContextOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.source.GitSourceContext) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Git repository URL.
-   * 
- * - * string url = 1; - */ - java.lang.String getUrl(); - /** - * - * - *
-   * Git repository URL.
-   * 
- * - * string url = 1; - */ - com.google.protobuf.ByteString getUrlBytes(); - - /** - * - * - *
-   * Git commit hash.
-   * 
- * - * string revision_id = 2; - */ - java.lang.String getRevisionId(); - /** - * - * - *
-   * Git commit hash.
-   * 
- * - * string revision_id = 2; - */ - com.google.protobuf.ByteString getRevisionIdBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/IamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/IamResourceName.java deleted file mode 100644 index 3b25c4e1..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/IamResourceName.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.source; - -import com.google.api.resourcenames.ResourceName; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public abstract class IamResourceName implements ResourceName { - protected IamResourceName() {} -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/IamResourceNames.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/IamResourceNames.java deleted file mode 100644 index 7e177013..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/IamResourceNames.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.source; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class IamResourceNames { - private IamResourceNames() {} - - public static IamResourceName parse(String resourceNameString) { - if (NoteName.isParsableFrom(resourceNameString)) { - return NoteName.parse(resourceNameString); - } - if (OccurrenceName.isParsableFrom(resourceNameString)) { - return OccurrenceName.parse(resourceNameString); - } - return UntypedIamResourceName.parse(resourceNameString); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/NoteName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/NoteName.java deleted file mode 100644 index 4baf191a..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/NoteName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.source; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class NoteName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/notes/{note}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/OccurrenceName.java deleted file mode 100644 index f7878ff0..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.source; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ProjectName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ProjectName.java deleted file mode 100644 index 78d579e1..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.source; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ProjectRepoId.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ProjectRepoId.java deleted file mode 100644 index 40b590e0..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ProjectRepoId.java +++ /dev/null @@ -1,758 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -/** - * - * - *
- * Selects a repo using a Google Cloud Platform project ID (e.g.,
- * winged-cargo-31) and a repo name within that project.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.source.ProjectRepoId} - */ -public final class ProjectRepoId extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.source.ProjectRepoId) - ProjectRepoIdOrBuilder { - private static final long serialVersionUID = 0L; - // Use ProjectRepoId.newBuilder() to construct. - private ProjectRepoId(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ProjectRepoId() { - projectId_ = ""; - repoName_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ProjectRepoId( - 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(); - - projectId_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - repoName_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_ProjectRepoId_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_ProjectRepoId_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.ProjectRepoId.class, - io.grafeas.v1beta1.source.ProjectRepoId.Builder.class); - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * The ID of the project.
-   * 
- * - * string project_id = 1; - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - 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(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * The ID of the project.
-   * 
- * - * string project_id = 1; - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int REPO_NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object repoName_; - /** - * - * - *
-   * The name of the repo. Leave empty for the default repo.
-   * 
- * - * string repo_name = 2; - */ - public java.lang.String getRepoName() { - java.lang.Object ref = repoName_; - 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(); - repoName_ = s; - return s; - } - } - /** - * - * - *
-   * The name of the repo. Leave empty for the default repo.
-   * 
- * - * string repo_name = 2; - */ - public com.google.protobuf.ByteString getRepoNameBytes() { - java.lang.Object ref = repoName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - repoName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getProjectIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (!getRepoNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, repoName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getProjectIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (!getRepoNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, repoName_); - } - 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 io.grafeas.v1beta1.source.ProjectRepoId)) { - return super.equals(obj); - } - io.grafeas.v1beta1.source.ProjectRepoId other = (io.grafeas.v1beta1.source.ProjectRepoId) obj; - - if (!getProjectId().equals(other.getProjectId())) return false; - if (!getRepoName().equals(other.getRepoName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + REPO_NAME_FIELD_NUMBER; - hash = (53 * hash) + getRepoName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.source.ProjectRepoId parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.ProjectRepoId parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.ProjectRepoId parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.ProjectRepoId parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.ProjectRepoId parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.ProjectRepoId parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.ProjectRepoId parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.ProjectRepoId 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 io.grafeas.v1beta1.source.ProjectRepoId parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.ProjectRepoId 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 io.grafeas.v1beta1.source.ProjectRepoId parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.ProjectRepoId 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(io.grafeas.v1beta1.source.ProjectRepoId 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; - } - /** - * - * - *
-   * Selects a repo using a Google Cloud Platform project ID (e.g.,
-   * winged-cargo-31) and a repo name within that project.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.source.ProjectRepoId} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.source.ProjectRepoId) - io.grafeas.v1beta1.source.ProjectRepoIdOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_ProjectRepoId_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_ProjectRepoId_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.ProjectRepoId.class, - io.grafeas.v1beta1.source.ProjectRepoId.Builder.class); - } - - // Construct using io.grafeas.v1beta1.source.ProjectRepoId.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - projectId_ = ""; - - repoName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_ProjectRepoId_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.ProjectRepoId getDefaultInstanceForType() { - return io.grafeas.v1beta1.source.ProjectRepoId.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.source.ProjectRepoId build() { - io.grafeas.v1beta1.source.ProjectRepoId result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.ProjectRepoId buildPartial() { - io.grafeas.v1beta1.source.ProjectRepoId result = - new io.grafeas.v1beta1.source.ProjectRepoId(this); - result.projectId_ = projectId_; - result.repoName_ = repoName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.source.ProjectRepoId) { - return mergeFrom((io.grafeas.v1beta1.source.ProjectRepoId) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.source.ProjectRepoId other) { - if (other == io.grafeas.v1beta1.source.ProjectRepoId.getDefaultInstance()) return this; - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (!other.getRepoName().isEmpty()) { - repoName_ = other.repoName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.source.ProjectRepoId parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.source.ProjectRepoId) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * The ID of the project.
-     * 
- * - * string project_id = 1; - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The ID of the project.
-     * 
- * - * string project_id = 1; - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The ID of the project.
-     * 
- * - * string project_id = 1; - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The ID of the project.
-     * 
- * - * string project_id = 1; - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * The ID of the project.
-     * 
- * - * string project_id = 1; - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.lang.Object repoName_ = ""; - /** - * - * - *
-     * The name of the repo. Leave empty for the default repo.
-     * 
- * - * string repo_name = 2; - */ - public java.lang.String getRepoName() { - java.lang.Object ref = repoName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - repoName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The name of the repo. Leave empty for the default repo.
-     * 
- * - * string repo_name = 2; - */ - public com.google.protobuf.ByteString getRepoNameBytes() { - java.lang.Object ref = repoName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - repoName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The name of the repo. Leave empty for the default repo.
-     * 
- * - * string repo_name = 2; - */ - public Builder setRepoName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - repoName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the repo. Leave empty for the default repo.
-     * 
- * - * string repo_name = 2; - */ - public Builder clearRepoName() { - - repoName_ = getDefaultInstance().getRepoName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the repo. Leave empty for the default repo.
-     * 
- * - * string repo_name = 2; - */ - public Builder setRepoNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - repoName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.source.ProjectRepoId) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.source.ProjectRepoId) - private static final io.grafeas.v1beta1.source.ProjectRepoId DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.source.ProjectRepoId(); - } - - public static io.grafeas.v1beta1.source.ProjectRepoId getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ProjectRepoId parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ProjectRepoId(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.ProjectRepoId getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ProjectRepoIdOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ProjectRepoIdOrBuilder.java deleted file mode 100644 index e276912e..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ProjectRepoIdOrBuilder.java +++ /dev/null @@ -1,52 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -public interface ProjectRepoIdOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.source.ProjectRepoId) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The ID of the project.
-   * 
- * - * string project_id = 1; - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * The ID of the project.
-   * 
- * - * string project_id = 1; - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * The name of the repo. Leave empty for the default repo.
-   * 
- * - * string repo_name = 2; - */ - java.lang.String getRepoName(); - /** - * - * - *
-   * The name of the repo. Leave empty for the default repo.
-   * 
- * - * string repo_name = 2; - */ - com.google.protobuf.ByteString getRepoNameBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/RepoId.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/RepoId.java deleted file mode 100644 index 170712cd..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/RepoId.java +++ /dev/null @@ -1,975 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -/** - * - * - *
- * A unique identifier for a Cloud Repo.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.source.RepoId} - */ -public final class RepoId extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.source.RepoId) - RepoIdOrBuilder { - private static final long serialVersionUID = 0L; - // Use RepoId.newBuilder() to construct. - private RepoId(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private RepoId() {} - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private RepoId( - 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: - { - io.grafeas.v1beta1.source.ProjectRepoId.Builder subBuilder = null; - if (idCase_ == 1) { - subBuilder = ((io.grafeas.v1beta1.source.ProjectRepoId) id_).toBuilder(); - } - id_ = - input.readMessage( - io.grafeas.v1beta1.source.ProjectRepoId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.source.ProjectRepoId) id_); - id_ = subBuilder.buildPartial(); - } - idCase_ = 1; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - idCase_ = 2; - id_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_RepoId_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_RepoId_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.RepoId.class, io.grafeas.v1beta1.source.RepoId.Builder.class); - } - - private int idCase_ = 0; - private java.lang.Object id_; - - public enum IdCase implements com.google.protobuf.Internal.EnumLite { - PROJECT_REPO_ID(1), - UID(2), - ID_NOT_SET(0); - private final int value; - - private IdCase(int value) { - this.value = value; - } - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static IdCase valueOf(int value) { - return forNumber(value); - } - - public static IdCase forNumber(int value) { - switch (value) { - case 1: - return PROJECT_REPO_ID; - case 2: - return UID; - case 0: - return ID_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public IdCase getIdCase() { - return IdCase.forNumber(idCase_); - } - - public static final int PROJECT_REPO_ID_FIELD_NUMBER = 1; - /** - * - * - *
-   * A combination of a project ID and a repo name.
-   * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - public boolean hasProjectRepoId() { - return idCase_ == 1; - } - /** - * - * - *
-   * A combination of a project ID and a repo name.
-   * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - public io.grafeas.v1beta1.source.ProjectRepoId getProjectRepoId() { - if (idCase_ == 1) { - return (io.grafeas.v1beta1.source.ProjectRepoId) id_; - } - return io.grafeas.v1beta1.source.ProjectRepoId.getDefaultInstance(); - } - /** - * - * - *
-   * A combination of a project ID and a repo name.
-   * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - public io.grafeas.v1beta1.source.ProjectRepoIdOrBuilder getProjectRepoIdOrBuilder() { - if (idCase_ == 1) { - return (io.grafeas.v1beta1.source.ProjectRepoId) id_; - } - return io.grafeas.v1beta1.source.ProjectRepoId.getDefaultInstance(); - } - - public static final int UID_FIELD_NUMBER = 2; - /** - * - * - *
-   * A server-assigned, globally unique identifier.
-   * 
- * - * string uid = 2; - */ - public java.lang.String getUid() { - java.lang.Object ref = ""; - if (idCase_ == 2) { - ref = id_; - } - 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(); - if (idCase_ == 2) { - id_ = s; - } - return s; - } - } - /** - * - * - *
-   * A server-assigned, globally unique identifier.
-   * 
- * - * string uid = 2; - */ - public com.google.protobuf.ByteString getUidBytes() { - java.lang.Object ref = ""; - if (idCase_ == 2) { - ref = id_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (idCase_ == 2) { - id_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (idCase_ == 1) { - output.writeMessage(1, (io.grafeas.v1beta1.source.ProjectRepoId) id_); - } - if (idCase_ == 2) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, id_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (idCase_ == 1) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 1, (io.grafeas.v1beta1.source.ProjectRepoId) id_); - } - if (idCase_ == 2) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, id_); - } - 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 io.grafeas.v1beta1.source.RepoId)) { - return super.equals(obj); - } - io.grafeas.v1beta1.source.RepoId other = (io.grafeas.v1beta1.source.RepoId) obj; - - if (!getIdCase().equals(other.getIdCase())) return false; - switch (idCase_) { - case 1: - if (!getProjectRepoId().equals(other.getProjectRepoId())) return false; - break; - case 2: - if (!getUid().equals(other.getUid())) return false; - break; - case 0: - default: - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (idCase_) { - case 1: - hash = (37 * hash) + PROJECT_REPO_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectRepoId().hashCode(); - break; - case 2: - hash = (37 * hash) + UID_FIELD_NUMBER; - hash = (53 * hash) + getUid().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.source.RepoId parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.RepoId parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.RepoId parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.RepoId parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.RepoId parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.RepoId parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.RepoId parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.RepoId 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 io.grafeas.v1beta1.source.RepoId parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.RepoId 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 io.grafeas.v1beta1.source.RepoId parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.RepoId 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(io.grafeas.v1beta1.source.RepoId prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A unique identifier for a Cloud Repo.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.source.RepoId} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.source.RepoId) - io.grafeas.v1beta1.source.RepoIdOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_RepoId_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_RepoId_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.RepoId.class, - io.grafeas.v1beta1.source.RepoId.Builder.class); - } - - // Construct using io.grafeas.v1beta1.source.RepoId.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - idCase_ = 0; - id_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_RepoId_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.RepoId getDefaultInstanceForType() { - return io.grafeas.v1beta1.source.RepoId.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.source.RepoId build() { - io.grafeas.v1beta1.source.RepoId result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.RepoId buildPartial() { - io.grafeas.v1beta1.source.RepoId result = new io.grafeas.v1beta1.source.RepoId(this); - if (idCase_ == 1) { - if (projectRepoIdBuilder_ == null) { - result.id_ = id_; - } else { - result.id_ = projectRepoIdBuilder_.build(); - } - } - if (idCase_ == 2) { - result.id_ = id_; - } - result.idCase_ = idCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.source.RepoId) { - return mergeFrom((io.grafeas.v1beta1.source.RepoId) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.source.RepoId other) { - if (other == io.grafeas.v1beta1.source.RepoId.getDefaultInstance()) return this; - switch (other.getIdCase()) { - case PROJECT_REPO_ID: - { - mergeProjectRepoId(other.getProjectRepoId()); - break; - } - case UID: - { - idCase_ = 2; - id_ = other.id_; - onChanged(); - break; - } - case ID_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.source.RepoId parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.source.RepoId) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int idCase_ = 0; - private java.lang.Object id_; - - public IdCase getIdCase() { - return IdCase.forNumber(idCase_); - } - - public Builder clearId() { - idCase_ = 0; - id_ = null; - onChanged(); - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.ProjectRepoId, - io.grafeas.v1beta1.source.ProjectRepoId.Builder, - io.grafeas.v1beta1.source.ProjectRepoIdOrBuilder> - projectRepoIdBuilder_; - /** - * - * - *
-     * A combination of a project ID and a repo name.
-     * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - public boolean hasProjectRepoId() { - return idCase_ == 1; - } - /** - * - * - *
-     * A combination of a project ID and a repo name.
-     * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - public io.grafeas.v1beta1.source.ProjectRepoId getProjectRepoId() { - if (projectRepoIdBuilder_ == null) { - if (idCase_ == 1) { - return (io.grafeas.v1beta1.source.ProjectRepoId) id_; - } - return io.grafeas.v1beta1.source.ProjectRepoId.getDefaultInstance(); - } else { - if (idCase_ == 1) { - return projectRepoIdBuilder_.getMessage(); - } - return io.grafeas.v1beta1.source.ProjectRepoId.getDefaultInstance(); - } - } - /** - * - * - *
-     * A combination of a project ID and a repo name.
-     * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - public Builder setProjectRepoId(io.grafeas.v1beta1.source.ProjectRepoId value) { - if (projectRepoIdBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - id_ = value; - onChanged(); - } else { - projectRepoIdBuilder_.setMessage(value); - } - idCase_ = 1; - return this; - } - /** - * - * - *
-     * A combination of a project ID and a repo name.
-     * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - public Builder setProjectRepoId( - io.grafeas.v1beta1.source.ProjectRepoId.Builder builderForValue) { - if (projectRepoIdBuilder_ == null) { - id_ = builderForValue.build(); - onChanged(); - } else { - projectRepoIdBuilder_.setMessage(builderForValue.build()); - } - idCase_ = 1; - return this; - } - /** - * - * - *
-     * A combination of a project ID and a repo name.
-     * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - public Builder mergeProjectRepoId(io.grafeas.v1beta1.source.ProjectRepoId value) { - if (projectRepoIdBuilder_ == null) { - if (idCase_ == 1 && id_ != io.grafeas.v1beta1.source.ProjectRepoId.getDefaultInstance()) { - id_ = - io.grafeas.v1beta1.source.ProjectRepoId.newBuilder( - (io.grafeas.v1beta1.source.ProjectRepoId) id_) - .mergeFrom(value) - .buildPartial(); - } else { - id_ = value; - } - onChanged(); - } else { - if (idCase_ == 1) { - projectRepoIdBuilder_.mergeFrom(value); - } - projectRepoIdBuilder_.setMessage(value); - } - idCase_ = 1; - return this; - } - /** - * - * - *
-     * A combination of a project ID and a repo name.
-     * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - public Builder clearProjectRepoId() { - if (projectRepoIdBuilder_ == null) { - if (idCase_ == 1) { - idCase_ = 0; - id_ = null; - onChanged(); - } - } else { - if (idCase_ == 1) { - idCase_ = 0; - id_ = null; - } - projectRepoIdBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A combination of a project ID and a repo name.
-     * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - public io.grafeas.v1beta1.source.ProjectRepoId.Builder getProjectRepoIdBuilder() { - return getProjectRepoIdFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A combination of a project ID and a repo name.
-     * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - public io.grafeas.v1beta1.source.ProjectRepoIdOrBuilder getProjectRepoIdOrBuilder() { - if ((idCase_ == 1) && (projectRepoIdBuilder_ != null)) { - return projectRepoIdBuilder_.getMessageOrBuilder(); - } else { - if (idCase_ == 1) { - return (io.grafeas.v1beta1.source.ProjectRepoId) id_; - } - return io.grafeas.v1beta1.source.ProjectRepoId.getDefaultInstance(); - } - } - /** - * - * - *
-     * A combination of a project ID and a repo name.
-     * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.ProjectRepoId, - io.grafeas.v1beta1.source.ProjectRepoId.Builder, - io.grafeas.v1beta1.source.ProjectRepoIdOrBuilder> - getProjectRepoIdFieldBuilder() { - if (projectRepoIdBuilder_ == null) { - if (!(idCase_ == 1)) { - id_ = io.grafeas.v1beta1.source.ProjectRepoId.getDefaultInstance(); - } - projectRepoIdBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.ProjectRepoId, - io.grafeas.v1beta1.source.ProjectRepoId.Builder, - io.grafeas.v1beta1.source.ProjectRepoIdOrBuilder>( - (io.grafeas.v1beta1.source.ProjectRepoId) id_, getParentForChildren(), isClean()); - id_ = null; - } - idCase_ = 1; - onChanged(); - ; - return projectRepoIdBuilder_; - } - - /** - * - * - *
-     * A server-assigned, globally unique identifier.
-     * 
- * - * string uid = 2; - */ - public java.lang.String getUid() { - java.lang.Object ref = ""; - if (idCase_ == 2) { - ref = id_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (idCase_ == 2) { - id_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * A server-assigned, globally unique identifier.
-     * 
- * - * string uid = 2; - */ - public com.google.protobuf.ByteString getUidBytes() { - java.lang.Object ref = ""; - if (idCase_ == 2) { - ref = id_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (idCase_ == 2) { - id_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * A server-assigned, globally unique identifier.
-     * 
- * - * string uid = 2; - */ - public Builder setUid(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - idCase_ = 2; - id_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * A server-assigned, globally unique identifier.
-     * 
- * - * string uid = 2; - */ - public Builder clearUid() { - if (idCase_ == 2) { - idCase_ = 0; - id_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-     * A server-assigned, globally unique identifier.
-     * 
- * - * string uid = 2; - */ - public Builder setUidBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - idCase_ = 2; - id_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.source.RepoId) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.source.RepoId) - private static final io.grafeas.v1beta1.source.RepoId DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.source.RepoId(); - } - - public static io.grafeas.v1beta1.source.RepoId getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public RepoId parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RepoId(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.RepoId getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/RepoIdOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/RepoIdOrBuilder.java deleted file mode 100644 index b93d8d5f..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/RepoIdOrBuilder.java +++ /dev/null @@ -1,64 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -public interface RepoIdOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.source.RepoId) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * A combination of a project ID and a repo name.
-   * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - boolean hasProjectRepoId(); - /** - * - * - *
-   * A combination of a project ID and a repo name.
-   * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - io.grafeas.v1beta1.source.ProjectRepoId getProjectRepoId(); - /** - * - * - *
-   * A combination of a project ID and a repo name.
-   * 
- * - * .grafeas.v1beta1.source.ProjectRepoId project_repo_id = 1; - */ - io.grafeas.v1beta1.source.ProjectRepoIdOrBuilder getProjectRepoIdOrBuilder(); - - /** - * - * - *
-   * A server-assigned, globally unique identifier.
-   * 
- * - * string uid = 2; - */ - java.lang.String getUid(); - /** - * - * - *
-   * A server-assigned, globally unique identifier.
-   * 
- * - * string uid = 2; - */ - com.google.protobuf.ByteString getUidBytes(); - - public io.grafeas.v1beta1.source.RepoId.IdCase getIdCase(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ScanConfigName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ScanConfigName.java deleted file mode 100644 index cc5cc0f9..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/ScanConfigName.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.source; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ScanConfigName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ScanConfigName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - scanConfig = Preconditions.checkNotNull(builder.getScanConfig()); - } - - public static ScanConfigName of(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build(); - } - - public static String format(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build().toString(); - } - - public static ScanConfigName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ScanConfigName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("scan_config")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ScanConfigName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("scanConfig", scanConfig); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "scan_config", scanConfig); - } - - /** Builder for ScanConfigName. */ - public static class Builder { - - private String project; - private String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setScanConfig(String scanConfig) { - this.scanConfig = scanConfig; - return this; - } - - private Builder() {} - - private Builder(ScanConfigName scanConfigName) { - project = scanConfigName.project; - scanConfig = scanConfigName.scanConfig; - } - - public ScanConfigName build() { - return new ScanConfigName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ScanConfigName) { - ScanConfigName that = (ScanConfigName) o; - return (this.project.equals(that.project)) && (this.scanConfig.equals(that.scanConfig)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= scanConfig.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/Source.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/Source.java deleted file mode 100644 index 25c86132..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/Source.java +++ /dev/null @@ -1,166 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -public final class Source { - private Source() {} - - 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_grafeas_v1beta1_source_SourceContext_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_source_SourceContext_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_source_SourceContext_LabelsEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_source_SourceContext_LabelsEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_source_AliasContext_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_source_AliasContext_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_source_CloudRepoSourceContext_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_source_CloudRepoSourceContext_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_source_GerritSourceContext_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_source_GerritSourceContext_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_source_GitSourceContext_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_source_GitSourceContext_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_source_RepoId_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_source_RepoId_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_source_ProjectRepoId_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_source_ProjectRepoId_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/devtools/containeranalysis/v1be" - + "ta1/source/source.proto\022\026grafeas.v1beta1" - + ".source\"\312\002\n\rSourceContext\022D\n\ncloud_repo\030" - + "\001 \001(\0132..grafeas.v1beta1.source.CloudRepo" - + "SourceContextH\000\022=\n\006gerrit\030\002 \001(\0132+.grafea" - + "s.v1beta1.source.GerritSourceContextH\000\0227" - + "\n\003git\030\003 \001(\0132(.grafeas.v1beta1.source.Git" - + "SourceContextH\000\022A\n\006labels\030\004 \003(\01321.grafea" - + "s.v1beta1.source.SourceContext.LabelsEnt" - + "ry\032-\n\013LabelsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030" - + "\002 \001(\t:\0028\001B\t\n\007context\"\226\001\n\014AliasContext\0227\n" - + "\004kind\030\001 \001(\0162).grafeas.v1beta1.source.Ali" - + "asContext.Kind\022\014\n\004name\030\002 \001(\t\"?\n\004Kind\022\024\n\020" - + "KIND_UNSPECIFIED\020\000\022\t\n\005FIXED\020\001\022\013\n\007MOVABLE" - + "\020\002\022\t\n\005OTHER\020\004\"\253\001\n\026CloudRepoSourceContext" - + "\022/\n\007repo_id\030\001 \001(\0132\036.grafeas.v1beta1.sour" - + "ce.RepoId\022\025\n\013revision_id\030\002 \001(\tH\000\022=\n\ralia" - + "s_context\030\003 \001(\0132$.grafeas.v1beta1.source" - + ".AliasContextH\000B\n\n\010revision\"\241\001\n\023GerritSo" - + "urceContext\022\020\n\010host_uri\030\001 \001(\t\022\026\n\016gerrit_" - + "project\030\002 \001(\t\022\025\n\013revision_id\030\003 \001(\tH\000\022=\n\r" - + "alias_context\030\004 \001(\0132$.grafeas.v1beta1.so" - + "urce.AliasContextH\000B\n\n\010revision\"4\n\020GitSo" - + "urceContext\022\013\n\003url\030\001 \001(\t\022\023\n\013revision_id\030" - + "\002 \001(\t\"_\n\006RepoId\022@\n\017project_repo_id\030\001 \001(\013" - + "2%.grafeas.v1beta1.source.ProjectRepoIdH" - + "\000\022\r\n\003uid\030\002 \001(\tH\000B\004\n\002id\"6\n\rProjectRepoId\022" - + "\022\n\nproject_id\030\001 \001(\t\022\021\n\trepo_name\030\002 \001(\tB{" - + "\n\031io.grafeas.v1beta1.sourceP\001ZVgoogle.go" - + "lang.org/genproto/googleapis/devtools/co" - + "ntaineranalysis/v1beta1/source;source\242\002\003" - + "GRAb\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[] {}, assigner); - internal_static_grafeas_v1beta1_source_SourceContext_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_grafeas_v1beta1_source_SourceContext_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_source_SourceContext_descriptor, - new java.lang.String[] { - "CloudRepo", "Gerrit", "Git", "Labels", "Context", - }); - internal_static_grafeas_v1beta1_source_SourceContext_LabelsEntry_descriptor = - internal_static_grafeas_v1beta1_source_SourceContext_descriptor.getNestedTypes().get(0); - internal_static_grafeas_v1beta1_source_SourceContext_LabelsEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_source_SourceContext_LabelsEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_grafeas_v1beta1_source_AliasContext_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_grafeas_v1beta1_source_AliasContext_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_source_AliasContext_descriptor, - new java.lang.String[] { - "Kind", "Name", - }); - internal_static_grafeas_v1beta1_source_CloudRepoSourceContext_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_grafeas_v1beta1_source_CloudRepoSourceContext_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_source_CloudRepoSourceContext_descriptor, - new java.lang.String[] { - "RepoId", "RevisionId", "AliasContext", "Revision", - }); - internal_static_grafeas_v1beta1_source_GerritSourceContext_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_grafeas_v1beta1_source_GerritSourceContext_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_source_GerritSourceContext_descriptor, - new java.lang.String[] { - "HostUri", "GerritProject", "RevisionId", "AliasContext", "Revision", - }); - internal_static_grafeas_v1beta1_source_GitSourceContext_descriptor = - getDescriptor().getMessageTypes().get(4); - internal_static_grafeas_v1beta1_source_GitSourceContext_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_source_GitSourceContext_descriptor, - new java.lang.String[] { - "Url", "RevisionId", - }); - internal_static_grafeas_v1beta1_source_RepoId_descriptor = - getDescriptor().getMessageTypes().get(5); - internal_static_grafeas_v1beta1_source_RepoId_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_source_RepoId_descriptor, - new java.lang.String[] { - "ProjectRepoId", "Uid", "Id", - }); - internal_static_grafeas_v1beta1_source_ProjectRepoId_descriptor = - getDescriptor().getMessageTypes().get(6); - internal_static_grafeas_v1beta1_source_ProjectRepoId_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_source_ProjectRepoId_descriptor, - new java.lang.String[] { - "ProjectId", "RepoName", - }); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/SourceContext.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/SourceContext.java deleted file mode 100644 index fef52ae9..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/SourceContext.java +++ /dev/null @@ -1,1693 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -/** - * - * - *
- * A SourceContext is a reference to a tree of files. A SourceContext together
- * with a path point to a unique revision of a single file or directory.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.source.SourceContext} - */ -public final class SourceContext extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.source.SourceContext) - SourceContextOrBuilder { - private static final long serialVersionUID = 0L; - // Use SourceContext.newBuilder() to construct. - private SourceContext(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private SourceContext() {} - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private SourceContext( - 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: - { - io.grafeas.v1beta1.source.CloudRepoSourceContext.Builder subBuilder = null; - if (contextCase_ == 1) { - subBuilder = - ((io.grafeas.v1beta1.source.CloudRepoSourceContext) context_).toBuilder(); - } - context_ = - input.readMessage( - io.grafeas.v1beta1.source.CloudRepoSourceContext.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.source.CloudRepoSourceContext) context_); - context_ = subBuilder.buildPartial(); - } - contextCase_ = 1; - break; - } - case 18: - { - io.grafeas.v1beta1.source.GerritSourceContext.Builder subBuilder = null; - if (contextCase_ == 2) { - subBuilder = ((io.grafeas.v1beta1.source.GerritSourceContext) context_).toBuilder(); - } - context_ = - input.readMessage( - io.grafeas.v1beta1.source.GerritSourceContext.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.source.GerritSourceContext) context_); - context_ = subBuilder.buildPartial(); - } - contextCase_ = 2; - break; - } - case 26: - { - io.grafeas.v1beta1.source.GitSourceContext.Builder subBuilder = null; - if (contextCase_ == 3) { - subBuilder = ((io.grafeas.v1beta1.source.GitSourceContext) context_).toBuilder(); - } - context_ = - input.readMessage( - io.grafeas.v1beta1.source.GitSourceContext.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((io.grafeas.v1beta1.source.GitSourceContext) context_); - context_ = subBuilder.buildPartial(); - } - contextCase_ = 3; - break; - } - case 34: - { - if (!((mutable_bitField0_ & 0x00000008) != 0)) { - labels_ = - com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000008; - } - com.google.protobuf.MapEntry labels__ = - input.readMessage( - LabelsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); - labels_.getMutableMap().put(labels__.getKey(), labels__.getValue()); - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_SourceContext_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 4: - return internalGetLabels(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_SourceContext_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.SourceContext.class, - io.grafeas.v1beta1.source.SourceContext.Builder.class); - } - - private int bitField0_; - private int contextCase_ = 0; - private java.lang.Object context_; - - public enum ContextCase implements com.google.protobuf.Internal.EnumLite { - CLOUD_REPO(1), - GERRIT(2), - GIT(3), - CONTEXT_NOT_SET(0); - private final int value; - - private ContextCase(int value) { - this.value = value; - } - /** @deprecated Use {@link #forNumber(int)} instead. */ - @java.lang.Deprecated - public static ContextCase valueOf(int value) { - return forNumber(value); - } - - public static ContextCase forNumber(int value) { - switch (value) { - case 1: - return CLOUD_REPO; - case 2: - return GERRIT; - case 3: - return GIT; - case 0: - return CONTEXT_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public ContextCase getContextCase() { - return ContextCase.forNumber(contextCase_); - } - - public static final int CLOUD_REPO_FIELD_NUMBER = 1; - /** - * - * - *
-   * A SourceContext referring to a revision in a Google Cloud Source Repo.
-   * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - public boolean hasCloudRepo() { - return contextCase_ == 1; - } - /** - * - * - *
-   * A SourceContext referring to a revision in a Google Cloud Source Repo.
-   * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - public io.grafeas.v1beta1.source.CloudRepoSourceContext getCloudRepo() { - if (contextCase_ == 1) { - return (io.grafeas.v1beta1.source.CloudRepoSourceContext) context_; - } - return io.grafeas.v1beta1.source.CloudRepoSourceContext.getDefaultInstance(); - } - /** - * - * - *
-   * A SourceContext referring to a revision in a Google Cloud Source Repo.
-   * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - public io.grafeas.v1beta1.source.CloudRepoSourceContextOrBuilder getCloudRepoOrBuilder() { - if (contextCase_ == 1) { - return (io.grafeas.v1beta1.source.CloudRepoSourceContext) context_; - } - return io.grafeas.v1beta1.source.CloudRepoSourceContext.getDefaultInstance(); - } - - public static final int GERRIT_FIELD_NUMBER = 2; - /** - * - * - *
-   * A SourceContext referring to a Gerrit project.
-   * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - public boolean hasGerrit() { - return contextCase_ == 2; - } - /** - * - * - *
-   * A SourceContext referring to a Gerrit project.
-   * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - public io.grafeas.v1beta1.source.GerritSourceContext getGerrit() { - if (contextCase_ == 2) { - return (io.grafeas.v1beta1.source.GerritSourceContext) context_; - } - return io.grafeas.v1beta1.source.GerritSourceContext.getDefaultInstance(); - } - /** - * - * - *
-   * A SourceContext referring to a Gerrit project.
-   * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - public io.grafeas.v1beta1.source.GerritSourceContextOrBuilder getGerritOrBuilder() { - if (contextCase_ == 2) { - return (io.grafeas.v1beta1.source.GerritSourceContext) context_; - } - return io.grafeas.v1beta1.source.GerritSourceContext.getDefaultInstance(); - } - - public static final int GIT_FIELD_NUMBER = 3; - /** - * - * - *
-   * A SourceContext referring to any third party Git repo (e.g., GitHub).
-   * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - public boolean hasGit() { - return contextCase_ == 3; - } - /** - * - * - *
-   * A SourceContext referring to any third party Git repo (e.g., GitHub).
-   * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - public io.grafeas.v1beta1.source.GitSourceContext getGit() { - if (contextCase_ == 3) { - return (io.grafeas.v1beta1.source.GitSourceContext) context_; - } - return io.grafeas.v1beta1.source.GitSourceContext.getDefaultInstance(); - } - /** - * - * - *
-   * A SourceContext referring to any third party Git repo (e.g., GitHub).
-   * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - public io.grafeas.v1beta1.source.GitSourceContextOrBuilder getGitOrBuilder() { - if (contextCase_ == 3) { - return (io.grafeas.v1beta1.source.GitSourceContext) context_; - } - return io.grafeas.v1beta1.source.GitSourceContext.getDefaultInstance(); - } - - public static final int LABELS_FIELD_NUMBER = 4; - - private static final class LabelsDefaultEntryHolder { - static final com.google.protobuf.MapEntry defaultEntry = - com.google.protobuf.MapEntry.newDefaultInstance( - io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_SourceContext_LabelsEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.STRING, - ""); - } - - private com.google.protobuf.MapField labels_; - - private com.google.protobuf.MapField internalGetLabels() { - if (labels_ == null) { - return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); - } - return labels_; - } - - public int getLabelsCount() { - return internalGetLabels().getMap().size(); - } - /** - * - * - *
-   * Labels with user defined metadata.
-   * 
- * - * map<string, string> labels = 4; - */ - public boolean containsLabels(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - return internalGetLabels().getMap().containsKey(key); - } - /** Use {@link #getLabelsMap()} instead. */ - @java.lang.Deprecated - public java.util.Map getLabels() { - return getLabelsMap(); - } - /** - * - * - *
-   * Labels with user defined metadata.
-   * 
- * - * map<string, string> labels = 4; - */ - public java.util.Map getLabelsMap() { - return internalGetLabels().getMap(); - } - /** - * - * - *
-   * Labels with user defined metadata.
-   * 
- * - * map<string, string> labels = 4; - */ - public java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetLabels().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-   * Labels with user defined metadata.
-   * 
- * - * map<string, string> labels = 4; - */ - public java.lang.String getLabelsOrThrow(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetLabels().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - 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 (contextCase_ == 1) { - output.writeMessage(1, (io.grafeas.v1beta1.source.CloudRepoSourceContext) context_); - } - if (contextCase_ == 2) { - output.writeMessage(2, (io.grafeas.v1beta1.source.GerritSourceContext) context_); - } - if (contextCase_ == 3) { - output.writeMessage(3, (io.grafeas.v1beta1.source.GitSourceContext) context_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 4); - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (contextCase_ == 1) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 1, (io.grafeas.v1beta1.source.CloudRepoSourceContext) context_); - } - if (contextCase_ == 2) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 2, (io.grafeas.v1beta1.source.GerritSourceContext) context_); - } - if (contextCase_ == 3) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 3, (io.grafeas.v1beta1.source.GitSourceContext) context_); - } - for (java.util.Map.Entry entry : - internalGetLabels().getMap().entrySet()) { - com.google.protobuf.MapEntry labels__ = - LabelsDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, labels__); - } - 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 io.grafeas.v1beta1.source.SourceContext)) { - return super.equals(obj); - } - io.grafeas.v1beta1.source.SourceContext other = (io.grafeas.v1beta1.source.SourceContext) obj; - - if (!internalGetLabels().equals(other.internalGetLabels())) return false; - if (!getContextCase().equals(other.getContextCase())) return false; - switch (contextCase_) { - case 1: - if (!getCloudRepo().equals(other.getCloudRepo())) return false; - break; - case 2: - if (!getGerrit().equals(other.getGerrit())) return false; - break; - case 3: - if (!getGit().equals(other.getGit())) return false; - break; - case 0: - default: - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (!internalGetLabels().getMap().isEmpty()) { - hash = (37 * hash) + LABELS_FIELD_NUMBER; - hash = (53 * hash) + internalGetLabels().hashCode(); - } - switch (contextCase_) { - case 1: - hash = (37 * hash) + CLOUD_REPO_FIELD_NUMBER; - hash = (53 * hash) + getCloudRepo().hashCode(); - break; - case 2: - hash = (37 * hash) + GERRIT_FIELD_NUMBER; - hash = (53 * hash) + getGerrit().hashCode(); - break; - case 3: - hash = (37 * hash) + GIT_FIELD_NUMBER; - hash = (53 * hash) + getGit().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.source.SourceContext parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.SourceContext parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.SourceContext parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.SourceContext parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.SourceContext parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.source.SourceContext parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.source.SourceContext parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.SourceContext 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 io.grafeas.v1beta1.source.SourceContext parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.SourceContext 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 io.grafeas.v1beta1.source.SourceContext parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.source.SourceContext 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(io.grafeas.v1beta1.source.SourceContext prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A SourceContext is a reference to a tree of files. A SourceContext together
-   * with a path point to a unique revision of a single file or directory.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.source.SourceContext} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.source.SourceContext) - io.grafeas.v1beta1.source.SourceContextOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_SourceContext_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 4: - return internalGetLabels(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 4: - return internalGetMutableLabels(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_SourceContext_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.source.SourceContext.class, - io.grafeas.v1beta1.source.SourceContext.Builder.class); - } - - // Construct using io.grafeas.v1beta1.source.SourceContext.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - internalGetMutableLabels().clear(); - contextCase_ = 0; - context_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.source.Source - .internal_static_grafeas_v1beta1_source_SourceContext_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.SourceContext getDefaultInstanceForType() { - return io.grafeas.v1beta1.source.SourceContext.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.source.SourceContext build() { - io.grafeas.v1beta1.source.SourceContext result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.SourceContext buildPartial() { - io.grafeas.v1beta1.source.SourceContext result = - new io.grafeas.v1beta1.source.SourceContext(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (contextCase_ == 1) { - if (cloudRepoBuilder_ == null) { - result.context_ = context_; - } else { - result.context_ = cloudRepoBuilder_.build(); - } - } - if (contextCase_ == 2) { - if (gerritBuilder_ == null) { - result.context_ = context_; - } else { - result.context_ = gerritBuilder_.build(); - } - } - if (contextCase_ == 3) { - if (gitBuilder_ == null) { - result.context_ = context_; - } else { - result.context_ = gitBuilder_.build(); - } - } - result.labels_ = internalGetLabels(); - result.labels_.makeImmutable(); - result.bitField0_ = to_bitField0_; - result.contextCase_ = contextCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.source.SourceContext) { - return mergeFrom((io.grafeas.v1beta1.source.SourceContext) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.source.SourceContext other) { - if (other == io.grafeas.v1beta1.source.SourceContext.getDefaultInstance()) return this; - internalGetMutableLabels().mergeFrom(other.internalGetLabels()); - switch (other.getContextCase()) { - case CLOUD_REPO: - { - mergeCloudRepo(other.getCloudRepo()); - break; - } - case GERRIT: - { - mergeGerrit(other.getGerrit()); - break; - } - case GIT: - { - mergeGit(other.getGit()); - break; - } - case CONTEXT_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.source.SourceContext parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.source.SourceContext) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int contextCase_ = 0; - private java.lang.Object context_; - - public ContextCase getContextCase() { - return ContextCase.forNumber(contextCase_); - } - - public Builder clearContext() { - contextCase_ = 0; - context_ = null; - onChanged(); - return this; - } - - private int bitField0_; - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.CloudRepoSourceContext, - io.grafeas.v1beta1.source.CloudRepoSourceContext.Builder, - io.grafeas.v1beta1.source.CloudRepoSourceContextOrBuilder> - cloudRepoBuilder_; - /** - * - * - *
-     * A SourceContext referring to a revision in a Google Cloud Source Repo.
-     * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - public boolean hasCloudRepo() { - return contextCase_ == 1; - } - /** - * - * - *
-     * A SourceContext referring to a revision in a Google Cloud Source Repo.
-     * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - public io.grafeas.v1beta1.source.CloudRepoSourceContext getCloudRepo() { - if (cloudRepoBuilder_ == null) { - if (contextCase_ == 1) { - return (io.grafeas.v1beta1.source.CloudRepoSourceContext) context_; - } - return io.grafeas.v1beta1.source.CloudRepoSourceContext.getDefaultInstance(); - } else { - if (contextCase_ == 1) { - return cloudRepoBuilder_.getMessage(); - } - return io.grafeas.v1beta1.source.CloudRepoSourceContext.getDefaultInstance(); - } - } - /** - * - * - *
-     * A SourceContext referring to a revision in a Google Cloud Source Repo.
-     * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - public Builder setCloudRepo(io.grafeas.v1beta1.source.CloudRepoSourceContext value) { - if (cloudRepoBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - context_ = value; - onChanged(); - } else { - cloudRepoBuilder_.setMessage(value); - } - contextCase_ = 1; - return this; - } - /** - * - * - *
-     * A SourceContext referring to a revision in a Google Cloud Source Repo.
-     * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - public Builder setCloudRepo( - io.grafeas.v1beta1.source.CloudRepoSourceContext.Builder builderForValue) { - if (cloudRepoBuilder_ == null) { - context_ = builderForValue.build(); - onChanged(); - } else { - cloudRepoBuilder_.setMessage(builderForValue.build()); - } - contextCase_ = 1; - return this; - } - /** - * - * - *
-     * A SourceContext referring to a revision in a Google Cloud Source Repo.
-     * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - public Builder mergeCloudRepo(io.grafeas.v1beta1.source.CloudRepoSourceContext value) { - if (cloudRepoBuilder_ == null) { - if (contextCase_ == 1 - && context_ != io.grafeas.v1beta1.source.CloudRepoSourceContext.getDefaultInstance()) { - context_ = - io.grafeas.v1beta1.source.CloudRepoSourceContext.newBuilder( - (io.grafeas.v1beta1.source.CloudRepoSourceContext) context_) - .mergeFrom(value) - .buildPartial(); - } else { - context_ = value; - } - onChanged(); - } else { - if (contextCase_ == 1) { - cloudRepoBuilder_.mergeFrom(value); - } - cloudRepoBuilder_.setMessage(value); - } - contextCase_ = 1; - return this; - } - /** - * - * - *
-     * A SourceContext referring to a revision in a Google Cloud Source Repo.
-     * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - public Builder clearCloudRepo() { - if (cloudRepoBuilder_ == null) { - if (contextCase_ == 1) { - contextCase_ = 0; - context_ = null; - onChanged(); - } - } else { - if (contextCase_ == 1) { - contextCase_ = 0; - context_ = null; - } - cloudRepoBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A SourceContext referring to a revision in a Google Cloud Source Repo.
-     * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - public io.grafeas.v1beta1.source.CloudRepoSourceContext.Builder getCloudRepoBuilder() { - return getCloudRepoFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A SourceContext referring to a revision in a Google Cloud Source Repo.
-     * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - public io.grafeas.v1beta1.source.CloudRepoSourceContextOrBuilder getCloudRepoOrBuilder() { - if ((contextCase_ == 1) && (cloudRepoBuilder_ != null)) { - return cloudRepoBuilder_.getMessageOrBuilder(); - } else { - if (contextCase_ == 1) { - return (io.grafeas.v1beta1.source.CloudRepoSourceContext) context_; - } - return io.grafeas.v1beta1.source.CloudRepoSourceContext.getDefaultInstance(); - } - } - /** - * - * - *
-     * A SourceContext referring to a revision in a Google Cloud Source Repo.
-     * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.CloudRepoSourceContext, - io.grafeas.v1beta1.source.CloudRepoSourceContext.Builder, - io.grafeas.v1beta1.source.CloudRepoSourceContextOrBuilder> - getCloudRepoFieldBuilder() { - if (cloudRepoBuilder_ == null) { - if (!(contextCase_ == 1)) { - context_ = io.grafeas.v1beta1.source.CloudRepoSourceContext.getDefaultInstance(); - } - cloudRepoBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.CloudRepoSourceContext, - io.grafeas.v1beta1.source.CloudRepoSourceContext.Builder, - io.grafeas.v1beta1.source.CloudRepoSourceContextOrBuilder>( - (io.grafeas.v1beta1.source.CloudRepoSourceContext) context_, - getParentForChildren(), - isClean()); - context_ = null; - } - contextCase_ = 1; - onChanged(); - ; - return cloudRepoBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.GerritSourceContext, - io.grafeas.v1beta1.source.GerritSourceContext.Builder, - io.grafeas.v1beta1.source.GerritSourceContextOrBuilder> - gerritBuilder_; - /** - * - * - *
-     * A SourceContext referring to a Gerrit project.
-     * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - public boolean hasGerrit() { - return contextCase_ == 2; - } - /** - * - * - *
-     * A SourceContext referring to a Gerrit project.
-     * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - public io.grafeas.v1beta1.source.GerritSourceContext getGerrit() { - if (gerritBuilder_ == null) { - if (contextCase_ == 2) { - return (io.grafeas.v1beta1.source.GerritSourceContext) context_; - } - return io.grafeas.v1beta1.source.GerritSourceContext.getDefaultInstance(); - } else { - if (contextCase_ == 2) { - return gerritBuilder_.getMessage(); - } - return io.grafeas.v1beta1.source.GerritSourceContext.getDefaultInstance(); - } - } - /** - * - * - *
-     * A SourceContext referring to a Gerrit project.
-     * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - public Builder setGerrit(io.grafeas.v1beta1.source.GerritSourceContext value) { - if (gerritBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - context_ = value; - onChanged(); - } else { - gerritBuilder_.setMessage(value); - } - contextCase_ = 2; - return this; - } - /** - * - * - *
-     * A SourceContext referring to a Gerrit project.
-     * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - public Builder setGerrit( - io.grafeas.v1beta1.source.GerritSourceContext.Builder builderForValue) { - if (gerritBuilder_ == null) { - context_ = builderForValue.build(); - onChanged(); - } else { - gerritBuilder_.setMessage(builderForValue.build()); - } - contextCase_ = 2; - return this; - } - /** - * - * - *
-     * A SourceContext referring to a Gerrit project.
-     * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - public Builder mergeGerrit(io.grafeas.v1beta1.source.GerritSourceContext value) { - if (gerritBuilder_ == null) { - if (contextCase_ == 2 - && context_ != io.grafeas.v1beta1.source.GerritSourceContext.getDefaultInstance()) { - context_ = - io.grafeas.v1beta1.source.GerritSourceContext.newBuilder( - (io.grafeas.v1beta1.source.GerritSourceContext) context_) - .mergeFrom(value) - .buildPartial(); - } else { - context_ = value; - } - onChanged(); - } else { - if (contextCase_ == 2) { - gerritBuilder_.mergeFrom(value); - } - gerritBuilder_.setMessage(value); - } - contextCase_ = 2; - return this; - } - /** - * - * - *
-     * A SourceContext referring to a Gerrit project.
-     * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - public Builder clearGerrit() { - if (gerritBuilder_ == null) { - if (contextCase_ == 2) { - contextCase_ = 0; - context_ = null; - onChanged(); - } - } else { - if (contextCase_ == 2) { - contextCase_ = 0; - context_ = null; - } - gerritBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A SourceContext referring to a Gerrit project.
-     * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - public io.grafeas.v1beta1.source.GerritSourceContext.Builder getGerritBuilder() { - return getGerritFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A SourceContext referring to a Gerrit project.
-     * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - public io.grafeas.v1beta1.source.GerritSourceContextOrBuilder getGerritOrBuilder() { - if ((contextCase_ == 2) && (gerritBuilder_ != null)) { - return gerritBuilder_.getMessageOrBuilder(); - } else { - if (contextCase_ == 2) { - return (io.grafeas.v1beta1.source.GerritSourceContext) context_; - } - return io.grafeas.v1beta1.source.GerritSourceContext.getDefaultInstance(); - } - } - /** - * - * - *
-     * A SourceContext referring to a Gerrit project.
-     * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.GerritSourceContext, - io.grafeas.v1beta1.source.GerritSourceContext.Builder, - io.grafeas.v1beta1.source.GerritSourceContextOrBuilder> - getGerritFieldBuilder() { - if (gerritBuilder_ == null) { - if (!(contextCase_ == 2)) { - context_ = io.grafeas.v1beta1.source.GerritSourceContext.getDefaultInstance(); - } - gerritBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.GerritSourceContext, - io.grafeas.v1beta1.source.GerritSourceContext.Builder, - io.grafeas.v1beta1.source.GerritSourceContextOrBuilder>( - (io.grafeas.v1beta1.source.GerritSourceContext) context_, - getParentForChildren(), - isClean()); - context_ = null; - } - contextCase_ = 2; - onChanged(); - ; - return gerritBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.GitSourceContext, - io.grafeas.v1beta1.source.GitSourceContext.Builder, - io.grafeas.v1beta1.source.GitSourceContextOrBuilder> - gitBuilder_; - /** - * - * - *
-     * A SourceContext referring to any third party Git repo (e.g., GitHub).
-     * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - public boolean hasGit() { - return contextCase_ == 3; - } - /** - * - * - *
-     * A SourceContext referring to any third party Git repo (e.g., GitHub).
-     * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - public io.grafeas.v1beta1.source.GitSourceContext getGit() { - if (gitBuilder_ == null) { - if (contextCase_ == 3) { - return (io.grafeas.v1beta1.source.GitSourceContext) context_; - } - return io.grafeas.v1beta1.source.GitSourceContext.getDefaultInstance(); - } else { - if (contextCase_ == 3) { - return gitBuilder_.getMessage(); - } - return io.grafeas.v1beta1.source.GitSourceContext.getDefaultInstance(); - } - } - /** - * - * - *
-     * A SourceContext referring to any third party Git repo (e.g., GitHub).
-     * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - public Builder setGit(io.grafeas.v1beta1.source.GitSourceContext value) { - if (gitBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - context_ = value; - onChanged(); - } else { - gitBuilder_.setMessage(value); - } - contextCase_ = 3; - return this; - } - /** - * - * - *
-     * A SourceContext referring to any third party Git repo (e.g., GitHub).
-     * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - public Builder setGit(io.grafeas.v1beta1.source.GitSourceContext.Builder builderForValue) { - if (gitBuilder_ == null) { - context_ = builderForValue.build(); - onChanged(); - } else { - gitBuilder_.setMessage(builderForValue.build()); - } - contextCase_ = 3; - return this; - } - /** - * - * - *
-     * A SourceContext referring to any third party Git repo (e.g., GitHub).
-     * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - public Builder mergeGit(io.grafeas.v1beta1.source.GitSourceContext value) { - if (gitBuilder_ == null) { - if (contextCase_ == 3 - && context_ != io.grafeas.v1beta1.source.GitSourceContext.getDefaultInstance()) { - context_ = - io.grafeas.v1beta1.source.GitSourceContext.newBuilder( - (io.grafeas.v1beta1.source.GitSourceContext) context_) - .mergeFrom(value) - .buildPartial(); - } else { - context_ = value; - } - onChanged(); - } else { - if (contextCase_ == 3) { - gitBuilder_.mergeFrom(value); - } - gitBuilder_.setMessage(value); - } - contextCase_ = 3; - return this; - } - /** - * - * - *
-     * A SourceContext referring to any third party Git repo (e.g., GitHub).
-     * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - public Builder clearGit() { - if (gitBuilder_ == null) { - if (contextCase_ == 3) { - contextCase_ = 0; - context_ = null; - onChanged(); - } - } else { - if (contextCase_ == 3) { - contextCase_ = 0; - context_ = null; - } - gitBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * A SourceContext referring to any third party Git repo (e.g., GitHub).
-     * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - public io.grafeas.v1beta1.source.GitSourceContext.Builder getGitBuilder() { - return getGitFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A SourceContext referring to any third party Git repo (e.g., GitHub).
-     * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - public io.grafeas.v1beta1.source.GitSourceContextOrBuilder getGitOrBuilder() { - if ((contextCase_ == 3) && (gitBuilder_ != null)) { - return gitBuilder_.getMessageOrBuilder(); - } else { - if (contextCase_ == 3) { - return (io.grafeas.v1beta1.source.GitSourceContext) context_; - } - return io.grafeas.v1beta1.source.GitSourceContext.getDefaultInstance(); - } - } - /** - * - * - *
-     * A SourceContext referring to any third party Git repo (e.g., GitHub).
-     * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.GitSourceContext, - io.grafeas.v1beta1.source.GitSourceContext.Builder, - io.grafeas.v1beta1.source.GitSourceContextOrBuilder> - getGitFieldBuilder() { - if (gitBuilder_ == null) { - if (!(contextCase_ == 3)) { - context_ = io.grafeas.v1beta1.source.GitSourceContext.getDefaultInstance(); - } - gitBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.source.GitSourceContext, - io.grafeas.v1beta1.source.GitSourceContext.Builder, - io.grafeas.v1beta1.source.GitSourceContextOrBuilder>( - (io.grafeas.v1beta1.source.GitSourceContext) context_, - getParentForChildren(), - isClean()); - context_ = null; - } - contextCase_ = 3; - onChanged(); - ; - return gitBuilder_; - } - - private com.google.protobuf.MapField labels_; - - private com.google.protobuf.MapField internalGetLabels() { - if (labels_ == null) { - return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); - } - return labels_; - } - - private com.google.protobuf.MapField - internalGetMutableLabels() { - onChanged(); - ; - if (labels_ == null) { - labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); - } - if (!labels_.isMutable()) { - labels_ = labels_.copy(); - } - return labels_; - } - - public int getLabelsCount() { - return internalGetLabels().getMap().size(); - } - /** - * - * - *
-     * Labels with user defined metadata.
-     * 
- * - * map<string, string> labels = 4; - */ - public boolean containsLabels(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - return internalGetLabels().getMap().containsKey(key); - } - /** Use {@link #getLabelsMap()} instead. */ - @java.lang.Deprecated - public java.util.Map getLabels() { - return getLabelsMap(); - } - /** - * - * - *
-     * Labels with user defined metadata.
-     * 
- * - * map<string, string> labels = 4; - */ - public java.util.Map getLabelsMap() { - return internalGetLabels().getMap(); - } - /** - * - * - *
-     * Labels with user defined metadata.
-     * 
- * - * map<string, string> labels = 4; - */ - public java.lang.String getLabelsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetLabels().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * Labels with user defined metadata.
-     * 
- * - * map<string, string> labels = 4; - */ - public java.lang.String getLabelsOrThrow(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetLabels().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearLabels() { - internalGetMutableLabels().getMutableMap().clear(); - return this; - } - /** - * - * - *
-     * Labels with user defined metadata.
-     * 
- * - * map<string, string> labels = 4; - */ - public Builder removeLabels(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - internalGetMutableLabels().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map getMutableLabels() { - return internalGetMutableLabels().getMutableMap(); - } - /** - * - * - *
-     * Labels with user defined metadata.
-     * 
- * - * map<string, string> labels = 4; - */ - public Builder putLabels(java.lang.String key, java.lang.String value) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - if (value == null) { - throw new java.lang.NullPointerException(); - } - internalGetMutableLabels().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-     * Labels with user defined metadata.
-     * 
- * - * map<string, string> labels = 4; - */ - public Builder putAllLabels(java.util.Map values) { - internalGetMutableLabels().getMutableMap().putAll(values); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.source.SourceContext) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.source.SourceContext) - private static final io.grafeas.v1beta1.source.SourceContext DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.source.SourceContext(); - } - - public static io.grafeas.v1beta1.source.SourceContext getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public SourceContext parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new SourceContext(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.source.SourceContext getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/SourceContextOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/SourceContextOrBuilder.java deleted file mode 100644 index 9787a96a..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/SourceContextOrBuilder.java +++ /dev/null @@ -1,159 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/source/source.proto - -package io.grafeas.v1beta1.source; - -public interface SourceContextOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.source.SourceContext) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * A SourceContext referring to a revision in a Google Cloud Source Repo.
-   * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - boolean hasCloudRepo(); - /** - * - * - *
-   * A SourceContext referring to a revision in a Google Cloud Source Repo.
-   * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - io.grafeas.v1beta1.source.CloudRepoSourceContext getCloudRepo(); - /** - * - * - *
-   * A SourceContext referring to a revision in a Google Cloud Source Repo.
-   * 
- * - * .grafeas.v1beta1.source.CloudRepoSourceContext cloud_repo = 1; - */ - io.grafeas.v1beta1.source.CloudRepoSourceContextOrBuilder getCloudRepoOrBuilder(); - - /** - * - * - *
-   * A SourceContext referring to a Gerrit project.
-   * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - boolean hasGerrit(); - /** - * - * - *
-   * A SourceContext referring to a Gerrit project.
-   * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - io.grafeas.v1beta1.source.GerritSourceContext getGerrit(); - /** - * - * - *
-   * A SourceContext referring to a Gerrit project.
-   * 
- * - * .grafeas.v1beta1.source.GerritSourceContext gerrit = 2; - */ - io.grafeas.v1beta1.source.GerritSourceContextOrBuilder getGerritOrBuilder(); - - /** - * - * - *
-   * A SourceContext referring to any third party Git repo (e.g., GitHub).
-   * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - boolean hasGit(); - /** - * - * - *
-   * A SourceContext referring to any third party Git repo (e.g., GitHub).
-   * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - io.grafeas.v1beta1.source.GitSourceContext getGit(); - /** - * - * - *
-   * A SourceContext referring to any third party Git repo (e.g., GitHub).
-   * 
- * - * .grafeas.v1beta1.source.GitSourceContext git = 3; - */ - io.grafeas.v1beta1.source.GitSourceContextOrBuilder getGitOrBuilder(); - - /** - * - * - *
-   * Labels with user defined metadata.
-   * 
- * - * map<string, string> labels = 4; - */ - int getLabelsCount(); - /** - * - * - *
-   * Labels with user defined metadata.
-   * 
- * - * map<string, string> labels = 4; - */ - boolean containsLabels(java.lang.String key); - /** Use {@link #getLabelsMap()} instead. */ - @java.lang.Deprecated - java.util.Map getLabels(); - /** - * - * - *
-   * Labels with user defined metadata.
-   * 
- * - * map<string, string> labels = 4; - */ - java.util.Map getLabelsMap(); - /** - * - * - *
-   * Labels with user defined metadata.
-   * 
- * - * map<string, string> labels = 4; - */ - java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue); - /** - * - * - *
-   * Labels with user defined metadata.
-   * 
- * - * map<string, string> labels = 4; - */ - java.lang.String getLabelsOrThrow(java.lang.String key); - - public io.grafeas.v1beta1.source.SourceContext.ContextCase getContextCase(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/UntypedIamResourceName.java deleted file mode 100644 index c9d58765..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/source/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.source; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/Details.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/Details.java deleted file mode 100644 index d75d84c4..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/Details.java +++ /dev/null @@ -1,2140 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto - -package io.grafeas.v1beta1.vulnerability; - -/** - * - * - *
- * Details of a vulnerability occurrence.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.vulnerability.Details} - */ -public final class Details extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.vulnerability.Details) - DetailsOrBuilder { - private static final long serialVersionUID = 0L; - // Use Details.newBuilder() to construct. - private Details(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Details() { - type_ = ""; - severity_ = 0; - packageIssue_ = java.util.Collections.emptyList(); - shortDescription_ = ""; - longDescription_ = ""; - relatedUrls_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Details( - 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(); - - type_ = s; - break; - } - case 16: - { - int rawValue = input.readEnum(); - - severity_ = rawValue; - break; - } - case 29: - { - cvssScore_ = input.readFloat(); - break; - } - case 34: - { - if (!((mutable_bitField0_ & 0x00000008) != 0)) { - packageIssue_ = - new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000008; - } - packageIssue_.add( - input.readMessage( - io.grafeas.v1beta1.vulnerability.PackageIssue.parser(), extensionRegistry)); - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - shortDescription_ = s; - break; - } - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - - longDescription_ = s; - break; - } - case 58: - { - if (!((mutable_bitField0_ & 0x00000040) != 0)) { - relatedUrls_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000040; - } - relatedUrls_.add( - input.readMessage( - io.grafeas.v1beta1.common.RelatedUrl.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000008) != 0)) { - packageIssue_ = java.util.Collections.unmodifiableList(packageIssue_); - } - if (((mutable_bitField0_ & 0x00000040) != 0)) { - relatedUrls_ = java.util.Collections.unmodifiableList(relatedUrls_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.vulnerability.Details.class, - io.grafeas.v1beta1.vulnerability.Details.Builder.class); - } - - private int bitField0_; - public static final int TYPE_FIELD_NUMBER = 1; - private volatile java.lang.Object type_; - /** - * - * - *
-   * The type of package; whether native or non native(ruby gems, node.js
-   * packages etc)
-   * 
- * - * string type = 1; - */ - public java.lang.String getType() { - java.lang.Object ref = type_; - 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(); - type_ = s; - return s; - } - } - /** - * - * - *
-   * The type of package; whether native or non native(ruby gems, node.js
-   * packages etc)
-   * 
- * - * string type = 1; - */ - public com.google.protobuf.ByteString getTypeBytes() { - java.lang.Object ref = type_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - type_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SEVERITY_FIELD_NUMBER = 2; - private int severity_; - /** - * - * - *
-   * Output only. The note provider assigned Severity of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public int getSeverityValue() { - return severity_; - } - /** - * - * - *
-   * Output only. The note provider assigned Severity of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public io.grafeas.v1beta1.vulnerability.Severity getSeverity() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.vulnerability.Severity result = - io.grafeas.v1beta1.vulnerability.Severity.valueOf(severity_); - return result == null ? io.grafeas.v1beta1.vulnerability.Severity.UNRECOGNIZED : result; - } - - public static final int CVSS_SCORE_FIELD_NUMBER = 3; - private float cvssScore_; - /** - * - * - *
-   * Output only. The CVSS score of this vulnerability. CVSS score is on a
-   * scale of 0-10 where 0 indicates low severity and 10 indicates high
-   * severity.
-   * 
- * - * float cvss_score = 3; - */ - public float getCvssScore() { - return cvssScore_; - } - - public static final int PACKAGE_ISSUE_FIELD_NUMBER = 4; - private java.util.List packageIssue_; - /** - * - * - *
-   * The set of affected locations and their fixes (if available) within the
-   * associated resource.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public java.util.List getPackageIssueList() { - return packageIssue_; - } - /** - * - * - *
-   * The set of affected locations and their fixes (if available) within the
-   * associated resource.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public java.util.List - getPackageIssueOrBuilderList() { - return packageIssue_; - } - /** - * - * - *
-   * The set of affected locations and their fixes (if available) within the
-   * associated resource.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public int getPackageIssueCount() { - return packageIssue_.size(); - } - /** - * - * - *
-   * The set of affected locations and their fixes (if available) within the
-   * associated resource.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public io.grafeas.v1beta1.vulnerability.PackageIssue getPackageIssue(int index) { - return packageIssue_.get(index); - } - /** - * - * - *
-   * The set of affected locations and their fixes (if available) within the
-   * associated resource.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public io.grafeas.v1beta1.vulnerability.PackageIssueOrBuilder getPackageIssueOrBuilder( - int index) { - return packageIssue_.get(index); - } - - public static final int SHORT_DESCRIPTION_FIELD_NUMBER = 5; - private volatile java.lang.Object shortDescription_; - /** - * - * - *
-   * Output only. A one sentence description of this vulnerability.
-   * 
- * - * string short_description = 5; - */ - public java.lang.String getShortDescription() { - java.lang.Object ref = shortDescription_; - 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(); - shortDescription_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. A one sentence description of this vulnerability.
-   * 
- * - * string short_description = 5; - */ - public com.google.protobuf.ByteString getShortDescriptionBytes() { - java.lang.Object ref = shortDescription_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - shortDescription_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int LONG_DESCRIPTION_FIELD_NUMBER = 6; - private volatile java.lang.Object longDescription_; - /** - * - * - *
-   * Output only. A detailed description of this vulnerability.
-   * 
- * - * string long_description = 6; - */ - public java.lang.String getLongDescription() { - java.lang.Object ref = longDescription_; - 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(); - longDescription_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. A detailed description of this vulnerability.
-   * 
- * - * string long_description = 6; - */ - public com.google.protobuf.ByteString getLongDescriptionBytes() { - java.lang.Object ref = longDescription_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - longDescription_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int RELATED_URLS_FIELD_NUMBER = 7; - private java.util.List relatedUrls_; - /** - * - * - *
-   * Output only. URLs related to this vulnerability.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public java.util.List getRelatedUrlsList() { - return relatedUrls_; - } - /** - * - * - *
-   * Output only. URLs related to this vulnerability.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public java.util.List - getRelatedUrlsOrBuilderList() { - return relatedUrls_; - } - /** - * - * - *
-   * Output only. URLs related to this vulnerability.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public int getRelatedUrlsCount() { - return relatedUrls_.size(); - } - /** - * - * - *
-   * Output only. URLs related to this vulnerability.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public io.grafeas.v1beta1.common.RelatedUrl getRelatedUrls(int index) { - return relatedUrls_.get(index); - } - /** - * - * - *
-   * Output only. URLs related to this vulnerability.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public io.grafeas.v1beta1.common.RelatedUrlOrBuilder getRelatedUrlsOrBuilder(int index) { - return relatedUrls_.get(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 (!getTypeBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, type_); - } - if (severity_ != io.grafeas.v1beta1.vulnerability.Severity.SEVERITY_UNSPECIFIED.getNumber()) { - output.writeEnum(2, severity_); - } - if (cvssScore_ != 0F) { - output.writeFloat(3, cvssScore_); - } - for (int i = 0; i < packageIssue_.size(); i++) { - output.writeMessage(4, packageIssue_.get(i)); - } - if (!getShortDescriptionBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, shortDescription_); - } - if (!getLongDescriptionBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 6, longDescription_); - } - for (int i = 0; i < relatedUrls_.size(); i++) { - output.writeMessage(7, relatedUrls_.get(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getTypeBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, type_); - } - if (severity_ != io.grafeas.v1beta1.vulnerability.Severity.SEVERITY_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, severity_); - } - if (cvssScore_ != 0F) { - size += com.google.protobuf.CodedOutputStream.computeFloatSize(3, cvssScore_); - } - for (int i = 0; i < packageIssue_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, packageIssue_.get(i)); - } - if (!getShortDescriptionBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, shortDescription_); - } - if (!getLongDescriptionBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, longDescription_); - } - for (int i = 0; i < relatedUrls_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, relatedUrls_.get(i)); - } - 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 io.grafeas.v1beta1.vulnerability.Details)) { - return super.equals(obj); - } - io.grafeas.v1beta1.vulnerability.Details other = (io.grafeas.v1beta1.vulnerability.Details) obj; - - if (!getType().equals(other.getType())) return false; - if (severity_ != other.severity_) return false; - if (java.lang.Float.floatToIntBits(getCvssScore()) - != java.lang.Float.floatToIntBits(other.getCvssScore())) return false; - if (!getPackageIssueList().equals(other.getPackageIssueList())) return false; - if (!getShortDescription().equals(other.getShortDescription())) return false; - if (!getLongDescription().equals(other.getLongDescription())) return false; - if (!getRelatedUrlsList().equals(other.getRelatedUrlsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + TYPE_FIELD_NUMBER; - hash = (53 * hash) + getType().hashCode(); - hash = (37 * hash) + SEVERITY_FIELD_NUMBER; - hash = (53 * hash) + severity_; - hash = (37 * hash) + CVSS_SCORE_FIELD_NUMBER; - hash = (53 * hash) + java.lang.Float.floatToIntBits(getCvssScore()); - if (getPackageIssueCount() > 0) { - hash = (37 * hash) + PACKAGE_ISSUE_FIELD_NUMBER; - hash = (53 * hash) + getPackageIssueList().hashCode(); - } - hash = (37 * hash) + SHORT_DESCRIPTION_FIELD_NUMBER; - hash = (53 * hash) + getShortDescription().hashCode(); - hash = (37 * hash) + LONG_DESCRIPTION_FIELD_NUMBER; - hash = (53 * hash) + getLongDescription().hashCode(); - if (getRelatedUrlsCount() > 0) { - hash = (37 * hash) + RELATED_URLS_FIELD_NUMBER; - hash = (53 * hash) + getRelatedUrlsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.vulnerability.Details parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.Details parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.Details parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.Details parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.Details parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.Details parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.Details parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.Details 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 io.grafeas.v1beta1.vulnerability.Details parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.Details 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 io.grafeas.v1beta1.vulnerability.Details parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.Details 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(io.grafeas.v1beta1.vulnerability.Details 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; - } - /** - * - * - *
-   * Details of a vulnerability occurrence.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.vulnerability.Details} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.vulnerability.Details) - io.grafeas.v1beta1.vulnerability.DetailsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Details_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Details_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.vulnerability.Details.class, - io.grafeas.v1beta1.vulnerability.Details.Builder.class); - } - - // Construct using io.grafeas.v1beta1.vulnerability.Details.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getPackageIssueFieldBuilder(); - getRelatedUrlsFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - type_ = ""; - - severity_ = 0; - - cvssScore_ = 0F; - - if (packageIssueBuilder_ == null) { - packageIssue_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - } else { - packageIssueBuilder_.clear(); - } - shortDescription_ = ""; - - longDescription_ = ""; - - if (relatedUrlsBuilder_ == null) { - relatedUrls_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000040); - } else { - relatedUrlsBuilder_.clear(); - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Details_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.Details getDefaultInstanceForType() { - return io.grafeas.v1beta1.vulnerability.Details.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.Details build() { - io.grafeas.v1beta1.vulnerability.Details result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.Details buildPartial() { - io.grafeas.v1beta1.vulnerability.Details result = - new io.grafeas.v1beta1.vulnerability.Details(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.type_ = type_; - result.severity_ = severity_; - result.cvssScore_ = cvssScore_; - if (packageIssueBuilder_ == null) { - if (((bitField0_ & 0x00000008) != 0)) { - packageIssue_ = java.util.Collections.unmodifiableList(packageIssue_); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.packageIssue_ = packageIssue_; - } else { - result.packageIssue_ = packageIssueBuilder_.build(); - } - result.shortDescription_ = shortDescription_; - result.longDescription_ = longDescription_; - if (relatedUrlsBuilder_ == null) { - if (((bitField0_ & 0x00000040) != 0)) { - relatedUrls_ = java.util.Collections.unmodifiableList(relatedUrls_); - bitField0_ = (bitField0_ & ~0x00000040); - } - result.relatedUrls_ = relatedUrls_; - } else { - result.relatedUrls_ = relatedUrlsBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.vulnerability.Details) { - return mergeFrom((io.grafeas.v1beta1.vulnerability.Details) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.vulnerability.Details other) { - if (other == io.grafeas.v1beta1.vulnerability.Details.getDefaultInstance()) return this; - if (!other.getType().isEmpty()) { - type_ = other.type_; - onChanged(); - } - if (other.severity_ != 0) { - setSeverityValue(other.getSeverityValue()); - } - if (other.getCvssScore() != 0F) { - setCvssScore(other.getCvssScore()); - } - if (packageIssueBuilder_ == null) { - if (!other.packageIssue_.isEmpty()) { - if (packageIssue_.isEmpty()) { - packageIssue_ = other.packageIssue_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensurePackageIssueIsMutable(); - packageIssue_.addAll(other.packageIssue_); - } - onChanged(); - } - } else { - if (!other.packageIssue_.isEmpty()) { - if (packageIssueBuilder_.isEmpty()) { - packageIssueBuilder_.dispose(); - packageIssueBuilder_ = null; - packageIssue_ = other.packageIssue_; - bitField0_ = (bitField0_ & ~0x00000008); - packageIssueBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getPackageIssueFieldBuilder() - : null; - } else { - packageIssueBuilder_.addAllMessages(other.packageIssue_); - } - } - } - if (!other.getShortDescription().isEmpty()) { - shortDescription_ = other.shortDescription_; - onChanged(); - } - if (!other.getLongDescription().isEmpty()) { - longDescription_ = other.longDescription_; - onChanged(); - } - if (relatedUrlsBuilder_ == null) { - if (!other.relatedUrls_.isEmpty()) { - if (relatedUrls_.isEmpty()) { - relatedUrls_ = other.relatedUrls_; - bitField0_ = (bitField0_ & ~0x00000040); - } else { - ensureRelatedUrlsIsMutable(); - relatedUrls_.addAll(other.relatedUrls_); - } - onChanged(); - } - } else { - if (!other.relatedUrls_.isEmpty()) { - if (relatedUrlsBuilder_.isEmpty()) { - relatedUrlsBuilder_.dispose(); - relatedUrlsBuilder_ = null; - relatedUrls_ = other.relatedUrls_; - bitField0_ = (bitField0_ & ~0x00000040); - relatedUrlsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getRelatedUrlsFieldBuilder() - : null; - } else { - relatedUrlsBuilder_.addAllMessages(other.relatedUrls_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.vulnerability.Details parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.vulnerability.Details) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object type_ = ""; - /** - * - * - *
-     * The type of package; whether native or non native(ruby gems, node.js
-     * packages etc)
-     * 
- * - * string type = 1; - */ - public java.lang.String getType() { - java.lang.Object ref = type_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - type_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The type of package; whether native or non native(ruby gems, node.js
-     * packages etc)
-     * 
- * - * string type = 1; - */ - public com.google.protobuf.ByteString getTypeBytes() { - java.lang.Object ref = type_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - type_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The type of package; whether native or non native(ruby gems, node.js
-     * packages etc)
-     * 
- * - * string type = 1; - */ - public Builder setType(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - type_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The type of package; whether native or non native(ruby gems, node.js
-     * packages etc)
-     * 
- * - * string type = 1; - */ - public Builder clearType() { - - type_ = getDefaultInstance().getType(); - onChanged(); - return this; - } - /** - * - * - *
-     * The type of package; whether native or non native(ruby gems, node.js
-     * packages etc)
-     * 
- * - * string type = 1; - */ - public Builder setTypeBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - type_ = value; - onChanged(); - return this; - } - - private int severity_ = 0; - /** - * - * - *
-     * Output only. The note provider assigned Severity of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public int getSeverityValue() { - return severity_; - } - /** - * - * - *
-     * Output only. The note provider assigned Severity of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public Builder setSeverityValue(int value) { - severity_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The note provider assigned Severity of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public io.grafeas.v1beta1.vulnerability.Severity getSeverity() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.vulnerability.Severity result = - io.grafeas.v1beta1.vulnerability.Severity.valueOf(severity_); - return result == null ? io.grafeas.v1beta1.vulnerability.Severity.UNRECOGNIZED : result; - } - /** - * - * - *
-     * Output only. The note provider assigned Severity of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public Builder setSeverity(io.grafeas.v1beta1.vulnerability.Severity value) { - if (value == null) { - throw new NullPointerException(); - } - - severity_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The note provider assigned Severity of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public Builder clearSeverity() { - - severity_ = 0; - onChanged(); - return this; - } - - private float cvssScore_; - /** - * - * - *
-     * Output only. The CVSS score of this vulnerability. CVSS score is on a
-     * scale of 0-10 where 0 indicates low severity and 10 indicates high
-     * severity.
-     * 
- * - * float cvss_score = 3; - */ - public float getCvssScore() { - return cvssScore_; - } - /** - * - * - *
-     * Output only. The CVSS score of this vulnerability. CVSS score is on a
-     * scale of 0-10 where 0 indicates low severity and 10 indicates high
-     * severity.
-     * 
- * - * float cvss_score = 3; - */ - public Builder setCvssScore(float value) { - - cvssScore_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The CVSS score of this vulnerability. CVSS score is on a
-     * scale of 0-10 where 0 indicates low severity and 10 indicates high
-     * severity.
-     * 
- * - * float cvss_score = 3; - */ - public Builder clearCvssScore() { - - cvssScore_ = 0F; - onChanged(); - return this; - } - - private java.util.List packageIssue_ = - java.util.Collections.emptyList(); - - private void ensurePackageIssueIsMutable() { - if (!((bitField0_ & 0x00000008) != 0)) { - packageIssue_ = - new java.util.ArrayList(packageIssue_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.PackageIssue, - io.grafeas.v1beta1.vulnerability.PackageIssue.Builder, - io.grafeas.v1beta1.vulnerability.PackageIssueOrBuilder> - packageIssueBuilder_; - - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public java.util.List getPackageIssueList() { - if (packageIssueBuilder_ == null) { - return java.util.Collections.unmodifiableList(packageIssue_); - } else { - return packageIssueBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public int getPackageIssueCount() { - if (packageIssueBuilder_ == null) { - return packageIssue_.size(); - } else { - return packageIssueBuilder_.getCount(); - } - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public io.grafeas.v1beta1.vulnerability.PackageIssue getPackageIssue(int index) { - if (packageIssueBuilder_ == null) { - return packageIssue_.get(index); - } else { - return packageIssueBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public Builder setPackageIssue(int index, io.grafeas.v1beta1.vulnerability.PackageIssue value) { - if (packageIssueBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensurePackageIssueIsMutable(); - packageIssue_.set(index, value); - onChanged(); - } else { - packageIssueBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public Builder setPackageIssue( - int index, io.grafeas.v1beta1.vulnerability.PackageIssue.Builder builderForValue) { - if (packageIssueBuilder_ == null) { - ensurePackageIssueIsMutable(); - packageIssue_.set(index, builderForValue.build()); - onChanged(); - } else { - packageIssueBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public Builder addPackageIssue(io.grafeas.v1beta1.vulnerability.PackageIssue value) { - if (packageIssueBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensurePackageIssueIsMutable(); - packageIssue_.add(value); - onChanged(); - } else { - packageIssueBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public Builder addPackageIssue(int index, io.grafeas.v1beta1.vulnerability.PackageIssue value) { - if (packageIssueBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensurePackageIssueIsMutable(); - packageIssue_.add(index, value); - onChanged(); - } else { - packageIssueBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public Builder addPackageIssue( - io.grafeas.v1beta1.vulnerability.PackageIssue.Builder builderForValue) { - if (packageIssueBuilder_ == null) { - ensurePackageIssueIsMutable(); - packageIssue_.add(builderForValue.build()); - onChanged(); - } else { - packageIssueBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public Builder addPackageIssue( - int index, io.grafeas.v1beta1.vulnerability.PackageIssue.Builder builderForValue) { - if (packageIssueBuilder_ == null) { - ensurePackageIssueIsMutable(); - packageIssue_.add(index, builderForValue.build()); - onChanged(); - } else { - packageIssueBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public Builder addAllPackageIssue( - java.lang.Iterable values) { - if (packageIssueBuilder_ == null) { - ensurePackageIssueIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, packageIssue_); - onChanged(); - } else { - packageIssueBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public Builder clearPackageIssue() { - if (packageIssueBuilder_ == null) { - packageIssue_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - packageIssueBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public Builder removePackageIssue(int index) { - if (packageIssueBuilder_ == null) { - ensurePackageIssueIsMutable(); - packageIssue_.remove(index); - onChanged(); - } else { - packageIssueBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public io.grafeas.v1beta1.vulnerability.PackageIssue.Builder getPackageIssueBuilder(int index) { - return getPackageIssueFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public io.grafeas.v1beta1.vulnerability.PackageIssueOrBuilder getPackageIssueOrBuilder( - int index) { - if (packageIssueBuilder_ == null) { - return packageIssue_.get(index); - } else { - return packageIssueBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public java.util.List - getPackageIssueOrBuilderList() { - if (packageIssueBuilder_ != null) { - return packageIssueBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(packageIssue_); - } - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public io.grafeas.v1beta1.vulnerability.PackageIssue.Builder addPackageIssueBuilder() { - return getPackageIssueFieldBuilder() - .addBuilder(io.grafeas.v1beta1.vulnerability.PackageIssue.getDefaultInstance()); - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public io.grafeas.v1beta1.vulnerability.PackageIssue.Builder addPackageIssueBuilder(int index) { - return getPackageIssueFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.vulnerability.PackageIssue.getDefaultInstance()); - } - /** - * - * - *
-     * The set of affected locations and their fixes (if available) within the
-     * associated resource.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - public java.util.List - getPackageIssueBuilderList() { - return getPackageIssueFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.PackageIssue, - io.grafeas.v1beta1.vulnerability.PackageIssue.Builder, - io.grafeas.v1beta1.vulnerability.PackageIssueOrBuilder> - getPackageIssueFieldBuilder() { - if (packageIssueBuilder_ == null) { - packageIssueBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.PackageIssue, - io.grafeas.v1beta1.vulnerability.PackageIssue.Builder, - io.grafeas.v1beta1.vulnerability.PackageIssueOrBuilder>( - packageIssue_, ((bitField0_ & 0x00000008) != 0), getParentForChildren(), isClean()); - packageIssue_ = null; - } - return packageIssueBuilder_; - } - - private java.lang.Object shortDescription_ = ""; - /** - * - * - *
-     * Output only. A one sentence description of this vulnerability.
-     * 
- * - * string short_description = 5; - */ - public java.lang.String getShortDescription() { - java.lang.Object ref = shortDescription_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - shortDescription_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. A one sentence description of this vulnerability.
-     * 
- * - * string short_description = 5; - */ - public com.google.protobuf.ByteString getShortDescriptionBytes() { - java.lang.Object ref = shortDescription_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - shortDescription_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. A one sentence description of this vulnerability.
-     * 
- * - * string short_description = 5; - */ - public Builder setShortDescription(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - shortDescription_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. A one sentence description of this vulnerability.
-     * 
- * - * string short_description = 5; - */ - public Builder clearShortDescription() { - - shortDescription_ = getDefaultInstance().getShortDescription(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. A one sentence description of this vulnerability.
-     * 
- * - * string short_description = 5; - */ - public Builder setShortDescriptionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - shortDescription_ = value; - onChanged(); - return this; - } - - private java.lang.Object longDescription_ = ""; - /** - * - * - *
-     * Output only. A detailed description of this vulnerability.
-     * 
- * - * string long_description = 6; - */ - public java.lang.String getLongDescription() { - java.lang.Object ref = longDescription_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - longDescription_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. A detailed description of this vulnerability.
-     * 
- * - * string long_description = 6; - */ - public com.google.protobuf.ByteString getLongDescriptionBytes() { - java.lang.Object ref = longDescription_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - longDescription_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. A detailed description of this vulnerability.
-     * 
- * - * string long_description = 6; - */ - public Builder setLongDescription(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - longDescription_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. A detailed description of this vulnerability.
-     * 
- * - * string long_description = 6; - */ - public Builder clearLongDescription() { - - longDescription_ = getDefaultInstance().getLongDescription(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. A detailed description of this vulnerability.
-     * 
- * - * string long_description = 6; - */ - public Builder setLongDescriptionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - longDescription_ = value; - onChanged(); - return this; - } - - private java.util.List relatedUrls_ = - java.util.Collections.emptyList(); - - private void ensureRelatedUrlsIsMutable() { - if (!((bitField0_ & 0x00000040) != 0)) { - relatedUrls_ = new java.util.ArrayList(relatedUrls_); - bitField0_ |= 0x00000040; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.common.RelatedUrl, - io.grafeas.v1beta1.common.RelatedUrl.Builder, - io.grafeas.v1beta1.common.RelatedUrlOrBuilder> - relatedUrlsBuilder_; - - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public java.util.List getRelatedUrlsList() { - if (relatedUrlsBuilder_ == null) { - return java.util.Collections.unmodifiableList(relatedUrls_); - } else { - return relatedUrlsBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public int getRelatedUrlsCount() { - if (relatedUrlsBuilder_ == null) { - return relatedUrls_.size(); - } else { - return relatedUrlsBuilder_.getCount(); - } - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public io.grafeas.v1beta1.common.RelatedUrl getRelatedUrls(int index) { - if (relatedUrlsBuilder_ == null) { - return relatedUrls_.get(index); - } else { - return relatedUrlsBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public Builder setRelatedUrls(int index, io.grafeas.v1beta1.common.RelatedUrl value) { - if (relatedUrlsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureRelatedUrlsIsMutable(); - relatedUrls_.set(index, value); - onChanged(); - } else { - relatedUrlsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public Builder setRelatedUrls( - int index, io.grafeas.v1beta1.common.RelatedUrl.Builder builderForValue) { - if (relatedUrlsBuilder_ == null) { - ensureRelatedUrlsIsMutable(); - relatedUrls_.set(index, builderForValue.build()); - onChanged(); - } else { - relatedUrlsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public Builder addRelatedUrls(io.grafeas.v1beta1.common.RelatedUrl value) { - if (relatedUrlsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureRelatedUrlsIsMutable(); - relatedUrls_.add(value); - onChanged(); - } else { - relatedUrlsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public Builder addRelatedUrls(int index, io.grafeas.v1beta1.common.RelatedUrl value) { - if (relatedUrlsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureRelatedUrlsIsMutable(); - relatedUrls_.add(index, value); - onChanged(); - } else { - relatedUrlsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public Builder addRelatedUrls(io.grafeas.v1beta1.common.RelatedUrl.Builder builderForValue) { - if (relatedUrlsBuilder_ == null) { - ensureRelatedUrlsIsMutable(); - relatedUrls_.add(builderForValue.build()); - onChanged(); - } else { - relatedUrlsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public Builder addRelatedUrls( - int index, io.grafeas.v1beta1.common.RelatedUrl.Builder builderForValue) { - if (relatedUrlsBuilder_ == null) { - ensureRelatedUrlsIsMutable(); - relatedUrls_.add(index, builderForValue.build()); - onChanged(); - } else { - relatedUrlsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public Builder addAllRelatedUrls( - java.lang.Iterable values) { - if (relatedUrlsBuilder_ == null) { - ensureRelatedUrlsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, relatedUrls_); - onChanged(); - } else { - relatedUrlsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public Builder clearRelatedUrls() { - if (relatedUrlsBuilder_ == null) { - relatedUrls_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000040); - onChanged(); - } else { - relatedUrlsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public Builder removeRelatedUrls(int index) { - if (relatedUrlsBuilder_ == null) { - ensureRelatedUrlsIsMutable(); - relatedUrls_.remove(index); - onChanged(); - } else { - relatedUrlsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public io.grafeas.v1beta1.common.RelatedUrl.Builder getRelatedUrlsBuilder(int index) { - return getRelatedUrlsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public io.grafeas.v1beta1.common.RelatedUrlOrBuilder getRelatedUrlsOrBuilder(int index) { - if (relatedUrlsBuilder_ == null) { - return relatedUrls_.get(index); - } else { - return relatedUrlsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public java.util.List - getRelatedUrlsOrBuilderList() { - if (relatedUrlsBuilder_ != null) { - return relatedUrlsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(relatedUrls_); - } - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public io.grafeas.v1beta1.common.RelatedUrl.Builder addRelatedUrlsBuilder() { - return getRelatedUrlsFieldBuilder() - .addBuilder(io.grafeas.v1beta1.common.RelatedUrl.getDefaultInstance()); - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public io.grafeas.v1beta1.common.RelatedUrl.Builder addRelatedUrlsBuilder(int index) { - return getRelatedUrlsFieldBuilder() - .addBuilder(index, io.grafeas.v1beta1.common.RelatedUrl.getDefaultInstance()); - } - /** - * - * - *
-     * Output only. URLs related to this vulnerability.
-     * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - public java.util.List - getRelatedUrlsBuilderList() { - return getRelatedUrlsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.common.RelatedUrl, - io.grafeas.v1beta1.common.RelatedUrl.Builder, - io.grafeas.v1beta1.common.RelatedUrlOrBuilder> - getRelatedUrlsFieldBuilder() { - if (relatedUrlsBuilder_ == null) { - relatedUrlsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.common.RelatedUrl, - io.grafeas.v1beta1.common.RelatedUrl.Builder, - io.grafeas.v1beta1.common.RelatedUrlOrBuilder>( - relatedUrls_, ((bitField0_ & 0x00000040) != 0), getParentForChildren(), isClean()); - relatedUrls_ = null; - } - return relatedUrlsBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.vulnerability.Details) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.vulnerability.Details) - private static final io.grafeas.v1beta1.vulnerability.Details DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.vulnerability.Details(); - } - - public static io.grafeas.v1beta1.vulnerability.Details getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser
PARSER = - new com.google.protobuf.AbstractParser
() { - @java.lang.Override - public Details parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Details(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser
parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser
getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.Details getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/DetailsOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/DetailsOrBuilder.java deleted file mode 100644 index e2c2ef22..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/DetailsOrBuilder.java +++ /dev/null @@ -1,218 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto - -package io.grafeas.v1beta1.vulnerability; - -public interface DetailsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.vulnerability.Details) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The type of package; whether native or non native(ruby gems, node.js
-   * packages etc)
-   * 
- * - * string type = 1; - */ - java.lang.String getType(); - /** - * - * - *
-   * The type of package; whether native or non native(ruby gems, node.js
-   * packages etc)
-   * 
- * - * string type = 1; - */ - com.google.protobuf.ByteString getTypeBytes(); - - /** - * - * - *
-   * Output only. The note provider assigned Severity of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - int getSeverityValue(); - /** - * - * - *
-   * Output only. The note provider assigned Severity of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - io.grafeas.v1beta1.vulnerability.Severity getSeverity(); - - /** - * - * - *
-   * Output only. The CVSS score of this vulnerability. CVSS score is on a
-   * scale of 0-10 where 0 indicates low severity and 10 indicates high
-   * severity.
-   * 
- * - * float cvss_score = 3; - */ - float getCvssScore(); - - /** - * - * - *
-   * The set of affected locations and their fixes (if available) within the
-   * associated resource.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - java.util.List getPackageIssueList(); - /** - * - * - *
-   * The set of affected locations and their fixes (if available) within the
-   * associated resource.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - io.grafeas.v1beta1.vulnerability.PackageIssue getPackageIssue(int index); - /** - * - * - *
-   * The set of affected locations and their fixes (if available) within the
-   * associated resource.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - int getPackageIssueCount(); - /** - * - * - *
-   * The set of affected locations and their fixes (if available) within the
-   * associated resource.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - java.util.List - getPackageIssueOrBuilderList(); - /** - * - * - *
-   * The set of affected locations and their fixes (if available) within the
-   * associated resource.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.PackageIssue package_issue = 4; - */ - io.grafeas.v1beta1.vulnerability.PackageIssueOrBuilder getPackageIssueOrBuilder(int index); - - /** - * - * - *
-   * Output only. A one sentence description of this vulnerability.
-   * 
- * - * string short_description = 5; - */ - java.lang.String getShortDescription(); - /** - * - * - *
-   * Output only. A one sentence description of this vulnerability.
-   * 
- * - * string short_description = 5; - */ - com.google.protobuf.ByteString getShortDescriptionBytes(); - - /** - * - * - *
-   * Output only. A detailed description of this vulnerability.
-   * 
- * - * string long_description = 6; - */ - java.lang.String getLongDescription(); - /** - * - * - *
-   * Output only. A detailed description of this vulnerability.
-   * 
- * - * string long_description = 6; - */ - com.google.protobuf.ByteString getLongDescriptionBytes(); - - /** - * - * - *
-   * Output only. URLs related to this vulnerability.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - java.util.List getRelatedUrlsList(); - /** - * - * - *
-   * Output only. URLs related to this vulnerability.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - io.grafeas.v1beta1.common.RelatedUrl getRelatedUrls(int index); - /** - * - * - *
-   * Output only. URLs related to this vulnerability.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - int getRelatedUrlsCount(); - /** - * - * - *
-   * Output only. URLs related to this vulnerability.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - java.util.List - getRelatedUrlsOrBuilderList(); - /** - * - * - *
-   * Output only. URLs related to this vulnerability.
-   * 
- * - * repeated .grafeas.v1beta1.RelatedUrl related_urls = 7; - */ - io.grafeas.v1beta1.common.RelatedUrlOrBuilder getRelatedUrlsOrBuilder(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/IamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/IamResourceName.java deleted file mode 100644 index 5f8ec225..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/IamResourceName.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.vulnerability; - -import com.google.api.resourcenames.ResourceName; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public abstract class IamResourceName implements ResourceName { - protected IamResourceName() {} -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/IamResourceNames.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/IamResourceNames.java deleted file mode 100644 index ecd77a64..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/IamResourceNames.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.vulnerability; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class IamResourceNames { - private IamResourceNames() {} - - public static IamResourceName parse(String resourceNameString) { - if (NoteName.isParsableFrom(resourceNameString)) { - return NoteName.parse(resourceNameString); - } - if (OccurrenceName.isParsableFrom(resourceNameString)) { - return OccurrenceName.parse(resourceNameString); - } - return UntypedIamResourceName.parse(resourceNameString); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/NoteName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/NoteName.java deleted file mode 100644 index 7db1b8f2..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/NoteName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.vulnerability; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class NoteName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/notes/{note}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private NoteName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - note = Preconditions.checkNotNull(builder.getNote()); - } - - public static NoteName of(String project, String note) { - return newBuilder().setProject(project).setNote(note).build(); - } - - public static String format(String project, String note) { - return newBuilder().setProject(project).setNote(note).build().toString(); - } - - public static NoteName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "NoteName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("note")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (NoteName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("note", note); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "note", note); - } - - /** Builder for NoteName. */ - public static class Builder { - - private String project; - private String note; - - public String getProject() { - return project; - } - - public String getNote() { - return note; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setNote(String note) { - this.note = note; - return this; - } - - private Builder() {} - - private Builder(NoteName noteName) { - project = noteName.project; - note = noteName.note; - } - - public NoteName build() { - return new NoteName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof NoteName) { - NoteName that = (NoteName) o; - return (this.project.equals(that.project)) && (this.note.equals(that.note)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= note.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/OccurrenceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/OccurrenceName.java deleted file mode 100644 index 18bc80cb..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/OccurrenceName.java +++ /dev/null @@ -1,179 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.vulnerability; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class OccurrenceName extends IamResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/occurrences/{occurrence}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private OccurrenceName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - occurrence = Preconditions.checkNotNull(builder.getOccurrence()); - } - - public static OccurrenceName of(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build(); - } - - public static String format(String project, String occurrence) { - return newBuilder().setProject(project).setOccurrence(occurrence).build().toString(); - } - - public static OccurrenceName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "OccurrenceName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("occurrence")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (OccurrenceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("occurrence", occurrence); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "occurrence", occurrence); - } - - /** Builder for OccurrenceName. */ - public static class Builder { - - private String project; - private String occurrence; - - public String getProject() { - return project; - } - - public String getOccurrence() { - return occurrence; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setOccurrence(String occurrence) { - this.occurrence = occurrence; - return this; - } - - private Builder() {} - - private Builder(OccurrenceName occurrenceName) { - project = occurrenceName.project; - occurrence = occurrenceName.occurrence; - } - - public OccurrenceName build() { - return new OccurrenceName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof OccurrenceName) { - OccurrenceName that = (OccurrenceName) o; - return (this.project.equals(that.project)) && (this.occurrence.equals(that.occurrence)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= occurrence.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/PackageIssue.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/PackageIssue.java deleted file mode 100644 index b6ecf515..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/PackageIssue.java +++ /dev/null @@ -1,1143 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto - -package io.grafeas.v1beta1.vulnerability; - -/** - * - * - *
- * This message wraps a location affected by a vulnerability and its
- * associated fix (if one is available).
- * 
- * - * Protobuf type {@code grafeas.v1beta1.vulnerability.PackageIssue} - */ -public final class PackageIssue extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.vulnerability.PackageIssue) - PackageIssueOrBuilder { - private static final long serialVersionUID = 0L; - // Use PackageIssue.newBuilder() to construct. - private PackageIssue(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private PackageIssue() { - severityName_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private PackageIssue( - 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: - { - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder subBuilder = null; - if (affectedLocation_ != null) { - subBuilder = affectedLocation_.toBuilder(); - } - affectedLocation_ = - input.readMessage( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(affectedLocation_); - affectedLocation_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder subBuilder = null; - if (fixedLocation_ != null) { - subBuilder = fixedLocation_.toBuilder(); - } - fixedLocation_ = - input.readMessage( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(fixedLocation_); - fixedLocation_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - severityName_ = s; - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_PackageIssue_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_PackageIssue_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.vulnerability.PackageIssue.class, - io.grafeas.v1beta1.vulnerability.PackageIssue.Builder.class); - } - - public static final int AFFECTED_LOCATION_FIELD_NUMBER = 1; - private io.grafeas.v1beta1.vulnerability.VulnerabilityLocation affectedLocation_; - /** - * - * - *
-   * The location of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - public boolean hasAffectedLocation() { - return affectedLocation_ != null; - } - /** - * - * - *
-   * The location of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation getAffectedLocation() { - return affectedLocation_ == null - ? io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.getDefaultInstance() - : affectedLocation_; - } - /** - * - * - *
-   * The location of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder - getAffectedLocationOrBuilder() { - return getAffectedLocation(); - } - - public static final int FIXED_LOCATION_FIELD_NUMBER = 2; - private io.grafeas.v1beta1.vulnerability.VulnerabilityLocation fixedLocation_; - /** - * - * - *
-   * The location of the available fix for vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - public boolean hasFixedLocation() { - return fixedLocation_ != null; - } - /** - * - * - *
-   * The location of the available fix for vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation getFixedLocation() { - return fixedLocation_ == null - ? io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.getDefaultInstance() - : fixedLocation_; - } - /** - * - * - *
-   * The location of the available fix for vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder - getFixedLocationOrBuilder() { - return getFixedLocation(); - } - - public static final int SEVERITY_NAME_FIELD_NUMBER = 3; - private volatile java.lang.Object severityName_; - /** - * - * - *
-   * The severity (e.g., distro assigned severity) for this vulnerability.
-   * 
- * - * string severity_name = 3; - */ - public java.lang.String getSeverityName() { - java.lang.Object ref = severityName_; - 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(); - severityName_ = s; - return s; - } - } - /** - * - * - *
-   * The severity (e.g., distro assigned severity) for this vulnerability.
-   * 
- * - * string severity_name = 3; - */ - public com.google.protobuf.ByteString getSeverityNameBytes() { - java.lang.Object ref = severityName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - severityName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (affectedLocation_ != null) { - output.writeMessage(1, getAffectedLocation()); - } - if (fixedLocation_ != null) { - output.writeMessage(2, getFixedLocation()); - } - if (!getSeverityNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, severityName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (affectedLocation_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getAffectedLocation()); - } - if (fixedLocation_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getFixedLocation()); - } - if (!getSeverityNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, severityName_); - } - 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 io.grafeas.v1beta1.vulnerability.PackageIssue)) { - return super.equals(obj); - } - io.grafeas.v1beta1.vulnerability.PackageIssue other = - (io.grafeas.v1beta1.vulnerability.PackageIssue) obj; - - if (hasAffectedLocation() != other.hasAffectedLocation()) return false; - if (hasAffectedLocation()) { - if (!getAffectedLocation().equals(other.getAffectedLocation())) return false; - } - if (hasFixedLocation() != other.hasFixedLocation()) return false; - if (hasFixedLocation()) { - if (!getFixedLocation().equals(other.getFixedLocation())) return false; - } - if (!getSeverityName().equals(other.getSeverityName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasAffectedLocation()) { - hash = (37 * hash) + AFFECTED_LOCATION_FIELD_NUMBER; - hash = (53 * hash) + getAffectedLocation().hashCode(); - } - if (hasFixedLocation()) { - hash = (37 * hash) + FIXED_LOCATION_FIELD_NUMBER; - hash = (53 * hash) + getFixedLocation().hashCode(); - } - hash = (37 * hash) + SEVERITY_NAME_FIELD_NUMBER; - hash = (53 * hash) + getSeverityName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.vulnerability.PackageIssue parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.PackageIssue parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.PackageIssue parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.PackageIssue parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.PackageIssue parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.PackageIssue parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.PackageIssue parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.PackageIssue 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 io.grafeas.v1beta1.vulnerability.PackageIssue parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.PackageIssue 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 io.grafeas.v1beta1.vulnerability.PackageIssue parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.PackageIssue 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(io.grafeas.v1beta1.vulnerability.PackageIssue 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; - } - /** - * - * - *
-   * This message wraps a location affected by a vulnerability and its
-   * associated fix (if one is available).
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.vulnerability.PackageIssue} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.vulnerability.PackageIssue) - io.grafeas.v1beta1.vulnerability.PackageIssueOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_PackageIssue_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_PackageIssue_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.vulnerability.PackageIssue.class, - io.grafeas.v1beta1.vulnerability.PackageIssue.Builder.class); - } - - // Construct using io.grafeas.v1beta1.vulnerability.PackageIssue.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (affectedLocationBuilder_ == null) { - affectedLocation_ = null; - } else { - affectedLocation_ = null; - affectedLocationBuilder_ = null; - } - if (fixedLocationBuilder_ == null) { - fixedLocation_ = null; - } else { - fixedLocation_ = null; - fixedLocationBuilder_ = null; - } - severityName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_PackageIssue_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.PackageIssue getDefaultInstanceForType() { - return io.grafeas.v1beta1.vulnerability.PackageIssue.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.PackageIssue build() { - io.grafeas.v1beta1.vulnerability.PackageIssue result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.PackageIssue buildPartial() { - io.grafeas.v1beta1.vulnerability.PackageIssue result = - new io.grafeas.v1beta1.vulnerability.PackageIssue(this); - if (affectedLocationBuilder_ == null) { - result.affectedLocation_ = affectedLocation_; - } else { - result.affectedLocation_ = affectedLocationBuilder_.build(); - } - if (fixedLocationBuilder_ == null) { - result.fixedLocation_ = fixedLocation_; - } else { - result.fixedLocation_ = fixedLocationBuilder_.build(); - } - result.severityName_ = severityName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.vulnerability.PackageIssue) { - return mergeFrom((io.grafeas.v1beta1.vulnerability.PackageIssue) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.vulnerability.PackageIssue other) { - if (other == io.grafeas.v1beta1.vulnerability.PackageIssue.getDefaultInstance()) return this; - if (other.hasAffectedLocation()) { - mergeAffectedLocation(other.getAffectedLocation()); - } - if (other.hasFixedLocation()) { - mergeFixedLocation(other.getFixedLocation()); - } - if (!other.getSeverityName().isEmpty()) { - severityName_ = other.severityName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.vulnerability.PackageIssue parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.vulnerability.PackageIssue) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private io.grafeas.v1beta1.vulnerability.VulnerabilityLocation affectedLocation_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder> - affectedLocationBuilder_; - /** - * - * - *
-     * The location of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - public boolean hasAffectedLocation() { - return affectedLocationBuilder_ != null || affectedLocation_ != null; - } - /** - * - * - *
-     * The location of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation getAffectedLocation() { - if (affectedLocationBuilder_ == null) { - return affectedLocation_ == null - ? io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.getDefaultInstance() - : affectedLocation_; - } else { - return affectedLocationBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The location of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - public Builder setAffectedLocation( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation value) { - if (affectedLocationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - affectedLocation_ = value; - onChanged(); - } else { - affectedLocationBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The location of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - public Builder setAffectedLocation( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder builderForValue) { - if (affectedLocationBuilder_ == null) { - affectedLocation_ = builderForValue.build(); - onChanged(); - } else { - affectedLocationBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The location of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - public Builder mergeAffectedLocation( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation value) { - if (affectedLocationBuilder_ == null) { - if (affectedLocation_ != null) { - affectedLocation_ = - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.newBuilder(affectedLocation_) - .mergeFrom(value) - .buildPartial(); - } else { - affectedLocation_ = value; - } - onChanged(); - } else { - affectedLocationBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The location of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - public Builder clearAffectedLocation() { - if (affectedLocationBuilder_ == null) { - affectedLocation_ = null; - onChanged(); - } else { - affectedLocation_ = null; - affectedLocationBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The location of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder - getAffectedLocationBuilder() { - - onChanged(); - return getAffectedLocationFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The location of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder - getAffectedLocationOrBuilder() { - if (affectedLocationBuilder_ != null) { - return affectedLocationBuilder_.getMessageOrBuilder(); - } else { - return affectedLocation_ == null - ? io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.getDefaultInstance() - : affectedLocation_; - } - } - /** - * - * - *
-     * The location of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder> - getAffectedLocationFieldBuilder() { - if (affectedLocationBuilder_ == null) { - affectedLocationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder>( - getAffectedLocation(), getParentForChildren(), isClean()); - affectedLocation_ = null; - } - return affectedLocationBuilder_; - } - - private io.grafeas.v1beta1.vulnerability.VulnerabilityLocation fixedLocation_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder> - fixedLocationBuilder_; - /** - * - * - *
-     * The location of the available fix for vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - public boolean hasFixedLocation() { - return fixedLocationBuilder_ != null || fixedLocation_ != null; - } - /** - * - * - *
-     * The location of the available fix for vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation getFixedLocation() { - if (fixedLocationBuilder_ == null) { - return fixedLocation_ == null - ? io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.getDefaultInstance() - : fixedLocation_; - } else { - return fixedLocationBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The location of the available fix for vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - public Builder setFixedLocation(io.grafeas.v1beta1.vulnerability.VulnerabilityLocation value) { - if (fixedLocationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - fixedLocation_ = value; - onChanged(); - } else { - fixedLocationBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The location of the available fix for vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - public Builder setFixedLocation( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder builderForValue) { - if (fixedLocationBuilder_ == null) { - fixedLocation_ = builderForValue.build(); - onChanged(); - } else { - fixedLocationBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The location of the available fix for vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - public Builder mergeFixedLocation( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation value) { - if (fixedLocationBuilder_ == null) { - if (fixedLocation_ != null) { - fixedLocation_ = - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.newBuilder(fixedLocation_) - .mergeFrom(value) - .buildPartial(); - } else { - fixedLocation_ = value; - } - onChanged(); - } else { - fixedLocationBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The location of the available fix for vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - public Builder clearFixedLocation() { - if (fixedLocationBuilder_ == null) { - fixedLocation_ = null; - onChanged(); - } else { - fixedLocation_ = null; - fixedLocationBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The location of the available fix for vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder - getFixedLocationBuilder() { - - onChanged(); - return getFixedLocationFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The location of the available fix for vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder - getFixedLocationOrBuilder() { - if (fixedLocationBuilder_ != null) { - return fixedLocationBuilder_.getMessageOrBuilder(); - } else { - return fixedLocation_ == null - ? io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.getDefaultInstance() - : fixedLocation_; - } - } - /** - * - * - *
-     * The location of the available fix for vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder> - getFixedLocationFieldBuilder() { - if (fixedLocationBuilder_ == null) { - fixedLocationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder>( - getFixedLocation(), getParentForChildren(), isClean()); - fixedLocation_ = null; - } - return fixedLocationBuilder_; - } - - private java.lang.Object severityName_ = ""; - /** - * - * - *
-     * The severity (e.g., distro assigned severity) for this vulnerability.
-     * 
- * - * string severity_name = 3; - */ - public java.lang.String getSeverityName() { - java.lang.Object ref = severityName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - severityName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The severity (e.g., distro assigned severity) for this vulnerability.
-     * 
- * - * string severity_name = 3; - */ - public com.google.protobuf.ByteString getSeverityNameBytes() { - java.lang.Object ref = severityName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - severityName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The severity (e.g., distro assigned severity) for this vulnerability.
-     * 
- * - * string severity_name = 3; - */ - public Builder setSeverityName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - severityName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The severity (e.g., distro assigned severity) for this vulnerability.
-     * 
- * - * string severity_name = 3; - */ - public Builder clearSeverityName() { - - severityName_ = getDefaultInstance().getSeverityName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The severity (e.g., distro assigned severity) for this vulnerability.
-     * 
- * - * string severity_name = 3; - */ - public Builder setSeverityNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - severityName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.vulnerability.PackageIssue) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.vulnerability.PackageIssue) - private static final io.grafeas.v1beta1.vulnerability.PackageIssue DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.vulnerability.PackageIssue(); - } - - public static io.grafeas.v1beta1.vulnerability.PackageIssue getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public PackageIssue parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new PackageIssue(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.PackageIssue getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/PackageIssueOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/PackageIssueOrBuilder.java deleted file mode 100644 index 27ee84c5..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/PackageIssueOrBuilder.java +++ /dev/null @@ -1,93 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto - -package io.grafeas.v1beta1.vulnerability; - -public interface PackageIssueOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.vulnerability.PackageIssue) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The location of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - boolean hasAffectedLocation(); - /** - * - * - *
-   * The location of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation getAffectedLocation(); - /** - * - * - *
-   * The location of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation affected_location = 1; - */ - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder getAffectedLocationOrBuilder(); - - /** - * - * - *
-   * The location of the available fix for vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - boolean hasFixedLocation(); - /** - * - * - *
-   * The location of the available fix for vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation getFixedLocation(); - /** - * - * - *
-   * The location of the available fix for vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 2; - */ - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder getFixedLocationOrBuilder(); - - /** - * - * - *
-   * The severity (e.g., distro assigned severity) for this vulnerability.
-   * 
- * - * string severity_name = 3; - */ - java.lang.String getSeverityName(); - /** - * - * - *
-   * The severity (e.g., distro assigned severity) for this vulnerability.
-   * 
- * - * string severity_name = 3; - */ - com.google.protobuf.ByteString getSeverityNameBytes(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/ProjectName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/ProjectName.java deleted file mode 100644 index 4dbfb223..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/ProjectName.java +++ /dev/null @@ -1,160 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.vulnerability; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ProjectName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}"); - - private volatile Map fieldValuesMap; - - private final String project; - - public String getProject() { - return project; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ProjectName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - } - - public static ProjectName of(String project) { - return newBuilder().setProject(project).build(); - } - - public static String format(String project) { - return newBuilder().setProject(project).build().toString(); - } - - public static ProjectName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ProjectName.parse: formattedString not in valid format"); - return of(matchMap.get("project")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ProjectName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project); - } - - /** Builder for ProjectName. */ - public static class Builder { - - private String project; - - public String getProject() { - return project; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - private Builder() {} - - private Builder(ProjectName projectName) { - project = projectName.project; - } - - public ProjectName build() { - return new ProjectName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ProjectName) { - ProjectName that = (ProjectName) o; - return (this.project.equals(that.project)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/ScanConfigName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/ScanConfigName.java deleted file mode 100644 index a043824c..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/ScanConfigName.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.vulnerability; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ScanConfigName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); - - private volatile Map fieldValuesMap; - - private final String project; - private final String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ScanConfigName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - scanConfig = Preconditions.checkNotNull(builder.getScanConfig()); - } - - public static ScanConfigName of(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build(); - } - - public static String format(String project, String scanConfig) { - return newBuilder().setProject(project).setScanConfig(scanConfig).build().toString(); - } - - public static ScanConfigName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch( - formattedString, "ScanConfigName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("scan_config")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ScanConfigName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("project", project); - fieldMapBuilder.put("scanConfig", scanConfig); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("project", project, "scan_config", scanConfig); - } - - /** Builder for ScanConfigName. */ - public static class Builder { - - private String project; - private String scanConfig; - - public String getProject() { - return project; - } - - public String getScanConfig() { - return scanConfig; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setScanConfig(String scanConfig) { - this.scanConfig = scanConfig; - return this; - } - - private Builder() {} - - private Builder(ScanConfigName scanConfigName) { - project = scanConfigName.project; - scanConfig = scanConfigName.scanConfig; - } - - public ScanConfigName build() { - return new ScanConfigName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ScanConfigName) { - ScanConfigName that = (ScanConfigName) o; - return (this.project.equals(that.project)) && (this.scanConfig.equals(that.scanConfig)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= project.hashCode(); - h *= 1000003; - h ^= scanConfig.hashCode(); - return h; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/Severity.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/Severity.java deleted file mode 100644 index c2b83120..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/Severity.java +++ /dev/null @@ -1,217 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto - -package io.grafeas.v1beta1.vulnerability; - -/** - * - * - *
- * Note provider-assigned severity/impact ranking.
- * 
- * - * Protobuf enum {@code grafeas.v1beta1.vulnerability.Severity} - */ -public enum Severity implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-   * Unknown.
-   * 
- * - * SEVERITY_UNSPECIFIED = 0; - */ - SEVERITY_UNSPECIFIED(0), - /** - * - * - *
-   * Minimal severity.
-   * 
- * - * MINIMAL = 1; - */ - MINIMAL(1), - /** - * - * - *
-   * Low severity.
-   * 
- * - * LOW = 2; - */ - LOW(2), - /** - * - * - *
-   * Medium severity.
-   * 
- * - * MEDIUM = 3; - */ - MEDIUM(3), - /** - * - * - *
-   * High severity.
-   * 
- * - * HIGH = 4; - */ - HIGH(4), - /** - * - * - *
-   * Critical severity.
-   * 
- * - * CRITICAL = 5; - */ - CRITICAL(5), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-   * Unknown.
-   * 
- * - * SEVERITY_UNSPECIFIED = 0; - */ - public static final int SEVERITY_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-   * Minimal severity.
-   * 
- * - * MINIMAL = 1; - */ - public static final int MINIMAL_VALUE = 1; - /** - * - * - *
-   * Low severity.
-   * 
- * - * LOW = 2; - */ - public static final int LOW_VALUE = 2; - /** - * - * - *
-   * Medium severity.
-   * 
- * - * MEDIUM = 3; - */ - public static final int MEDIUM_VALUE = 3; - /** - * - * - *
-   * High severity.
-   * 
- * - * HIGH = 4; - */ - public static final int HIGH_VALUE = 4; - /** - * - * - *
-   * Critical severity.
-   * 
- * - * CRITICAL = 5; - */ - public static final int CRITICAL_VALUE = 5; - - 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 Severity valueOf(int value) { - return forNumber(value); - } - - public static Severity forNumber(int value) { - switch (value) { - case 0: - return SEVERITY_UNSPECIFIED; - case 1: - return MINIMAL; - case 2: - return LOW; - case 3: - return MEDIUM; - case 4: - return HIGH; - case 5: - return CRITICAL; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Severity findValueByNumber(int number) { - return Severity.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Severity[] VALUES = values(); - - public static Severity valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Severity(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:grafeas.v1beta1.vulnerability.Severity) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/UntypedIamResourceName.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/UntypedIamResourceName.java deleted file mode 100644 index 066c6550..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/UntypedIamResourceName.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * 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 io.grafeas.v1beta1.vulnerability; - -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class UntypedIamResourceName extends IamResourceName { - - private final String rawValue; - private Map valueMap; - - private UntypedIamResourceName(String rawValue) { - this.rawValue = Preconditions.checkNotNull(rawValue); - this.valueMap = ImmutableMap.of("", rawValue); - } - - public static UntypedIamResourceName from(ResourceName resourceName) { - return new UntypedIamResourceName(resourceName.toString()); - } - - public static UntypedIamResourceName parse(String formattedString) { - return new UntypedIamResourceName(formattedString); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (UntypedIamResourceName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return true; - } - - /** Return a map with a single value rawValue keyed on an empty String "". */ - public Map getFieldValuesMap() { - return valueMap; - } - - /** Return the initial rawValue if @param fieldName is an empty String, else return null. */ - public String getFieldValue(String fieldName) { - return valueMap.get(fieldName); - } - - @Override - public String toString() { - return rawValue; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof UntypedIamResourceName) { - UntypedIamResourceName that = (UntypedIamResourceName) o; - return this.rawValue.equals(that.rawValue); - } - return false; - } - - @Override - public int hashCode() { - return rawValue.hashCode(); - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/Vulnerability.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/Vulnerability.java deleted file mode 100644 index 4a277752..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/Vulnerability.java +++ /dev/null @@ -1,3571 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto - -package io.grafeas.v1beta1.vulnerability; - -/** - * - * - *
- * Vulnerability provides metadata about a security vulnerability.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.vulnerability.Vulnerability} - */ -public final class Vulnerability extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.vulnerability.Vulnerability) - VulnerabilityOrBuilder { - private static final long serialVersionUID = 0L; - // Use Vulnerability.newBuilder() to construct. - private Vulnerability(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Vulnerability() { - severity_ = 0; - details_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Vulnerability( - 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 13: - { - cvssScore_ = input.readFloat(); - break; - } - case 16: - { - int rawValue = input.readEnum(); - - severity_ = rawValue; - break; - } - case 26: - { - if (!((mutable_bitField0_ & 0x00000004) != 0)) { - details_ = - new java.util.ArrayList< - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail>(); - mutable_bitField0_ |= 0x00000004; - } - details_.add( - input.readMessage( - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.parser(), - extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(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_ & 0x00000004) != 0)) { - details_ = java.util.Collections.unmodifiableList(details_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Vulnerability_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Vulnerability_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.vulnerability.Vulnerability.class, - io.grafeas.v1beta1.vulnerability.Vulnerability.Builder.class); - } - - public interface DetailOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.vulnerability.Vulnerability.Detail) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) in
-     * which the vulnerability manifests.  Examples include distro or storage
-     * location for vulnerable jar.
-     * 
- * - * string cpe_uri = 1; - */ - java.lang.String getCpeUri(); - /** - * - * - *
-     * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) in
-     * which the vulnerability manifests.  Examples include distro or storage
-     * location for vulnerable jar.
-     * 
- * - * string cpe_uri = 1; - */ - com.google.protobuf.ByteString getCpeUriBytes(); - - /** - * - * - *
-     * The name of the package where the vulnerability was found.
-     * 
- * - * string package = 2; - */ - java.lang.String getPackage(); - /** - * - * - *
-     * The name of the package where the vulnerability was found.
-     * 
- * - * string package = 2; - */ - com.google.protobuf.ByteString getPackageBytes(); - - /** - * - * - *
-     * The min version of the package in which the vulnerability exists.
-     * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - boolean hasMinAffectedVersion(); - /** - * - * - *
-     * The min version of the package in which the vulnerability exists.
-     * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - io.grafeas.v1beta1.pkg.Version getMinAffectedVersion(); - /** - * - * - *
-     * The min version of the package in which the vulnerability exists.
-     * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - io.grafeas.v1beta1.pkg.VersionOrBuilder getMinAffectedVersionOrBuilder(); - - /** - * - * - *
-     * The max version of the package in which the vulnerability exists.
-     * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - boolean hasMaxAffectedVersion(); - /** - * - * - *
-     * The max version of the package in which the vulnerability exists.
-     * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - io.grafeas.v1beta1.pkg.Version getMaxAffectedVersion(); - /** - * - * - *
-     * The max version of the package in which the vulnerability exists.
-     * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - io.grafeas.v1beta1.pkg.VersionOrBuilder getMaxAffectedVersionOrBuilder(); - - /** - * - * - *
-     * The severity (eg: distro assigned severity) for this vulnerability.
-     * 
- * - * string severity_name = 5; - */ - java.lang.String getSeverityName(); - /** - * - * - *
-     * The severity (eg: distro assigned severity) for this vulnerability.
-     * 
- * - * string severity_name = 5; - */ - com.google.protobuf.ByteString getSeverityNameBytes(); - - /** - * - * - *
-     * A vendor-specific description of this note.
-     * 
- * - * string description = 6; - */ - java.lang.String getDescription(); - /** - * - * - *
-     * A vendor-specific description of this note.
-     * 
- * - * string description = 6; - */ - com.google.protobuf.ByteString getDescriptionBytes(); - - /** - * - * - *
-     * The fix for this specific package version.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - boolean hasFixedLocation(); - /** - * - * - *
-     * The fix for this specific package version.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation getFixedLocation(); - /** - * - * - *
-     * The fix for this specific package version.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder getFixedLocationOrBuilder(); - - /** - * - * - *
-     * The type of package; whether native or non native(ruby gems, node.js
-     * packages etc).
-     * 
- * - * string package_type = 8; - */ - java.lang.String getPackageType(); - /** - * - * - *
-     * The type of package; whether native or non native(ruby gems, node.js
-     * packages etc).
-     * 
- * - * string package_type = 8; - */ - com.google.protobuf.ByteString getPackageTypeBytes(); - - /** - * - * - *
-     * Whether this detail is obsolete. Occurrences are expected not to point to
-     * obsolete details.
-     * 
- * - * bool is_obsolete = 9; - */ - boolean getIsObsolete(); - } - /** - * - * - *
-   * Identifies all occurrences of this vulnerability in the package for a
-   * specific distro/location. For example: glibc in
-   * cpe:/o:debian:debian_linux:8 for versions 2.1 - 2.2
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.vulnerability.Vulnerability.Detail} - */ - public static final class Detail extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.vulnerability.Vulnerability.Detail) - DetailOrBuilder { - private static final long serialVersionUID = 0L; - // Use Detail.newBuilder() to construct. - private Detail(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Detail() { - cpeUri_ = ""; - package_ = ""; - severityName_ = ""; - description_ = ""; - packageType_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Detail( - 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(); - - cpeUri_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - package_ = s; - break; - } - case 26: - { - io.grafeas.v1beta1.pkg.Version.Builder subBuilder = null; - if (minAffectedVersion_ != null) { - subBuilder = minAffectedVersion_.toBuilder(); - } - minAffectedVersion_ = - input.readMessage(io.grafeas.v1beta1.pkg.Version.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(minAffectedVersion_); - minAffectedVersion_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - io.grafeas.v1beta1.pkg.Version.Builder subBuilder = null; - if (maxAffectedVersion_ != null) { - subBuilder = maxAffectedVersion_.toBuilder(); - } - maxAffectedVersion_ = - input.readMessage(io.grafeas.v1beta1.pkg.Version.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(maxAffectedVersion_); - maxAffectedVersion_ = subBuilder.buildPartial(); - } - - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - severityName_ = s; - break; - } - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - - description_ = s; - break; - } - case 58: - { - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder subBuilder = null; - if (fixedLocation_ != null) { - subBuilder = fixedLocation_.toBuilder(); - } - fixedLocation_ = - input.readMessage( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(fixedLocation_); - fixedLocation_ = subBuilder.buildPartial(); - } - - break; - } - case 66: - { - java.lang.String s = input.readStringRequireUtf8(); - - packageType_ = s; - break; - } - case 72: - { - isObsolete_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Vulnerability_Detail_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Vulnerability_Detail_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.class, - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.Builder.class); - } - - public static final int CPE_URI_FIELD_NUMBER = 1; - private volatile java.lang.Object cpeUri_; - /** - * - * - *
-     * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) in
-     * which the vulnerability manifests.  Examples include distro or storage
-     * location for vulnerable jar.
-     * 
- * - * string cpe_uri = 1; - */ - public java.lang.String getCpeUri() { - java.lang.Object ref = cpeUri_; - 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(); - cpeUri_ = s; - return s; - } - } - /** - * - * - *
-     * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) in
-     * which the vulnerability manifests.  Examples include distro or storage
-     * location for vulnerable jar.
-     * 
- * - * string cpe_uri = 1; - */ - public com.google.protobuf.ByteString getCpeUriBytes() { - java.lang.Object ref = cpeUri_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - cpeUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PACKAGE_FIELD_NUMBER = 2; - private volatile java.lang.Object package_; - /** - * - * - *
-     * The name of the package where the vulnerability was found.
-     * 
- * - * string package = 2; - */ - public java.lang.String getPackage() { - java.lang.Object ref = package_; - 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(); - package_ = s; - return s; - } - } - /** - * - * - *
-     * The name of the package where the vulnerability was found.
-     * 
- * - * string package = 2; - */ - public com.google.protobuf.ByteString getPackageBytes() { - java.lang.Object ref = package_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - package_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int MIN_AFFECTED_VERSION_FIELD_NUMBER = 3; - private io.grafeas.v1beta1.pkg.Version minAffectedVersion_; - /** - * - * - *
-     * The min version of the package in which the vulnerability exists.
-     * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - public boolean hasMinAffectedVersion() { - return minAffectedVersion_ != null; - } - /** - * - * - *
-     * The min version of the package in which the vulnerability exists.
-     * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - public io.grafeas.v1beta1.pkg.Version getMinAffectedVersion() { - return minAffectedVersion_ == null - ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() - : minAffectedVersion_; - } - /** - * - * - *
-     * The min version of the package in which the vulnerability exists.
-     * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - public io.grafeas.v1beta1.pkg.VersionOrBuilder getMinAffectedVersionOrBuilder() { - return getMinAffectedVersion(); - } - - public static final int MAX_AFFECTED_VERSION_FIELD_NUMBER = 4; - private io.grafeas.v1beta1.pkg.Version maxAffectedVersion_; - /** - * - * - *
-     * The max version of the package in which the vulnerability exists.
-     * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - public boolean hasMaxAffectedVersion() { - return maxAffectedVersion_ != null; - } - /** - * - * - *
-     * The max version of the package in which the vulnerability exists.
-     * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - public io.grafeas.v1beta1.pkg.Version getMaxAffectedVersion() { - return maxAffectedVersion_ == null - ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() - : maxAffectedVersion_; - } - /** - * - * - *
-     * The max version of the package in which the vulnerability exists.
-     * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - public io.grafeas.v1beta1.pkg.VersionOrBuilder getMaxAffectedVersionOrBuilder() { - return getMaxAffectedVersion(); - } - - public static final int SEVERITY_NAME_FIELD_NUMBER = 5; - private volatile java.lang.Object severityName_; - /** - * - * - *
-     * The severity (eg: distro assigned severity) for this vulnerability.
-     * 
- * - * string severity_name = 5; - */ - public java.lang.String getSeverityName() { - java.lang.Object ref = severityName_; - 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(); - severityName_ = s; - return s; - } - } - /** - * - * - *
-     * The severity (eg: distro assigned severity) for this vulnerability.
-     * 
- * - * string severity_name = 5; - */ - public com.google.protobuf.ByteString getSeverityNameBytes() { - java.lang.Object ref = severityName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - severityName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DESCRIPTION_FIELD_NUMBER = 6; - private volatile java.lang.Object description_; - /** - * - * - *
-     * A vendor-specific description of this note.
-     * 
- * - * string description = 6; - */ - public java.lang.String getDescription() { - java.lang.Object ref = description_; - 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(); - description_ = s; - return s; - } - } - /** - * - * - *
-     * A vendor-specific description of this note.
-     * 
- * - * string description = 6; - */ - public com.google.protobuf.ByteString getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int FIXED_LOCATION_FIELD_NUMBER = 7; - private io.grafeas.v1beta1.vulnerability.VulnerabilityLocation fixedLocation_; - /** - * - * - *
-     * The fix for this specific package version.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - public boolean hasFixedLocation() { - return fixedLocation_ != null; - } - /** - * - * - *
-     * The fix for this specific package version.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation getFixedLocation() { - return fixedLocation_ == null - ? io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.getDefaultInstance() - : fixedLocation_; - } - /** - * - * - *
-     * The fix for this specific package version.
-     * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder - getFixedLocationOrBuilder() { - return getFixedLocation(); - } - - public static final int PACKAGE_TYPE_FIELD_NUMBER = 8; - private volatile java.lang.Object packageType_; - /** - * - * - *
-     * The type of package; whether native or non native(ruby gems, node.js
-     * packages etc).
-     * 
- * - * string package_type = 8; - */ - public java.lang.String getPackageType() { - java.lang.Object ref = packageType_; - 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(); - packageType_ = s; - return s; - } - } - /** - * - * - *
-     * The type of package; whether native or non native(ruby gems, node.js
-     * packages etc).
-     * 
- * - * string package_type = 8; - */ - public com.google.protobuf.ByteString getPackageTypeBytes() { - java.lang.Object ref = packageType_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - packageType_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int IS_OBSOLETE_FIELD_NUMBER = 9; - private boolean isObsolete_; - /** - * - * - *
-     * Whether this detail is obsolete. Occurrences are expected not to point to
-     * obsolete details.
-     * 
- * - * bool is_obsolete = 9; - */ - public boolean getIsObsolete() { - return isObsolete_; - } - - 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 (!getCpeUriBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, cpeUri_); - } - if (!getPackageBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, package_); - } - if (minAffectedVersion_ != null) { - output.writeMessage(3, getMinAffectedVersion()); - } - if (maxAffectedVersion_ != null) { - output.writeMessage(4, getMaxAffectedVersion()); - } - if (!getSeverityNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, severityName_); - } - if (!getDescriptionBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 6, description_); - } - if (fixedLocation_ != null) { - output.writeMessage(7, getFixedLocation()); - } - if (!getPackageTypeBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 8, packageType_); - } - if (isObsolete_ != false) { - output.writeBool(9, isObsolete_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getCpeUriBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, cpeUri_); - } - if (!getPackageBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, package_); - } - if (minAffectedVersion_ != null) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize(3, getMinAffectedVersion()); - } - if (maxAffectedVersion_ != null) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize(4, getMaxAffectedVersion()); - } - if (!getSeverityNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, severityName_); - } - if (!getDescriptionBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, description_); - } - if (fixedLocation_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getFixedLocation()); - } - if (!getPackageTypeBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, packageType_); - } - if (isObsolete_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(9, isObsolete_); - } - 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 io.grafeas.v1beta1.vulnerability.Vulnerability.Detail)) { - return super.equals(obj); - } - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail other = - (io.grafeas.v1beta1.vulnerability.Vulnerability.Detail) obj; - - if (!getCpeUri().equals(other.getCpeUri())) return false; - if (!getPackage().equals(other.getPackage())) return false; - if (hasMinAffectedVersion() != other.hasMinAffectedVersion()) return false; - if (hasMinAffectedVersion()) { - if (!getMinAffectedVersion().equals(other.getMinAffectedVersion())) return false; - } - if (hasMaxAffectedVersion() != other.hasMaxAffectedVersion()) return false; - if (hasMaxAffectedVersion()) { - if (!getMaxAffectedVersion().equals(other.getMaxAffectedVersion())) return false; - } - if (!getSeverityName().equals(other.getSeverityName())) return false; - if (!getDescription().equals(other.getDescription())) return false; - if (hasFixedLocation() != other.hasFixedLocation()) return false; - if (hasFixedLocation()) { - if (!getFixedLocation().equals(other.getFixedLocation())) return false; - } - if (!getPackageType().equals(other.getPackageType())) return false; - if (getIsObsolete() != other.getIsObsolete()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + CPE_URI_FIELD_NUMBER; - hash = (53 * hash) + getCpeUri().hashCode(); - hash = (37 * hash) + PACKAGE_FIELD_NUMBER; - hash = (53 * hash) + getPackage().hashCode(); - if (hasMinAffectedVersion()) { - hash = (37 * hash) + MIN_AFFECTED_VERSION_FIELD_NUMBER; - hash = (53 * hash) + getMinAffectedVersion().hashCode(); - } - if (hasMaxAffectedVersion()) { - hash = (37 * hash) + MAX_AFFECTED_VERSION_FIELD_NUMBER; - hash = (53 * hash) + getMaxAffectedVersion().hashCode(); - } - hash = (37 * hash) + SEVERITY_NAME_FIELD_NUMBER; - hash = (53 * hash) + getSeverityName().hashCode(); - hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; - hash = (53 * hash) + getDescription().hashCode(); - if (hasFixedLocation()) { - hash = (37 * hash) + FIXED_LOCATION_FIELD_NUMBER; - hash = (53 * hash) + getFixedLocation().hashCode(); - } - hash = (37 * hash) + PACKAGE_TYPE_FIELD_NUMBER; - hash = (53 * hash) + getPackageType().hashCode(); - hash = (37 * hash) + IS_OBSOLETE_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getIsObsolete()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability.Detail parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability.Detail parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability.Detail parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability.Detail parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability.Detail parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability.Detail parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability.Detail parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability.Detail 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 io.grafeas.v1beta1.vulnerability.Vulnerability.Detail parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability.Detail 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 io.grafeas.v1beta1.vulnerability.Vulnerability.Detail parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability.Detail 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( - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail 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; - } - /** - * - * - *
-     * Identifies all occurrences of this vulnerability in the package for a
-     * specific distro/location. For example: glibc in
-     * cpe:/o:debian:debian_linux:8 for versions 2.1 - 2.2
-     * 
- * - * Protobuf type {@code grafeas.v1beta1.vulnerability.Vulnerability.Detail} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.vulnerability.Vulnerability.Detail) - io.grafeas.v1beta1.vulnerability.Vulnerability.DetailOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Vulnerability_Detail_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Vulnerability_Detail_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.class, - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.Builder.class); - } - - // Construct using io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - cpeUri_ = ""; - - package_ = ""; - - if (minAffectedVersionBuilder_ == null) { - minAffectedVersion_ = null; - } else { - minAffectedVersion_ = null; - minAffectedVersionBuilder_ = null; - } - if (maxAffectedVersionBuilder_ == null) { - maxAffectedVersion_ = null; - } else { - maxAffectedVersion_ = null; - maxAffectedVersionBuilder_ = null; - } - severityName_ = ""; - - description_ = ""; - - if (fixedLocationBuilder_ == null) { - fixedLocation_ = null; - } else { - fixedLocation_ = null; - fixedLocationBuilder_ = null; - } - packageType_ = ""; - - isObsolete_ = false; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Vulnerability_Detail_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.Vulnerability.Detail getDefaultInstanceForType() { - return io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.Vulnerability.Detail build() { - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.Vulnerability.Detail buildPartial() { - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail result = - new io.grafeas.v1beta1.vulnerability.Vulnerability.Detail(this); - result.cpeUri_ = cpeUri_; - result.package_ = package_; - if (minAffectedVersionBuilder_ == null) { - result.minAffectedVersion_ = minAffectedVersion_; - } else { - result.minAffectedVersion_ = minAffectedVersionBuilder_.build(); - } - if (maxAffectedVersionBuilder_ == null) { - result.maxAffectedVersion_ = maxAffectedVersion_; - } else { - result.maxAffectedVersion_ = maxAffectedVersionBuilder_.build(); - } - result.severityName_ = severityName_; - result.description_ = description_; - if (fixedLocationBuilder_ == null) { - result.fixedLocation_ = fixedLocation_; - } else { - result.fixedLocation_ = fixedLocationBuilder_.build(); - } - result.packageType_ = packageType_; - result.isObsolete_ = isObsolete_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.vulnerability.Vulnerability.Detail) { - return mergeFrom((io.grafeas.v1beta1.vulnerability.Vulnerability.Detail) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.vulnerability.Vulnerability.Detail other) { - if (other == io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.getDefaultInstance()) - return this; - if (!other.getCpeUri().isEmpty()) { - cpeUri_ = other.cpeUri_; - onChanged(); - } - if (!other.getPackage().isEmpty()) { - package_ = other.package_; - onChanged(); - } - if (other.hasMinAffectedVersion()) { - mergeMinAffectedVersion(other.getMinAffectedVersion()); - } - if (other.hasMaxAffectedVersion()) { - mergeMaxAffectedVersion(other.getMaxAffectedVersion()); - } - if (!other.getSeverityName().isEmpty()) { - severityName_ = other.severityName_; - onChanged(); - } - if (!other.getDescription().isEmpty()) { - description_ = other.description_; - onChanged(); - } - if (other.hasFixedLocation()) { - mergeFixedLocation(other.getFixedLocation()); - } - if (!other.getPackageType().isEmpty()) { - packageType_ = other.packageType_; - onChanged(); - } - if (other.getIsObsolete() != false) { - setIsObsolete(other.getIsObsolete()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (io.grafeas.v1beta1.vulnerability.Vulnerability.Detail) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object cpeUri_ = ""; - /** - * - * - *
-       * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) in
-       * which the vulnerability manifests.  Examples include distro or storage
-       * location for vulnerable jar.
-       * 
- * - * string cpe_uri = 1; - */ - public java.lang.String getCpeUri() { - java.lang.Object ref = cpeUri_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - cpeUri_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) in
-       * which the vulnerability manifests.  Examples include distro or storage
-       * location for vulnerable jar.
-       * 
- * - * string cpe_uri = 1; - */ - public com.google.protobuf.ByteString getCpeUriBytes() { - java.lang.Object ref = cpeUri_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - cpeUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) in
-       * which the vulnerability manifests.  Examples include distro or storage
-       * location for vulnerable jar.
-       * 
- * - * string cpe_uri = 1; - */ - public Builder setCpeUri(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - cpeUri_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) in
-       * which the vulnerability manifests.  Examples include distro or storage
-       * location for vulnerable jar.
-       * 
- * - * string cpe_uri = 1; - */ - public Builder clearCpeUri() { - - cpeUri_ = getDefaultInstance().getCpeUri(); - onChanged(); - return this; - } - /** - * - * - *
-       * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) in
-       * which the vulnerability manifests.  Examples include distro or storage
-       * location for vulnerable jar.
-       * 
- * - * string cpe_uri = 1; - */ - public Builder setCpeUriBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - cpeUri_ = value; - onChanged(); - return this; - } - - private java.lang.Object package_ = ""; - /** - * - * - *
-       * The name of the package where the vulnerability was found.
-       * 
- * - * string package = 2; - */ - public java.lang.String getPackage() { - java.lang.Object ref = package_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - package_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The name of the package where the vulnerability was found.
-       * 
- * - * string package = 2; - */ - public com.google.protobuf.ByteString getPackageBytes() { - java.lang.Object ref = package_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - package_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The name of the package where the vulnerability was found.
-       * 
- * - * string package = 2; - */ - public Builder setPackage(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - package_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The name of the package where the vulnerability was found.
-       * 
- * - * string package = 2; - */ - public Builder clearPackage() { - - package_ = getDefaultInstance().getPackage(); - onChanged(); - return this; - } - /** - * - * - *
-       * The name of the package where the vulnerability was found.
-       * 
- * - * string package = 2; - */ - public Builder setPackageBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - package_ = value; - onChanged(); - return this; - } - - private io.grafeas.v1beta1.pkg.Version minAffectedVersion_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder> - minAffectedVersionBuilder_; - /** - * - * - *
-       * The min version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - public boolean hasMinAffectedVersion() { - return minAffectedVersionBuilder_ != null || minAffectedVersion_ != null; - } - /** - * - * - *
-       * The min version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - public io.grafeas.v1beta1.pkg.Version getMinAffectedVersion() { - if (minAffectedVersionBuilder_ == null) { - return minAffectedVersion_ == null - ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() - : minAffectedVersion_; - } else { - return minAffectedVersionBuilder_.getMessage(); - } - } - /** - * - * - *
-       * The min version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - public Builder setMinAffectedVersion(io.grafeas.v1beta1.pkg.Version value) { - if (minAffectedVersionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - minAffectedVersion_ = value; - onChanged(); - } else { - minAffectedVersionBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * The min version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - public Builder setMinAffectedVersion(io.grafeas.v1beta1.pkg.Version.Builder builderForValue) { - if (minAffectedVersionBuilder_ == null) { - minAffectedVersion_ = builderForValue.build(); - onChanged(); - } else { - minAffectedVersionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * The min version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - public Builder mergeMinAffectedVersion(io.grafeas.v1beta1.pkg.Version value) { - if (minAffectedVersionBuilder_ == null) { - if (minAffectedVersion_ != null) { - minAffectedVersion_ = - io.grafeas.v1beta1.pkg.Version.newBuilder(minAffectedVersion_) - .mergeFrom(value) - .buildPartial(); - } else { - minAffectedVersion_ = value; - } - onChanged(); - } else { - minAffectedVersionBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * The min version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - public Builder clearMinAffectedVersion() { - if (minAffectedVersionBuilder_ == null) { - minAffectedVersion_ = null; - onChanged(); - } else { - minAffectedVersion_ = null; - minAffectedVersionBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * The min version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - public io.grafeas.v1beta1.pkg.Version.Builder getMinAffectedVersionBuilder() { - - onChanged(); - return getMinAffectedVersionFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * The min version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - public io.grafeas.v1beta1.pkg.VersionOrBuilder getMinAffectedVersionOrBuilder() { - if (minAffectedVersionBuilder_ != null) { - return minAffectedVersionBuilder_.getMessageOrBuilder(); - } else { - return minAffectedVersion_ == null - ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() - : minAffectedVersion_; - } - } - /** - * - * - *
-       * The min version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version min_affected_version = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder> - getMinAffectedVersionFieldBuilder() { - if (minAffectedVersionBuilder_ == null) { - minAffectedVersionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder>( - getMinAffectedVersion(), getParentForChildren(), isClean()); - minAffectedVersion_ = null; - } - return minAffectedVersionBuilder_; - } - - private io.grafeas.v1beta1.pkg.Version maxAffectedVersion_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder> - maxAffectedVersionBuilder_; - /** - * - * - *
-       * The max version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - public boolean hasMaxAffectedVersion() { - return maxAffectedVersionBuilder_ != null || maxAffectedVersion_ != null; - } - /** - * - * - *
-       * The max version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - public io.grafeas.v1beta1.pkg.Version getMaxAffectedVersion() { - if (maxAffectedVersionBuilder_ == null) { - return maxAffectedVersion_ == null - ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() - : maxAffectedVersion_; - } else { - return maxAffectedVersionBuilder_.getMessage(); - } - } - /** - * - * - *
-       * The max version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - public Builder setMaxAffectedVersion(io.grafeas.v1beta1.pkg.Version value) { - if (maxAffectedVersionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - maxAffectedVersion_ = value; - onChanged(); - } else { - maxAffectedVersionBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * The max version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - public Builder setMaxAffectedVersion(io.grafeas.v1beta1.pkg.Version.Builder builderForValue) { - if (maxAffectedVersionBuilder_ == null) { - maxAffectedVersion_ = builderForValue.build(); - onChanged(); - } else { - maxAffectedVersionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * The max version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - public Builder mergeMaxAffectedVersion(io.grafeas.v1beta1.pkg.Version value) { - if (maxAffectedVersionBuilder_ == null) { - if (maxAffectedVersion_ != null) { - maxAffectedVersion_ = - io.grafeas.v1beta1.pkg.Version.newBuilder(maxAffectedVersion_) - .mergeFrom(value) - .buildPartial(); - } else { - maxAffectedVersion_ = value; - } - onChanged(); - } else { - maxAffectedVersionBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * The max version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - public Builder clearMaxAffectedVersion() { - if (maxAffectedVersionBuilder_ == null) { - maxAffectedVersion_ = null; - onChanged(); - } else { - maxAffectedVersion_ = null; - maxAffectedVersionBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * The max version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - public io.grafeas.v1beta1.pkg.Version.Builder getMaxAffectedVersionBuilder() { - - onChanged(); - return getMaxAffectedVersionFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * The max version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - public io.grafeas.v1beta1.pkg.VersionOrBuilder getMaxAffectedVersionOrBuilder() { - if (maxAffectedVersionBuilder_ != null) { - return maxAffectedVersionBuilder_.getMessageOrBuilder(); - } else { - return maxAffectedVersion_ == null - ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() - : maxAffectedVersion_; - } - } - /** - * - * - *
-       * The max version of the package in which the vulnerability exists.
-       * 
- * - * .grafeas.v1beta1.package.Version max_affected_version = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder> - getMaxAffectedVersionFieldBuilder() { - if (maxAffectedVersionBuilder_ == null) { - maxAffectedVersionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder>( - getMaxAffectedVersion(), getParentForChildren(), isClean()); - maxAffectedVersion_ = null; - } - return maxAffectedVersionBuilder_; - } - - private java.lang.Object severityName_ = ""; - /** - * - * - *
-       * The severity (eg: distro assigned severity) for this vulnerability.
-       * 
- * - * string severity_name = 5; - */ - public java.lang.String getSeverityName() { - java.lang.Object ref = severityName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - severityName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The severity (eg: distro assigned severity) for this vulnerability.
-       * 
- * - * string severity_name = 5; - */ - public com.google.protobuf.ByteString getSeverityNameBytes() { - java.lang.Object ref = severityName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - severityName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The severity (eg: distro assigned severity) for this vulnerability.
-       * 
- * - * string severity_name = 5; - */ - public Builder setSeverityName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - severityName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The severity (eg: distro assigned severity) for this vulnerability.
-       * 
- * - * string severity_name = 5; - */ - public Builder clearSeverityName() { - - severityName_ = getDefaultInstance().getSeverityName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The severity (eg: distro assigned severity) for this vulnerability.
-       * 
- * - * string severity_name = 5; - */ - public Builder setSeverityNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - severityName_ = value; - onChanged(); - return this; - } - - private java.lang.Object description_ = ""; - /** - * - * - *
-       * A vendor-specific description of this note.
-       * 
- * - * string description = 6; - */ - public java.lang.String getDescription() { - java.lang.Object ref = description_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - description_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * A vendor-specific description of this note.
-       * 
- * - * string description = 6; - */ - public com.google.protobuf.ByteString getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * A vendor-specific description of this note.
-       * 
- * - * string description = 6; - */ - public Builder setDescription(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - description_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * A vendor-specific description of this note.
-       * 
- * - * string description = 6; - */ - public Builder clearDescription() { - - description_ = getDefaultInstance().getDescription(); - onChanged(); - return this; - } - /** - * - * - *
-       * A vendor-specific description of this note.
-       * 
- * - * string description = 6; - */ - public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - description_ = value; - onChanged(); - return this; - } - - private io.grafeas.v1beta1.vulnerability.VulnerabilityLocation fixedLocation_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder> - fixedLocationBuilder_; - /** - * - * - *
-       * The fix for this specific package version.
-       * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - public boolean hasFixedLocation() { - return fixedLocationBuilder_ != null || fixedLocation_ != null; - } - /** - * - * - *
-       * The fix for this specific package version.
-       * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation getFixedLocation() { - if (fixedLocationBuilder_ == null) { - return fixedLocation_ == null - ? io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.getDefaultInstance() - : fixedLocation_; - } else { - return fixedLocationBuilder_.getMessage(); - } - } - /** - * - * - *
-       * The fix for this specific package version.
-       * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - public Builder setFixedLocation( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation value) { - if (fixedLocationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - fixedLocation_ = value; - onChanged(); - } else { - fixedLocationBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * The fix for this specific package version.
-       * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - public Builder setFixedLocation( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder builderForValue) { - if (fixedLocationBuilder_ == null) { - fixedLocation_ = builderForValue.build(); - onChanged(); - } else { - fixedLocationBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * The fix for this specific package version.
-       * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - public Builder mergeFixedLocation( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation value) { - if (fixedLocationBuilder_ == null) { - if (fixedLocation_ != null) { - fixedLocation_ = - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.newBuilder(fixedLocation_) - .mergeFrom(value) - .buildPartial(); - } else { - fixedLocation_ = value; - } - onChanged(); - } else { - fixedLocationBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * The fix for this specific package version.
-       * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - public Builder clearFixedLocation() { - if (fixedLocationBuilder_ == null) { - fixedLocation_ = null; - onChanged(); - } else { - fixedLocation_ = null; - fixedLocationBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * The fix for this specific package version.
-       * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder - getFixedLocationBuilder() { - - onChanged(); - return getFixedLocationFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * The fix for this specific package version.
-       * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder - getFixedLocationOrBuilder() { - if (fixedLocationBuilder_ != null) { - return fixedLocationBuilder_.getMessageOrBuilder(); - } else { - return fixedLocation_ == null - ? io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.getDefaultInstance() - : fixedLocation_; - } - } - /** - * - * - *
-       * The fix for this specific package version.
-       * 
- * - * .grafeas.v1beta1.vulnerability.VulnerabilityLocation fixed_location = 7; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder> - getFixedLocationFieldBuilder() { - if (fixedLocationBuilder_ == null) { - fixedLocationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder>( - getFixedLocation(), getParentForChildren(), isClean()); - fixedLocation_ = null; - } - return fixedLocationBuilder_; - } - - private java.lang.Object packageType_ = ""; - /** - * - * - *
-       * The type of package; whether native or non native(ruby gems, node.js
-       * packages etc).
-       * 
- * - * string package_type = 8; - */ - public java.lang.String getPackageType() { - java.lang.Object ref = packageType_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - packageType_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The type of package; whether native or non native(ruby gems, node.js
-       * packages etc).
-       * 
- * - * string package_type = 8; - */ - public com.google.protobuf.ByteString getPackageTypeBytes() { - java.lang.Object ref = packageType_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - packageType_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The type of package; whether native or non native(ruby gems, node.js
-       * packages etc).
-       * 
- * - * string package_type = 8; - */ - public Builder setPackageType(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - packageType_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The type of package; whether native or non native(ruby gems, node.js
-       * packages etc).
-       * 
- * - * string package_type = 8; - */ - public Builder clearPackageType() { - - packageType_ = getDefaultInstance().getPackageType(); - onChanged(); - return this; - } - /** - * - * - *
-       * The type of package; whether native or non native(ruby gems, node.js
-       * packages etc).
-       * 
- * - * string package_type = 8; - */ - public Builder setPackageTypeBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - packageType_ = value; - onChanged(); - return this; - } - - private boolean isObsolete_; - /** - * - * - *
-       * Whether this detail is obsolete. Occurrences are expected not to point to
-       * obsolete details.
-       * 
- * - * bool is_obsolete = 9; - */ - public boolean getIsObsolete() { - return isObsolete_; - } - /** - * - * - *
-       * Whether this detail is obsolete. Occurrences are expected not to point to
-       * obsolete details.
-       * 
- * - * bool is_obsolete = 9; - */ - public Builder setIsObsolete(boolean value) { - - isObsolete_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Whether this detail is obsolete. Occurrences are expected not to point to
-       * obsolete details.
-       * 
- * - * bool is_obsolete = 9; - */ - public Builder clearIsObsolete() { - - isObsolete_ = false; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.vulnerability.Vulnerability.Detail) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.vulnerability.Vulnerability.Detail) - private static final io.grafeas.v1beta1.vulnerability.Vulnerability.Detail DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.vulnerability.Vulnerability.Detail(); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability.Detail getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Detail parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Detail(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.Vulnerability.Detail getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - private int bitField0_; - public static final int CVSS_SCORE_FIELD_NUMBER = 1; - private float cvssScore_; - /** - * - * - *
-   * The CVSS score for this vulnerability.
-   * 
- * - * float cvss_score = 1; - */ - public float getCvssScore() { - return cvssScore_; - } - - public static final int SEVERITY_FIELD_NUMBER = 2; - private int severity_; - /** - * - * - *
-   * Note provider assigned impact of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public int getSeverityValue() { - return severity_; - } - /** - * - * - *
-   * Note provider assigned impact of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public io.grafeas.v1beta1.vulnerability.Severity getSeverity() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.vulnerability.Severity result = - io.grafeas.v1beta1.vulnerability.Severity.valueOf(severity_); - return result == null ? io.grafeas.v1beta1.vulnerability.Severity.UNRECOGNIZED : result; - } - - public static final int DETAILS_FIELD_NUMBER = 3; - private java.util.List details_; - /** - * - * - *
-   * All information about the package to specifically identify this
-   * vulnerability. One entry per (version range and cpe_uri) the package
-   * vulnerability has manifested in.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public java.util.List getDetailsList() { - return details_; - } - /** - * - * - *
-   * All information about the package to specifically identify this
-   * vulnerability. One entry per (version range and cpe_uri) the package
-   * vulnerability has manifested in.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public java.util.List - getDetailsOrBuilderList() { - return details_; - } - /** - * - * - *
-   * All information about the package to specifically identify this
-   * vulnerability. One entry per (version range and cpe_uri) the package
-   * vulnerability has manifested in.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public int getDetailsCount() { - return details_.size(); - } - /** - * - * - *
-   * All information about the package to specifically identify this
-   * vulnerability. One entry per (version range and cpe_uri) the package
-   * vulnerability has manifested in.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public io.grafeas.v1beta1.vulnerability.Vulnerability.Detail getDetails(int index) { - return details_.get(index); - } - /** - * - * - *
-   * All information about the package to specifically identify this
-   * vulnerability. One entry per (version range and cpe_uri) the package
-   * vulnerability has manifested in.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public io.grafeas.v1beta1.vulnerability.Vulnerability.DetailOrBuilder getDetailsOrBuilder( - int index) { - return details_.get(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 (cvssScore_ != 0F) { - output.writeFloat(1, cvssScore_); - } - if (severity_ != io.grafeas.v1beta1.vulnerability.Severity.SEVERITY_UNSPECIFIED.getNumber()) { - output.writeEnum(2, severity_); - } - for (int i = 0; i < details_.size(); i++) { - output.writeMessage(3, details_.get(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (cvssScore_ != 0F) { - size += com.google.protobuf.CodedOutputStream.computeFloatSize(1, cvssScore_); - } - if (severity_ != io.grafeas.v1beta1.vulnerability.Severity.SEVERITY_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, severity_); - } - for (int i = 0; i < details_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, details_.get(i)); - } - 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 io.grafeas.v1beta1.vulnerability.Vulnerability)) { - return super.equals(obj); - } - io.grafeas.v1beta1.vulnerability.Vulnerability other = - (io.grafeas.v1beta1.vulnerability.Vulnerability) obj; - - if (java.lang.Float.floatToIntBits(getCvssScore()) - != java.lang.Float.floatToIntBits(other.getCvssScore())) return false; - if (severity_ != other.severity_) return false; - if (!getDetailsList().equals(other.getDetailsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + CVSS_SCORE_FIELD_NUMBER; - hash = (53 * hash) + java.lang.Float.floatToIntBits(getCvssScore()); - hash = (37 * hash) + SEVERITY_FIELD_NUMBER; - hash = (53 * hash) + severity_; - if (getDetailsCount() > 0) { - hash = (37 * hash) + DETAILS_FIELD_NUMBER; - hash = (53 * hash) + getDetailsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability 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 io.grafeas.v1beta1.vulnerability.Vulnerability parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability 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 io.grafeas.v1beta1.vulnerability.Vulnerability parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability 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(io.grafeas.v1beta1.vulnerability.Vulnerability 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; - } - /** - * - * - *
-   * Vulnerability provides metadata about a security vulnerability.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.vulnerability.Vulnerability} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.vulnerability.Vulnerability) - io.grafeas.v1beta1.vulnerability.VulnerabilityOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Vulnerability_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Vulnerability_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.vulnerability.Vulnerability.class, - io.grafeas.v1beta1.vulnerability.Vulnerability.Builder.class); - } - - // Construct using io.grafeas.v1beta1.vulnerability.Vulnerability.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getDetailsFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - cvssScore_ = 0F; - - severity_ = 0; - - if (detailsBuilder_ == null) { - details_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - } else { - detailsBuilder_.clear(); - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_Vulnerability_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.Vulnerability getDefaultInstanceForType() { - return io.grafeas.v1beta1.vulnerability.Vulnerability.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.Vulnerability build() { - io.grafeas.v1beta1.vulnerability.Vulnerability result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.Vulnerability buildPartial() { - io.grafeas.v1beta1.vulnerability.Vulnerability result = - new io.grafeas.v1beta1.vulnerability.Vulnerability(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.cvssScore_ = cvssScore_; - result.severity_ = severity_; - if (detailsBuilder_ == null) { - if (((bitField0_ & 0x00000004) != 0)) { - details_ = java.util.Collections.unmodifiableList(details_); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.details_ = details_; - } else { - result.details_ = detailsBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.vulnerability.Vulnerability) { - return mergeFrom((io.grafeas.v1beta1.vulnerability.Vulnerability) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.vulnerability.Vulnerability other) { - if (other == io.grafeas.v1beta1.vulnerability.Vulnerability.getDefaultInstance()) return this; - if (other.getCvssScore() != 0F) { - setCvssScore(other.getCvssScore()); - } - if (other.severity_ != 0) { - setSeverityValue(other.getSeverityValue()); - } - if (detailsBuilder_ == null) { - if (!other.details_.isEmpty()) { - if (details_.isEmpty()) { - details_ = other.details_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureDetailsIsMutable(); - details_.addAll(other.details_); - } - onChanged(); - } - } else { - if (!other.details_.isEmpty()) { - if (detailsBuilder_.isEmpty()) { - detailsBuilder_.dispose(); - detailsBuilder_ = null; - details_ = other.details_; - bitField0_ = (bitField0_ & ~0x00000004); - detailsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getDetailsFieldBuilder() - : null; - } else { - detailsBuilder_.addAllMessages(other.details_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.vulnerability.Vulnerability parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (io.grafeas.v1beta1.vulnerability.Vulnerability) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private float cvssScore_; - /** - * - * - *
-     * The CVSS score for this vulnerability.
-     * 
- * - * float cvss_score = 1; - */ - public float getCvssScore() { - return cvssScore_; - } - /** - * - * - *
-     * The CVSS score for this vulnerability.
-     * 
- * - * float cvss_score = 1; - */ - public Builder setCvssScore(float value) { - - cvssScore_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The CVSS score for this vulnerability.
-     * 
- * - * float cvss_score = 1; - */ - public Builder clearCvssScore() { - - cvssScore_ = 0F; - onChanged(); - return this; - } - - private int severity_ = 0; - /** - * - * - *
-     * Note provider assigned impact of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public int getSeverityValue() { - return severity_; - } - /** - * - * - *
-     * Note provider assigned impact of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public Builder setSeverityValue(int value) { - severity_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Note provider assigned impact of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public io.grafeas.v1beta1.vulnerability.Severity getSeverity() { - @SuppressWarnings("deprecation") - io.grafeas.v1beta1.vulnerability.Severity result = - io.grafeas.v1beta1.vulnerability.Severity.valueOf(severity_); - return result == null ? io.grafeas.v1beta1.vulnerability.Severity.UNRECOGNIZED : result; - } - /** - * - * - *
-     * Note provider assigned impact of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public Builder setSeverity(io.grafeas.v1beta1.vulnerability.Severity value) { - if (value == null) { - throw new NullPointerException(); - } - - severity_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Note provider assigned impact of the vulnerability.
-     * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - public Builder clearSeverity() { - - severity_ = 0; - onChanged(); - return this; - } - - private java.util.List details_ = - java.util.Collections.emptyList(); - - private void ensureDetailsIsMutable() { - if (!((bitField0_ & 0x00000004) != 0)) { - details_ = - new java.util.ArrayList( - details_); - bitField0_ |= 0x00000004; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail, - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.Builder, - io.grafeas.v1beta1.vulnerability.Vulnerability.DetailOrBuilder> - detailsBuilder_; - - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public java.util.List getDetailsList() { - if (detailsBuilder_ == null) { - return java.util.Collections.unmodifiableList(details_); - } else { - return detailsBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public int getDetailsCount() { - if (detailsBuilder_ == null) { - return details_.size(); - } else { - return detailsBuilder_.getCount(); - } - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public io.grafeas.v1beta1.vulnerability.Vulnerability.Detail getDetails(int index) { - if (detailsBuilder_ == null) { - return details_.get(index); - } else { - return detailsBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public Builder setDetails( - int index, io.grafeas.v1beta1.vulnerability.Vulnerability.Detail value) { - if (detailsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureDetailsIsMutable(); - details_.set(index, value); - onChanged(); - } else { - detailsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public Builder setDetails( - int index, io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.Builder builderForValue) { - if (detailsBuilder_ == null) { - ensureDetailsIsMutable(); - details_.set(index, builderForValue.build()); - onChanged(); - } else { - detailsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public Builder addDetails(io.grafeas.v1beta1.vulnerability.Vulnerability.Detail value) { - if (detailsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureDetailsIsMutable(); - details_.add(value); - onChanged(); - } else { - detailsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public Builder addDetails( - int index, io.grafeas.v1beta1.vulnerability.Vulnerability.Detail value) { - if (detailsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureDetailsIsMutable(); - details_.add(index, value); - onChanged(); - } else { - detailsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public Builder addDetails( - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.Builder builderForValue) { - if (detailsBuilder_ == null) { - ensureDetailsIsMutable(); - details_.add(builderForValue.build()); - onChanged(); - } else { - detailsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public Builder addDetails( - int index, io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.Builder builderForValue) { - if (detailsBuilder_ == null) { - ensureDetailsIsMutable(); - details_.add(index, builderForValue.build()); - onChanged(); - } else { - detailsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public Builder addAllDetails( - java.lang.Iterable - values) { - if (detailsBuilder_ == null) { - ensureDetailsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, details_); - onChanged(); - } else { - detailsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public Builder clearDetails() { - if (detailsBuilder_ == null) { - details_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - } else { - detailsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public Builder removeDetails(int index) { - if (detailsBuilder_ == null) { - ensureDetailsIsMutable(); - details_.remove(index); - onChanged(); - } else { - detailsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.Builder getDetailsBuilder( - int index) { - return getDetailsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public io.grafeas.v1beta1.vulnerability.Vulnerability.DetailOrBuilder getDetailsOrBuilder( - int index) { - if (detailsBuilder_ == null) { - return details_.get(index); - } else { - return detailsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public java.util.List - getDetailsOrBuilderList() { - if (detailsBuilder_ != null) { - return detailsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(details_); - } - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.Builder addDetailsBuilder() { - return getDetailsFieldBuilder() - .addBuilder(io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.getDefaultInstance()); - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.Builder addDetailsBuilder( - int index) { - return getDetailsFieldBuilder() - .addBuilder( - index, io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.getDefaultInstance()); - } - /** - * - * - *
-     * All information about the package to specifically identify this
-     * vulnerability. One entry per (version range and cpe_uri) the package
-     * vulnerability has manifested in.
-     * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - public java.util.List - getDetailsBuilderList() { - return getDetailsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail, - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.Builder, - io.grafeas.v1beta1.vulnerability.Vulnerability.DetailOrBuilder> - getDetailsFieldBuilder() { - if (detailsBuilder_ == null) { - detailsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail, - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail.Builder, - io.grafeas.v1beta1.vulnerability.Vulnerability.DetailOrBuilder>( - details_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); - details_ = null; - } - return detailsBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.vulnerability.Vulnerability) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.vulnerability.Vulnerability) - private static final io.grafeas.v1beta1.vulnerability.Vulnerability DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.vulnerability.Vulnerability(); - } - - public static io.grafeas.v1beta1.vulnerability.Vulnerability getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Vulnerability parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Vulnerability(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.Vulnerability getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityLocation.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityLocation.java deleted file mode 100644 index 1253ee42..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityLocation.java +++ /dev/null @@ -1,1024 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto - -package io.grafeas.v1beta1.vulnerability; - -/** - * - * - *
- * The location of the vulnerability.
- * 
- * - * Protobuf type {@code grafeas.v1beta1.vulnerability.VulnerabilityLocation} - */ -public final class VulnerabilityLocation extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:grafeas.v1beta1.vulnerability.VulnerabilityLocation) - VulnerabilityLocationOrBuilder { - private static final long serialVersionUID = 0L; - // Use VulnerabilityLocation.newBuilder() to construct. - private VulnerabilityLocation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private VulnerabilityLocation() { - cpeUri_ = ""; - package_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private VulnerabilityLocation( - 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(); - - cpeUri_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - package_ = s; - break; - } - case 26: - { - io.grafeas.v1beta1.pkg.Version.Builder subBuilder = null; - if (version_ != null) { - subBuilder = version_.toBuilder(); - } - version_ = - input.readMessage(io.grafeas.v1beta1.pkg.Version.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(version_); - version_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(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 io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_VulnerabilityLocation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_VulnerabilityLocation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.class, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder.class); - } - - public static final int CPE_URI_FIELD_NUMBER = 1; - private volatile java.lang.Object cpeUri_; - /** - * - * - *
-   * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/)
-   * format. Examples include distro or storage location for vulnerable jar.
-   * 
- * - * string cpe_uri = 1; - */ - public java.lang.String getCpeUri() { - java.lang.Object ref = cpeUri_; - 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(); - cpeUri_ = s; - return s; - } - } - /** - * - * - *
-   * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/)
-   * format. Examples include distro or storage location for vulnerable jar.
-   * 
- * - * string cpe_uri = 1; - */ - public com.google.protobuf.ByteString getCpeUriBytes() { - java.lang.Object ref = cpeUri_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - cpeUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PACKAGE_FIELD_NUMBER = 2; - private volatile java.lang.Object package_; - /** - * - * - *
-   * The package being described.
-   * 
- * - * string package = 2; - */ - public java.lang.String getPackage() { - java.lang.Object ref = package_; - 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(); - package_ = s; - return s; - } - } - /** - * - * - *
-   * The package being described.
-   * 
- * - * string package = 2; - */ - public com.google.protobuf.ByteString getPackageBytes() { - java.lang.Object ref = package_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - package_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int VERSION_FIELD_NUMBER = 3; - private io.grafeas.v1beta1.pkg.Version version_; - /** - * - * - *
-   * The version of the package being described.
-   * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - public boolean hasVersion() { - return version_ != null; - } - /** - * - * - *
-   * The version of the package being described.
-   * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - public io.grafeas.v1beta1.pkg.Version getVersion() { - return version_ == null ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() : version_; - } - /** - * - * - *
-   * The version of the package being described.
-   * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - public io.grafeas.v1beta1.pkg.VersionOrBuilder getVersionOrBuilder() { - return getVersion(); - } - - 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 (!getCpeUriBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, cpeUri_); - } - if (!getPackageBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, package_); - } - if (version_ != null) { - output.writeMessage(3, getVersion()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getCpeUriBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, cpeUri_); - } - if (!getPackageBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, package_); - } - if (version_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getVersion()); - } - 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 io.grafeas.v1beta1.vulnerability.VulnerabilityLocation)) { - return super.equals(obj); - } - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation other = - (io.grafeas.v1beta1.vulnerability.VulnerabilityLocation) obj; - - if (!getCpeUri().equals(other.getCpeUri())) return false; - if (!getPackage().equals(other.getPackage())) return false; - if (hasVersion() != other.hasVersion()) return false; - if (hasVersion()) { - if (!getVersion().equals(other.getVersion())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + CPE_URI_FIELD_NUMBER; - hash = (53 * hash) + getCpeUri().hashCode(); - hash = (37 * hash) + PACKAGE_FIELD_NUMBER; - hash = (53 * hash) + getPackage().hashCode(); - if (hasVersion()) { - hash = (37 * hash) + VERSION_FIELD_NUMBER; - hash = (53 * hash) + getVersion().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static io.grafeas.v1beta1.vulnerability.VulnerabilityLocation parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.VulnerabilityLocation parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.VulnerabilityLocation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.VulnerabilityLocation parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.VulnerabilityLocation parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static io.grafeas.v1beta1.vulnerability.VulnerabilityLocation parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static io.grafeas.v1beta1.vulnerability.VulnerabilityLocation parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.VulnerabilityLocation 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 io.grafeas.v1beta1.vulnerability.VulnerabilityLocation parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.VulnerabilityLocation 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 io.grafeas.v1beta1.vulnerability.VulnerabilityLocation parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static io.grafeas.v1beta1.vulnerability.VulnerabilityLocation 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( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation 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; - } - /** - * - * - *
-   * The location of the vulnerability.
-   * 
- * - * Protobuf type {@code grafeas.v1beta1.vulnerability.VulnerabilityLocation} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:grafeas.v1beta1.vulnerability.VulnerabilityLocation) - io.grafeas.v1beta1.vulnerability.VulnerabilityLocationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_VulnerabilityLocation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_VulnerabilityLocation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.class, - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.Builder.class); - } - - // Construct using io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - cpeUri_ = ""; - - package_ = ""; - - if (versionBuilder_ == null) { - version_ = null; - } else { - version_ = null; - versionBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityOuterClass - .internal_static_grafeas_v1beta1_vulnerability_VulnerabilityLocation_descriptor; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation getDefaultInstanceForType() { - return io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.getDefaultInstance(); - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation build() { - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation buildPartial() { - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation result = - new io.grafeas.v1beta1.vulnerability.VulnerabilityLocation(this); - result.cpeUri_ = cpeUri_; - result.package_ = package_; - if (versionBuilder_ == null) { - result.version_ = version_; - } else { - result.version_ = versionBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof io.grafeas.v1beta1.vulnerability.VulnerabilityLocation) { - return mergeFrom((io.grafeas.v1beta1.vulnerability.VulnerabilityLocation) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(io.grafeas.v1beta1.vulnerability.VulnerabilityLocation other) { - if (other == io.grafeas.v1beta1.vulnerability.VulnerabilityLocation.getDefaultInstance()) - return this; - if (!other.getCpeUri().isEmpty()) { - cpeUri_ = other.cpeUri_; - onChanged(); - } - if (!other.getPackage().isEmpty()) { - package_ = other.package_; - onChanged(); - } - if (other.hasVersion()) { - mergeVersion(other.getVersion()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - io.grafeas.v1beta1.vulnerability.VulnerabilityLocation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (io.grafeas.v1beta1.vulnerability.VulnerabilityLocation) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object cpeUri_ = ""; - /** - * - * - *
-     * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/)
-     * format. Examples include distro or storage location for vulnerable jar.
-     * 
- * - * string cpe_uri = 1; - */ - public java.lang.String getCpeUri() { - java.lang.Object ref = cpeUri_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - cpeUri_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/)
-     * format. Examples include distro or storage location for vulnerable jar.
-     * 
- * - * string cpe_uri = 1; - */ - public com.google.protobuf.ByteString getCpeUriBytes() { - java.lang.Object ref = cpeUri_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - cpeUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/)
-     * format. Examples include distro or storage location for vulnerable jar.
-     * 
- * - * string cpe_uri = 1; - */ - public Builder setCpeUri(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - cpeUri_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/)
-     * format. Examples include distro or storage location for vulnerable jar.
-     * 
- * - * string cpe_uri = 1; - */ - public Builder clearCpeUri() { - - cpeUri_ = getDefaultInstance().getCpeUri(); - onChanged(); - return this; - } - /** - * - * - *
-     * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/)
-     * format. Examples include distro or storage location for vulnerable jar.
-     * 
- * - * string cpe_uri = 1; - */ - public Builder setCpeUriBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - cpeUri_ = value; - onChanged(); - return this; - } - - private java.lang.Object package_ = ""; - /** - * - * - *
-     * The package being described.
-     * 
- * - * string package = 2; - */ - public java.lang.String getPackage() { - java.lang.Object ref = package_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - package_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The package being described.
-     * 
- * - * string package = 2; - */ - public com.google.protobuf.ByteString getPackageBytes() { - java.lang.Object ref = package_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - package_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The package being described.
-     * 
- * - * string package = 2; - */ - public Builder setPackage(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - package_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The package being described.
-     * 
- * - * string package = 2; - */ - public Builder clearPackage() { - - package_ = getDefaultInstance().getPackage(); - onChanged(); - return this; - } - /** - * - * - *
-     * The package being described.
-     * 
- * - * string package = 2; - */ - public Builder setPackageBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - package_ = value; - onChanged(); - return this; - } - - private io.grafeas.v1beta1.pkg.Version version_; - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder> - versionBuilder_; - /** - * - * - *
-     * The version of the package being described.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - public boolean hasVersion() { - return versionBuilder_ != null || version_ != null; - } - /** - * - * - *
-     * The version of the package being described.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - public io.grafeas.v1beta1.pkg.Version getVersion() { - if (versionBuilder_ == null) { - return version_ == null ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() : version_; - } else { - return versionBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The version of the package being described.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - public Builder setVersion(io.grafeas.v1beta1.pkg.Version value) { - if (versionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - version_ = value; - onChanged(); - } else { - versionBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The version of the package being described.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - public Builder setVersion(io.grafeas.v1beta1.pkg.Version.Builder builderForValue) { - if (versionBuilder_ == null) { - version_ = builderForValue.build(); - onChanged(); - } else { - versionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The version of the package being described.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - public Builder mergeVersion(io.grafeas.v1beta1.pkg.Version value) { - if (versionBuilder_ == null) { - if (version_ != null) { - version_ = - io.grafeas.v1beta1.pkg.Version.newBuilder(version_).mergeFrom(value).buildPartial(); - } else { - version_ = value; - } - onChanged(); - } else { - versionBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The version of the package being described.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - public Builder clearVersion() { - if (versionBuilder_ == null) { - version_ = null; - onChanged(); - } else { - version_ = null; - versionBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The version of the package being described.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - public io.grafeas.v1beta1.pkg.Version.Builder getVersionBuilder() { - - onChanged(); - return getVersionFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The version of the package being described.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - public io.grafeas.v1beta1.pkg.VersionOrBuilder getVersionOrBuilder() { - if (versionBuilder_ != null) { - return versionBuilder_.getMessageOrBuilder(); - } else { - return version_ == null ? io.grafeas.v1beta1.pkg.Version.getDefaultInstance() : version_; - } - } - /** - * - * - *
-     * The version of the package being described.
-     * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder> - getVersionFieldBuilder() { - if (versionBuilder_ == null) { - versionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - io.grafeas.v1beta1.pkg.Version, - io.grafeas.v1beta1.pkg.Version.Builder, - io.grafeas.v1beta1.pkg.VersionOrBuilder>( - getVersion(), getParentForChildren(), isClean()); - version_ = null; - } - return versionBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:grafeas.v1beta1.vulnerability.VulnerabilityLocation) - } - - // @@protoc_insertion_point(class_scope:grafeas.v1beta1.vulnerability.VulnerabilityLocation) - private static final io.grafeas.v1beta1.vulnerability.VulnerabilityLocation DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new io.grafeas.v1beta1.vulnerability.VulnerabilityLocation(); - } - - public static io.grafeas.v1beta1.vulnerability.VulnerabilityLocation getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public VulnerabilityLocation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new VulnerabilityLocation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public io.grafeas.v1beta1.vulnerability.VulnerabilityLocation getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityLocationOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityLocationOrBuilder.java deleted file mode 100644 index 587a488c..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityLocationOrBuilder.java +++ /dev/null @@ -1,85 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto - -package io.grafeas.v1beta1.vulnerability; - -public interface VulnerabilityLocationOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.vulnerability.VulnerabilityLocation) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/)
-   * format. Examples include distro or storage location for vulnerable jar.
-   * 
- * - * string cpe_uri = 1; - */ - java.lang.String getCpeUri(); - /** - * - * - *
-   * The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/)
-   * format. Examples include distro or storage location for vulnerable jar.
-   * 
- * - * string cpe_uri = 1; - */ - com.google.protobuf.ByteString getCpeUriBytes(); - - /** - * - * - *
-   * The package being described.
-   * 
- * - * string package = 2; - */ - java.lang.String getPackage(); - /** - * - * - *
-   * The package being described.
-   * 
- * - * string package = 2; - */ - com.google.protobuf.ByteString getPackageBytes(); - - /** - * - * - *
-   * The version of the package being described.
-   * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - boolean hasVersion(); - /** - * - * - *
-   * The version of the package being described.
-   * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - io.grafeas.v1beta1.pkg.Version getVersion(); - /** - * - * - *
-   * The version of the package being described.
-   * 
- * - * .grafeas.v1beta1.package.Version version = 3; - */ - io.grafeas.v1beta1.pkg.VersionOrBuilder getVersionOrBuilder(); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityOrBuilder.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityOrBuilder.java deleted file mode 100644 index 611d5a1d..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityOrBuilder.java +++ /dev/null @@ -1,104 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto - -package io.grafeas.v1beta1.vulnerability; - -public interface VulnerabilityOrBuilder - extends - // @@protoc_insertion_point(interface_extends:grafeas.v1beta1.vulnerability.Vulnerability) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The CVSS score for this vulnerability.
-   * 
- * - * float cvss_score = 1; - */ - float getCvssScore(); - - /** - * - * - *
-   * Note provider assigned impact of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - int getSeverityValue(); - /** - * - * - *
-   * Note provider assigned impact of the vulnerability.
-   * 
- * - * .grafeas.v1beta1.vulnerability.Severity severity = 2; - */ - io.grafeas.v1beta1.vulnerability.Severity getSeverity(); - - /** - * - * - *
-   * All information about the package to specifically identify this
-   * vulnerability. One entry per (version range and cpe_uri) the package
-   * vulnerability has manifested in.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - java.util.List getDetailsList(); - /** - * - * - *
-   * All information about the package to specifically identify this
-   * vulnerability. One entry per (version range and cpe_uri) the package
-   * vulnerability has manifested in.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - io.grafeas.v1beta1.vulnerability.Vulnerability.Detail getDetails(int index); - /** - * - * - *
-   * All information about the package to specifically identify this
-   * vulnerability. One entry per (version range and cpe_uri) the package
-   * vulnerability has manifested in.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - int getDetailsCount(); - /** - * - * - *
-   * All information about the package to specifically identify this
-   * vulnerability. One entry per (version range and cpe_uri) the package
-   * vulnerability has manifested in.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - java.util.List - getDetailsOrBuilderList(); - /** - * - * - *
-   * All information about the package to specifically identify this
-   * vulnerability. One entry per (version range and cpe_uri) the package
-   * vulnerability has manifested in.
-   * 
- * - * repeated .grafeas.v1beta1.vulnerability.Vulnerability.Detail details = 3; - */ - io.grafeas.v1beta1.vulnerability.Vulnerability.DetailOrBuilder getDetailsOrBuilder(int index); -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityOuterClass.java b/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityOuterClass.java deleted file mode 100644 index 730d31c5..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/java/io/grafeas/v1beta1/vulnerability/VulnerabilityOuterClass.java +++ /dev/null @@ -1,161 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto - -package io.grafeas.v1beta1.vulnerability; - -public final class VulnerabilityOuterClass { - private VulnerabilityOuterClass() {} - - 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_grafeas_v1beta1_vulnerability_Vulnerability_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_vulnerability_Vulnerability_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_vulnerability_Vulnerability_Detail_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_vulnerability_Vulnerability_Detail_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_vulnerability_Details_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_vulnerability_Details_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_vulnerability_PackageIssue_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_vulnerability_PackageIssue_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_grafeas_v1beta1_vulnerability_VulnerabilityLocation_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_grafeas_v1beta1_vulnerability_VulnerabilityLocation_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { - return descriptor; - } - - private static com.google.protobuf.Descriptors.FileDescriptor descriptor; - - static { - java.lang.String[] descriptorData = { - "\nKgoogle/devtools/containeranalysis/v1be" - + "ta1/vulnerability/vulnerability.proto\022\035g" - + "rafeas.v1beta1.vulnerability\032=google/dev" - + "tools/containeranalysis/v1beta1/common/c" - + "ommon.proto\032?google/devtools/containeran" - + "alysis/v1beta1/package/package.proto\"\366\003\n" - + "\rVulnerability\022\022\n\ncvss_score\030\001 \001(\002\0229\n\010se" - + "verity\030\002 \001(\0162\'.grafeas.v1beta1.vulnerabi" - + "lity.Severity\022D\n\007details\030\003 \003(\01323.grafeas" - + ".v1beta1.vulnerability.Vulnerability.Det" - + "ail\032\317\002\n\006Detail\022\017\n\007cpe_uri\030\001 \001(\t\022\017\n\007packa" - + "ge\030\002 \001(\t\022>\n\024min_affected_version\030\003 \001(\0132 " - + ".grafeas.v1beta1.package.Version\022>\n\024max_" - + "affected_version\030\004 \001(\0132 .grafeas.v1beta1" - + ".package.Version\022\025\n\rseverity_name\030\005 \001(\t\022" - + "\023\n\013description\030\006 \001(\t\022L\n\016fixed_location\030\007" - + " \001(\01324.grafeas.v1beta1.vulnerability.Vul" - + "nerabilityLocation\022\024\n\014package_type\030\010 \001(\t" - + "\022\023\n\013is_obsolete\030\t \001(\010\"\222\002\n\007Details\022\014\n\004typ" - + "e\030\001 \001(\t\0229\n\010severity\030\002 \001(\0162\'.grafeas.v1be" - + "ta1.vulnerability.Severity\022\022\n\ncvss_score" - + "\030\003 \001(\002\022B\n\rpackage_issue\030\004 \003(\0132+.grafeas." - + "v1beta1.vulnerability.PackageIssue\022\031\n\021sh" - + "ort_description\030\005 \001(\t\022\030\n\020long_descriptio" - + "n\030\006 \001(\t\0221\n\014related_urls\030\007 \003(\0132\033.grafeas." - + "v1beta1.RelatedUrl\"\304\001\n\014PackageIssue\022O\n\021a" - + "ffected_location\030\001 \001(\01324.grafeas.v1beta1" - + ".vulnerability.VulnerabilityLocation\022L\n\016" - + "fixed_location\030\002 \001(\01324.grafeas.v1beta1.v" - + "ulnerability.VulnerabilityLocation\022\025\n\rse" - + "verity_name\030\003 \001(\t\"l\n\025VulnerabilityLocati" - + "on\022\017\n\007cpe_uri\030\001 \001(\t\022\017\n\007package\030\002 \001(\t\0221\n\007" - + "version\030\003 \001(\0132 .grafeas.v1beta1.package." - + "Version*^\n\010Severity\022\030\n\024SEVERITY_UNSPECIF" - + "IED\020\000\022\013\n\007MINIMAL\020\001\022\007\n\003LOW\020\002\022\n\n\006MEDIUM\020\003\022" - + "\010\n\004HIGH\020\004\022\014\n\010CRITICAL\020\005B\220\001\n io.grafeas.v" - + "1beta1.vulnerabilityP\001Zdgoogle.golang.or" - + "g/genproto/googleapis/devtools/container" - + "analysis/v1beta1/vulnerability;vulnerabi" - + "lity\242\002\003GRAb\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[] { - io.grafeas.v1beta1.common.Common.getDescriptor(), - io.grafeas.v1beta1.pkg.PackageOuterClass.getDescriptor(), - }, - assigner); - internal_static_grafeas_v1beta1_vulnerability_Vulnerability_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_grafeas_v1beta1_vulnerability_Vulnerability_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_vulnerability_Vulnerability_descriptor, - new java.lang.String[] { - "CvssScore", "Severity", "Details", - }); - internal_static_grafeas_v1beta1_vulnerability_Vulnerability_Detail_descriptor = - internal_static_grafeas_v1beta1_vulnerability_Vulnerability_descriptor - .getNestedTypes() - .get(0); - internal_static_grafeas_v1beta1_vulnerability_Vulnerability_Detail_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_vulnerability_Vulnerability_Detail_descriptor, - new java.lang.String[] { - "CpeUri", - "Package", - "MinAffectedVersion", - "MaxAffectedVersion", - "SeverityName", - "Description", - "FixedLocation", - "PackageType", - "IsObsolete", - }); - internal_static_grafeas_v1beta1_vulnerability_Details_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_grafeas_v1beta1_vulnerability_Details_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_vulnerability_Details_descriptor, - new java.lang.String[] { - "Type", - "Severity", - "CvssScore", - "PackageIssue", - "ShortDescription", - "LongDescription", - "RelatedUrls", - }); - internal_static_grafeas_v1beta1_vulnerability_PackageIssue_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_grafeas_v1beta1_vulnerability_PackageIssue_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_vulnerability_PackageIssue_descriptor, - new java.lang.String[] { - "AffectedLocation", "FixedLocation", "SeverityName", - }); - internal_static_grafeas_v1beta1_vulnerability_VulnerabilityLocation_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_grafeas_v1beta1_vulnerability_VulnerabilityLocation_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_grafeas_v1beta1_vulnerability_VulnerabilityLocation_descriptor, - new java.lang.String[] { - "CpeUri", "Package", "Version", - }); - io.grafeas.v1beta1.common.Common.getDescriptor(); - io.grafeas.v1beta1.pkg.PackageOuterClass.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/attestation/attestation.proto b/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/attestation/attestation.proto deleted file mode 100644 index e60b6e91..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/attestation/attestation.proto +++ /dev/null @@ -1,132 +0,0 @@ -// Copyright 2018 The Grafeas Authors. All rights reserved. -// -// 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. - -syntax = "proto3"; - -package grafeas.v1beta1.attestation; - -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1/attestation;attestation"; -option java_multiple_files = true; -option java_package = "io.grafeas.v1beta1.attestation"; -option objc_class_prefix = "GRA"; - -// An attestation wrapper with a PGP-compatible signature. This message only -// supports `ATTACHED` signatures, where the payload that is signed is included -// alongside the signature itself in the same file. -message PgpSignedAttestation { - // The raw content of the signature, as output by GNU Privacy Guard (GPG) or - // equivalent. Since this message only supports attached signatures, the - // payload that was signed must be attached. While the signature format - // supported is dependent on the verification implementation, currently only - // ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than - // `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor - // --output=signature.gpg payload.json` will create the signature content - // expected in this field in `signature.gpg` for the `payload.json` - // attestation payload. - string signature = 1; - - // Type (for example schema) of the attestation payload that was signed. - enum ContentType { - // `ContentType` is not set. - CONTENT_TYPE_UNSPECIFIED = 0; - // Atomic format attestation signature. See - // https://github.com/containers/image/blob/8a5d2f82a6e3263290c8e0276c3e0f64e77723e7/docs/atomic-signature.md - // The payload extracted from `signature` is a JSON blob conforming to the - // linked schema. - SIMPLE_SIGNING_JSON = 1; - } - - // Type (for example schema) of the attestation payload that was signed. - // The verifier must ensure that the provided type is one that the verifier - // supports, and that the attestation payload is a valid instantiation of that - // type (for example by validating a JSON schema). - ContentType content_type = 3; - - // This field is used by verifiers to select the public key used to validate - // the signature. Note that the policy of the verifier ultimately determines - // which public keys verify a signature based on the context of the - // verification. There is no guarantee validation will succeed if the - // verifier has no key matching this ID, even if it has a key under a - // different ID that would verify the signature. Note that this ID should also - // be present in the signature content above, but that is not expected to be - // used by the verifier. - oneof key_id { - // The cryptographic fingerprint of the key used to generate the signature, - // as output by, e.g. `gpg --list-keys`. This should be the version 4, full - // 160-bit fingerprint, expressed as a 40 character hexidecimal string. See - // https://tools.ietf.org/html/rfc4880#section-12.2 for details. - // Implementations may choose to acknowledge "LONG", "SHORT", or other - // abbreviated key IDs, but only the full fingerprint is guaranteed to work. - // In gpg, the full fingerprint can be retrieved from the `fpr` field - // returned when calling --list-keys with --with-colons. For example: - // ``` - // gpg --with-colons --with-fingerprint --force-v4-certs \ - // --list-keys attester@example.com - // tru::1:1513631572:0:3:1:5 - // pub:...... - // fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB: - // ``` - // Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`. - string pgp_key_id = 2; - } -} - -// Note kind that represents a logical attestation "role" or "authority". For -// example, an organization might have one `Authority` for "QA" and one for -// "build". This Note is intended to act strictly as a grouping mechanism for -// the attached Occurrences (Attestations). This grouping mechanism also -// provides a security boundary, since IAM ACLs gate the ability for a principle -// to attach an Occurrence to a given Note. It also provides a single point of -// lookup to find all attached Attestation Occurrences, even if they don't all -// live in the same project. -message Authority { - // This submessage provides human-readable hints about the purpose of the - // Authority. Because the name of a Note acts as its resource reference, it is - // important to disambiguate the canonical name of the Note (which might be a - // UUID for security purposes) from "readable" names more suitable for debug - // output. Note that these hints should NOT be used to look up authorities in - // security sensitive contexts, such as when looking up Attestations to - // verify. - message Hint { - // The human readable name of this Attestation Authority, for example "qa". - string human_readable_name = 1; - } - - // Hint hints at the purpose of the attestation authority. - Hint hint = 1; -} - -// Details of an attestation occurrence. -message Details { - // Attestation for the resource. - Attestation attestation = 1; -} - -// Occurrence that represents a single "attestation". The authenticity of an -// Attestation can be verified using the attached signature. If the verifier -// trusts the public key of the signer, then verifying the signature is -// sufficient to establish trust. In this circumstance, the Authority to which -// this Attestation is attached is primarily useful for look-up (how to find -// this Attestation if you already know the Authority and artifact to be -// verified) and intent (which authority was this attestation intended to sign -// for). -message Attestation { - // The signature, generally over the `resource_url`, that verifies this - // attestation. The semantics of the signature veracity are ultimately - // determined by the verification engine. - oneof signature { - // A PGP signed attestation. - PgpSignedAttestation pgp_signed_attestation = 1; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/build/build.proto b/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/build/build.proto deleted file mode 100644 index 32b357f0..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/build/build.proto +++ /dev/null @@ -1,96 +0,0 @@ -// Copyright 2018 The Grafeas Authors. All rights reserved. -// -// 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. - -syntax = "proto3"; - -package grafeas.v1beta1.build; - -import "google/devtools/containeranalysis/v1beta1/provenance/provenance.proto"; - -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1/build;build"; -option java_multiple_files = true; -option java_package = "io.grafeas.v1beta1.build"; -option objc_class_prefix = "GRA"; - -// Note holding the version of the provider's builder and the signature of the -// provenance message in linked BuildDetails. -message Build { - // Version of the builder which produced this Note. - string builder_version = 1; - - // Signature of the build in Occurrences pointing to the Note containing this - // `BuilderDetails`. - BuildSignature signature = 2; -} - -// Message encapsulating the signature of the verified build. -message BuildSignature { - // Public key of the builder which can be used to verify that the related - // findings are valid and unchanged. If `key_type` is empty, this defaults - // to PEM encoded public keys. - // - // This field may be empty if `key_id` references an external key. - // - // For Cloud Container Builder based signatures, this is a PEM encoded public - // key. To verify the Cloud Container Builder signature, place the contents of - // this field into a file (public.pem). The signature field is base64-decoded - // into its binary representation in signature.bin, and the provenance bytes - // from `BuildDetails` are base64-decoded into a binary representation in - // signed.bin. OpenSSL can then verify the signature: - // `openssl sha256 -verify public.pem -signature signature.bin signed.bin` - string public_key = 1; - - // Signature of the related `BuildProvenance`. In JSON, this is base-64 - // encoded. - bytes signature = 2; - - // An ID for the key used to sign. This could be either an Id for the key - // stored in `public_key` (such as the Id or fingerprint for a PGP key, or the - // CN for a cert), or a reference to an external key (such as a reference to a - // key in Cloud Key Management Service). - string key_id = 3; - - // Public key formats - enum KeyType { - // `KeyType` is not set. - KEY_TYPE_UNSPECIFIED = 0; - // `PGP ASCII Armored` public key. - PGP_ASCII_ARMORED = 1; - // `PKIX PEM` public key. - PKIX_PEM = 2; - } - - // The type of the key, either stored in `public_key` or referenced in - // `key_id` - KeyType key_type = 4; -} - -// Details of a build occurrence. -message Details { - // The actual provenance for the build. - grafeas.v1beta1.provenance.BuildProvenance provenance = 1; - - // Serialized JSON representation of the provenance, used in generating the - // `BuildSignature` in the corresponding Result. After verifying the - // signature, `provenance_bytes` can be unmarshalled and compared to the - // provenance to confirm that it is unchanged. A base64-encoded string - // representation of the provenance bytes is used for the signature in order - // to interoperate with openssl which expects this format for signature - // verification. - // - // The serialized form is captured both to avoid ambiguity in how the - // provenance is marshalled to json as well to prevent incompatibilities with - // future changes. - string provenance_bytes = 2; -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/common/common.proto b/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/common/common.proto deleted file mode 100644 index a8a2ddad..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/common/common.proto +++ /dev/null @@ -1,50 +0,0 @@ -// Copyright 2018 The Grafeas Authors. All rights reserved. -// -// 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. - -syntax = "proto3"; - -package grafeas.v1beta1; - -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1/common;common"; -option java_multiple_files = true; -option java_package = "io.grafeas.v1beta1.common"; -option objc_class_prefix = "GRA"; - -// Kind represents the kinds of notes supported. -enum NoteKind { - // Unknown. - NOTE_KIND_UNSPECIFIED = 0; - // The note and occurrence represent a package vulnerability. - VULNERABILITY = 1; - // The note and occurrence assert build provenance. - BUILD = 2; - // This represents an image basis relationship. - IMAGE = 3; - // This represents a package installed via a package manager. - PACKAGE = 4; - // The note and occurrence track deployment events. - DEPLOYMENT = 5; - // The note and occurrence track the initial discovery status of a resource. - DISCOVERY = 6; - // This represents a logical "role" that can attest to artifacts. - ATTESTATION = 7; -} - -// Metadata for any related URL information. -message RelatedUrl { - // Specific URL associated with the resource. - string url = 1; - // Label to describe usage of the URL. - string label = 2; -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/containeranalysis.proto b/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/containeranalysis.proto deleted file mode 100644 index b1515338..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/containeranalysis.proto +++ /dev/null @@ -1,190 +0,0 @@ -// 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. - -syntax = "proto3"; - -package google.devtools.containeranalysis.v1beta1; - -import "google/api/annotations.proto"; -import "google/iam/v1/iam_policy.proto"; -import "google/iam/v1/policy.proto"; -import "google/protobuf/timestamp.proto"; - -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1;containeranalysis"; -option java_multiple_files = true; -option java_package = "com.google.containeranalysis.v1beta1"; -option objc_class_prefix = "GCA"; - -// Retrieves analysis results of Cloud components such as Docker container -// images. The Container Analysis API is an implementation of the -// [Grafeas](grafeas.io) API. -// -// Analysis results are stored as a series of occurrences. An `Occurrence` -// contains information about a specific analysis instance on a resource. An -// occurrence refers to a `Note`. A note contains details describing the -// analysis and is generally stored in a separate project, called a `Provider`. -// Multiple occurrences can refer to the same note. -// -// For example, an SSL vulnerability could affect multiple images. In this case, -// there would be one note for the vulnerability and an occurrence for each -// image with the vulnerability referring to that note. -service ContainerAnalysisV1Beta1 { - // Sets the access control policy on the specified note or occurrence. - // Requires `containeranalysis.notes.setIamPolicy` or - // `containeranalysis.occurrences.setIamPolicy` permission if the resource is - // a note or an occurrence, respectively. - // - // The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for - // notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for - // occurrences. - rpc SetIamPolicy(google.iam.v1.SetIamPolicyRequest) - returns (google.iam.v1.Policy) { - option (google.api.http) = { - post: "/v1beta1/{resource=projects/*/notes/*}:setIamPolicy" - body: "*" - additional_bindings { - post: "/v1beta1/{resource=projects/*/occurrences/*}:setIamPolicy" - body: "*" - } - }; - } - - // Gets the access control policy for a note or an occurrence resource. - // Requires `containeranalysis.notes.setIamPolicy` or - // `containeranalysis.occurrences.setIamPolicy` permission if the resource is - // a note or occurrence, respectively. - // - // The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for - // notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for - // occurrences. - rpc GetIamPolicy(google.iam.v1.GetIamPolicyRequest) - returns (google.iam.v1.Policy) { - option (google.api.http) = { - post: "/v1beta1/{resource=projects/*/notes/*}:getIamPolicy" - body: "*" - additional_bindings { - post: "/v1beta1/{resource=projects/*/occurrences/*}:getIamPolicy" - body: "*" - } - }; - } - - // Returns the permissions that a caller has on the specified note or - // occurrence. Requires list permission on the project (for example, - // `containeranalysis.notes.list`). - // - // The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for - // notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for - // occurrences. - rpc TestIamPermissions(google.iam.v1.TestIamPermissionsRequest) - returns (google.iam.v1.TestIamPermissionsResponse) { - option (google.api.http) = { - post: "/v1beta1/{resource=projects/*/notes/*}:testIamPermissions" - body: "*" - additional_bindings { - post: "/v1beta1/{resource=projects/*/occurrences/*}:testIamPermissions" - body: "*" - } - }; - } - - // Gets the specified scan configuration. - rpc GetScanConfig(GetScanConfigRequest) returns (ScanConfig) { - option (google.api.http) = { - get: "/v1beta1/{name=projects/*/scanConfigs/*}" - }; - } - - // Lists scan configurations for the specified project. - rpc ListScanConfigs(ListScanConfigsRequest) - returns (ListScanConfigsResponse) { - option (google.api.http) = { - get: "/v1beta1/{parent=projects/*}/scanConfigs" - }; - } - - // Updates the specified scan configuration. - rpc UpdateScanConfig(UpdateScanConfigRequest) returns (ScanConfig) { - option (google.api.http) = { - put: "/v1beta1/{name=projects/*/scanConfigs/*}" - body: "scan_config" - }; - } -} - -// A scan configuration specifies whether Cloud components in a project have a -// particular type of analysis being run. For example, it can configure whether -// vulnerability scanning is being done on Docker images or not. -message ScanConfig { - // Output only. The name of the scan configuration in the form of - // `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`. - string name = 1; - - // Output only. A human-readable description of what the scan configuration - // does. - string description = 2; - - // Whether the scan is enabled. - bool enabled = 3; - - // Output only. The time this scan config was created. - google.protobuf.Timestamp create_time = 4; - - // Output only. The time this scan config was last updated. - google.protobuf.Timestamp update_time = 5; -} - -// Request to get a scan configuration. -message GetScanConfigRequest { - // The name of the scan configuration in the form of - // `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`. - string name = 1; -} - -// Request to list scan configurations. -message ListScanConfigsRequest { - // The name of the project to list scan configurations for in the form of - // `projects/[PROJECT_ID]`. - string parent = 1; - - // The filter expression. - string filter = 2; - - // The number of scan configs to return in the list. - int32 page_size = 3; - - // Token to provide to skip to a particular spot in the list. - string page_token = 4; -} - -// Response for listing scan configurations. -message ListScanConfigsResponse { - // The scan configurations requested. - repeated ScanConfig scan_configs = 1; - - // The next pagination token in the list response. It should be used as - // `page_token` for the following request. An empty value means no more - // results. - string next_page_token = 2; -} - -// A request to update a scan configuration. -message UpdateScanConfigRequest { - // The name of the scan configuration in the form of - // `projects/[PROJECT_ID]/scanConfigs/[SCAN_CONFIG_ID]`. - string name = 1; - - // The updated scan configuration. - ScanConfig scan_config = 2; -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/deployment/deployment.proto b/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/deployment/deployment.proto deleted file mode 100644 index 96a81aeb..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/deployment/deployment.proto +++ /dev/null @@ -1,74 +0,0 @@ -// Copyright 2018 The Grafeas Authors. All rights reserved. -// -// 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. - -syntax = "proto3"; - -package grafeas.v1beta1.deployment; - -import "google/protobuf/timestamp.proto"; - -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1/deployment;deployment"; -option java_multiple_files = true; -option java_package = "io.grafeas.v1beta1.deployment"; -option objc_class_prefix = "GRA"; - -// An artifact that can be deployed in some runtime. -message Deployable { - // Resource URI for the artifact being deployed. - repeated string resource_uri = 1; -} - -// Details of a deployment occurrence. -message Details { - // Deployment history for the resource. - Deployment deployment = 1; -} - -// The period during which some deployable was active in a runtime. -message Deployment { - // Identity of the user that triggered this deployment. - string user_email = 1; - - // Beginning of the lifetime of this deployment. - google.protobuf.Timestamp deploy_time = 2; - - // End of the lifetime of this deployment. - google.protobuf.Timestamp undeploy_time = 3; - - // Configuration used to create this deployment. - string config = 4; - - // Address of the runtime element hosting this deployment. - string address = 5; - - // Output only. Resource URI for the artifact being deployed taken from - // the deployable field with the same name. - repeated string resource_uri = 6; - - // Types of platforms. - enum Platform { - // Unknown. - PLATFORM_UNSPECIFIED = 0; - // Google Container Engine. - GKE = 1; - // Google App Engine: Flexible Environment. - FLEX = 2; - // Custom user-defined platform. - CUSTOM = 3; - } - // Platform hosting this deployment. - Platform platform = 7; - - // next_id = 8; -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/discovery/discovery.proto b/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/discovery/discovery.proto deleted file mode 100644 index 4ed5aeba..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/discovery/discovery.proto +++ /dev/null @@ -1,85 +0,0 @@ -// Copyright 2018 The Grafeas Authors. All rights reserved. -// -// 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. - -syntax = "proto3"; - -package grafeas.v1beta1.discovery; - -import "google/devtools/containeranalysis/v1beta1/common/common.proto"; -import "google/protobuf/timestamp.proto"; -import "google/rpc/status.proto"; - -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1/discovery;discovery"; -option java_multiple_files = true; -option java_package = "io.grafeas.v1beta1.discovery"; -option objc_class_prefix = "GRA"; - -// A note that indicates a type of analysis a provider would perform. This note -// exists in a provider's project. A `Discovery` occurrence is created in a -// consumer's project at the start of analysis. -message Discovery { - // The kind of analysis that is handled by this discovery. - grafeas.v1beta1.NoteKind analysis_kind = 1; -} - -// Details of a discovery occurrence. -message Details { - // Analysis status for the discovered resource. - Discovered discovered = 1; -} - -// Provides information about the analysis status of a discovered resource. -message Discovered { - // Whether the resource is continuously analyzed. - enum ContinuousAnalysis { - // Unknown. - CONTINUOUS_ANALYSIS_UNSPECIFIED = 0; - // The resource is continuously analyzed. - ACTIVE = 1; - // The resource is ignored for continuous analysis. - INACTIVE = 2; - } - - // Whether the resource is continuously analyzed. - ContinuousAnalysis continuous_analysis = 1; - - // The last time continuous analysis was done for this resource. - google.protobuf.Timestamp last_analysis_time = 2; - - // Analysis status for a resource. Currently for initial analysis only (not - // updated in continuous analysis). - enum AnalysisStatus { - // Unknown. - ANALYSIS_STATUS_UNSPECIFIED = 0; - // Resource is known but no action has been taken yet. - PENDING = 1; - // Resource is being analyzed. - SCANNING = 2; - // Analysis has finished successfully. - FINISHED_SUCCESS = 3; - // Analysis has finished unsuccessfully, the analysis itself is in a bad - // state. - FINISHED_FAILED = 4; - // The resource is known not to be supported - FINISHED_UNSUPPORTED = 5; - } - - // The status of discovery for the resource. - AnalysisStatus analysis_status = 3; - - // When an error is encountered this will contain a LocalizedMessage under - // details to show to the user. The LocalizedMessage is output only and - // populated by the API. - google.rpc.Status analysis_status_error = 4; -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto b/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto deleted file mode 100644 index 9c2ac8b0..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/grafeas/grafeas.proto +++ /dev/null @@ -1,502 +0,0 @@ -// Copyright 2018 The Grafeas Authors. All rights reserved. -// -// 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. - -syntax = "proto3"; - -package grafeas.v1beta1; - -import "google/api/annotations.proto"; -import "google/devtools/containeranalysis/v1beta1/attestation/attestation.proto"; -import "google/devtools/containeranalysis/v1beta1/build/build.proto"; -import "google/devtools/containeranalysis/v1beta1/common/common.proto"; -import "google/devtools/containeranalysis/v1beta1/deployment/deployment.proto"; -import "google/devtools/containeranalysis/v1beta1/discovery/discovery.proto"; -import "google/devtools/containeranalysis/v1beta1/image/image.proto"; -import "google/devtools/containeranalysis/v1beta1/package/package.proto"; -import "google/devtools/containeranalysis/v1beta1/provenance/provenance.proto"; -import "google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto"; -import "google/protobuf/empty.proto"; -import "google/protobuf/field_mask.proto"; -import "google/protobuf/timestamp.proto"; - -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1/grafeas;grafeas"; -option java_multiple_files = true; -option java_package = "io.grafeas.v1beta1"; -option objc_class_prefix = "GRA"; - -// [Grafeas](grafeas.io) API. -// -// Retrieves analysis results of Cloud components such as Docker container -// images. -// -// Analysis results are stored as a series of occurrences. An `Occurrence` -// contains information about a specific analysis instance on a resource. An -// occurrence refers to a `Note`. A note contains details describing the -// analysis and is generally stored in a separate project, called a `Provider`. -// Multiple occurrences can refer to the same note. -// -// For example, an SSL vulnerability could affect multiple images. In this case, -// there would be one note for the vulnerability and an occurrence for each -// image with the vulnerability referring to that note. -service GrafeasV1Beta1 { - // Gets the specified occurrence. - rpc GetOccurrence(GetOccurrenceRequest) returns (Occurrence) { - option (google.api.http) = { - get: "/v1beta1/{name=projects/*/occurrences/*}" - }; - } - - // Lists occurrences for the specified project. - rpc ListOccurrences(ListOccurrencesRequest) - returns (ListOccurrencesResponse) { - option (google.api.http) = { - get: "/v1beta1/{parent=projects/*}/occurrences" - }; - } - - // Deletes the specified occurrence. For example, use this method to delete an - // occurrence when the occurrence is no longer applicable for the given - // resource. - rpc DeleteOccurrence(DeleteOccurrenceRequest) - returns (google.protobuf.Empty) { - option (google.api.http) = { - delete: "/v1beta1/{name=projects/*/occurrences/*}" - }; - } - - // Creates a new occurrence. - rpc CreateOccurrence(CreateOccurrenceRequest) returns (Occurrence) { - option (google.api.http) = { - post: "/v1beta1/{parent=projects/*}/occurrences" - body: "occurrence" - }; - } - - // Creates new occurrences in batch. - rpc BatchCreateOccurrences(BatchCreateOccurrencesRequest) - returns (BatchCreateOccurrencesResponse) { - option (google.api.http) = { - post: "/v1beta1/{parent=projects/*}/occurrences:batchCreate" - body: "*" - }; - } - - // Updates the specified occurrence. - rpc UpdateOccurrence(UpdateOccurrenceRequest) returns (Occurrence) { - option (google.api.http) = { - patch: "/v1beta1/{name=projects/*/occurrences/*}" - body: "occurrence" - }; - } - - // Gets the note attached to the specified occurrence. Consumer projects can - // use this method to get a note that belongs to a provider project. - rpc GetOccurrenceNote(GetOccurrenceNoteRequest) returns (Note) { - option (google.api.http) = { - get: "/v1beta1/{name=projects/*/occurrences/*}/notes" - }; - } - - // Gets the specified note. - rpc GetNote(GetNoteRequest) returns (Note) { - option (google.api.http) = { - get: "/v1beta1/{name=projects/*/notes/*}" - }; - } - - // Lists notes for the specified project. - rpc ListNotes(ListNotesRequest) returns (ListNotesResponse) { - option (google.api.http) = { - get: "/v1beta1/{parent=projects/*}/notes" - }; - } - - // Deletes the specified note. - rpc DeleteNote(DeleteNoteRequest) returns (google.protobuf.Empty) { - option (google.api.http) = { - delete: "/v1beta1/{name=projects/*/notes/*}" - }; - } - - // Creates a new note. - rpc CreateNote(CreateNoteRequest) returns (Note) { - option (google.api.http) = { - post: "/v1beta1/{parent=projects/*}/notes" - body: "note" - }; - } - - // Creates new notes in batch. - rpc BatchCreateNotes(BatchCreateNotesRequest) - returns (BatchCreateNotesResponse) { - option (google.api.http) = { - post: "/v1beta1/{parent=projects/*}/notes:batchCreate" - body: "*" - }; - } - - // Updates the specified note. - rpc UpdateNote(UpdateNoteRequest) returns (Note) { - option (google.api.http) = { - patch: "/v1beta1/{name=projects/*/notes/*}" - body: "note" - }; - } - - // Lists occurrences referencing the specified note. Provider projects can use - // this method to get all occurrences across consumer projects referencing the - // specified note. - rpc ListNoteOccurrences(ListNoteOccurrencesRequest) - returns (ListNoteOccurrencesResponse) { - option (google.api.http) = { - get: "/v1beta1/{name=projects/*/notes/*}/occurrences" - }; - } - - // Gets a summary of the number and severity of occurrences. - rpc GetVulnerabilityOccurrencesSummary( - GetVulnerabilityOccurrencesSummaryRequest) - returns (VulnerabilityOccurrencesSummary) { - option (google.api.http) = { - get: "/v1beta1/{parent=projects/*}/occurrences:vulnerabilitySummary" - }; - } -} - -// An instance of an analysis type that has been found on a resource. -message Occurrence { - // Output only. The name of the occurrence in the form of - // `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - string name = 1; - - // Required. Immutable. The resource for which the occurrence applies. - Resource resource = 2; - - // Required. Immutable. The analysis note associated with this occurrence, in - // the form of `projects[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used - // as a filter in list requests. - string note_name = 3; - - // Output only. This explicitly denotes which of the occurrence details are - // specified. This field can be used as a filter in list requests. - grafeas.v1beta1.NoteKind kind = 4; - - // A description of actions that can be taken to remedy the note. - string remediation = 5; - - // Output only. The time this occurrence was created. - google.protobuf.Timestamp create_time = 6; - - // Output only. The time this occurrence was last updated. - google.protobuf.Timestamp update_time = 7; - - // Required. Immutable. Describes the details of the note kind found on this - // resource. - oneof details { - // Describes a security vulnerability. - grafeas.v1beta1.vulnerability.Details vulnerability = 8; - // Describes a verifiable build. - grafeas.v1beta1.build.Details build = 9; - // Describes how this resource derives from the basis in the associated - // note. - grafeas.v1beta1.image.Details derived_image = 10; - // Describes the installation of a package on the linked resource. - grafeas.v1beta1.package.Details installation = 11; - // Describes the deployment of an artifact on a runtime. - grafeas.v1beta1.deployment.Details deployment = 12; - // Describes when a resource was discovered. - grafeas.v1beta1.discovery.Details discovered = 13; - // Describes an attestation of an artifact. - grafeas.v1beta1.attestation.Details attestation = 14; - } - - // next_id = 15; -} - -// An entity that can have metadata. For example, a Docker image. -message Resource { - // The name of the resource. For example, the name of a Docker image - - // "Debian". - string name = 1; - // The unique URI of the resource. For example, - // `https://gcr.io/project/image@sha256:foo` for a Docker image. - string uri = 2; - // The hash of the resource content. For example, the Docker digest. - grafeas.v1beta1.provenance.Hash content_hash = 3; - - // next_id = 4; -} - -// A type of analysis that can be done for a resource. -message Note { - // Output only. The name of the note in the form of - // `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - string name = 1; - - // A one sentence description of this note. - string short_description = 2; - - // A detailed description of this note. - string long_description = 3; - - // Output only. The type of analysis. This field can be used as a filter in - // list requests. - grafeas.v1beta1.NoteKind kind = 4; - - // URLs associated with this note. - repeated grafeas.v1beta1.RelatedUrl related_url = 5; - - // Time of expiration for this note. Empty if note does not expire. - google.protobuf.Timestamp expiration_time = 6; - - // Output only. The time this note was created. This field can be used as a - // filter in list requests. - google.protobuf.Timestamp create_time = 7; - - // Output only. The time this note was last updated. This field can be used as - // a filter in list requests. - google.protobuf.Timestamp update_time = 8; - - // Other notes related to this note. - repeated string related_note_names = 9; - - // Required. Immutable. The type of analysis this note represents. - oneof type { - // A note describing a package vulnerability. - grafeas.v1beta1.vulnerability.Vulnerability vulnerability = 10; - // A note describing build provenance for a verifiable build. - grafeas.v1beta1.build.Build build = 11; - // A note describing a base image. - grafeas.v1beta1.image.Basis base_image = 12; - // A note describing a package hosted by various package managers. - grafeas.v1beta1.package.Package package = 13; - // A note describing something that can be deployed. - grafeas.v1beta1.deployment.Deployable deployable = 14; - // A note describing the initial analysis of a resource. - grafeas.v1beta1.discovery.Discovery discovery = 15; - // A note describing an attestation role. - grafeas.v1beta1.attestation.Authority attestation_authority = 16; - } - - // next_id = 17; -} - -// Request to get an occurrence. -message GetOccurrenceRequest { - // The name of the occurrence in the form of - // `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - string name = 1; -} - -// Request to list occurrences. -message ListOccurrencesRequest { - // The name of the project to list occurrences for in the form of - // `projects/[PROJECT_ID]`. - string parent = 1; - - // The filter expression. - string filter = 2; - - // Number of occurrences to return in the list. - int32 page_size = 3; - - // Token to provide to skip to a particular spot in the list. - string page_token = 4; - - // next_id = 7; -} - -// Response for listing occurrences. -message ListOccurrencesResponse { - // The occurrences requested. - repeated Occurrence occurrences = 1; - // The next pagination token in the list response. It should be used as - // `page_token` for the following request. An empty value means no more - // results. - string next_page_token = 2; -} - -// Request to delete a occurrence. -message DeleteOccurrenceRequest { - // The name of the occurrence in the form of - // `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - string name = 1; -} - -// Request to create a new occurrence. -message CreateOccurrenceRequest { - // The name of the project in the form of `projects/[PROJECT_ID]`, under which - // the occurrence is to be created. - string parent = 1; - // The occurrence to create. - Occurrence occurrence = 2; -} - -// Request to update an occurrence. -message UpdateOccurrenceRequest { - // The name of the occurrence in the form of - // `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - string name = 1; - // The updated occurrence. - Occurrence occurrence = 2; - // The fields to update. - google.protobuf.FieldMask update_mask = 3; -} - -// Request to get a note. -message GetNoteRequest { - // The name of the note in the form of - // `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - string name = 1; -} - -// Request to get the note to which the specified occurrence is attached. -message GetOccurrenceNoteRequest { - // The name of the occurrence in the form of - // `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. - string name = 1; -} - -// Request to list notes. -message ListNotesRequest { - // The name of the project to list notes for in the form of - // `projects/[PROJECT_ID]`. - string parent = 1; - // The filter expression. - string filter = 2; - // Number of notes to return in the list. - int32 page_size = 3; - // Token to provide to skip to a particular spot in the list. - string page_token = 4; -} - -// Response for listing notes. -message ListNotesResponse { - // The notes requested. - repeated Note notes = 1; - // The next pagination token in the list response. It should be used as - // `page_token` for the following request. An empty value means no more - // results. - string next_page_token = 2; -} - -// Request to delete a note. -message DeleteNoteRequest { - // The name of the note in the form of - // `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - string name = 1; -} - -// Request to create a new note. -message CreateNoteRequest { - // The name of the project in the form of `projects/[PROJECT_ID]`, under which - // the note is to be created. - string parent = 1; - // The ID to use for this note. - string note_id = 2; - // The note to create. - Note note = 3; -} - -// Request to update a note. -message UpdateNoteRequest { - // The name of the note in the form of - // `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - string name = 1; - // The updated note. - Note note = 2; - // The fields to update. - google.protobuf.FieldMask update_mask = 3; -} - -// Request to list occurrences for a note. -message ListNoteOccurrencesRequest { - // The name of the note to list occurrences for in the form of - // `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. - string name = 1; - // The filter expression. - string filter = 2; - // Number of occurrences to return in the list. - int32 page_size = 3; - // Token to provide to skip to a particular spot in the list. - string page_token = 4; -} - -// Response for listing occurrences for a note. -message ListNoteOccurrencesResponse { - // The occurrences attached to the specified note. - repeated Occurrence occurrences = 1; - // Token to provide to skip to a particular spot in the list. - string next_page_token = 2; -} - -// Request to create notes in batch. -message BatchCreateNotesRequest { - // The name of the project in the form of `projects/[PROJECT_ID]`, under which - // the notes are to be created. - string parent = 1; - - // The notes to create. - map notes = 2; -} - -// Response for creating notes in batch. -message BatchCreateNotesResponse { - // The notes that were created. - repeated Note notes = 1; -} - -// Request to create occurrences in batch. -message BatchCreateOccurrencesRequest { - // The name of the project in the form of `projects/[PROJECT_ID]`, under which - // the occurrences are to be created. - string parent = 1; - // The occurrences to create. - repeated Occurrence occurrences = 2; -} - -// Response for creating occurrences in batch. -message BatchCreateOccurrencesResponse { - // The occurrences that were created. - repeated Occurrence occurrences = 1; -} - -// Request to get a vulnerability summary for some set of occurrences. -message GetVulnerabilityOccurrencesSummaryRequest { - // The name of the project to get a vulnerability summary for in the form of - // `projects/[PROJECT_ID]`. - string parent = 1; - // The filter expression. - string filter = 2; -} - -// A summary of how many vulnerability occurrences there are per resource and -// severity type. -message VulnerabilityOccurrencesSummary { - // A listing by resource of the number of fixable and total vulnerabilities. - repeated FixableTotalByDigest counts = 1; - - // Per resource and severity counts of fixable and total vulnerabilites. - message FixableTotalByDigest { - // The affected resource. - Resource resource = 1; - // The severity for this count. SEVERITY_UNSPECIFIED indicates total across - // all severities. - grafeas.v1beta1.vulnerability.Severity severity = 2; - // The number of fixable vulnerabilities associated with this resource. - int64 fixable_count = 3; - // The total number of vulnerabilities associated with this resource. - int64 total_count = 4; - } -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/image/image.proto b/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/image/image.proto deleted file mode 100644 index 01f5305a..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/image/image.proto +++ /dev/null @@ -1,144 +0,0 @@ -// Copyright 2018 The Grafeas Authors. All rights reserved. -// -// 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. - -syntax = "proto3"; - -package grafeas.v1beta1.image; - -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1/image;image"; -option java_multiple_files = true; -option java_package = "io.grafeas.v1beta1.image"; -option objc_class_prefix = "GRA"; - -// Layer holds metadata specific to a layer of a Docker image. -message Layer { - // Instructions from Dockerfile. - enum Directive { - // Default value for unsupported/missing directive. - DIRECTIVE_UNSPECIFIED = 0; - - // https://docs.docker.com/reference/builder/#maintainer - MAINTAINER = 1; - - // https://docs.docker.com/reference/builder/#run - RUN = 2; - - // https://docs.docker.com/reference/builder/#cmd - CMD = 3; - - // https://docs.docker.com/reference/builder/#label - LABEL = 4; - - // https://docs.docker.com/reference/builder/#expose - EXPOSE = 5; - - // https://docs.docker.com/reference/builder/#env - ENV = 6; - - // https://docs.docker.com/reference/builder/#add - ADD = 7; - - // https://docs.docker.com/reference/builder/#copy - COPY = 8; - - // https://docs.docker.com/reference/builder/#entrypoint - ENTRYPOINT = 9; - - // https://docs.docker.com/reference/builder/#volume - VOLUME = 10; - - // https://docs.docker.com/reference/builder/#user - USER = 11; - - // https://docs.docker.com/reference/builder/#workdir - WORKDIR = 12; - - // https://docs.docker.com/reference/builder/#arg - ARG = 13; - - // https://docs.docker.com/reference/builder/#onbuild - ONBUILD = 14; - - // https://docs.docker.com/reference/builder/#stopsignal - STOPSIGNAL = 15; - - // https://docs.docker.com/reference/builder/#healthcheck - HEALTHCHECK = 16; - - // https://docs.docker.com/reference/builder/#shell - SHELL = 17; - } - - // The recovered Dockerfile directive used to construct this layer. - Directive directive = 1; - - // The recovered arguments to the Dockerfile directive. - string arguments = 2; -} - -// A set of properties that uniquely identify a given Docker image. -message Fingerprint { - // The layer-id of the final layer in the Docker image's v1 representation. - string v1_name = 1; - - // The ordered list of v2 blobs that represent a given image. - repeated string v2_blob = 2; - - // Output only. The name of the image's v2 blobs computed via: - // [bottom] := v2_blob[bottom] - // [N] := sha256(v2_blob[N] + " " + v2_name[N+1]) - // Only the name of the final blob is kept. - string v2_name = 3; -} - -// Basis describes the base image portion (Note) of the DockerImage -// relationship. Linked occurrences are derived from this or an -// equivalent image via: -// FROM -// Or an equivalent reference, e.g. a tag of the resource_url. -message Basis { - // The resource_url for the resource representing the basis of - // associated occurrence images. - string resource_url = 1; - - // The fingerprint of the base image. - Fingerprint fingerprint = 2; -} - -// Details of an image occurrence. -message Details { - // The child image derived from the base image. - Derived derived_image = 1; -} - -// Derived describes the derived image portion (Occurrence) of the DockerImage -// relationship. This image would be produced from a Dockerfile with FROM -// . -message Derived { - // The fingerprint of the derived image. - Fingerprint fingerprint = 1; - - // Output only. The number of layers by which this image differs from the - // associated image basis. - int32 distance = 2; - - // This contains layer-specific metadata, if populated it has length - // "distance" and is ordered with [distance] being the layer immediately - // following the base image and [1] being the final layer. - repeated Layer layer_info = 3; - - // Output only. This contains the base image URL for the derived image - // occurrence. - string base_resource_url = 4; -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/package/package.proto b/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/package/package.proto deleted file mode 100644 index 07031d50..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/package/package.proto +++ /dev/null @@ -1,127 +0,0 @@ -// Copyright 2018 The Grafeas Authors. All rights reserved. -// -// 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. - -syntax = "proto3"; - -package grafeas.v1beta1.package; - -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1/package;package"; -option java_multiple_files = true; -option java_package = "io.grafeas.v1beta1.pkg"; -option objc_class_prefix = "GRA"; - -// Instruction set architectures supported by various package managers. -enum Architecture { - // Unknown architecture. - ARCHITECTURE_UNSPECIFIED = 0; - // X86 architecture. - X86 = 1; - // X64 architecture. - X64 = 2; -} - -// This represents a particular channel of distribution for a given package. -// E.g., Debian's jessie-backports dpkg mirror. -message Distribution { - // The cpe_uri in [cpe format](https://cpe.mitre.org/specification/) - // denoting the package manager version distributing a package. - string cpe_uri = 1; - - // The CPU architecture for which packages in this distribution channel were - // built. - Architecture architecture = 2; - - // The latest available version of this package in this distribution - // channel. - Version latest_version = 3; - - // A freeform string denoting the maintainer of this package. - string maintainer = 4; - - // The distribution channel-specific homepage for this package. - string url = 5; - - // The distribution channel-specific description of this package. - string description = 6; -} - -// An occurrence of a particular package installation found within a system's -// filesystem. E.g., glibc was found in /var/lib/dpkg/status. -message Location { - // The cpe_uri in [cpe format](https://cpe.mitre.org/specification/) - // denoting the package manager version distributing a package. - string cpe_uri = 1; - - // The version installed at this location. - Version version = 2; - - // The path from which we gathered that this package/version is installed. - string path = 3; -} - -// This represents a particular package that is distributed over various -// channels. E.g., glibc (aka libc6) is distributed by many, at various -// versions. -message Package { - // The name of the package. - string name = 1; - - // The various channels by which a package is distributed. - repeated Distribution distribution = 10; -} - -// Details of a package occurrence. -message Details { - // Where the package was installed. - Installation installation = 1; -} - -// This represents how a particular software package may be installed on a -// system. -message Installation { - // Output only. The name of the installed package. - string name = 1; - - // All of the places within the filesystem versions of this package - // have been found. - repeated Location location = 2; -} - -// Version contains structured information about the version of a package. -message Version { - // Used to correct mistakes in the version numbering scheme. - int32 epoch = 1; - // The main part of the version name. - string name = 2; - // The iteration of the package build from the above version. - string revision = 3; - - // Whether this is an ordinary package version or a sentinel MIN/MAX version. - enum VersionKind { - // Unknown. - VERSION_KIND_UNSPECIFIED = 0; - // A standard package version, defined by the other fields. - NORMAL = 1; - // A special version representing negative infinity, other fields are - // ignored. - MINIMUM = 2; - // A special version representing positive infinity, other fields are - // ignored. - MAXIMUM = 3; - }; - - // Distinguish between sentinel MIN/MAX versions and normal versions. If - // kind is not NORMAL, then the other fields are ignored. - VersionKind kind = 4; -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/provenance/provenance.proto b/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/provenance/provenance.proto deleted file mode 100644 index 3d334284..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/provenance/provenance.proto +++ /dev/null @@ -1,164 +0,0 @@ -// Copyright 2018 The Grafeas Authors. All rights reserved. -// -// 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. - -syntax = "proto3"; - -package grafeas.v1beta1.provenance; - -import "google/devtools/containeranalysis/v1beta1/source/source.proto"; -import "google/protobuf/timestamp.proto"; - -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1/provenance;provenance"; -option java_multiple_files = true; -option java_package = "io.grafeas.v1beta1.provenance"; -option objc_class_prefix = "GRA"; - -// Provenance of a build. Contains all information needed to verify the full -// details about the build from source to completion. -message BuildProvenance { - // Unique identifier of the build. - string id = 1; - - // ID of the project. - string project_id = 2; - - // Commands requested by the build. - repeated Command commands = 3; - - // Output of the build. - repeated Artifact built_artifacts = 4; - - // Time at which the build was created. - google.protobuf.Timestamp create_time = 5; - - // Time at which execution of the build was started. - google.protobuf.Timestamp start_time = 6; - - // Time at which execution of the build was finished. - google.protobuf.Timestamp end_time = 7; - - // E-mail address of the user who initiated this build. Note that this was the - // user's e-mail address at the time the build was initiated; this address may - // not represent the same end-user for all time. - string creator = 8; - - // URI where any logs for this provenance were written. - string logs_uri = 9; - - // Details of the Source input to the build. - Source source_provenance = 10; - - // Trigger identifier if the build was triggered automatically; empty if not. - string trigger_id = 11; - - // Special options applied to this build. This is a catch-all field where - // build providers can enter any desired additional details. - map build_options = 12; - - // Version string of the builder at the time this build was executed. - string builder_version = 13; - - // next_id = 14 -} - -// Source describes the location of the source used for the build. -message Source { - // If provided, the input binary artifacts for the build came from this - // location. - string artifact_storage_source_uri = 1; - - // Hash(es) of the build source, which can be used to verify that the original - // source integrity was maintained in the build. - // - // The keys to this map are file paths used as build source and the values - // contain the hash values for those files. - // - // If the build source came in a single package such as a gzipped tarfile - // (.tar.gz), the FileHash will be for the single path to that file. - map file_hashes = 2; - - // If provided, the source code used for the build came from this location. - grafeas.v1beta1.source.SourceContext context = 3; - - // If provided, some of the source code used for the build may be found in - // these locations, in the case where the source repository had multiple - // remotes or submodules. This list will not include the context specified in - // the context field. - repeated grafeas.v1beta1.source.SourceContext additional_contexts = 4; -} - -// Container message for hashes of byte content of files, used in Source -// messages to verify integrity of source input to the build. -message FileHashes { - // Collection of file hashes. - repeated Hash file_hash = 1; -} - -// Container message for hash values. -message Hash { - // Specifies the hash algorithm, if any. - enum HashType { - // Unknown. - HASH_TYPE_UNSPECIFIED = 0; - // A SHA-256 hash. - SHA256 = 1; - } - - // The type of hash that was performed. - HashType type = 1; - // The hash value. - bytes value = 2; -} - -// Command describes a step performed as part of the build pipeline. -message Command { - // Name of the command, as presented on the command line, or if the command is - // packaged as a Docker container, as presented to `docker pull`. - string name = 1; - - // Environment variables set before running this command. - repeated string env = 2; - - // Command-line arguments used when executing this command. - repeated string args = 3; - - // Working directory (relative to project source root) used when running this - // command. - string dir = 4; - - // Optional unique identifier for this command, used in wait_for to reference - // this command as a dependency. - string id = 5; - - // The ID(s) of the command(s) that this command depends on. - repeated string wait_for = 6; -} - -// Artifact describes a build product. -message Artifact { - // Hash or checksum value of a binary, or Docker Registry 2.0 digest of a - // container. - string checksum = 1; - - // Artifact ID, if any; for container images, this will be a URL by digest - // like `gcr.io/projectID/imagename@sha256:123456`. - string id = 2; - - // Related artifact names. This may be the path to a binary or jar file, or in - // the case of a container build, the name used to push the container image to - // Google Container Registry, as presented to `docker push`. Note that a - // single Artifact ID can have multiple names, for example if two tags are - // applied to one image. - repeated string names = 3; -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/source/source.proto b/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/source/source.proto deleted file mode 100644 index 01be060c..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/source/source.proto +++ /dev/null @@ -1,134 +0,0 @@ -// Copyright 2018 The Grafeas Authors. All rights reserved. -// -// 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. - -syntax = "proto3"; - -package grafeas.v1beta1.source; - -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1/source;source"; -option java_multiple_files = true; -option java_package = "io.grafeas.v1beta1.source"; -option objc_class_prefix = "GRA"; - -// A SourceContext is a reference to a tree of files. A SourceContext together -// with a path point to a unique revision of a single file or directory. -message SourceContext { - // A SourceContext can refer any one of the following types of repositories. - oneof context { - // A SourceContext referring to a revision in a Google Cloud Source Repo. - CloudRepoSourceContext cloud_repo = 1; - - // A SourceContext referring to a Gerrit project. - GerritSourceContext gerrit = 2; - - // A SourceContext referring to any third party Git repo (e.g., GitHub). - GitSourceContext git = 3; - } - - // Labels with user defined metadata. - map labels = 4; -} - -// An alias to a repo revision. -message AliasContext { - // The type of an alias. - enum Kind { - // Unknown. - KIND_UNSPECIFIED = 0; - // Git tag. - FIXED = 1; - // Git branch. - MOVABLE = 2; - // Used to specify non-standard aliases. For example, if a Git repo has a - // ref named "refs/foo/bar". - OTHER = 4; - } - - // The alias kind. - Kind kind = 1; - - // The alias name. - string name = 2; -} - -// A CloudRepoSourceContext denotes a particular revision in a Google Cloud -// Source Repo. -message CloudRepoSourceContext { - // The ID of the repo. - RepoId repo_id = 1; - - // A revision in a Cloud Repo can be identified by either its revision ID or - // its alias. - oneof revision { - // A revision ID. - string revision_id = 2; - - // An alias, which may be a branch or tag. - AliasContext alias_context = 3; - } -} - -// A SourceContext referring to a Gerrit project. -message GerritSourceContext { - // The URI of a running Gerrit instance. - string host_uri = 1; - - // The full project name within the host. Projects may be nested, so - // "project/subproject" is a valid project name. The "repo name" is the - // hostURI/project. - string gerrit_project = 2; - - // A revision in a Gerrit project can be identified by either its revision ID - // or its alias. - oneof revision { - // A revision (commit) ID. - string revision_id = 3; - - // An alias, which may be a branch or tag. - AliasContext alias_context = 4; - } -} - -// A GitSourceContext denotes a particular revision in a third party Git -// repository (e.g., GitHub). -message GitSourceContext { - // Git repository URL. - string url = 1; - - // Git commit hash. - string revision_id = 2; -} - -// A unique identifier for a Cloud Repo. -message RepoId { - // A cloud repo can be identified by either its project ID and repository name - // combination, or its globally unique identifier. - oneof id { - // A combination of a project ID and a repo name. - ProjectRepoId project_repo_id = 1; - - // A server-assigned, globally unique identifier. - string uid = 2; - } -} - -// Selects a repo using a Google Cloud Platform project ID (e.g., -// winged-cargo-31) and a repo name within that project. -message ProjectRepoId { - // The ID of the project. - string project_id = 1; - - // The name of the repo. Leave empty for the default repo. - string repo_name = 2; -} diff --git a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto b/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto deleted file mode 100644 index aef35c4e..00000000 --- a/proto-google-cloud-containeranalysis-v1beta1/src/main/proto/google/devtools/containeranalysis/v1beta1/vulnerability/vulnerability.proto +++ /dev/null @@ -1,145 +0,0 @@ -// Copyright 2018 The Grafeas Authors. All rights reserved. -// -// 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. - -syntax = "proto3"; - -package grafeas.v1beta1.vulnerability; - -import "google/devtools/containeranalysis/v1beta1/common/common.proto"; -import "google/devtools/containeranalysis/v1beta1/package/package.proto"; - -option go_package = "google.golang.org/genproto/googleapis/devtools/containeranalysis/v1beta1/vulnerability;vulnerability"; -option java_multiple_files = true; -option java_package = "io.grafeas.v1beta1.vulnerability"; -option objc_class_prefix = "GRA"; - -// Note provider-assigned severity/impact ranking. -enum Severity { - // Unknown. - SEVERITY_UNSPECIFIED = 0; - // Minimal severity. - MINIMAL = 1; - // Low severity. - LOW = 2; - // Medium severity. - MEDIUM = 3; - // High severity. - HIGH = 4; - // Critical severity. - CRITICAL = 5; -} - -// Vulnerability provides metadata about a security vulnerability. -message Vulnerability { - // The CVSS score for this vulnerability. - float cvss_score = 1; - - // Note provider assigned impact of the vulnerability. - Severity severity = 2; - - // All information about the package to specifically identify this - // vulnerability. One entry per (version range and cpe_uri) the package - // vulnerability has manifested in. - repeated Detail details = 3; - - // Identifies all occurrences of this vulnerability in the package for a - // specific distro/location. For example: glibc in - // cpe:/o:debian:debian_linux:8 for versions 2.1 - 2.2 - message Detail { - // The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) in - // which the vulnerability manifests. Examples include distro or storage - // location for vulnerable jar. - string cpe_uri = 1; - - // The name of the package where the vulnerability was found. - string package = 2; - - // The min version of the package in which the vulnerability exists. - grafeas.v1beta1.package.Version min_affected_version = 3; - - // The max version of the package in which the vulnerability exists. - grafeas.v1beta1.package.Version max_affected_version = 4; - - // The severity (eg: distro assigned severity) for this vulnerability. - string severity_name = 5; - - // A vendor-specific description of this note. - string description = 6; - - // The fix for this specific package version. - VulnerabilityLocation fixed_location = 7; - - // The type of package; whether native or non native(ruby gems, node.js - // packages etc). - string package_type = 8; - - // Whether this detail is obsolete. Occurrences are expected not to point to - // obsolete details. - bool is_obsolete = 9; - } -} - -// Details of a vulnerability occurrence. -message Details { - // The type of package; whether native or non native(ruby gems, node.js - // packages etc) - string type = 1; - - // Output only. The note provider assigned Severity of the vulnerability. - Severity severity = 2; - - // Output only. The CVSS score of this vulnerability. CVSS score is on a - // scale of 0-10 where 0 indicates low severity and 10 indicates high - // severity. - float cvss_score = 3; - - // The set of affected locations and their fixes (if available) within the - // associated resource. - repeated PackageIssue package_issue = 4; - - // Output only. A one sentence description of this vulnerability. - string short_description = 5; - - // Output only. A detailed description of this vulnerability. - string long_description = 6; - - // Output only. URLs related to this vulnerability. - repeated grafeas.v1beta1.RelatedUrl related_urls = 7; -} - -// This message wraps a location affected by a vulnerability and its -// associated fix (if one is available). -message PackageIssue { - // The location of the vulnerability. - VulnerabilityLocation affected_location = 1; - - // The location of the available fix for vulnerability. - VulnerabilityLocation fixed_location = 2; - - // The severity (e.g., distro assigned severity) for this vulnerability. - string severity_name = 3; -} - -// The location of the vulnerability. -message VulnerabilityLocation { - // The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) - // format. Examples include distro or storage location for vulnerable jar. - string cpe_uri = 1; - - // The package being described. - string package = 2; - - // The version of the package being described. - grafeas.v1beta1.package.Version version = 3; -} diff --git a/renovate.json b/renovate.json new file mode 100644 index 00000000..99810470 --- /dev/null +++ b/renovate.json @@ -0,0 +1,27 @@ +{ + "extends": [ + "config:base" + ], + "ignoreDeps": [], + "packageRules": [ + { + "managers": ["maven"], + "packageNames": ["com.google.guava:guava*"], + "versionScheme": "docker" + }, + { + "packagePatterns": ["^io.grpc:grpc-"], + "groupName": "gRPC packages" + }, + { + "packagePatterns": ["^com.google.protobuf:protobuf-"], + "groupName": "Protobuf packages" + }, + { + "packagePatterns": ["^io.opencensus:opencensus-"], + "groupName": "OpenCensus packages" + } + ], + "semanticCommits": true, + "semanticCommitType": "deps" +} diff --git a/google-cloud-container/synth.metadata b/synth.metadata similarity index 100% rename from google-cloud-container/synth.metadata rename to synth.metadata diff --git a/google-cloud-container/synth.py b/synth.py similarity index 65% rename from google-cloud-container/synth.py rename to synth.py index 9912e1b8..1b35d41a 100644 --- a/google-cloud-container/synth.py +++ b/synth.py @@ -31,10 +31,20 @@ config_path=config_pattern.format(version=version), artman_output_name='') - s.copy(library / f'gapic-google-cloud-{service}-{version}/src', 'src') - s.copy(library / f'grpc-google-cloud-{service}-{version}/src', f'../../google-api-grpc/grpc-google-cloud-{service}-{version}/src') - s.copy(library / f'proto-google-cloud-{service}-{version}/src', f'../../google-api-grpc/proto-google-cloud-{service}-{version}/src') + package_name = f'com.google.cloud.{service}.{version}' + java.fix_proto_headers(library / f'proto-google-cloud-{service}-{version}') + java.fix_grpc_headers(library / f'grpc-google-cloud-{service}-{version}', package_name) - java.format_code('./src') - java.format_code(f'../../google-api-grpc/grpc-google-cloud-{service}-{version}/src') - java.format_code(f'../../google-api-grpc/proto-google-cloud-{service}-{version}/src') + s.copy(library / f'gapic-google-cloud-{service}-{version}/src', f'google-cloud-{service}/src') + s.copy(library / f'grpc-google-cloud-{service}-{version}/src', f'grpc-google-cloud-{service}-{version}/src') + s.copy(library / f'proto-google-cloud-{service}-{version}/src', f'proto-google-cloud-{service}-{version}/src') + + java.format_code(f'google-cloud-{service}/src') + java.format_code(f'grpc-google-cloud-{service}-{version}/src') + java.format_code(f'proto-google-cloud-{service}-{version}/src') + +common_templates = gcp.CommonTemplates() +templates = common_templates.java_library() +s.copy(templates, excludes=[ + 'README.md', +]) \ No newline at end of file diff --git a/versions.txt b/versions.txt new file mode 100644 index 00000000..560ef27b --- /dev/null +++ b/versions.txt @@ -0,0 +1,11 @@ +# Format: +# module:released-version:current-version + +proto-google-cloud-containeranalysis-v1:0.82.0:0.82.0 +proto-google-cloud-container-v1:0.82.0:0.82.0 +proto-google-cloud-containeranalysis-v1beta1:0.82.0:0.82.0 +grpc-google-cloud-containeranalysis-v1beta1:0.82.0:0.82.0 +grpc-google-cloud-container-v1:0.82.0:0.82.0 +grpc-google-cloud-containeranalysis-v1:0.82.0:0.82.0 +google-cloud-containeranalysis:0.117.0-beta:0.117.0-beta +google-cloud-container:0.117.0-beta:0.117.0-beta \ No newline at end of file